strip: regression from dynamic editing: handle geometry coerce differently to avoid layout bugs
This commit is contained in:
parent
992ca91e37
commit
7fad36c194
4 changed files with 13 additions and 9 deletions
|
|
@ -421,6 +421,11 @@ var Editor = class Editor {
|
|||
|
||||
} else {
|
||||
|
||||
if (widget.parent !== widgetManager && widget.parent.getProp('type') === 'strip') {
|
||||
// special case for widgets in strips
|
||||
if (propName === 'top' || propName === 'left' || propName === (widget.parent.getProp('horizontal') ? 'height' : 'width')) continue
|
||||
}
|
||||
|
||||
field = editField(this, widget, propName, props[propName])
|
||||
if (!field) continue
|
||||
|
||||
|
|
@ -474,7 +479,7 @@ var Editor = class Editor {
|
|||
|
||||
}
|
||||
|
||||
if (widget.props.top !== undefined) {
|
||||
if (widget.props.top !== undefined && widget.parent.getProp('type') !== 'strip') {
|
||||
let $container = $(widget.container)
|
||||
$container.draggable({
|
||||
cursor:'-webkit-grabbing',
|
||||
|
|
|
|||
|
|
@ -142,13 +142,6 @@ class Widget extends EventEmitter {
|
|||
this.children = []
|
||||
this.reCreateOptions = options.reCreateOptions
|
||||
|
||||
// strip parent ? no position
|
||||
if (this.parent && this.parent.props && this.parent.props.type == 'strip') {
|
||||
delete this.props.top
|
||||
delete this.props.left
|
||||
delete this.props[this.parent.getProp('horizontal') ? 'height' : 'width']
|
||||
}
|
||||
|
||||
this.createPropsCache()
|
||||
|
||||
if (this.getProp('id') == 'root' && !options.root) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue