alecpl
2011-11-20 b1867b8f198374d26e1bfdfeaeac16971608b551
program/include/main.inc
@@ -1281,11 +1281,6 @@
  $path .= $prefix.$currentFolder;
  if (!isset($arrFolders[$currentFolder])) {
    // Check \Noselect attribute (if attributes are in cache)
    if (!$virtual && ($attrs = $RCMAIL->imap->mailbox_attributes($path))) {
      $virtual = in_array('\\Noselect', $attrs);
    }
    $arrFolders[$currentFolder] = array(
      'id' => $path,
      'name' => rcube_charset_convert($currentFolder, 'UTF7-IMAP'),
@@ -1594,7 +1589,7 @@
 */
function rcube_html_editor($mode='')
{
  global $RCMAIL, $CONFIG;
  global $RCMAIL;
  $hook = $RCMAIL->plugins->exec_hook('html_editor', array('mode' => $mode));
@@ -1603,8 +1598,11 @@
  $lang = strtolower($_SESSION['language']);
  // TinyMCE uses 'tw' for zh_TW (which is wrong, because tw is a code of Twi language)
  $lang = ($lang == 'zh_tw') ? 'tw' : substr($lang, 0, 2);
  // TinyMCE uses two-letter lang codes, with exception of Chinese
  if (strpos($lang, 'zh_') === 0)
    $lang = str_replace('_', '-', $lang);
  else
    $lang = substr($lang, 0, 2);
  if (!file_exists(INSTALL_PATH . 'program/js/tiny_mce/langs/'.$lang.'.js'))
    $lang = 'en';
@@ -1616,8 +1614,8 @@
        'mode'       => $mode,
        'skin_path'  => '$__skin_path',
        'lang'       => $lang,
        'spellcheck' => intval($CONFIG['enable_spellcheck']),
        'spelldict'  => intval($CONFIG['spellcheck_dictionary']),
        'spellcheck' => intval($RCMAIL->config->get('enable_spellcheck')),
        'spelldict'  => intval($RCMAIL->config->get('spellcheck_dictionary')),
    ))), 'foot');
}