Merge pull request #9959 from Chocobo1/strict

Use Javascript strict mode
This commit is contained in:
Mike Tzou 2018-12-20 20:16:39 +08:00 committed by GitHub
commit 25cefee0f8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
30 changed files with 310 additions and 222 deletions

View file

@ -22,10 +22,12 @@
* THE SOFTWARE.
*/
torrentsTable = new TorrentsTable();
torrentPeersTable = new TorrentPeersTable();
searchResultsTable = new SearchResultsTable();
searchPluginsTable = new SearchPluginsTable();
'use strict';
var torrentsTable = new TorrentsTable();
var torrentPeersTable = new TorrentPeersTable();
var searchResultsTable = new SearchResultsTable();
var searchPluginsTable = new SearchPluginsTable();
var updatePropertiesPanel = function() {};
@ -322,7 +324,7 @@ window.addEvent('load', function() {
if (!categoryList)
return;
var childrens = categoryList.childNodes;
for (var i in childrens) {
for (var i = 0; i < childrens.length; ++i) {
if (childrens[i].id == selected_category)
childrens[i].className = "selectedFilter";
else
@ -643,20 +645,20 @@ window.addEvent('load', function() {
var addSearchPanel = function() {
new MochaUI.Panel({
id : 'SearchPanel',
title : 'Search',
header : false,
padding : {
top : 0,
right : 0,
bottom : 0,
left : 0
id: 'SearchPanel',
title: 'Search',
header: false,
padding: {
top: 0,
right: 0,
bottom: 0,
left: 0
},
loadMethod : 'xhr',
contentURL : 'search.html',
loadMethod: 'xhr',
contentURL: 'search.html',
content: '',
column : 'searchTabColumn',
height : null
column: 'searchTabColumn',
height: null
});
};