Skip to content

Commit

Permalink
Eliminates vertical sizing and scrolling problems.
Browse files Browse the repository at this point in the history
  • Loading branch information
deleted committed Oct 19, 2012
1 parent 9a3d3d3 commit fca15d5
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
8 changes: 8 additions & 0 deletions geocamTiePoint/static/external/js/splitter.js
Expand Up @@ -321,6 +321,14 @@ var splitterCounter = 0;
// Custom events bubble in jQuery 1.3; avoid recursion
e.stopPropagation();
if ( e.target != this ) return;

// Hack to fix vertical overlflow problems
function fitWindowHeight(blockElem) {
blockElem.height( $(window).height() - blockElem.offset().top );
}
fitWindowHeight(splitter);
//fitWindowHeight($('#contents'));

// Determine new width/height of splitter container
splitter._DF = splitter[0][opts.pxFixed] - splitter._PBF;
splitter._DA = splitter[0][opts.pxSplit] - splitter._PBA;
Expand Down
2 changes: 1 addition & 1 deletion geocamTiePoint/static/geocamTiePoint/css/backbone.css
@@ -1,5 +1,6 @@
body{
background-color: #FAFAFA;
overflow-y: hidden;
}

#navlist {
Expand Down Expand Up @@ -60,4 +61,3 @@ input#locationSearch {
#new_overlay_view > form > input {
display: block;
}

6 changes: 6 additions & 0 deletions geocamTiePoint/static/geocamTiePoint/js/backbone/router.js
Expand Up @@ -75,4 +75,10 @@ $(function($) {
window.setState = function(state) {
if (app.currentView && app.currentView.setState) return app.currentView.setState(state);
};

//Keep the content container height in sync with the window
$(window).resize(function(e){
var container = $('#contents');
container.height( $(window).height() - container.offset().top );
}).resize();
});

0 comments on commit fca15d5

Please sign in to comment.