From 51e9e72f3270ecadc70eac38d3c20a8b82bfdf6b Mon Sep 17 00:00:00 2001 From: rolux Date: Sat, 29 Oct 2011 19:46:46 +0200 Subject: [PATCH] cleanup, remove trailing whitespace --- static/js/api/pandora.js | 2 +- static/js/embed/pandora.js | 2 +- static/js/init.js | 15 +++++++-------- static/js/pandora/Query.js | 5 ++--- static/js/pandora/UI.js | 2 +- static/js/pandora/URL.js | 7 +++---- static/js/pandora/account.js | 4 ++-- static/js/pandora/browser.js | 2 +- static/js/pandora/clipList.js | 2 +- static/js/pandora/clipPlayer.js | 2 +- static/js/pandora/eventsDialog.js | 2 +- static/js/pandora/filesView.js | 2 +- static/js/pandora/filter.js | 1 - static/js/pandora/findElement.js | 2 +- static/js/pandora/folderList.js | 3 +-- static/js/pandora/helpDialog.js | 1 - static/js/pandora/home.js | 10 +++++----- static/js/pandora/info.js | 4 ++-- static/js/pandora/infoView.js | 9 ++++----- static/js/pandora/item.js | 5 ++--- static/js/pandora/list.js | 6 +++--- static/js/pandora/mainPanel.js | 2 +- static/js/pandora/mediaView.js | 2 +- static/js/pandora/menu.js | 2 +- static/js/pandora/namesDialog.js | 4 ++-- static/js/pandora/navigationView.js | 4 ++-- static/js/pandora/preferencesDialog.js | 2 +- static/js/pandora/siteDialog.js | 2 +- static/js/pandora/status.js | 1 - static/js/pandora/titlesDialog.js | 2 +- static/js/pandora/toolbar.js | 4 ++-- static/js/pandora/usersDialog.js | 8 ++++---- static/js/pandora/utils.js | 12 ++++++------ static/js/pandora/viewSelect.js | 2 +- 34 files changed, 63 insertions(+), 72 deletions(-) diff --git a/static/js/api/pandora.js b/static/js/api/pandora.js index 42f640ffd..ca746b448 100755 --- a/static/js/api/pandora.js +++ b/static/js/api/pandora.js @@ -144,7 +144,7 @@ function constructList() { .appendTo(info) var f = app.actions[id].code[0]; $('').html(' View Source ('+f+')').appendTo(info) - $('
').append($code).appendTo(info) 
+                $('
').append($code).appendTo(info)
                 hljs.highlightBlock($code[0], '    ');
 
                 hash += id + ','
diff --git a/static/js/embed/pandora.js b/static/js/embed/pandora.js
index 4874ccd4c..e1bf11b6a 100755
--- a/static/js/embed/pandora.js
+++ b/static/js/embed/pandora.js
@@ -58,7 +58,7 @@ Ox.load('UI', {
                         Ox.UI.hideLoadingScreen();
                     });
                     return that;
-                }, 
+                },
             });
             Ox.extend(pandora.user, {
                 videoFormat: Ox.UI.getVideoFormat(pandora.site.video.formats)
diff --git a/static/js/init.js b/static/js/init.js
index 9990b8a54..9590acdf7 100644
--- a/static/js/init.js
+++ b/static/js/init.js
@@ -132,7 +132,7 @@ window.onerror = function(error, url, line) {
         script.onload = callback;
         script.src = '/static/oxjs/dev/Ox.js';
         script.type = 'text/javascript';
-        document.head.appendChild(script);            
+        document.head.appendChild(script);
     }
 
     function loadOxUI(callback) {
@@ -226,13 +226,13 @@ window.onerror = function(error, url, line) {
                 edits: [
                     {id: 'personal', title: 'Personal Edits'},
                     {id: 'favorite', title: 'Favorite Edits', showBrowser: false},
-                    {id: 'featured', title: 'Featured Edits', showBrowser: false}                        
+                    {id: 'featured', title: 'Featured Edits', showBrowser: false}
                 ],
                 texts: [
                     {id: 'personal', title: 'Personal Texts'},
                     {id: 'favorite', title: 'Favorite Texts', showBrowser: false},
-                    {id: 'featured', title: 'Featured Texts', showBrowser: false}                        
-                ] 
+                    {id: 'featured', title: 'Featured Texts', showBrowser: false}
+                ]
             },
             sortKeys: Ox.map(pandora.site.itemKeys, function(key) {
                 return key.columnWidth ? Ox.extend(key, {
@@ -270,7 +270,7 @@ window.onerror = function(error, url, line) {
 
             Ox.Theme(pandora.user.ui.theme);
             localStorage.theme = pandora.user.ui.theme;
-            pandora.$ui.appPanel = pandora.ui.appPanel().display();        
+            pandora.$ui.appPanel = pandora.ui.appPanel().display();
             Ox.Request.requests() && pandora.$ui.loadingIcon.start();
             pandora.$ui.body.ajaxStart(pandora.$ui.loadingIcon.start);
             pandora.$ui.body.ajaxStop(pandora.$ui.loadingIcon.stop);
@@ -278,7 +278,7 @@ window.onerror = function(error, url, line) {
             pandora.site.sectionButtonsWidth = pandora.$ui.sectionButtons.width() + 8;
 
         });
-        
+
     }
 
     function loadBrowserMessage() {
@@ -345,14 +345,13 @@ window.onerror = function(error, url, line) {
                             .css({width: '32px', height: '32px', margin: '4px'})
                     )
                     .appendTo($images);
-            });        
+            });
             $('
') .css({ textAlign: 'center' }) .html(html) .appendTo($message); - }); function loadImages(images, callback) { diff --git a/static/js/pandora/Query.js b/static/js/pandora/Query.js index 77530ac2d..97c317efc 100644 --- a/static/js/pandora/Query.js +++ b/static/js/pandora/Query.js @@ -166,7 +166,7 @@ pandora.Query = (function() { }).length; // indices of non-advanced find queries indices = Ox.map(pandora.site.findKeys, function(findKey) { - var key = findKey.id == 'all' ? '' : findKey.id, + var key = findKey.id == 'all' ? '' : findKey.id, index = oneCondition(ret.query.conditions, key, ''); return index > -1 ? index : null; }); @@ -178,7 +178,7 @@ pandora.Query = (function() { index: indices[0], key: ret.query.conditions[indices[0]].key, value: decodeURIComponent(ret.query.conditions[indices[0]].value) - } : {index: -1, key: 'advanced', value: ''} + } : {index: -1, key: 'advanced', value: ''} } } } @@ -287,7 +287,6 @@ pandora.Query = (function() { find: constructFind(pandora.user.ui.query), sort: (operator == pandora.getSortOperator(key) ? '' : operator) + key }); - } else { return pandora.user.ui.item + '/' + pandora.user.ui.itemView; } diff --git a/static/js/pandora/UI.js b/static/js/pandora/UI.js index e26b3438a..c24849117 100644 --- a/static/js/pandora/UI.js +++ b/static/js/pandora/UI.js @@ -18,7 +18,7 @@ pandora.UI = (function() { pandora.user.ui = pandora.site.user.ui; pandora.user.ui._list = pandora.getListsState(pandora.user.ui.find); pandora.user.ui._groupsState = pandora.getGroupsState(pandora.user.ui.find); - pandora.user.ui._findState = pandora.getFindState(pandora.user.ui.find); + pandora.user.ui._findState = pandora.getFindState(pandora.user.ui.find); }; // sets pandora.user.ui.key to val diff --git a/static/js/pandora/URL.js b/static/js/pandora/URL.js index eaee7dd2b..b25ddf774 100644 --- a/static/js/pandora/URL.js +++ b/static/js/pandora/URL.js @@ -124,7 +124,6 @@ pandora.URL = (function() { pandora.user.ui._list = pandora.getListsState(pandora.user.ui.find); pandora.user.ui._groupsState = pandora.getGroupsState(pandora.user.ui.find); pandora.user.ui._findState = pandora.getFindState(pandora.user.ui.find); - } else { /* pandora.UI.set({ @@ -166,7 +165,7 @@ pandora.URL = (function() { callback && callback(); } else { - + var set = { section: state.type == pandora.site.itemsSection ? 'items' : state.type, item: state.item, @@ -243,7 +242,7 @@ pandora.URL = (function() { } pandora.user.ui.showHome = false; - + } that.init = function() { @@ -417,7 +416,7 @@ pandora.URL = (function() { } else { action = 'push'; } - self.URL[action](getState(), pandora.getPageTitle(), getState(/*keys*/)); + self.URL[action](getState(), pandora.getPageTitle(), getState(/*keys*/)); } }; diff --git a/static/js/pandora/account.js b/static/js/pandora/account.js index c116dcfab..2c14584e1 100644 --- a/static/js/pandora/account.js +++ b/static/js/pandora/account.js @@ -271,7 +271,7 @@ pandora.ui.accountForm = function(action, value) { labelWidth: 120, validate: pandora.validateUser('username', true), width: 320 - }); + }); } else if (type == 'usernameOrEmail') { return Ox.FormElementGroup({ id: 'usernameOrEmail', @@ -310,7 +310,7 @@ pandora.ui.accountForm = function(action, value) { }); } } - return that; + return that; }; pandora.ui.accountSignoutDialog = function() { diff --git a/static/js/pandora/browser.js b/static/js/pandora/browser.js index 0f5a01d2e..dd284d2b4 100644 --- a/static/js/pandora/browser.js +++ b/static/js/pandora/browser.js @@ -115,7 +115,7 @@ pandora.ui.browser = function() { }, select: function(data) { pandora.UI.set({ - 'item': data.ids[0] + 'item': data.ids[0] }); }, toggle: function(data) { diff --git a/static/js/pandora/clipList.js b/static/js/pandora/clipList.js index df28a63a1..d9fc0e599 100644 --- a/static/js/pandora/clipList.js +++ b/static/js/pandora/clipList.js @@ -190,7 +190,7 @@ pandora.ui.clipList = function(videoRatio) { } }, pandora_itemsort: function(data) { - that.options({sort: data.value}); + that.options({sort: data.value}); }, pandora_listsort: function(data) { that.options({sort: data.value}); diff --git a/static/js/pandora/clipPlayer.js b/static/js/pandora/clipPlayer.js index 0bce67620..cfdf6e757 100644 --- a/static/js/pandora/clipPlayer.js +++ b/static/js/pandora/clipPlayer.js @@ -39,7 +39,7 @@ pandora.ui.clipPlayer = function() { pandora.api.get({id: id, keys: ['durations']}, function(result) { //Ox.print('API get item', id, 'result', result.data); var points = [item['in'], item.out], - partsAndPoints = pandora.getVideoPartsAndPoints(result.data.durations, points); + partsAndPoints = pandora.getVideoPartsAndPoints(result.data.durations, points); data[i] = { parts: partsAndPoints.parts.map(function(i) { var part = (i + 1), diff --git a/static/js/pandora/eventsDialog.js b/static/js/pandora/eventsDialog.js index 988183ce0..72a9ccdfc 100644 --- a/static/js/pandora/eventsDialog.js +++ b/static/js/pandora/eventsDialog.js @@ -59,7 +59,7 @@ pandora.ui.eventsDialog = function() { $content; pandora.api.findEvents({ - query: {conditions: [], operator: '&'} + query: {conditions: [], operator: '&'} }, function(result) { pandora.api.findEvents({ query: {conditions: [], operator: '&'}, diff --git a/static/js/pandora/filesView.js b/static/js/pandora/filesView.js index 0a92f0b85..b5bbd80ff 100644 --- a/static/js/pandora/filesView.js +++ b/static/js/pandora/filesView.js @@ -125,7 +125,7 @@ pandora.ui.filesView = function(options, self) { { align: 'right', format: {type: 'value', args: ['B']}, - id: 'size', + id: 'size', operator: '-', title: 'Size', visible: true, diff --git a/static/js/pandora/filter.js b/static/js/pandora/filter.js index f55fffa12..e4c6e57ce 100644 --- a/static/js/pandora/filter.js +++ b/static/js/pandora/filter.js @@ -46,7 +46,6 @@ pandora.ui.filter = function(list) { pandora.$ui.groups.forEach(function($group) { $group.reloadList(); }); - }); } else { pandora.UI.set({find: data.query}); diff --git a/static/js/pandora/findElement.js b/static/js/pandora/findElement.js index 4e5dd969c..18a42d7ba 100644 --- a/static/js/pandora/findElement.js +++ b/static/js/pandora/findElement.js @@ -139,7 +139,7 @@ pandora.ui.findElement = function() { callback(result.data.items); }); } else { - callback([]); + callback([]); } } : null; } diff --git a/static/js/pandora/folderList.js b/static/js/pandora/folderList.js index 6f0e842d0..7666afcd3 100644 --- a/static/js/pandora/folderList.js +++ b/static/js/pandora/folderList.js @@ -240,7 +240,7 @@ pandora.ui.folderList = function(id) { min: 0, pageLength: 1000, //selected: pandora.getListData().folder == id ? [pandora.user.ui._list] : [], - sort: [{key: 'position', operator: '+'}], + sort: [{key: 'position', operator: '+'}], sortable: id != 'featured' || pandora.user.level == 'admin' }) .css({ @@ -296,7 +296,6 @@ pandora.ui.folderList = function(id) { //var $list = pandora.$ui.folderList[id]; if (data.key == 'user') { pandora.$ui.listDialog = pandora.ui.listDialog('icon').open(); - } else if (data.key == 'type') { if (that.value(data.id, 'type') == 'smart') { pandora.$ui.listDialog = pandora.ui.listDialog('query').open(); diff --git a/static/js/pandora/helpDialog.js b/static/js/pandora/helpDialog.js index 2a3fae4e8..9b853f42b 100644 --- a/static/js/pandora/helpDialog.js +++ b/static/js/pandora/helpDialog.js @@ -32,5 +32,4 @@ pandora.ui.helpDialog = function() { content.html('Help is coming soon...') }); return that; - }; diff --git a/static/js/pandora/home.js b/static/js/pandora/home.js index 27f56135b..f6b0b55e8 100644 --- a/static/js/pandora/home.js +++ b/static/js/pandora/home.js @@ -157,7 +157,7 @@ pandora.ui.home = function() { pandora.URL.push('/signup'); that.fadeOutScreen(); } - }), + }), $signinButton = Ox.Button({ title: 'Sign In', width: 74 @@ -176,7 +176,7 @@ pandora.ui.home = function() { pandora.URL.push('/signin'); that.fadeOutScreen(); } - }), + }), $preferencesButton = Ox.Button({ title: 'Preferences', width: 156 @@ -195,7 +195,7 @@ pandora.ui.home = function() { pandora.URL.push('/preferences'); that.fadeOutScreen(); } - }), + }), $aboutButton = Ox.Button({ title: 'About ' + pandora.site.site.name, width: 156 @@ -228,7 +228,7 @@ pandora.ui.home = function() { height: '16px', margin: 'auto', opacity: 0, - textAlign: 'center' + textAlign: 'center' }) .appendTo(that); @@ -276,5 +276,5 @@ pandora.ui.home = function() { }; return that; - + }; diff --git a/static/js/pandora/info.js b/static/js/pandora/info.js index 6b0e59099..0d8a0da89 100644 --- a/static/js/pandora/info.js +++ b/static/js/pandora/info.js @@ -1,6 +1,6 @@ // vim: et:ts=4:sw=4:sts=4:ft=javascript pandora.ui.info = function() { - + var ui = pandora.user.ui, view = getView(), @@ -63,7 +63,7 @@ pandora.ui.info = function() { function updateInfo() { var id = getId(), previousView = view; - view = getView(); + view = getView(); if (view == 'list') { that.empty().append(pandora.$ui.listInfo = pandora.ui.listInfo()); previousView == 'video' && resizeInfo(); diff --git a/static/js/pandora/infoView.js b/static/js/pandora/infoView.js index 0ab7be9e6..a2d6be3d4 100644 --- a/static/js/pandora/infoView.js +++ b/static/js/pandora/infoView.js @@ -141,7 +141,7 @@ pandora.ui.infoView = function(data) { format: function(value) { return formatTitle(value); }, - tooltip: isEditable ? 'Doubleclick to edit' : '', + tooltip: isEditable ? 'Doubleclick to edit' : '', value: data.title }) .css({ @@ -411,7 +411,7 @@ pandora.ui.infoView = function(data) { ) .appendTo($text); }); - + $('
').css({height: '16px'}).appendTo($text); // Hue, Saturation, Lightness, Volume -------------------------------------- @@ -469,7 +469,7 @@ pandora.ui.infoView = function(data) { }) ) .appendTo($statistics); - + } $('
').css({height: '16px'}).appendTo($statistics); @@ -738,7 +738,6 @@ pandora.ui.infoView = function(data) { }) .appendTo($info); }); - } function renderRightsLevel() { @@ -794,7 +793,7 @@ pandora.ui.infoView = function(data) { left: margin + iconLeft + 'px', width: iconWidth + 'px', height: iconHeight + 'px', - borderRadius: borderRadius + 'px' + borderRadius: borderRadius + 'px' }, 250); $reflection.animate({ top: margin + iconHeight + 'px', diff --git a/static/js/pandora/item.js b/static/js/pandora/item.js index 846054b16..f94b55400 100644 --- a/static/js/pandora/item.js +++ b/static/js/pandora/item.js @@ -98,7 +98,7 @@ pandora.ui.item = function() { labelWidth: 100, value: result.data[key.id], type: 'text', - width: 500 + width: 500 }); }), separators: [ @@ -126,7 +126,7 @@ pandora.ui.item = function() { pandora.api.edit(Ox.extend(changed, {id: pandora.user.ui.item}), function(result) { //fixme just reload parts that need reloading window.location.reload(); - }); + }); } } })); @@ -280,7 +280,6 @@ pandora.ui.item = function() { //fixme: check that edit was successfull pandora.api.editAnnotation(data, function(result) { Ox.print('done updateAnnotation', result); - }); }, pandora_showannotations: function(data) { diff --git a/static/js/pandora/list.js b/static/js/pandora/list.js index aa1d3d750..28cb4e081 100644 --- a/static/js/pandora/list.js +++ b/static/js/pandora/list.js @@ -115,7 +115,7 @@ pandora.ui.list = function() { pandora.UI.set({listColumns: data.ids}); /* data.ids.forEach(function(id) { - columnWidth[id] = + columnWidth[id] = pandora.user.ui.lists[pandora.user.ui.list].columnWidth[id] || Ox.getObjectById(pandora.site.sortKeys, id).width }); @@ -515,7 +515,7 @@ pandora.ui.list = function() { pandora.$ui.mainMenu.enableItem('openmovie'); } else { pandora.$ui.mainMenu.disableItem('copy'); - pandora.$ui.mainMenu.disableItem('openmovie'); + pandora.$ui.mainMenu.disableItem('openmovie'); } pandora.$ui.leftPanel.replaceElement(2, pandora.$ui.info = pandora.ui.info()); pandora.api.find({ @@ -540,7 +540,7 @@ pandora.ui.list = function() { that.options({sort: data.value}); } }); - + } if (['grid', 'timelines'].indexOf(pandora.user.ui.listView) > -1) { diff --git a/static/js/pandora/mainPanel.js b/static/js/pandora/mainPanel.js index 2c8d8c56d..57eaf572d 100644 --- a/static/js/pandora/mainPanel.js +++ b/static/js/pandora/mainPanel.js @@ -34,7 +34,7 @@ pandora.ui.mainPanel = function() { } if (!Ox.isEqual(data.find, previousUI._groupsState[i].find)) { pandora.$ui.groups[i].reloadList(); - } + } }); } else { that.replaceElement(1, pandora.$ui.rightPanel = pandora.ui.rightPanel()); diff --git a/static/js/pandora/mediaView.js b/static/js/pandora/mediaView.js index 98575a0c5..d4fcdd47f 100644 --- a/static/js/pandora/mediaView.js +++ b/static/js/pandora/mediaView.js @@ -98,7 +98,7 @@ pandora.ui.mediaView = function() { function renderPreview() { var previewWidth = pandora.$ui.document.width() - pandora.$ui.mainPanel.size(0) - 1 - listWidth, previewHeight = pandora.$ui.contentPanel.size(1), - previewRatio = previewWidth / previewHeight, + previewRatio = previewWidth / previewHeight, imageRatio = selectedImage.width / selectedImage.height, imageWidth = imageRatio > previewRatio ? previewWidth : Math.round(previewHeight * imageRatio), imageHeight = imageRatio < previewRatio ? previewHeight : Math.round(previewWidth / imageRatio), diff --git a/static/js/pandora/menu.js b/static/js/pandora/menu.js index 7503fe177..60457a530 100644 --- a/static/js/pandora/menu.js +++ b/static/js/pandora/menu.js @@ -190,7 +190,7 @@ pandora.ui.mainMenu = function() { sort: [{key: key, operator: operator}] }); groups[position].sort[0].key = key; - pandora.UI.set({groups: groups}); + pandora.UI.set({groups: groups}); } else if (data.id == 'sortmovies') { pandora.UI.set({listSort: [{key: value, operator: ''}]}); } else if (data.id == 'viewicons') { diff --git a/static/js/pandora/namesDialog.js b/static/js/pandora/namesDialog.js index 47121f6bb..89059320b 100644 --- a/static/js/pandora/namesDialog.js +++ b/static/js/pandora/namesDialog.js @@ -29,7 +29,7 @@ pandora.ui.namesDialog = function() { query: query }), callback); } - }); + }); } }), @@ -116,7 +116,7 @@ pandora.ui.namesDialog = function() { }) } }), - + that = Ox.Dialog({ buttons: [ Ox.Button({ diff --git a/static/js/pandora/navigationView.js b/static/js/pandora/navigationView.js index 385972072..edebf3753 100644 --- a/static/js/pandora/navigationView.js +++ b/static/js/pandora/navigationView.js @@ -182,7 +182,7 @@ pandora.ui.navigationView = function(type, videoRatio) { ); // needed for resize handlers further up pandora.$ui.map = $element; - + } else { pandora.api.findEvents({ @@ -214,7 +214,7 @@ pandora.ui.navigationView = function(type, videoRatio) { ); // needed for resize handlers further up pandora.$ui.calendar = $element; - }); + }); } diff --git a/static/js/pandora/preferencesDialog.js b/static/js/pandora/preferencesDialog.js index e8a6217da..19f277bb1 100644 --- a/static/js/pandora/preferencesDialog.js +++ b/static/js/pandora/preferencesDialog.js @@ -140,5 +140,5 @@ pandora.ui.preferencesDialog = function() { }); return $dialog; - + }; diff --git a/static/js/pandora/siteDialog.js b/static/js/pandora/siteDialog.js index ea24ca924..3bd1b415a 100644 --- a/static/js/pandora/siteDialog.js +++ b/static/js/pandora/siteDialog.js @@ -90,5 +90,5 @@ pandora.ui.siteDialog = function(section) { }); return $dialog; - + }; diff --git a/static/js/pandora/status.js b/static/js/pandora/status.js index 1c80e0827..ad856f615 100644 --- a/static/js/pandora/status.js +++ b/static/js/pandora/status.js @@ -6,7 +6,6 @@ pandora.ui.status = function(key, data) { if (!pandora.user.ui.item && pandora.user.ui.listView == 'clip') { itemName = data.items != 1 ? 'Clips' : 'Clip'; } - segments.push(Ox.formatNumber(data.items) + ' '+ itemName); if (data.runtime) segments.push(Ox.formatDuration(data.runtime, 'short')); diff --git a/static/js/pandora/titlesDialog.js b/static/js/pandora/titlesDialog.js index 0b8bf43e7..5cc547413 100644 --- a/static/js/pandora/titlesDialog.js +++ b/static/js/pandora/titlesDialog.js @@ -27,7 +27,7 @@ pandora.ui.titlesDialog = function() { query: query }), callback); } - }); + }); } }), diff --git a/static/js/pandora/toolbar.js b/static/js/pandora/toolbar.js index dee1c6572..04b461e04 100644 --- a/static/js/pandora/toolbar.js +++ b/static/js/pandora/toolbar.js @@ -11,7 +11,7 @@ pandora.ui.toolbar = function() { pandora.$ui.backButton = pandora.ui.backButton() ); that.append( - pandora.$ui.viewSelect = pandora.ui.viewSelect() + pandora.$ui.viewSelect = pandora.ui.viewSelect() ); if (!ui.item || pandora.isClipView()) { that.append( @@ -38,7 +38,7 @@ pandora.ui.toolbar = function() { // fixme: maybe there's a better method name for this? pandora.api.updateExternalData({ id: ui.item - }, function(result) { + }, function(result) { Ox.Request.clearCache(item); if (ui.item == item && ui.itemView == 'info') { pandora.$ui.contentPanel.replaceElement( diff --git a/static/js/pandora/usersDialog.js b/static/js/pandora/usersDialog.js index 40d53ffe1..508fb00fc 100644 --- a/static/js/pandora/usersDialog.js +++ b/static/js/pandora/usersDialog.js @@ -210,7 +210,7 @@ pandora.ui.usersDialog = function() { $status.html( Ox.formatNumber(numberOfUsers) + ' user' + (numberOfUsers == 1 ? '' : 's') - + ' (' + Ox.formatNumber(numberOfUsers) + ' registered, 0 guests)' + + ' (' + Ox.formatNumber(numberOfUsers) + ' registered, 0 guests)' ); }, select: function(data) { @@ -305,7 +305,7 @@ pandora.ui.usersDialog = function() { } ], orientation: 'vertical' - }) + }) }, { element: Ox.SplitPanel({ @@ -432,7 +432,7 @@ pandora.ui.usersDialog = function() { } else { data[event.id] = event.data.value; } - $list.value(userData.id, event.id, data[event.id]); + $list.value(userData.id, event.id, data[event.id]); pandora.api.editUser(data, function(result) { Ox.Request.clearCache('findUsers'); }); @@ -454,7 +454,7 @@ pandora.ui.usersDialog = function() { query: query }), callback); } - }); + }); } return that; diff --git a/static/js/pandora/utils.js b/static/js/pandora/utils.js index 448de44eb..721355e6d 100644 --- a/static/js/pandora/utils.js +++ b/static/js/pandora/utils.js @@ -87,7 +87,7 @@ pandora.addList = function() { var posterFrames = result.data.items.map(function(item) { return {item: item.id, position: item.posterFrame}; }); - posterFrames = posterFrames.length == 1 + posterFrames = posterFrames.length == 1 ? Ox.repeat([posterFrames[0]], 4) : posterFrames.length == 2 ? [posterFrames[0], posterFrames[1], posterFrames[1], posterFrames[0]] @@ -128,7 +128,7 @@ pandora.addList = function() { conditions: [{key: 'list', value: newList, operator: '=='}], operator: '&' } - }); + }); } }).reloadList(); } @@ -340,7 +340,7 @@ pandora.enableDragAndDrop = function($list, canMove) { drag.item == 1 ? 'singular' : 'plural' ].toLowerCase() ) + '
to ' + ( - drag.target && !drag.target.selected + drag.target && !drag.target.selected ? 'the list "' + drag.target.name + '"' : 'another list' ); @@ -489,7 +489,7 @@ pandora.getInfoHeight = function(includeHidden) { ); return (pandora.user.ui.showInfo || includeHidden) * Math.min( isVideoPreview - ? Math.round(pandora.user.ui.sidebarSize / (16/9)) + 16 + ? Math.round(pandora.user.ui.sidebarSize / (16/9)) + 16 : pandora.user.ui.sidebarSize, window.innerHeight - 109 // 20 menu + 24 bar + 64 (4 closed folders) + 1 resizebar ); @@ -616,7 +616,7 @@ pandora.getMetadataByIdOrName = function(item, view, str, callback) { pandora.getPageTitle = function(itemTitle) { Ox.print('ITEM TITLES', itemTitles) if (itemTitle) { - itemTitles[pandora.user.ui.item] = itemTitle + itemTitles[pandora.user.ui.item] = itemTitle } var parts = [pandora.site.site.name]; if (!pandora.user.ui.item) { @@ -760,7 +760,7 @@ pandora.resizeFolders = function() { .resizeColumn('name', columnWidth.name); } else { $list.resizeColumn(id == 'favorite' ? 'id' : 'name', width - 96); - } + } } if (!pandora.user.ui.showFolder[pandora.user.ui.section][id]) { pandora.$ui.folder[pos].update(); diff --git a/static/js/pandora/viewSelect.js b/static/js/pandora/viewSelect.js index 4b3fc95e0..b73639b8c 100644 --- a/static/js/pandora/viewSelect.js +++ b/static/js/pandora/viewSelect.js @@ -47,7 +47,7 @@ pandora.ui.viewSelect = function() { pandora_itemview: function(data) { that.selectItem(data.value); } - }); + }); return that; };