Index: trunk/extensions/OnlineStatusBar/OnlineStatusBarHooks.php |
— | — | @@ -112,7 +112,7 @@ |
113 | 113 | * @return bool |
114 | 114 | */ |
115 | 115 | public static function preferencesHook( User $user, array &$preferences ) { |
116 | | - global $wgOnlineStatusBarDefaultOnline, $wgOnlineStatusBarDefaultEnabled, $wgOnlineStatusBar_AwayTime, $wgOnlineStatusBarModes; |
| 116 | + global $wgOnlineStatusBarDefaultOnline, $wgOnlineStatusBarDefaultEnabled, $wgOnlineStatusBar_AwayTime, $wgOnlineStatusBar_LogoutTime, $wgOnlineStatusBarModes; |
117 | 117 | $preferences['OnlineStatusBar_active'] = array( 'type' => 'toggle', 'label-message' => 'onlinestatusbar-used', 'section' => 'misc/onlinestatus' ); |
118 | 118 | $preferences['OnlineStatusBar_hide'] = array( 'type' => 'toggle', 'label-message' => 'onlinestatusbar-hide', 'section' => 'misc/onlinestatus' ); |
119 | 119 | $preferences['OnlineStatusBar_away'] = array( 'type' => 'toggle', 'label-message' => 'onlinestatusbar-away', 'section' => 'misc/onlinestatus' ); |
— | — | @@ -125,7 +125,7 @@ |
126 | 126 | wfMessage( 'onlinestatusbar-status-hidden' )->escaped() => 'hidden' |
127 | 127 | ), |
128 | 128 | ); |
129 | | - $preferences['OnlineStatusBar_awaytime'] = array( 'type' => 'text', 'label-message' => 'onlinestatusbar-away-time', 'section' => 'misc/onlinestatus' ); |
| 129 | + $preferences['OnlineStatusBar_awaytime'] = array( 'min' => 2, 'max' => $wgOnlineStatusBar_LogoutTime, 'type' => 'int', 'label-message' => 'onlinestatusbar-away-time', 'section' => 'misc/onlinestatus' ); |
130 | 130 | return true; |
131 | 131 | } |
132 | 132 | |