update for auto-resizing of element-height inspector.

This commit is contained in:
kunw 2016-06-27 14:33:31 +08:00
parent d73fbda8c8
commit d1b7df6817
2 changed files with 3 additions and 4 deletions

View File

@ -32,6 +32,7 @@ body {
.container-fluid-custom {
background-color: #EFEFEF;
width: 100%;
height: 100%;
min-width: 1px;
overflow: auto;
min-height: 1px;

View File

@ -23,15 +23,13 @@
if(!angular.isDefined(scope.subsHeight)) scope.subsHeight = 110;
if(!angular.isDefined(scope.subsSection)) scope.subsSection = 32;
if(!angular.isDefined(scope.subsSubPane)) scope.subsSubPane = 226;
if(!angular.isDefined(scope.subsTabPane)) scope.subsTabPane = 66;
scope.$watch(scope.getDimension, function(current) {
if(current) {
var h = current.h;
element.css({'height' : (h - scope.subsHeight) + 'px'});
var h = current.h;
element.find('.section').css({'height': (h - scope.subsHeight - scope.subsSection) + 'px'});
element.find('.sub-pane').css({'height': (h - scope.subsHeight - scope.subsSubPane) + 'px'});
element.find('.tab-pane').css({'height': (h - scope.subsHeight - scope.subsTabPane) + 'px'});
element.find('.tab-pane').css({'height': (h - scope.subsHeight - scope.subsSubPane) + 'px'});
}
}, true);