From 087c7dc5d2e58e4aa99f1ffdb9b8f01c6121ce1d Mon Sep 17 00:00:00 2001 From: alecpl <alec@alec.pl> Date: Tue, 29 Jun 2010 15:27:26 -0400 Subject: [PATCH] - Improved compose screen: resizable body and attachments list, vertical splitter, options menu - Removed productname/version element, changed footer size to 20px --- program/js/googiespell.js | 42 +++++++++++++++++++++++------------------- 1 files changed, 23 insertions(+), 19 deletions(-) diff --git a/program/js/googiespell.js b/program/js/googiespell.js index 51acb73..a9879f3 100644 --- a/program/js/googiespell.js +++ b/program/js/googiespell.js @@ -767,6 +767,27 @@ $(this.switch_lan_pic).removeClass().addClass('googie_lang_3d_on'); }; +this.showLangWindow = function(elm) { + if (this.show_menu_observer) + this.show_menu_observer(this); + + this.createLangWindow(); + $('body').append(this.language_window); + + var pos = $(elm).offset(), + height = $(elm).height(), + width = $(elm).width(), + h = $(this.language_window).height(), + pageheight = $(document).height(), + left = this.change_lang_pic_placement == 'right' ? + pos.left - 100 + width : pos.left + width, + top = pos.top + h < pageheight ? pos.top + height : pos.top - h - 4; + + $(this.language_window).css({'visibility': 'visible', 'top' : top+'px','left' : left+'px'}); + + this.highlightCurSel(); +}; + this.deHighlightCurSel = function() { $(this.lang_cur_elm).removeClass().addClass('googie_list_onout'); }; @@ -776,30 +797,13 @@ GOOGIE_CUR_LANG = GOOGIE_DEFAULT_LANG; for (var i=0; i < this.lang_elms.length; i++) { if ($(this.lang_elms[i]).attr('googieId') == GOOGIE_CUR_LANG) { - this.lang_elms[i].className = "googie_list_selected"; + this.lang_elms[i].className = 'googie_list_selected'; this.lang_cur_elm = this.lang_elms[i]; } else { - this.lang_elms[i].className = "googie_list_onout"; + this.lang_elms[i].className = 'googie_list_onout'; } } -}; - -this.showLangWindow = function(elm) { - if (this.show_menu_observer) - this.show_menu_observer(this); - - this.createLangWindow(); - $('body').append(this.language_window); - - var pos = $(elm).offset(), - top = pos.top + $(elm).height(), - left = this.change_lang_pic_placement == 'right' ? - pos.left - 100 + $(elm).width() : pos.left + $(elm).width(); - - $(this.language_window).css({'visibility': 'visible', 'top' : top+'px','left' : left+'px'}); - - this.highlightCurSel(); }; this.createChangeLangPic = function() { -- Gitblit v1.9.1