[prev in list] [next in list] [prev in thread] [next in thread]
List: squirrelmail-cvs
Subject: [SM-CVS] CVS: squirrelmail/functions page_header.php,1.197,1.198
From: Paul Lesneiwski <pdontthink () users ! sourceforge ! net>
Date: 2005-09-24 0:25:02
Message-ID: E1EIxqg-00019v-Mj () sc8-pr-cvs1 ! sourceforge ! net
[Download RAW message or body]
Update of /cvsroot/squirrelmail/squirrelmail/functions
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4443/functions
Modified Files:
page_header.php
Log Message:
Fixed/restored reply focus functionality
Index: page_header.php
===================================================================
RCS file: /cvsroot/squirrelmail/squirrelmail/functions/page_header.php,v
retrieving revision 1.197
retrieving revision 1.198
diff -u -w -r1.197 -r1.198
--- page_header.php 18 Sep 2005 10:25:49 -0000 1.197
+++ page_header.php 24 Sep 2005 00:25:00 -0000 1.198
@@ -142,10 +142,25 @@
* @return void
*/
-function displayPageHeader($color, $mailbox, $sHeaderJs='', $sBodyTagJs = 'onload="checkForm();"') {
- global $hide_sm_attributions, $frame_top,
+function displayPageHeader($color, $mailbox, $sHeaderJs='', $sBodyTagJs = '') {
+
+ global $reply_focus, $hide_sm_attributions, $frame_top,
$provider_name, $provider_uri, $startMessage,
- $javascript_on;
+ $javascript_on, $action;
+
+ if (empty($sBodyTagJs)) {
+ if (strpos($action, 'reply') !== FALSE && $reply_focus) {
+ if ($reply_focus == 'select')
+ $sBodyTagJs = 'onload="checkForm(\'select\');"';
+ else if ($reply_focus == 'focus')
+ $sBodyTagJs = 'onload="checkForm(\'focus\');"';
+ else if ($reply_focus != 'none')
+ $sBodyTagJs = 'onload="checkForm();"';
+ }
+ else
+ $sBodyTagJs = 'onload="checkForm();"';
+ }
+
sqgetGlobalVar('delimiter', $delimiter, SQ_SESSION );
@@ -238,8 +253,24 @@
* @param string sBodyTagJs js events to be inserted in the body tag
* @return void
*/
-function compose_Header($color, $mailbox, $sHeaderJs='', $sBodyTagJs = 'onload="checkForm();"') {
- global $javascript_on;
+function compose_Header($color, $mailbox, $sHeaderJs='', $sBodyTagJs = '') {
+
+ global $reply_focus, $javascript_on, $action;
+
+ if (empty($sBodyTagJs)) {
+ if (strpos($action, 'reply') !== FALSE && $reply_focus) {
+ if ($reply_focus == 'select')
+ $sBodyTagJs = 'onload="checkForm(\'select\');"';
+ else if ($reply_focus == 'focus')
+ $sBodyTagJs = 'onload="checkForm(\'focus\');"';
+ else if ($reply_focus != 'none')
+ $sBodyTagJs = 'onload="checkForm();"';
+ }
+ else
+ $sBodyTagJs = 'onload="checkForm();"';
+ }
+
+
/*
* Locate the first displayable form element (only when JavaScript on)
*/
-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php
--
squirrelmail-cvs mailing list
List Address: squirrelmail-cvs@lists.sourceforge.net
List Info: https://lists.sourceforge.net/lists/listinfo/squirrelmail-cvs
http://squirrelmail.org/cvs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic