mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 18:55:26 +00:00
minor changes
This commit is contained in:
parent
017e48470b
commit
9ac68f9bfa
1 changed files with 6 additions and 4 deletions
|
|
@ -91,9 +91,11 @@ CloudCommander.Menu.set = (function(){
|
|||
document.onclick = function(pEvent){
|
||||
if(pEvent.x && pEvent.y){
|
||||
var lLayer = lThis.getById('context-menu-layer')
|
||||
var lStyle = lLayer.style.cssText;
|
||||
/* hide invisible menu layer */
|
||||
lLayer.style.cssText = lLayer.style.cssText
|
||||
.replace('z-index: 1', 'z-index:-1')
|
||||
if(lStyle)
|
||||
lLayer.style.cssText = lStyle
|
||||
.replace('z-index: 1', 'z-index:-1')
|
||||
|
||||
/* get element by point */
|
||||
var lElement = document.elementFromPoint(pEvent.x, pEvent.y)
|
||||
|
|
@ -105,8 +107,8 @@ CloudCommander.Menu.set = (function(){
|
|||
.parentElement);
|
||||
|
||||
/* show invisible menu layer */
|
||||
lLayer.style.cssText = lLayer.style.cssText
|
||||
.replace('z-index: -1', 'z-index: 1')
|
||||
if(lStyle)
|
||||
lLayer.style.cssText = lStyle;
|
||||
|
||||
/* if document.onclick was set up
|
||||
* before us, it's best time to call it
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue