Permalink
Browse files

26 -> RESULT_OFFSET_Y

  • Loading branch information...
1 parent 7693224 commit bb33329eb5ae68ff974a8a9d724e76500a98faa7 @etrepum etrepum committed Jul 17, 2010
Showing with 4 additions and 2 deletions.
  1. +4 −2 priv/static/erldocs.js
View
@@ -1,4 +1,6 @@
var ErlDocs = (function(index) {
+ /* Search box height? */
+ var RESULT_OFFSET_Y = 26;
/* Human readable keyCode index */
var KEY = {'BACKSPACE': 8, 'TAB': 9, 'NUM_PAD_CLEAR': 12, 'ENTER': 13, 'SHIFT': 16, 'CTRL': 17, 'ALT': 18, 'PAUSE': 19, 'CAPS_LOCK': 20, 'ESCAPE': 27, 'SPACEBAR': 32, 'PAGE_UP': 33, 'PAGE_DOWN': 34, 'END': 35, 'HOME': 36, 'ARROW_LEFT': 37, 'ARROW_UP': 38, 'ARROW_RIGHT': 39, 'ARROW_DOWN': 40, 'PRINT_SCREEN': 44, 'INSERT': 45, 'DELETE': 46, 'SEMICOLON': 59, 'WINDOWS_LEFT': 91, 'WINDOWS_RIGHT': 92, 'SELECT': 93, 'NUM_PAD_ASTERISK': 106, 'NUM_PAD_PLUS_SIGN': 107, 'NUM_PAD_HYPHEN-MINUS': 109, 'NUM_PAD_FULL_STOP': 110, 'NUM_PAD_SOLIDUS': 111, 'NUM_LOCK': 144, 'SCROLL_LOCK': 145, 'SEMICOLON': 186, 'EQUALS_SIGN': 187, 'COMMA': 188, 'HYPHEN-MINUS': 189, 'FULL_STOP': 190, 'SOLIDUS': 191, 'GRAVE_ACCENT': 192, 'LEFT_SQUARE_BRACKET': 219, 'REVERSE_SOLIDUS': 220, 'RIGHT_SQUARE_BRACKET': 221, 'APOSTROPHE': 222};
(function () {
@@ -42,7 +44,7 @@ var ErlDocs = (function(index) {
function scrollIntoView($parent, $child) {
- var childTop = $child.position().top - 26,
+ var childTop = $child.position().top - RESULT_OFFSET_Y,
scrollTop = $parent[0].scrollTop,
childHeight = $child.height(),
parentHeight = $parent.height(),
@@ -103,7 +105,7 @@ var ErlDocs = (function(index) {
};
function windowResize() {
- $results.height($(window).height() - 26);
+ $results.height($(window).height() - RESULT_OFFSET_Y);
};
function showModules() {

0 comments on commit bb33329

Please sign in to comment.