diff options
author | Sarven Capadisli <csarven@controlyourself.ca> | 2009-02-06 06:28:14 +0000 |
---|---|---|
committer | Sarven Capadisli <csarven@controlyourself.ca> | 2009-02-06 06:28:14 +0000 |
commit | a6cf3a2fb3b150cba06143f6a744a49a0cf91e83 (patch) | |
tree | 98c6ad8d94f578602e52a4736b1e5efa62d1c3db /actions/avatarsettings.php | |
parent | ac23321a4039eeffe2d7fedf2a45504b97b49b70 (diff) | |
parent | d3ff8bfec63db1648e6336924030255904a6eeb5 (diff) |
Merge branch '0.7.x' of git@gitorious.org:laconica/dev into 0.7.x
Diffstat (limited to 'actions/avatarsettings.php')
-rw-r--r-- | actions/avatarsettings.php | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/actions/avatarsettings.php b/actions/avatarsettings.php index 68c6ce701..3f50ca24c 100644 --- a/actions/avatarsettings.php +++ b/actions/avatarsettings.php @@ -75,7 +75,7 @@ class AvatarsettingsAction extends AccountSettingsAction function getInstructions() { - return _('You can upload your personal avatar.'); + return sprintf(_('You can upload your personal avatar. The maximum file size is %s.'), ImageFile::maxFileSize()); } /** @@ -155,7 +155,7 @@ class AvatarsettingsAction extends AccountSettingsAction $this->element('input', array('name' => 'MAX_FILE_SIZE', 'type' => 'hidden', 'id' => 'MAX_FILE_SIZE', - 'value' => MAX_AVATAR_SIZE)); + 'value' => ImageFile::maxFileSizeInt())); $this->elementEnd('li'); $this->elementEnd('ul'); @@ -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)); + } } } |