Changeset 4763 in subversion
- Timestamp:
- May 13, 2011 1:31:09 PM (2 years ago)
- Location:
- branches/release-0.5
- Files:
-
- 12 edited
-
CHANGELOG (modified) (1 diff)
-
plugins/new_user_dialog/new_user_dialog.php (modified) (2 diffs)
-
plugins/new_user_dialog/package.xml (modified) (3 diffs)
-
program/include/main.inc (modified) (12 diffs)
-
program/include/rcube_imap.php (modified) (5 diffs)
-
program/include/rcube_template.php (modified) (10 diffs)
-
program/js/app.js (modified) (7 diffs)
-
program/js/list.js (modified) (4 diffs)
-
program/localization/pl_PL/labels.inc (modified) (1 diff)
-
skins/default/ie6hacks.css (modified) (1 diff)
-
skins/default/iehacks.css (modified) (2 diffs)
-
skins/default/mail.css (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/release-0.5/CHANGELOG
r4729 r4763 2 2 =========================== 3 3 4 - Fix some CSS issues in Settings for Internet Explorer 5 - Fixed handling of folder with name "0" in folder selector 6 - Fix bug where messages were deleted instead moved to trash folder after Shift key was used (#1487902) 4 7 - Fix relative URLs handling according to a <base> in HTML (#1487889) 5 8 - Fix handling of top-level domains with more than 5 chars or unicode chars (#1487883) -
branches/release-0.5/plugins/new_user_dialog/new_user_dialog.php
r4301 r4763 63 63 'type' => 'text', 64 64 'name' => '_email', 65 'value' => idn_to_utf8($identity['email']),65 'value' => rcube_idn_to_utf8($identity['email']), 66 66 'disabled' => ($identities_level == 1 || $identities_level == 3) 67 67 ))); … … 114 114 $save_data['email'] = $identity['email']; 115 115 else 116 $save_data['email'] = idn_to_ascii($save_data['email']);116 $save_data['email'] = rcube_idn_to_ascii($save_data['email']); 117 117 118 118 // save data if not empty -
branches/release-0.5/plugins/new_user_dialog/package.xml
r4301 r4763 14 14 <active>yes</active> 15 15 </lead> 16 <date>201 0-12-02</date>17 <time>1 2:00:00</time>16 <date>2011-05-12</date> 17 <time>10:00</time> 18 18 <version> 19 <release>1. 3</release>19 <release>1.4</release> 20 20 <api>1.0</api> 21 21 </version> … … 26 26 <license uri="http://www.gnu.org/licenses/gpl-2.0.html">GNU GPLv2</license> 27 27 <notes> 28 - Added setting of focus on name input 29 - Added gl_ES translation 28 - Fixed IDNA encoding/decoding of e-mail addresses (#1487909) 30 29 </notes> 31 30 <contents> … … 120 119 </notes> 121 120 </release> 121 <release> 122 <date>2010-12-02</date> 123 <time>12:00:00</time> 124 <version> 125 <release>1.3</release> 126 <api>1.0</api> 127 </version> 128 <stability> 129 <release>stable</release> 130 <api>stable</api> 131 </stability> 132 <license uri="http://www.gnu.org/licenses/gpl-2.0.html">GNU GPLv2</license> 133 <notes> 134 - Added setting of focus on name input 135 - Added gl_ES translation 136 </notes> 137 </release> 122 138 </changelog> 123 139 </package> -
branches/release-0.5/program/include/main.inc
r4568 r4763 1290 1290 global $RCMAIL; 1291 1291 static $a_mailboxes; 1292 1292 1293 1293 $attrib += array('maxlength' => 100, 'realnames' => false); 1294 1294 1295 1295 // add some labels to client 1296 1296 $RCMAIL->output->add_label('purgefolderconfirm', 'deletemessagesconfirm'); 1297 1297 1298 1298 $type = $attrib['type'] ? $attrib['type'] : 'ul'; 1299 1299 unset($attrib['type']); … … 1304 1304 // get mailbox list 1305 1305 $mbox_name = $RCMAIL->imap->get_mailbox_name(); 1306 1306 1307 1307 // build the folders tree 1308 1308 if (empty($a_mailboxes)) { … … 1319 1319 $hook = $RCMAIL->plugins->exec_hook('render_mailboxlist', array('list' => $a_mailboxes, 'delimiter' => $delimiter)); 1320 1320 1321 if ($type =='select') {1321 if ($type == 'select') { 1322 1322 $select = new html_select($attrib); 1323 1323 1324 1324 // add no-selection option 1325 1325 if ($attrib['noselection']) 1326 $select->add(rcube_label($attrib['noselection']), ' 0');1327 1326 $select->add(rcube_label($attrib['noselection']), ''); 1327 1328 1328 rcmail_render_folder_tree_select($hook['list'], $mbox_name, $attrib['maxlength'], $select, $attrib['realnames']); 1329 1329 $out = $select->show(); … … 1332 1332 $js_mailboxlist = array(); 1333 1333 $out = html::tag('ul', $attrib, rcmail_render_folder_tree_html($hook['list'], $mbox_name, $js_mailboxlist, $attrib), html::$common_attrib); 1334 1334 1335 1335 $RCMAIL->output->add_gui_object('mailboxlist', $attrib['id']); 1336 1336 $RCMAIL->output->set_env('mailboxes', $js_mailboxlist); … … 1351 1351 { 1352 1352 global $RCMAIL; 1353 1353 1354 1354 $p += array('maxlength' => 100, 'realnames' => false); 1355 1355 $a_mailboxes = array(); … … 1424 1424 rcmail_build_folder_tree($arrFolders[$currentFolder]['folders'], $subFolders, $delm, $path.$delm); 1425 1425 } 1426 1426 1427 1427 1428 1428 /** … … 1434 1434 { 1435 1435 global $RCMAIL, $CONFIG; 1436 1436 1437 1437 $maxlength = intval($attrib['maxlength']); 1438 1438 $realnames = (bool)$attrib['realnames']; … … 1477 1477 else 1478 1478 $classes[] = '_'.asciiwords($folder_class ? $folder_class : strtolower($folder['id']), true); 1479 1479 1480 1480 $classes[] = $zebra_class; 1481 1481 1482 1482 if ($folder['id'] == $mbox_name) 1483 1483 $classes[] = 'selected'; … … 1485 1485 $collapsed = preg_match('/&'.rawurlencode($folder['id']).'&/', $RCMAIL->config->get('collapsed_folders')); 1486 1486 $unread = $msgcounts ? intval($msgcounts[$folder['id']]['UNSEEN']) : 0; 1487 1487 1488 1488 if ($folder['virtual']) 1489 1489 $classes[] = 'virtual'; … … 1509 1509 'onclick' => sprintf("%s.command('collapse-folder', '%s')", JS_OBJECT_NAME, $js_name) 1510 1510 ), ' ') : '')); 1511 1511 1512 1512 $jslist[$folder_id] = array('id' => $folder['id'], 'name' => $foldername, 'virtual' => $folder['virtual']); 1513 1513 1514 1514 if (!empty($folder['folders'])) { 1515 1515 $out .= html::tag('ul', array('style' => ($collapsed ? "display:none;" : null)), … … 1531 1531 */ 1532 1532 function rcmail_render_folder_tree_select(&$arrFolders, &$mbox_name, $maxlength, &$select, $realnames=false, $nestLevel=0) 1533 { 1534 $idx = 0; 1533 { 1535 1534 $out = ''; 1536 foreach ($arrFolders as $key=>$folder) 1537 {1535 1536 foreach ($arrFolders as $key=>$folder) { 1538 1537 if (!$realnames && ($folder_class = rcmail_folder_classname($folder['id']))) 1539 1538 $foldername = rcube_label($folder_class); 1540 else 1541 { 1539 else { 1542 1540 $foldername = $folder['name']; 1543 1541 1544 1542 // shorten the folder name to a given length 1545 1543 if ($maxlength && $maxlength>1) 1546 1544 $foldername = abbreviate_string($foldername, $maxlength); 1547 }1545 } 1548 1546 1549 1547 $select->add(str_repeat(' ', $nestLevel*4) . $foldername, $folder['id']); … … 1551 1549 if (!empty($folder['folders'])) 1552 1550 $out .= rcmail_render_folder_tree_select($folder['folders'], $mbox_name, $maxlength, $select, $realnames, $nestLevel+1); 1553 1554 $idx++; 1555 } 1551 } 1556 1552 1557 1553 return $out; 1558 }1554 } 1559 1555 1560 1556 -
branches/release-0.5/program/include/rcube_imap.php
r4643 r4763 3565 3565 } 3566 3566 else if ($this->get_capability('ANNOTATEMORE') || $this->get_capability('ANNOTATEMORE2')) { 3567 foreach ( $entries as $entry => $value) {3567 foreach ((array)$entries as $entry => $value) { 3568 3568 list($ent, $attr) = $this->md2annotate($entry); 3569 3569 $entries[$entry] = array($ent, $attr, $value); … … 3598 3598 } 3599 3599 else if ($this->get_capability('ANNOTATEMORE') || $this->get_capability('ANNOTATEMORE2')) { 3600 foreach ( $entries as $idx => $entry) {3600 foreach ((array)$entries as $idx => $entry) { 3601 3601 list($ent, $attr) = $this->md2annotate($entry); 3602 3602 $entries[$idx] = array($ent, $attr, NULL); … … 3627 3627 3628 3628 if ($this->get_capability('METADATA') || 3629 !strlen(($mailbox) && $this->get_capability('METADATA-SERVER'))3629 (!strlen($mailbox) && $this->get_capability('METADATA-SERVER')) 3630 3630 ) { 3631 3631 return $this->conn->getMetadata($mailbox, $entries, $options); … … 3636 3636 3637 3637 // Convert entry names 3638 foreach ( $entries as $entry) {3638 foreach ((array)$entries as $entry) { 3639 3639 list($ent, $attr) = $this->md2annotate($entry); 3640 3640 $queries[$attr][] = $ent; … … 3657 3657 * entry-attrib names for older ANNOTATEMORE version. 3658 3658 * 3659 * @param string Entry name3659 * @param string $entry Entry name 3660 3660 * 3661 3661 * @return array Entry-attribute list, NULL if not supported (?) 3662 3662 */ 3663 private function md2annotate($ name)3663 private function md2annotate($entry) 3664 3664 { 3665 3665 if (substr($entry, 0, 7) == '/shared') { -
branches/release-0.5/program/include/rcube_template.php
r4666 r4763 114 114 } 115 115 116 117 116 /** 118 117 * Set page title variable … … 122 121 $this->pagetitle = $title; 123 122 } 124 125 123 126 124 /** … … 143 141 return $title; 144 142 } 145 146 143 147 144 /** … … 227 224 } 228 225 229 230 226 /** 231 227 * Add a localized label to the client environment … … 241 237 } 242 238 } 243 244 239 245 240 /** … … 263 258 } 264 259 265 266 260 /** 267 261 * Delete all stored env variables and commands … … 283 277 } 284 278 285 286 279 /** 287 280 * Redirect to a certain url … … 296 289 exit; 297 290 } 298 299 291 300 292 /** … … 362 354 363 355 /** 364 * Parse a specific skin template and deliver to stdout 365 * 366 * Either returns nothing, or exists hard (exit();) 356 * Parse a specific skin template and deliver to stdout (or return) 367 357 * 368 358 * @param string Template name 369 359 * @param boolean Exit script 370 * @return void 360 * @param boolean Don't write to stdout, return parsed content instead 361 * 371 362 * @link http://php.net/manual/en/function.exit.php 372 363 */ 373 private function parse($name = 'main', $exit= true)364 function parse($name = 'main', $exit = true, $write = true) 374 365 { 375 366 $skin_path = $this->config['skin_path']; … … 429 420 $hook = $this->app->plugins->exec_hook("render_page", array('template' => $realname, 'content' => $output)); 430 421 431 // add debug console432 if ($this->config['debug_level'] & 8) {433 $this->add_footer('<div id="console" style="position:absolute;top:5px;left:5px;width:405px;padding:2px;background:white;z-index:9000;">434 <a href="#toggle" onclick="con=$(\'#dbgconsole\');con[con.is(\':visible\')?\'hide\':\'show\']();return false">console</a>435 <textarea name="console" id="dbgconsole" rows="20" cols="40" wrap="off" style="display:none;width:400px;border:none;font-size:10px" spellcheck="false"></textarea></div>'436 );437 }438 439 422 $output = $this->parse_with_globals($hook['content']); 440 $this->write(trim($output)); 423 424 if ($write) { 425 // add debug console 426 if ($this->config['debug_level'] & 8) { 427 $this->add_footer('<div id="console" style="position:absolute;top:5px;left:5px;width:405px;padding:2px;background:white;z-index:9000;"> 428 <a href="#toggle" onclick="con=$(\'#dbgconsole\');con[con.is(\':visible\')?\'hide\':\'show\']();return false">console</a> 429 <textarea name="console" id="dbgconsole" rows="20" cols="40" wrap="off" style="display:none;width:400px;border:none;font-size:10px" spellcheck="false"></textarea></div>' 430 ); 431 } 432 $this->write(trim($output)); 433 } 434 else { 435 return $output; 436 } 437 441 438 if ($exit) { 442 439 exit; 443 440 } 444 441 } 445 446 442 447 443 /** -
branches/release-0.5/program/js/app.js
r4729 r4763 648 648 case 'delete': 649 649 // mail task 650 if (this.task =='mail')650 if (this.task == 'mail') 651 651 this.delete_messages(); 652 652 // addressbook task 653 else if (this.task =='addressbook')653 else if (this.task == 'addressbook') 654 654 this.delete_contacts(); 655 655 // user settings task 656 else if (this.task =='settings')656 else if (this.task == 'settings') 657 657 this.delete_identity(); 658 658 break; … … 1354 1354 this.doc_mouse_up = function(e) 1355 1355 { 1356 var model, list, li ;1357 1358 if ( this.message_list) {1359 if (!rcube_mouse_is_over(e, this.message_list.list.parentNode))1360 this.message_list.blur();1356 var model, list, li, id; 1357 1358 if (list = this.message_list) { 1359 if (!rcube_mouse_is_over(e, list.list.parentNode)) 1360 list.blur(); 1361 1361 else 1362 this.message_list.focus(); 1363 list = this.message_list; 1362 list.focus(); 1364 1363 model = this.env.mailboxes; 1365 1364 } 1366 else if ( this.contact_list) {1367 if (!rcube_mouse_is_over(e, this.contact_list.list.parentNode))1368 this.contact_list.blur();1365 else if (list = this.contact_list) { 1366 if (!rcube_mouse_is_over(e, list.list.parentNode)) 1367 list.blur(); 1369 1368 else 1370 this.contact_list.focus(); 1371 list = this.contact_list; 1369 list.focus(); 1372 1370 model = this.env.contactfolders; 1373 1371 } … … 1390 1388 // reset 'pressed' buttons 1391 1389 if (this.buttons_sel) { 1392 for ( varid in this.buttons_sel)1390 for (id in this.buttons_sel) 1393 1391 if (typeof id != 'function') 1394 1392 this.button_out(this.buttons_sel[id], id); … … 1489 1487 else if (list.key_pressed == 34) 1490 1488 this.command('nextpage'); 1491 else1492 list.shiftkey = false;1493 1489 }; 1494 1490 … … 2416 2412 this.delete_messages = function() 2417 2413 { 2418 var selection = this.message_list ? $.merge([], this.message_list.get_selection()) : []; 2414 var uid, i, len, trash = this.env.trash_mailbox, 2415 list = this.message_list, 2416 selection = list ? $.merge([], list.get_selection()) : []; 2419 2417 2420 2418 // exit if no mailbox specified or if selection is empty … … 2423 2421 2424 2422 // also select childs of collapsed rows 2425 for ( var uid,i=0, len=selection.length; i<len; i++) {2423 for (i=0, len=selection.length; i<len; i++) { 2426 2424 uid = selection[i]; 2427 if ( this.message_list.rows[uid].has_children && !this.message_list.rows[uid].expanded)2428 this.message_list.select_childs(uid);2425 if (list.rows[uid].has_children && !list.rows[uid].expanded) 2426 list.select_childs(uid); 2429 2427 } 2430 2428 … … 2435 2433 } 2436 2434 // if there isn't a defined trash mailbox or we are in it 2437 else if (!this.env.trash_mailbox || this.env.mailbox == this.env.trash_mailbox) 2435 // @TODO: we should check if defined trash mailbox exists 2436 else if (!trash || this.env.mailbox == trash) 2438 2437 this.permanently_remove_messages(); 2439 2438 // if there is a trash mailbox defined and we're not currently in it 2440 2439 else { 2441 2440 // if shift was pressed delete it immediately 2442 if ( this.message_list && this.message_list.shiftkey) {2441 if (list && list.shiftkey) { 2443 2442 if (confirm(this.get_label('deletemessagesconfirm'))) 2444 2443 this.permanently_remove_messages(); 2445 2444 } 2446 2445 else 2447 this.move_messages(t his.env.trash_mailbox);2446 this.move_messages(trash); 2448 2447 } 2449 2448 -
branches/release-0.5/program/js/list.js
r4666 r4763 102 102 { 103 103 // make references in internal array and set event handlers 104 if (row && String(row.id).match(/ rcmrow([a-z0-9\-_=\+\/]+)/i)) {104 if (row && String(row.id).match(/^rcmrow([a-z0-9\-_=\+\/]+)/i)) { 105 105 var self = this, 106 106 uid = RegExp.$1; … … 602 602 603 603 for (i=0, len=rows.length-1; i<len; i++) 604 if (rows[i].id && String(rows[i].id).match(/ rcmrow([a-z0-9\-_=\+\/]+)/i) && this.rows[RegExp.$1] != null)604 if (rows[i].id && String(rows[i].id).match(/^rcmrow([a-z0-9\-_=\+\/]+)/i) && this.rows[RegExp.$1] != null) 605 605 return RegExp.$1; 606 606 } … … 615 615 616 616 for (i=rows.length-1; i>=0; i--) 617 if (rows[i].id && String(rows[i].id).match(/ rcmrow([a-z0-9\-_=\+\/]+)/i) && this.rows[RegExp.$1] != null)617 if (rows[i].id && String(rows[i].id).match(/^rcmrow([a-z0-9\-_=\+\/]+)/i) && this.rows[RegExp.$1] != null) 618 618 return RegExp.$1; 619 619 } … … 989 989 this.key_pressed = keyCode; 990 990 this.triggerEvent('keypress'); 991 // reset shiftkey flag, we need it only for registered events 992 this.shiftkey = false; 991 993 992 994 if (this.key_pressed == this.BACKSPACE_KEY) -
branches/release-0.5/program/localization/pl_PL/labels.inc
r4362 r4763 410 410 $labels['contactproperties'] = 'WÅaÅciwoÅci'; 411 411 $labels['properties'] = 'WÅaÅciwoÅci'; 412 $labels['folderproperties'] = 'WÅÄ 413 ÅciwoÅci folderu'; 412 $labels['folderproperties'] = 'WÅaÅciwoÅci folderu'; 414 413 $labels['parentfolder'] = 'Folder nadrzÄdny'; 415 414 $labels['location'] = 'PoÅoÅŒenie'; -
branches/release-0.5/skins/default/ie6hacks.css
r4469 r4763 144 144 } 145 145 146 body.iframe .boxtitle 147 { 148 position: absolute; 149 } 150 151 #subscription-table 152 { 153 width: auto; 154 } -
branches/release-0.5/skins/default/iehacks.css
r4539 r4763 118 118 } 119 119 120 #subscription-table121 {122 width: auto;123 }124 125 120 #messagelist 126 121 { … … 182 177 183 178 #contacts-box, 184 #prefs-box 179 #prefs-box, 180 #folder-box 185 181 { 186 182 width: expression((parseInt(this.parentNode.offsetWidth)-555)+'px'); 183 overflow: hidden; 187 184 } 188 185 -
branches/release-0.5/skins/default/mail.css
r4509 r4763 150 150 } 151 151 152 #messagetoolbar select.mboxlist option[value=" 0"]152 #messagetoolbar select.mboxlist option[value=""] 153 153 { 154 154 padding-left: 2px;
Note: See TracChangeset
for help on using the changeset viewer.
