summaryrefslogtreecommitdiff
path: root/actions
diff options
context:
space:
mode:
authorEvan Prodromou <evan@controlyourself.ca>2009-02-05 16:34:38 -0500
committerEvan Prodromou <evan@controlyourself.ca>2009-02-05 16:34:38 -0500
commit444c7944809544928e05bd71479f6551acc98fc4 (patch)
treef60b27e195786358d26356566cdb4f6381c384c8 /actions
parent99d520b351cdcfd93901732228d3be3d9e0a442b (diff)
Don't show stretchy-box on avatar if not cropping
Diffstat (limited to 'actions')
-rw-r--r--actions/avatarsettings.php14
1 files changed, 8 insertions, 6 deletions
diff --git a/actions/avatarsettings.php b/actions/avatarsettings.php
index 5c702ecc0..3f50ca24c 100644
--- a/actions/avatarsettings.php
+++ b/actions/avatarsettings.php
@@ -373,12 +373,14 @@ class AvatarsettingsAction extends AccountSettingsAction
{
parent::showScripts();
- $jcropPack = common_path('js/jcrop/jquery.Jcrop.pack.js');
- $jcropGo = common_path('js/jcrop/jquery.Jcrop.go.js');
+ if ($this->mode == 'crop') {
+ $jcropPack = common_path('js/jcrop/jquery.Jcrop.pack.js');
+ $jcropGo = common_path('js/jcrop/jquery.Jcrop.go.js');
- $this->element('script', array('type' => 'text/javascript',
- 'src' => $jcropPack));
- $this->element('script', array('type' => 'text/javascript',
- 'src' => $jcropGo));
+ $this->element('script', array('type' => 'text/javascript',
+ 'src' => $jcropPack));
+ $this->element('script', array('type' => 'text/javascript',
+ 'src' => $jcropGo));
+ }
}
}