From 443857dffe946e93865bfd36bef4001203df2a39 Mon Sep 17 00:00:00 2001 From: drry Date: Mon, 3 Nov 2008 15:58:50 +0000 Subject: * cosmetic changes. git-svn-id: http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk@22654 d0d07461-0603-4401-acd4-de1884942a52 --- bookmarktoolbar-hint.js | 33 +++++++++++++-------------------- 1 file changed, 13 insertions(+), 20 deletions(-) (limited to 'bookmarktoolbar-hint.js') diff --git a/bookmarktoolbar-hint.js b/bookmarktoolbar-hint.js index a37ab94..3257d30 100644 --- a/bookmarktoolbar-hint.js +++ b/bookmarktoolbar-hint.js @@ -2,7 +2,7 @@ // @name BookmarksToolbar-Hint // @description Feature the BookmarksToolbar-Hint // @description-ja ブックマークツールバーのヒント機能を提供 -// @version 0.2b +// @version 0.2c // ==/VimperatorPlugin== // // Usage: @@ -30,32 +30,25 @@ liberator.plugins.bookmarkToolbarHints = (function(){ return tooltip; } function clearTooltips(){ - while(tooltipbox.hasChildNodes()){ + while (tooltipbox.hasChildNodes()){ tooltipbox.firstChild.hidePopup(); tooltipbox.removeChild(tooltipbox.firstChild); } } - function getToolbar(){ - if (toolbar) - return toolbar; - else - toolbar = document.getElementById('bookmarksBarContent'); - - return toolbar; - } + function getToolbar() toolbar || (toolbar = document.getElementById('bookmarksBarContent')); function onKeyPress(event){ manager.onEvent(event); event.stopPropagation(); event.preventDefault(); } function updateSelector(){ - for (var i=0; i= num*10){ @@ -190,7 +183,7 @@ liberator.plugins.bookmarkToolbarHints = (function(){ useShift = false; window.removeEventListener('keypress',onKeyPress,true); liberator.modules.modes.reset(true); - while(tooltipbox.hasChildNodes()){ + while (tooltipbox.hasChildNodes()){ tooltipbox.firstChild.hidePopup(); tooltipbox.removeChild(tooltipbox.firstChild); } -- cgit v1.2.3