Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/main/Main.js

Issue 1907263002: DevTools: Fix all outstanding JavaScript style issues. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove yoda disable. fix throw parens Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2007 Matt Lilek (pewtermoose@gmail.com). 3 * Copyright (C) 2007 Matt Lilek (pewtermoose@gmail.com).
4 * Copyright (C) 2009 Joseph Pecoraro 4 * Copyright (C) 2009 Joseph Pecoraro
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 9 *
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 */ 76 */
77 _createSettings: function(prefs) 77 _createSettings: function(prefs)
78 { 78 {
79 // Patch settings from the URL param (for tests). 79 // Patch settings from the URL param (for tests).
80 var settingsParam = Runtime.queryParam("settings"); 80 var settingsParam = Runtime.queryParam("settings");
81 if (settingsParam) { 81 if (settingsParam) {
82 try { 82 try {
83 var settings = JSON.parse(window.decodeURI(settingsParam)); 83 var settings = JSON.parse(window.decodeURI(settingsParam));
84 for (var key in settings) 84 for (var key in settings)
85 prefs[key] = settings[key]; 85 prefs[key] = settings[key];
86 } catch(e) { 86 } catch (e) {
87 // Ignore malformed settings. 87 // Ignore malformed settings.
88 } 88 }
89 } 89 }
90 90
91 this._initializeExperiments(prefs); 91 this._initializeExperiments(prefs);
92 WebInspector.settings = new WebInspector.Settings(new WebInspector.Setti ngsStorage(prefs, 92 WebInspector.settings = new WebInspector.Settings(new WebInspector.Setti ngsStorage(prefs,
93 InspectorFrontendHost.setPreference, InspectorFrontendHost.removePre ference, InspectorFrontendHost.clearPreferences)); 93 InspectorFrontendHost.setPreference, InspectorFrontendHost.removePre ference, InspectorFrontendHost.clearPreferences));
94 94
95 if (!InspectorFrontendHost.isUnderTest()) 95 if (!InspectorFrontendHost.isUnderTest())
96 new WebInspector.VersionController().updateVersion(); 96 new WebInspector.VersionController().updateVersion();
(...skipping 1002 matching lines...) Expand 10 before | Expand all | Expand 10 after
1099 * @return {?Element} 1099 * @return {?Element}
1100 */ 1100 */
1101 settingElement: function() 1101 settingElement: function()
1102 { 1102 {
1103 return WebInspector.SettingsUI.createSettingCheckbox(WebInspector.UIStri ng("Show rulers"), WebInspector.moduleSetting("showMetricsRulers")); 1103 return WebInspector.SettingsUI.createSettingCheckbox(WebInspector.UIStri ng("Show rulers"), WebInspector.moduleSetting("showMetricsRulers"));
1104 } 1104 }
1105 } 1105 }
1106 1106
1107 1107
1108 new WebInspector.Main(); 1108 new WebInspector.Main();
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698