diff options
Diffstat (limited to 'www/js/views/fms.js')
-rw-r--r-- | www/js/views/fms.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/www/js/views/fms.js b/www/js/views/fms.js index d701b00..7302c4d 100644 --- a/www/js/views/fms.js +++ b/www/js/views/fms.js @@ -5,6 +5,7 @@ events: { 'pagehide': 'destroy', + 'pagebeforeshow': 'beforeDisplay', 'pageshow': 'afterDisplay', 'click .ui-btn-left': 'onClickButtonPrev', 'click .ui-btn-right': 'onClickButtonNext' @@ -32,8 +33,20 @@ return this; }, + fixPageHeight: function() { + var screen = $(window).height(), + header = $('[data-role=header]').height(), + footer = $('[data-role=footer]').height(), + content = screen - header - footer; + $('[data-role=content]').css({'height': content }); + }, + afterRender: function() {}, + beforeDisplay: function() { + this.fixPageHeight(); + }, + afterDisplay: function() {}, navigate: function( route, direction ) { |