diff options
author | Milo Casagrande <milo.casagrande@linaro.org> | 2014-12-04 13:46:41 +0100 |
---|---|---|
committer | Milo Casagrande <milo.casagrande@linaro.org> | 2014-12-04 13:46:41 +0100 |
commit | 3971650c9fb3f65ec56bc8a7fe83a4db858e29ee (patch) | |
tree | 4046634694a6d2ea7a13d66bdb7a165e917530a9 | |
parent | fb6e7c1f10b4ba409914d01e3bcbf29b4b8cf20f (diff) |
Removed libraries.
Change-Id: Id30c98331bcaeb5f19477a8ea6d88742f229e692
-rw-r--r-- | app/dashboard/static/js/linaro-hotkeys-1.0.js | 41 | ||||
-rw-r--r-- | app/dashboard/static/js/linaro-hotkeys-1.0.min.js | 1 | ||||
-rw-r--r-- | app/dashboard/static/js/linaro-jslib-1.0.2.js | 117 | ||||
-rw-r--r-- | app/dashboard/static/js/linaro-jslib-1.0.2.min.js | 3 |
4 files changed, 0 insertions, 162 deletions
diff --git a/app/dashboard/static/js/linaro-hotkeys-1.0.js b/app/dashboard/static/js/linaro-hotkeys-1.0.js deleted file mode 100644 index fc6a5fa..0000000 --- a/app/dashboard/static/js/linaro-hotkeys-1.0.js +++ /dev/null @@ -1,41 +0,0 @@ -$(document).ready(function () { - 'use strict'; - - var selectSearch = function () { - $('.input-sm').focus(); - }, - selectTableLength = function () { - $('.length-menu .input-sm').focus(); - }, - goToHome = function () { - window.location = $('#home-l')[0].href; - }, - goToJob = function () { - window.location = $('#job-l')[0].href; - }, - goToBuild = function () { - window.location = $('#build-l')[0].href; - }, - goToBoot = function () { - window.location = $('#boot-l')[0].href; - }, - goToInfo = function () { - window.location = $('#info-l')[0].href; - }, - showHelp = function () { - $('#modal-hotkeys').modal('show'); - }; - - $(document).mapHotKeys( - [ - {key: '/', action: selectSearch}, - {key: 'l', action: selectTableLength}, - $.mapHotKeys.createSequence('s', 'h', $(document), showHelp), - $.mapHotKeys.createSequence('g', 'h', $(document), goToHome), - $.mapHotKeys.createSequence('g', 'j', $(document), goToJob), - $.mapHotKeys.createSequence('g', 'b', $(document), goToBuild), - $.mapHotKeys.createSequence('g', 't', $(document), goToBoot), - $.mapHotKeys.createSequence('g', 'i', $(document), goToInfo) - ] - ); -}); diff --git a/app/dashboard/static/js/linaro-hotkeys-1.0.min.js b/app/dashboard/static/js/linaro-hotkeys-1.0.min.js deleted file mode 100644 index 2d50498..0000000 --- a/app/dashboard/static/js/linaro-hotkeys-1.0.min.js +++ /dev/null @@ -1 +0,0 @@ -$(document).ready(function(){"use strict";var e=function(){$(".input-sm").focus()},o=function(){$(".length-menu .input-sm").focus()},n=function(){window.location=$("#home-l")[0].href},t=function(){window.location=$("#job-l")[0].href},c=function(){window.location=$("#build-l")[0].href},u=function(){window.location=$("#boot-l")[0].href},i=function(){window.location=$("#info-l")[0].href},a=function(){$("#modal-hotkeys").modal("show")};$(document).mapHotKeys([{key:"/",action:e},{key:"l",action:o},$.mapHotKeys.createSequence("s","h",$(document),a),$.mapHotKeys.createSequence("g","h",$(document),n),$.mapHotKeys.createSequence("g","j",$(document),t),$.mapHotKeys.createSequence("g","b",$(document),c),$.mapHotKeys.createSequence("g","t",$(document),u),$.mapHotKeys.createSequence("g","i",$(document),i)])});
\ No newline at end of file diff --git a/app/dashboard/static/js/linaro-jslib-1.0.2.js b/app/dashboard/static/js/linaro-jslib-1.0.2.js deleted file mode 100644 index d820817..0000000 --- a/app/dashboard/static/js/linaro-jslib-1.0.2.js +++ /dev/null @@ -1,117 +0,0 @@ -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU Affero General Public License as -// published by the Free Software Foundation, either version 3 of the -// License, or (at your option) any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU Affero General Public License for more details. -// -// You should have received a copy of the GNU Affero General Public License -// along with this program. If not, see <http://www.gnu.org/licenses/>. - -/* - Return a custom date in ISO format, based on UTC time. - The format returned is: YYYY-MM-DD HH:MM:SS UTC -*/ -Date.prototype.getCustomISOFormat = function() { - 'use strict'; - var year = this.getUTCFullYear().toString(), - month = (this.getUTCMonth() + 1).toString(), - day = this.getUTCDate().toString(), - hour = this.getUTCHours().toString(), - minute = this.getUTCMinutes().toString(), - seconds = this.getUTCSeconds().toString(); - - month = month[1] ? month : '0' + month[0]; - day = day[1] ? day : '0' + day[0]; - - hour = hour[1] ? hour : '0' + hour[0]; - minute = minute[1] ? minute : '0' + minute[0]; - seconds = seconds[1] ? seconds : '0' + seconds[0]; - - return year + '-' + month + '-' + day + ' ' + hour + ':' + minute + - ':' + seconds + ' UTC'; -}; - -/* - Return a custom date in ISO format. - The format returned is: YYYY-MM-DD -*/ -Date.prototype.getCustomISODate = function() { - 'use strict'; - var year = this.getUTCFullYear().toString(), - month = (this.getUTCMonth() + 1).toString(), - day = this.getUTCDate().toString(); - - month = month[1] ? month : '0' + month[0]; - day = day[1] ? day : '0' + day[0]; - - return year + '-' + month + '-' + day; -}; - -/* - Return a custom time representation. This is mostly useful to calulate - elapsed time. - The full format returned is: X hours Y min. Z sec. T mill. - - If one of the values for hours, minutes, seconds or milliseconds is 0, - it will not be returned. -*/ -Date.prototype.getCustomTime = function() { - 'use strict'; - var localHours = this.getUTCHours(), - localMinutes = this.getUTCMinutes(), - localSeconds = this.getUTCSeconds(), - localMilliseconds = this.getMilliseconds(), - localTime = ''; - - if (localHours !== 0) { - localTime += localHours.toString() + ' hours '; - } - - if (localMinutes !== 0) { - localTime += localMinutes.toString() + ' min. '; - } - - if (localSeconds !== 0) { - localTime += localSeconds.toString() + ' sec. '; - } - - if (localMilliseconds !== 0) { - localTime += localMilliseconds.toString() + ' mill.'; - } - - if (!localTime) { - localTime = '0'; - } - - return localTime.trim(); -}; - -/* - Concatenate objects together in one single object. -*/ -function collectObjects() { - 'use strict'; - var return_obj = {}, - len = arguments.length, - arg, - i = 0, - key; - - for (i = 0; i < len; i++) { - arg = arguments[i]; - - if (typeof arg === 'object') { - for (key in arg) { - if (arg.hasOwnProperty(key)) { - return_obj[key] = arg[key]; - } - } - } - } - - return return_obj; -} diff --git a/app/dashboard/static/js/linaro-jslib-1.0.2.min.js b/app/dashboard/static/js/linaro-jslib-1.0.2.min.js deleted file mode 100644 index e27e16e..0000000 --- a/app/dashboard/static/js/linaro-jslib-1.0.2.min.js +++ /dev/null @@ -1,3 +0,0 @@ -Date.prototype.getCustomISOFormat=function(){var e=this.getUTCFullYear().toString(),c=(this.getUTCMonth()+1).toString(),b=this.getUTCDate().toString(),d=this.getUTCHours().toString(),a=this.getUTCMinutes().toString(),f=this.getUTCSeconds().toString(),c=c[1]?c:"0"+c[0],b=b[1]?b:"0"+b[0],d=d[1]?d:"0"+d[0],a=a[1]?a:"0"+a[0],f=f[1]?f:"0"+f[0];return e+"-"+c+"-"+b+" "+d+":"+a+":"+f+" UTC"}; -Date.prototype.getCustomISODate=function(){var e=this.getUTCFullYear().toString(),c=(this.getUTCMonth()+1).toString(),b=this.getUTCDate().toString(),c=c[1]?c:"0"+c[0],b=b[1]?b:"0"+b[0];return e+"-"+c+"-"+b};Date.prototype.getCustomTime=function(){var e=this.getUTCHours(),c=this.getUTCMinutes(),b=this.getUTCSeconds(),d=this.getMilliseconds(),a="";0!==e&&(a+=e.toString()+" hours ");0!==c&&(a+=c.toString()+" min. ");0!==b&&(a+=b.toString()+" sec. ");0!==d&&(a+=d.toString()+" mill.");a||(a="0");return a.trim()}; -function collectObjects(){for(var e={},c=arguments.length,b,d=0,a,d=0;d<c;d++)if(b=arguments[d],"object"===typeof b)for(a in b)b.hasOwnProperty(a)&&(e[a]=b[a]);return e}; |