Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
WEBUI: fix window shadow issues on collapse / uilevel change
  • Loading branch information
perexg committed Apr 5, 2016
1 parent e2b378f commit 051a031
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions src/webui/static/app/idnode.js
Expand Up @@ -936,7 +936,12 @@ tvheadend.idnode_editor_form = function(uilevel, d, meta, panel, conf)
collapsible: conf.nocollapse ? false : true,
collapsed: conf.collapsed ? true : false,
animCollapse: true,
items: conf.items
items: conf.items,
listeners: {
collapse: function() {
panel.fireEvent('collapse');
}
}
});
}

Expand Down Expand Up @@ -1043,6 +1048,11 @@ tvheadend.idnode_editor = function(_uilevel, item, conf)
var buttons = [];
var uilevel = _uilevel;

function shadow() {
if (panel.ownerCt.baseCls == "x-window")
panel.ownerCt.syncShadow();
}

function destroy() {
panel.removeAll(true);
}
Expand Down Expand Up @@ -1154,6 +1164,7 @@ tvheadend.idnode_editor = function(_uilevel, item, conf)
destroy();
build();
panel.getForm().setValues(values);
shadow();
});
buttons.push('->');
buttons.push(uilevelBtn);
Expand Down Expand Up @@ -1186,7 +1197,12 @@ tvheadend.idnode_editor = function(_uilevel, item, conf)
defaultType: 'textfield',
buttonAlign: 'left',
autoScroll: true,
buttons: buttons
buttons: buttons,
listeners: {
collapse: function() {
shadow();
}
}
});

build();
Expand Down

0 comments on commit 051a031

Please sign in to comment.