menu css
This commit is contained in:
parent
4e1eafc2ba
commit
b5c9df41a8
@ -342,25 +342,46 @@ table.row td {
|
|||||||
|
|
||||||
#menuDiv * { margin: 0; padding: 0; }
|
#menuDiv * { margin: 0; padding: 0; }
|
||||||
#midMenu{
|
#midMenu{
|
||||||
z-index: 101;
|
background: #fff;
|
||||||
width: 10em;
|
border-color: #ccc #666 #666 #ccc;
|
||||||
background: rgba(255, 255, 255, 0.65);
|
border-style: solid;
|
||||||
|
border-width: 1px;
|
||||||
|
cursor: default;
|
||||||
|
font: normal 13px Arial, sans-serif;
|
||||||
|
margin: 0;
|
||||||
|
outline: none;
|
||||||
|
padding: 4px 0;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
/* display: none; */
|
overflow-y: auto;
|
||||||
|
overflow-x: hidden;
|
||||||
|
max-height: 100%;
|
||||||
|
z-index: 101;
|
||||||
|
|
||||||
|
border-radius: 4px;
|
||||||
}
|
}
|
||||||
#midMenu ul{
|
#midMenu .menuitem{
|
||||||
width: 100%;
|
|
||||||
list-style: none;
|
|
||||||
border: 1px solid #000;
|
|
||||||
border-bottom: 0px;
|
|
||||||
}
|
|
||||||
#midMenu ul li{
|
|
||||||
/* height: 30px; */
|
|
||||||
/* font-size: 16px; */
|
|
||||||
color: #000;
|
color: #000;
|
||||||
/* line-height: 30px; */
|
font: normal 13px Arial, sans-serif;
|
||||||
/* text-align: center; */
|
list-style: none;
|
||||||
border-bottom: 1px solid #000;
|
margin: 0;
|
||||||
|
padding: 4px 7em 4px 28px;
|
||||||
|
white-space: nowrap;
|
||||||
|
|
||||||
|
/* padding-left: 12px; */
|
||||||
|
|
||||||
|
/* padding-right: 20px; */
|
||||||
|
}
|
||||||
|
#midMenu .menuitem:hover{
|
||||||
|
background-color: #d6e9f8;
|
||||||
|
border-color: #d6e9f8;
|
||||||
|
border-style: dotted;
|
||||||
|
border-width: 1px 0;
|
||||||
|
padding-bottom: 3px;
|
||||||
|
padding-top: 3px;
|
||||||
|
}
|
||||||
|
#midMenu .menuitem-content{
|
||||||
|
color: #000;
|
||||||
|
font: normal 13px Arial, sans-serif;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* for vue dom */
|
/* for vue dom */
|
||||||
|
|||||||
@ -633,9 +633,12 @@ editor.prototype.listen = function () {
|
|||||||
editor.info = 0;
|
editor.info = 0;
|
||||||
editor.pos=pos;
|
editor.pos=pos;
|
||||||
} else {
|
} else {
|
||||||
editor.info=editor.ids[editor.indexs[thisevent.idnum]];
|
var ids=editor.indexs[thisevent.idnum];
|
||||||
|
ids=ids[0]?ids[0]:ids;
|
||||||
|
editor.info=editor.ids[ids];
|
||||||
pos.x=editor.widthsX[thisevent.images][1];
|
pos.x=editor.widthsX[thisevent.images][1];
|
||||||
pos.y=editor.info.y;
|
pos.y=editor.info.y;
|
||||||
|
if(thisevent.images=='terrains')pos.y++;
|
||||||
ysize = thisevent.images.indexOf('48') === -1 ? 32 : 48;
|
ysize = thisevent.images.indexOf('48') === -1 ? 32 : 48;
|
||||||
}
|
}
|
||||||
setTimeout(function(){selectBox.isSelected = true;});
|
setTimeout(function(){selectBox.isSelected = true;});
|
||||||
@ -647,6 +650,30 @@ editor.prototype.listen = function () {
|
|||||||
editor_mode.onmode('emenyitem');
|
editor_mode.onmode('emenyitem');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var copyLoc = document.getElementById('copyLoc');
|
||||||
|
copyLoc.onmousedown = function(e){
|
||||||
|
editor.hideMidMenu();
|
||||||
|
e.stopPropagation();
|
||||||
|
var thisevent = editor.map[editor.pos.y][editor.pos.x];
|
||||||
|
if(thisevent==0){
|
||||||
|
|
||||||
|
} else {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
var moveLoc = document.getElementById('moveLoc');
|
||||||
|
moveLoc.onmousedown = function(e){
|
||||||
|
editor.hideMidMenu();
|
||||||
|
e.stopPropagation();
|
||||||
|
var thisevent = editor.map[editor.pos.y][editor.pos.x];
|
||||||
|
if(thisevent==0){
|
||||||
|
|
||||||
|
} else {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}//绑定事件
|
}//绑定事件
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@ -268,12 +268,9 @@
|
|||||||
</div>
|
</div>
|
||||||
<div id="menuDiv">
|
<div id="menuDiv">
|
||||||
<div id="midMenu" style="display:none">
|
<div id="midMenu" style="display:none">
|
||||||
<ul>
|
<div id='chooseInRight' class="menuitem"><div class="menuitem-content">在右侧选中</div></div>
|
||||||
<li id='chooseInRight'>在右侧选中</li>
|
<div id='copyLoc' class="menuitem"><div class="menuitem-content">复制(未完成)</div></div>
|
||||||
<li id='copyLoc'>复制(未完成)</li>
|
<div id='moveLoc' class="menuitem"><div class="menuitem-content">移动(未完成)</div></div>
|
||||||
<li id='moveLoc'>移动(未完成)</li>
|
|
||||||
<li>样式先不管了<br>( ╯-_-)╯┴—┴</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user