タブバーを自動的に隠す設定の時、タブバーの開閉の瞬間にコンテンツ領域をクリックするとページの内容が選択された状態になってしまう問題を修正
git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@6762 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
parent
7052223e33
commit
076c5bb4ff
@ -12,7 +12,7 @@
|
|||||||
http://www.cozmixng.org/repos/piro/fx3-compatibility-lib/trunk/stopRendering.js
|
http://www.cozmixng.org/repos/piro/fx3-compatibility-lib/trunk/stopRendering.js
|
||||||
*/
|
*/
|
||||||
(function() {
|
(function() {
|
||||||
const currentRevision = 6;
|
const currentRevision = 7;
|
||||||
|
|
||||||
if (!('piro.sakura.ne.jp' in window)) window['piro.sakura.ne.jp'] = {};
|
if (!('piro.sakura.ne.jp' in window)) window['piro.sakura.ne.jp'] = {};
|
||||||
|
|
||||||
@ -34,6 +34,7 @@
|
|||||||
revision : currentRevision,
|
revision : currentRevision,
|
||||||
|
|
||||||
_stopLevel : 0,
|
_stopLevel : 0,
|
||||||
|
_listening : false,
|
||||||
|
|
||||||
get baswWindow()
|
get baswWindow()
|
||||||
{
|
{
|
||||||
@ -51,6 +52,10 @@
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
this.baswWindow.setPosition(window.top.innerWidth * 3, window.top.innerHeight * 3);
|
this.baswWindow.setPosition(window.top.innerWidth * 3, window.top.innerHeight * 3);
|
||||||
|
if (!this._listening) {
|
||||||
|
window.addEventListener('mousedown', this, true);
|
||||||
|
this._listening = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
this._stopLevel++;
|
this._stopLevel++;
|
||||||
},
|
},
|
||||||
@ -61,6 +66,11 @@
|
|||||||
if (this._stopLevel > 0)
|
if (this._stopLevel > 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if (this._listening) {
|
||||||
|
window.removeEventListener('mousedown', this, true);
|
||||||
|
this._listening = false;
|
||||||
|
}
|
||||||
|
|
||||||
this._stopLevel = 0;
|
this._stopLevel = 0;
|
||||||
|
|
||||||
if (this.useCanvas) {
|
if (this.useCanvas) {
|
||||||
@ -123,6 +133,13 @@
|
|||||||
this._popups.splice(index, 1);
|
this._popups.splice(index, 1);
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
case 'mousedown':
|
||||||
|
this._stopLevel = 0;
|
||||||
|
this.hideCanvas();
|
||||||
|
aEvent.stopPropagation();
|
||||||
|
aEvent.preventDefault();
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -236,12 +253,6 @@
|
|||||||
this.shown = false;
|
this.shown = false;
|
||||||
},
|
},
|
||||||
|
|
||||||
onClick : function(aEvent)
|
|
||||||
{
|
|
||||||
this._stopLevel = 0;
|
|
||||||
this.hideCanvas();
|
|
||||||
},
|
|
||||||
|
|
||||||
|
|
||||||
get browsers()
|
get browsers()
|
||||||
{
|
{
|
||||||
@ -291,7 +302,7 @@
|
|||||||
|
|
||||||
var box = document.createElement('box');
|
var box = document.createElement('box');
|
||||||
box.setAttribute('id', 'fullScreenCanvas-box');
|
box.setAttribute('id', 'fullScreenCanvas-box');
|
||||||
box.setAttribute('onclick', 'window["piro.sakura.ne.jp"].stopRendering.onClick(event);');
|
box.setAttribute('onmousedown', 'window["piro.sakura.ne.jp"].stopRendering.handleEvent(event);');
|
||||||
this.box = box;
|
this.box = box;
|
||||||
|
|
||||||
box.appendChild(canvas);
|
box.appendChild(canvas);
|
||||||
|
Loading…
Reference in New Issue
Block a user