##// END OF EJS Templates
Fixed body container height not stretching to fill remainer of height
Jonathan Frederic -
Show More
@@ -73,14 +73,14 define(["notebook/js/widget"], function(widget_manager) {
73 this.$window = $('<div />')
73 this.$window = $('<div />')
74 .addClass('modal widget-modal')
74 .addClass('modal widget-modal')
75 .appendTo($('#notebook-container'));
75 .appendTo($('#notebook-container'));
76 var title_bar = $('<div />')
76 this.$title_bar = $('<div />')
77 .addClass('popover-title')
77 .addClass('popover-title')
78 .appendTo(this.$window);
78 .appendTo(this.$window);
79 var that = this;
79 var that = this;
80 $('<button />')
80 $('<button />')
81 .addClass('close')
81 .addClass('close')
82 .html('&times;')
82 .html('&times;')
83 .appendTo(title_bar)
83 .appendTo(this.$title_bar)
84 .click(function(){
84 .click(function(){
85 that.hide();
85 that.hide();
86 event.stopPropagation();
86 event.stopPropagation();
@@ -88,7 +88,7 define(["notebook/js/widget"], function(widget_manager) {
88 this.$title = $('<div />')
88 this.$title = $('<div />')
89 .addClass('widget-modal-title')
89 .addClass('widget-modal-title')
90 .html('&nbsp;')
90 .html('&nbsp;')
91 .appendTo(title_bar);
91 .appendTo(this.$title_bar);
92 this.$body = $('<div />')
92 this.$body = $('<div />')
93 .addClass('modal-body')
93 .addClass('modal-body')
94 .addClass('widget-container')
94 .addClass('widget-container')
@@ -104,6 +104,10 define(["notebook/js/widget"], function(widget_manager) {
104
104
105 this.$window.draggable({handle: '.popover-title', snap: '#notebook, .modal', snapMode: 'both'});
105 this.$window.draggable({handle: '.popover-title', snap: '#notebook, .modal', snapMode: 'both'});
106 this.$window.resizable();
106 this.$window.resizable();
107 this.$window.on('resize', function(){
108 that.$body.outerHeight(that.$window.innerHeight() - that.$title_bar.outerHeight());
109 })
110
107 this._shown_once = false;
111 this._shown_once = false;
108 },
112 },
109
113
General Comments 0
You need to be logged in to leave comments. Login now