add Ox.MODE (build/dev), + cosmetic changes

This commit is contained in:
rolux 2013-12-06 10:34:56 +01:00
parent ba0336f3c9
commit 525218dc35

View file

@ -17,11 +17,11 @@ Ox.EARTH_RADIUS = 6378137;
Ox.EARTH_CIRCUMFERENCE = 2 * Math.PI * Ox.EARTH_RADIUS; Ox.EARTH_CIRCUMFERENCE = 2 * Math.PI * Ox.EARTH_RADIUS;
//@ Ox.EARTH_SURFACE <n> Surface of the earth in square meters //@ Ox.EARTH_SURFACE <n> Surface of the earth in square meters
Ox.EARTH_SURFACE = 4 * Math.PI * Math.pow(Ox.EARTH_RADIUS, 2); Ox.EARTH_SURFACE = 4 * Math.PI * Math.pow(Ox.EARTH_RADIUS, 2);
//@ Ox.HTML_ENTITIES <object> HTML entities for ... (FIXME) //@ Ox.HTML_ENTITIES <o> HTML entities for ... (FIXME)
Ox.HTML_ENTITIES = { Ox.HTML_ENTITIES = {
'"': '&quot;', '&': '&amp;', "'": '&apos;', '<': '&lt;', '>': '&gt;' '"': '&quot;', '&': '&amp;', "'": '&apos;', '<': '&lt;', '>': '&gt;'
}; };
//@ Ox.KEYS <object> Names for key codes //@ Ox.KEYS <o> Names for key codes
// The dot notation ('0.numpad') allows for namespaced events ('key_0.numpad'), // The dot notation ('0.numpad') allows for namespaced events ('key_0.numpad'),
// so that binding to 'key_0' will catch both 'key_0' and 'key_0.numpad'. // so that binding to 'key_0' will catch both 'key_0' and 'key_0.numpad'.
Ox.KEYS = { Ox.KEYS = {
@ -83,11 +83,11 @@ Ox.MONTHS = [
'January', 'February', 'March', 'April', 'May', 'June', 'January', 'February', 'March', 'April', 'May', 'June',
'July', 'August', 'September', 'October', 'November', 'December' 'July', 'August', 'September', 'October', 'November', 'December'
]; ];
//@ Ox.SHORT_MONTHS <[str]> Short names of months //@ Ox.SHORT_MONTHS <[s]> Short names of months
Ox.SHORT_MONTHS = Ox.MONTHS.map(function(val) { Ox.SHORT_MONTHS = Ox.MONTHS.map(function(val) {
return val.slice(0, 3); return val.slice(0, 3);
}); });
//@ Ox.PATH <str> Path of Ox.js //@ Ox.PATH <s> Path of Ox.js
Ox.PATH = (function() { Ox.PATH = (function() {
// IE8 can't apply slice to NodeLists, see Ox.slice // IE8 can't apply slice to NodeLists, see Ox.slice
var index, regexp = /Ox\.js(\?\d+|)$/, var index, regexp = /Ox\.js(\?\d+|)$/,
@ -99,6 +99,8 @@ Ox.PATH = (function() {
} }
} }
}()); }());
//@ Ox.MODE <s> Mode ('build' or 'dev')
Ox.MODE = Ox.PATH.slice(0, -1).split('/').pop();
//@ Ox.PREFIXES <[str]> `['', 'K', 'M', 'G', 'T', 'P']` //@ Ox.PREFIXES <[str]> `['', 'K', 'M', 'G', 'T', 'P']`
Ox.PREFIXES = ['', 'K', 'M', 'G', 'T', 'P']; Ox.PREFIXES = ['', 'K', 'M', 'G', 'T', 'P'];
//@ Ox.SEASONS <[s]> Names of the seasons of the year //@ Ox.SEASONS <[s]> Names of the seasons of the year
@ -122,7 +124,7 @@ Ox.SYMBOLS = {
REDO: '\u21BA', UNDO: '\u21BB', PAGEUP: '\u21DE', PAGEDOWN: '\u21DF', REDO: '\u21BA', UNDO: '\u21BB', PAGEUP: '\u21DE', PAGEDOWN: '\u21DF',
CAPSLOCK: '\u21EA', TAB: '\u21E5', SHIFT: '\u21E7', INFINITY: '\u221E', CAPSLOCK: '\u21EA', TAB: '\u21E5', SHIFT: '\u21E7', INFINITY: '\u221E',
CONTROL: '\u2303', COMMAND: '\u2318', ENTER: '\u2324', ALT: '\u2325', CONTROL: '\u2303', COMMAND: '\u2318', ENTER: '\u2324', ALT: '\u2325',
DELETE: '\u2326', CLEAR:'\u2327',BACKSPACE: '\u232B', OPTION: '\u2387', DELETE: '\u2326', CLEAR:'\u2327', BACKSPACE: '\u232B', OPTION: '\u2387',
NAVIGATE: '\u2388', ESCAPE: '\u238B', EJECT: '\u23CF', NAVIGATE: '\u2388', ESCAPE: '\u238B', EJECT: '\u23CF',
SPACE: '\u2423', DIAMOND: '\u25C6', SPACE: '\u2423', DIAMOND: '\u25C6',
STAR: '\u2605', SOUND: '\u266B', TRASH: '\u267A', FLAG: '\u2691', STAR: '\u2605', SOUND: '\u266B', TRASH: '\u267A', FLAG: '\u2691',