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

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

Issue 2109813003: [DevTools] No NetworkManager and NetworkLog for v8only mode (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressing code review comments Created 4 years, 5 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 290 matching lines...) Expand 10 before | Expand all | Expand 10 after
301 /** 301 /**
302 * @param {!WebInspector.Event} event 302 * @param {!WebInspector.Event} event
303 */ 303 */
304 function onDisconnected(event) 304 function onDisconnected(event)
305 { 305 {
306 if (WebInspector._disconnectedScreenWithReasonWasShown) 306 if (WebInspector._disconnectedScreenWithReasonWasShown)
307 return; 307 return;
308 WebInspector.RemoteDebuggingTerminatedScreen.show(event.data.reason) ; 308 WebInspector.RemoteDebuggingTerminatedScreen.show(event.data.reason) ;
309 } 309 }
310 310
311 var targetType = Runtime.queryParam("isSharedWorker") ? WebInspector.Tar get.Type.ServiceWorker : WebInspector.Target.Type.Page; 311 var targetType = WebInspector.Target.Type.Page;
312 if (Runtime.queryParam("isSharedWorker"))
313 targetType = WebInspector.Target.Type.ServiceWorker;
314 else if (Runtime.queryParam("v8only"))
315 targetType = WebInspector.Target.Type.JSInspector;
316
312 this._mainTarget = WebInspector.targetManager.createTarget(WebInspector. UIString("Main"), targetType, connection, null); 317 this._mainTarget = WebInspector.targetManager.createTarget(WebInspector. UIString("Main"), targetType, connection, null);
313 console.timeStamp("Main._mainTargetCreated"); 318 console.timeStamp("Main._mainTargetCreated");
314 this._registerShortcuts(); 319 this._registerShortcuts();
315 320
316 this._mainTarget.registerInspectorDispatcher(this); 321 this._mainTarget.registerInspectorDispatcher(this);
317 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.E vents.ReloadInspectedPage, this._reloadInspectedPage, this); 322 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.E vents.ReloadInspectedPage, this._reloadInspectedPage, this);
318 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.E vents.EvaluateForTestInFrontend, this._evaluateForTestInFrontend, this); 323 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.E vents.EvaluateForTestInFrontend, this._evaluateForTestInFrontend, this);
319 324
320 if (this._mainTarget.isServiceWorker() || this._mainTarget.isPage()) 325 if (this._mainTarget.isServiceWorker() || this._mainTarget.isPage() || t his._mainTarget.isJSInspector())
321 this._mainTarget.runtimeAgent().run(); 326 this._mainTarget.runtimeAgent().run();
322 327
323 this._mainTarget.inspectorAgent().enable(); 328 this._mainTarget.inspectorAgent().enable();
324 InspectorFrontendHost.readyForTest(); 329 InspectorFrontendHost.readyForTest();
325 330
326 // Asynchronously run the extensions. 331 // Asynchronously run the extensions.
327 setTimeout(lateInitialization, 0); 332 setTimeout(lateInitialization, 0);
328 333
329 function lateInitialization() 334 function lateInitialization()
330 { 335 {
(...skipping 781 matching lines...) Expand 10 before | Expand all | Expand 10 after
1112 * @return {?Element} 1117 * @return {?Element}
1113 */ 1118 */
1114 settingElement: function() 1119 settingElement: function()
1115 { 1120 {
1116 return WebInspector.SettingsUI.createSettingCheckbox(WebInspector.UIStri ng("Show rulers"), WebInspector.moduleSetting("showMetricsRulers")); 1121 return WebInspector.SettingsUI.createSettingCheckbox(WebInspector.UIStri ng("Show rulers"), WebInspector.moduleSetting("showMetricsRulers"));
1117 } 1122 }
1118 } 1123 }
1119 1124
1120 1125
1121 new WebInspector.Main(); 1126 new WebInspector.Main();
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698