Ctrl-Tabでプレビュー表示する設定のときはキーイベントを全く監視しないようにした

git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@4945 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
piro 2009-08-14 06:36:59 +00:00
parent be76052958
commit 1cf67e1a65

View File

@ -2135,8 +2135,8 @@ catch(e) {
get shouldListenKeyEventsForAutoExpandByFocusChange() get shouldListenKeyEventsForAutoExpandByFocusChange()
{ {
return !this.getPref('browser.ctrlTab.previews') && return !this.getPref('browser.ctrlTab.previews') &&
!this.getTreePref('autoCollapseExpandSubTreeOnSelect.whileFocusMovingByShortcut') && !this.getTreePref('autoCollapseExpandSubTreeOnSelect.whileFocusMovingByShortcut') &&
this.getTreePref('autoCollapseExpandSubTreeOnSelect'); this.getTreePref('autoCollapseExpandSubTreeOnSelect');
}, },
// autohide // autohide
@ -2161,9 +2161,12 @@ catch(e) {
get shouldListenKeyEventsForAutoHide() get shouldListenKeyEventsForAutoHide()
{ {
return this.getTreePref('tabbar.autoShow.accelKeyDown') || return !this.getPref('browser.ctrlTab.previews') &&
this.getTreePref('tabbar.autoShow.tabSwitch') || (
this.getTreePref('tabbar.autoShow.feedback'); this.getTreePref('tabbar.autoShow.accelKeyDown') ||
this.getTreePref('tabbar.autoShow.tabSwitch') ||
this.getTreePref('tabbar.autoShow.feedback')
);
}, },
onTabbarResized : function(aEvent) onTabbarResized : function(aEvent)
@ -2705,15 +2708,14 @@ catch(e) {
this.expandTwistyArea = value; this.expandTwistyArea = value;
break; break;
case 'browser.ctrlTab.previews':
this.updateAutoHideKeyListeners();
case 'extensions.treestyletab.autoCollapseExpandSubTreeOnSelect.whileFocusMovingByShortcut': case 'extensions.treestyletab.autoCollapseExpandSubTreeOnSelect.whileFocusMovingByShortcut':
case 'extensions.treestyletab.autoCollapseExpandSubTreeOnSelect': case 'extensions.treestyletab.autoCollapseExpandSubTreeOnSelect':
case 'browser.ctrlTab.previews': if (this.shouldListenKeyEventsForAutoExpandByFocusChange)
if (this.shouldListenKeyEventsForAutoExpandByFocusChange) {
this.startListenKeyEventsFor(this.LISTEN_FOR_AUTOEXPAND_BY_FOCUSCHANGE); this.startListenKeyEventsFor(this.LISTEN_FOR_AUTOEXPAND_BY_FOCUSCHANGE);
} else
else {
this.endListenKeyEventsFor(this.LISTEN_FOR_AUTOEXPAND_BY_FOCUSCHANGE); this.endListenKeyEventsFor(this.LISTEN_FOR_AUTOEXPAND_BY_FOCUSCHANGE);
}
break; break;
default: default: