Author: ralfbecker
Date: Tue Nov 3 11:19:48 2009
New Revision: 28236
URL: http://www.egroupware.org/viewvc/egroupware?rev=28236&view=rev Log:
"- fixed wrong languague in notifications, because translation->userlang was changed to a static class-var
- fixed sometimes wrong prefs for to notified user were used (because more then one user got notified)"
// restore the user enviroment
if ($this->save_prefs) $GLOBALS['egw_info']['user'] = $this->save_prefs; unset($this->save_prefs);
- if ($GLOBALS['egw_info']['user']['preferences']['common']['lang'] != $GLOBALS['egw']->translation->userlang)
- {
- $GLOBALS['egw']->translation->init();
+ if ($GLOBALS['egw_info']['user']['preferences']['common']['lang'] != translation::$userlang)
+ {
+ translation::init();
}
return !count($this->errors);
}
@@ -472,11 +472,9 @@
if (is_numeric($user_or_lang)) // user --> read everything from his prefs
{
- if ($user_or_lang != $this->user)
- {
- $GLOBALS['egw']->preferences->preferences($user_or_lang);
- $GLOBALS['egw_info']['user']['preferences'] = $GLOBALS['egw']->preferences->read_repository();
- }
+ $GLOBALS['egw']->preferences->__construct($user_or_lang);
+ $GLOBALS['egw_info']['user']['preferences'] = $GLOBALS['egw']->preferences->read_repository();
+
if ($check && $this->check2pref) $check = $this->check2pref[$check];
if ($check && !$GLOBALS['egw_info']['user']['preferences'][$this->app][$check])
{
@@ -497,9 +495,9 @@
$GLOBALS['egw_info']['user']['preferences'] = $GLOBALS['egw']->preferences->default;
$GLOBALS['egw_info']['user']['preferences']['common']['lang'] = $user_or_lang;
}
- if ($lang != $GLOBALS['egw']->translation->userlang) // load the right language if needed
- {
- $GLOBALS['egw']->translation->init();
+ if ($lang != translation::$userlang) // load the right language if needed
+ {
+ translation::init();
}
// send over notification_app
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference _______________________________________________
eGroupWare-cvs mailing list
eGroupWare-cvs@... https://lists.sourceforge.net/lists/listinfo/egroupware-cvs