editor: hide position actions when more than 1 widget are selected
This commit is contained in:
parent
4fd618ae65
commit
aac8952ecc
2 changed files with 2 additions and 2 deletions
|
|
@ -189,7 +189,7 @@ var handleClick = function(event) {
|
|||
|
||||
}
|
||||
|
||||
if (parent !== widgetManager && editor.selectedWidgets[0].parent.children.length > 1) {
|
||||
if (parent !== widgetManager && editor.selectedWidgets.length === 1 && editor.selectedWidgets[0].parent.children.length > 1) {
|
||||
actions.push({
|
||||
separator: true
|
||||
})
|
||||
|
|
|
|||
|
|
@ -412,7 +412,7 @@ class Editor {
|
|||
case 'pageup':
|
||||
case 'home':
|
||||
case 'end':
|
||||
if (!this.selectedWidgets.length || this.selectedWidgets[0].parent.children.length <= 1) return
|
||||
if (this.selectedWidgets.length !== 1 || this.selectedWidgets[0].parent.children.length <= 1) return
|
||||
|
||||
var curWidget2 = this.selectedWidgets[0],
|
||||
index = curWidget2.parent.children.indexOf(curWidget2),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue