| Index: chrome_linux/resources/inspector/inspector.js
|
| ===================================================================
|
| --- chrome_linux/resources/inspector/inspector.js (revision 229864)
|
| +++ chrome_linux/resources/inspector/inspector.js (working copy)
|
| @@ -40,7 +40,7 @@
|
| return 1;if(this<other)
|
| return-1;return 0;}
|
| function sanitizeHref(href)
|
| -{return href&&href.trim().toLowerCase().startsWith("javascript:")?null:href;}
|
| +{return href&&href.trim().toLowerCase().startsWith("javascript:")?"":href;}
|
| String.prototype.removeURLFragment=function()
|
| {var fragmentIndex=this.indexOf("#");if(fragmentIndex==-1)
|
| fragmentIndex=this.length;return this.substring(0,fragmentIndex);}
|
| @@ -255,7 +255,8 @@
|
| throw"recursion depth limit reached in StringPool.deepIntern(), perhaps attempting to traverse cyclical references?";for(var field in obj){switch(typeof obj[field]){case"string":obj[field]=this.intern(obj[field]);break;case"object":this.internObjectStrings(obj[field],depthLimit);break;}}}}
|
| var _importedScripts={};function importScript(scriptName)
|
| {if(_importedScripts[scriptName])
|
| -return;var xhr=new XMLHttpRequest();_importedScripts[scriptName]=true;xhr.open("GET",scriptName,false);xhr.send(null);if(!xhr.responseText)
|
| +return;var xhr=new XMLHttpRequest();_importedScripts[scriptName]=true;if(window.flattenImports)
|
| +scriptName=scriptName.split("/").reverse()[0];xhr.open("GET",scriptName,false);xhr.send(null);if(!xhr.responseText)
|
| throw"empty response arrived for script '"+scriptName+"'";var sourceURL=WebInspector.ParsedURL.completeURL(window.location.href,scriptName);window.eval(xhr.responseText+"\n//# sourceURL="+sourceURL);}
|
| var loadScript=importScript;function CallbackBarrier()
|
| {this._pendingIncomingCallbacksCount=0;}
|
| @@ -681,8 +682,7 @@
|
| TreeElement.prototype.isEventWithinDisclosureTriangle=function(event)
|
| {var paddingLeftValue=window.getComputedStyle(this._listItemNode).getPropertyCSSValue("padding-left");var computedLeftPadding=paddingLeftValue?paddingLeftValue.getFloatValue(CSSPrimitiveValue.CSS_PX):0;var left=this._listItemNode.totalOffsetLeft()+computedLeftPadding;return event.pageX>=left&&event.pageX<=left+this.arrowToggleWidth&&this.hasChildren;}
|
| var WebInspector={_panelDescriptors:function()
|
| -{this.panels={};WebInspector.inspectorView=new WebInspector.InspectorView();var parentElement=document.getElementById("main");WebInspector.inspectorView.show(parentElement);WebInspector.inspectorView.addEventListener(WebInspector.InspectorView.Events.PanelSelected,this._panelSelected,this);var elements=new WebInspector.ElementsPanelDescriptor();var resources=new WebInspector.PanelDescriptor("resources",WebInspector.UIString("Resources"),"ResourcesPanel","ResourcesPanel.js");var network=new WebInspector.NetworkPanelDescriptor();var scripts=new WebInspector.ScriptsPanelDescriptor();var timeline=new WebInspector.TimelinePanelDescriptor();var profiles=new WebInspector.ProfilesPanelDescriptor();var audits=new WebInspector.PanelDescriptor("audits",WebInspector.UIString("Audits"),"AuditsPanel","AuditsPanel.js");var console=new WebInspector.PanelDescriptor("console",WebInspector.UIString("Console"),"ConsolePanel");var allDescriptors=[elements,resources,network,scripts,timeline,profiles,audits,console];if(WebInspector.experimentsSettings.layersPanel.isEnabled()){var layers=new WebInspector.LayersPanelDescriptor();allDescriptors.push(layers);}
|
| -var allProfilers=[profiles];if(WebInspector.experimentsSettings.customizableToolbar.isEnabled()){allProfilers=[];allProfilers.push(new WebInspector.PanelDescriptor("cpu-profiler",WebInspector.UIString("CPU Profiler"),"CPUProfilerPanel","ProfilesPanel.js"));if(!WebInspector.WorkerManager.isWorkerFrontend())
|
| +{this.panels={};WebInspector.inspectorView=new WebInspector.InspectorView();var parentElement=document.getElementById("main");WebInspector.inspectorView.show(parentElement);WebInspector.inspectorView.addEventListener(WebInspector.InspectorView.Events.PanelSelected,this._panelSelected,this);var elements=new WebInspector.ElementsPanelDescriptor();var resources=new WebInspector.PanelDescriptor("resources",WebInspector.UIString("Resources"),"ResourcesPanel","ResourcesPanel.js");var network=new WebInspector.NetworkPanelDescriptor();var scripts=new WebInspector.ScriptsPanelDescriptor();var timeline=new WebInspector.TimelinePanelDescriptor();var profiles=new WebInspector.ProfilesPanelDescriptor();var audits=new WebInspector.PanelDescriptor("audits",WebInspector.UIString("Audits"),"AuditsPanel","AuditsPanel.js");var console=new WebInspector.PanelDescriptor("console",WebInspector.UIString("Console"),"ConsolePanel");var allDescriptors=[elements,resources,network,scripts,timeline,profiles,audits,console];var allProfilers=[profiles];if(WebInspector.experimentsSettings.customizableToolbar.isEnabled()){allProfilers=[];allProfilers.push(new WebInspector.PanelDescriptor("cpu-profiler",WebInspector.UIString("CPU Profiler"),"CPUProfilerPanel","ProfilesPanel.js"));if(!WebInspector.WorkerManager.isWorkerFrontend())
|
| allProfilers.push(new WebInspector.PanelDescriptor("css-profiler",WebInspector.UIString("CSS Profiler"),"CSSSelectorProfilerPanel","ProfilesPanel.js"));allProfilers.push(new WebInspector.PanelDescriptor("heap-profiler",WebInspector.UIString("Heap Profiler"),"HeapProfilerPanel","ProfilesPanel.js"));if(!WebInspector.WorkerManager.isWorkerFrontend()&&WebInspector.experimentsSettings.canvasInspection.isEnabled())
|
| allProfilers.push(new WebInspector.PanelDescriptor("canvas-profiler",WebInspector.UIString("Canvas Profiler"),"CanvasProfilerPanel","ProfilesPanel.js"));Array.prototype.splice.bind(allDescriptors,allDescriptors.indexOf(profiles),1).apply(null,allProfilers);}
|
| var panelDescriptors=[];if(WebInspector.WorkerManager.isWorkerFrontend()){panelDescriptors.push(scripts);panelDescriptors.push(timeline);panelDescriptors=panelDescriptors.concat(allProfilers);panelDescriptors.push(console);return panelDescriptors;}
|
| @@ -690,23 +690,18 @@
|
| panelDescriptors.push(allDescriptors[i]);return panelDescriptors;},_panelSelected:function()
|
| {this._toggleConsoleButton.setEnabled(WebInspector.inspectorView.currentPanel().name!=="console");},_createGlobalStatusBarItems:function()
|
| {var bottomStatusBarContainer=document.getElementById("bottom-status-bar-container");var mainStatusBar=document.getElementById("main-status-bar");mainStatusBar.insertBefore(this.dockController.element,bottomStatusBarContainer);this._toggleConsoleButton=new WebInspector.StatusBarButton(WebInspector.UIString("Show console."),"console-status-bar-item");this._toggleConsoleButton.addEventListener("click",this._toggleConsoleButtonClicked.bind(this),false);mainStatusBar.insertBefore(this._toggleConsoleButton.element,bottomStatusBarContainer);if(this.inspectElementModeController)
|
| -mainStatusBar.insertBefore(this.inspectElementModeController.toggleSearchButton.element,bottomStatusBarContainer);if(WebInspector.queryParamsObject["remoteFrontend"]&&WebInspector.experimentsSettings.screencast.isEnabled()){this._toggleScreencastButton=new WebInspector.StatusBarButton(WebInspector.UIString("Toggle screencast."),"screencast-status-bar-item");this._toggleScreencastButton.addEventListener("click",this._toggleScreencastButtonClicked.bind(this),false);mainStatusBar.insertBefore(this._toggleScreencastButton.element,bottomStatusBarContainer);}
|
| -mainStatusBar.appendChild(this.settingsController.statusBarItem);},_toggleConsoleButtonClicked:function()
|
| +mainStatusBar.insertBefore(this.inspectElementModeController.toggleSearchButton.element,bottomStatusBarContainer);mainStatusBar.appendChild(this.settingsController.statusBarItem);},_toggleConsoleButtonClicked:function()
|
| {if(!this._toggleConsoleButton.enabled())
|
| return;var animationType=window.event&&window.event.shiftKey?WebInspector.Drawer.AnimationType.Slow:WebInspector.Drawer.AnimationType.Normal;if(this._toggleConsoleButton.toggled)
|
| this.closeConsole(animationType);else
|
| -this.showConsole(animationType);},_toggleScreencastButtonClicked:function()
|
| -{this._toggleScreencastButton.toggled=!this._toggleScreencastButton.toggled;if(!this._screencastView){this._screencastView=new WebInspector.ScreencastView();this._screencastSplitView=new WebInspector.SplitView(true,"screencastSplitView");this._screencastSplitView.markAsRoot();this._screencastSplitView.show(document.body);this._screencastView.show(this._screencastSplitView.firstElement());this._screencastSplitView.secondElement().appendChild(document.getElementById("root"));this.inspectorView.element.remove();this.inspectorView.show(document.getElementById("main"));}
|
| -if(this._toggleScreencastButton.toggled)
|
| -this._screencastSplitView.showBoth();else
|
| -this._screencastSplitView.showOnlySecond();},showViewInDrawer:function(statusBarElement,view,onclose)
|
| +this.showConsole(animationType);},showViewInDrawer:function(statusBarElement,view,onclose)
|
| {this._toggleConsoleButton.title=WebInspector.UIString("Show console.");this._toggleConsoleButton.toggled=false;this._removeDrawerView();var drawerStatusBarHeader=document.createElement("div");drawerStatusBarHeader.className="drawer-header status-bar-item";drawerStatusBarHeader.appendChild(statusBarElement);drawerStatusBarHeader.onclose=onclose;var closeButton=drawerStatusBarHeader.createChild("div","close-button");closeButton.addEventListener("click",this.closeViewInDrawer.bind(this),false);var panelStatusBar=document.getElementById("panel-status-bar");var drawerViewAnchor=document.getElementById("drawer-view-anchor");panelStatusBar.insertBefore(drawerStatusBarHeader,drawerViewAnchor);this._drawerStatusBarHeader=drawerStatusBarHeader;this.drawer.show(view,WebInspector.Drawer.AnimationType.Immediately);},closeViewInDrawer:function()
|
| {if(this._drawerStatusBarHeader){this._removeDrawerView();if(this._consoleWasShown)
|
| this.showConsole();else
|
| this.drawer.hide(WebInspector.Drawer.AnimationType.Immediately);}},_removeDrawerView:function()
|
| {if(this._drawerStatusBarHeader){this._drawerStatusBarHeader.remove();if(this._drawerStatusBarHeader.onclose)
|
| this._drawerStatusBarHeader.onclose();delete this._drawerStatusBarHeader;}},showConsole:function(animationType)
|
| -{animationType=animationType||WebInspector.Drawer.AnimationType.Normal;if(this.consoleView.isShowing()&&!WebInspector.drawer.isHiding())
|
| +{animationType=animationType||WebInspector.Drawer.AnimationType.Normal;if(this.consoleView.isShowing())
|
| return;if(WebInspector.drawer.visible)
|
| this._removeDrawerView();this._toggleConsoleButton.toggled=true;this._toggleConsoleButton.title=WebInspector.UIString("Hide console.");this.drawer.show(this.consoleView,animationType);this._consoleWasShown=true;},closeConsole:function(animationType)
|
| {animationType=animationType||WebInspector.Drawer.AnimationType.Normal;if(!this.consoleView.isShowing()||!WebInspector.drawer.visible)
|
| @@ -734,7 +729,18 @@
|
| {this._zoomLevel=Math.max(this._zoomLevel-1,-WebInspector.Zoom.DefaultOffset);this._requestZoom();},_resetZoom:function()
|
| {this._zoomLevel=0;this._requestZoom();},_requestZoom:function()
|
| {WebInspector.settings.zoomLevel.set(this._zoomLevel);var index=this._zoomLevel+WebInspector.Zoom.DefaultOffset;index=Math.min(WebInspector.Zoom.Table.length-1,index);index=Math.max(0,index);InspectorFrontendHost.setZoomFactor(WebInspector.Zoom.Table[index]);},_debuggerPaused:function()
|
| -{WebInspector.panel("scripts");}}
|
| +{WebInspector.panel("scripts");},_setupTethering:function()
|
| +{if(!this._portForwardings){this._portForwardings={};WebInspector.settings.portForwardings.addChangeListener(this._setupTethering.bind(this));}
|
| +var entries=WebInspector.settings.portForwardings.get();var newForwardings={};for(var i=0;i<entries.length;++i)
|
| +newForwardings[entries[i].port]=entries[i].location;for(var port in this._portForwardings){if(!newForwardings[port])
|
| +unbind(port);}
|
| +for(var port in newForwardings){if(this._portForwardings[port]&&newForwardings[port]===this._portForwardings[port])
|
| +continue;if(this._portForwardings[port])
|
| +unbind(port);bind(port,newForwardings[port]);}
|
| +this._portForwardings=newForwardings;function bind(port,location)
|
| +{var command={method:"Tethering.bind",params:{port:parseInt(port,10),location:location},id:InspectorBackend.nextCallbackId()};InspectorBackend.sendMessageObjectToBackend(command);}
|
| +function unbind(port)
|
| +{var command={method:"Tethering.unbind",params:{port:parseInt(port,10)},id:InspectorBackend.nextCallbackId()};InspectorBackend.sendMessageObjectToBackend(command);}}}
|
| WebInspector.Events={InspectorLoaded:"InspectorLoaded",InspectorClosing:"InspectorClosing"}
|
| {(function parseQueryParameters()
|
| {WebInspector.queryParamsObject={};var queryParams=window.location.search;if(!queryParams)
|
| @@ -772,7 +778,8 @@
|
| WebInspector.showPanel(WebInspector.settings.lastActivePanel.get());}
|
| InspectorAgent.enable(showInitialPanel);this.databaseModel=new WebInspector.DatabaseModel();this.domStorageModel=new WebInspector.DOMStorageModel();ProfilerAgent.enable();WebInspector.settings.forceCompositingMode=WebInspector.settings.createBackendSetting("forceCompositingMode",false,PageAgent.setForceCompositingMode.bind(PageAgent));WebInspector.settings.showPaintRects=WebInspector.settings.createBackendSetting("showPaintRects",false,PageAgent.setShowPaintRects.bind(PageAgent));WebInspector.settings.showDebugBorders=WebInspector.settings.createBackendSetting("showDebugBorders",false,PageAgent.setShowDebugBorders.bind(PageAgent));WebInspector.settings.continuousPainting=WebInspector.settings.createBackendSetting("continuousPainting",false,PageAgent.setContinuousPaintingEnabled.bind(PageAgent));WebInspector.settings.showFPSCounter=WebInspector.settings.createBackendSetting("showFPSCounter",false,PageAgent.setShowFPSCounter.bind(PageAgent));WebInspector.settings.showScrollBottleneckRects=WebInspector.settings.createBackendSetting("showScrollBottleneckRects",false,PageAgent.setShowScrollBottleneckRects.bind(PageAgent));WebInspector.settings.showMetricsRulers.addChangeListener(showRulersChanged);function showRulersChanged()
|
| {PageAgent.setShowViewportSizeOnResize(true,WebInspector.settings.showMetricsRulers.get());}
|
| -showRulersChanged();WebInspector.WorkerManager.loadCompleted();InspectorFrontendAPI.loadCompleted();WebInspector.notifications.dispatchEventToListeners(WebInspector.Events.InspectorLoaded);}
|
| +showRulersChanged();WebInspector.WorkerManager.loadCompleted();InspectorFrontendAPI.loadCompleted();if(WebInspector.experimentsSettings.tethering.isEnabled())
|
| +this._setupTethering();WebInspector.notifications.dispatchEventToListeners(WebInspector.Events.InspectorLoaded);}
|
| var windowLoaded=function()
|
| {WebInspector.loaded();window.removeEventListener("DOMContentLoaded",windowLoaded,false);delete windowLoaded;};window.addEventListener("DOMContentLoaded",windowLoaded,false);var messagesToDispatch=[];WebInspector.dispatchQueueIsEmpty=function(){return messagesToDispatch.length==0;}
|
| WebInspector.dispatch=function(message){messagesToDispatch.push(message);setTimeout(function(){InspectorBackend.dispatch(messagesToDispatch.shift());},0);}
|
| @@ -781,8 +788,7 @@
|
| WebInspector.inspectorView.doResize();if(WebInspector.drawer)
|
| WebInspector.drawer.resize();if(WebInspector.toolbar)
|
| WebInspector.toolbar.resize();if(WebInspector.settingsController)
|
| -WebInspector.settingsController.resize();if(WebInspector._screencastSplitView)
|
| -WebInspector._screencastSplitView.doResize();}
|
| +WebInspector.settingsController.resize();}
|
| WebInspector.setDockingUnavailable=function(unavailable)
|
| {if(this.dockController)
|
| this.dockController.setDockingUnavailable(unavailable);}
|
| @@ -809,18 +815,17 @@
|
| WebInspector.showPanel("resources").showResource(resource);else
|
| InspectorFrontendHost.openInNewTab(resourceURL);}
|
| WebInspector._registerShortcuts=function()
|
| -{var shortcut=WebInspector.KeyboardShortcut;var section=WebInspector.shortcutsScreen.section(WebInspector.UIString("All Panels"));var keys=[shortcut.makeDescriptor("[",shortcut.Modifiers.CtrlOrMeta),shortcut.makeDescriptor("]",shortcut.Modifiers.CtrlOrMeta)];section.addRelatedKeys(keys,WebInspector.UIString("Go to the panel to the left/right"));keys=[shortcut.makeDescriptor("[",shortcut.Modifiers.CtrlOrMeta|shortcut.Modifiers.Alt),shortcut.makeDescriptor("]",shortcut.Modifiers.CtrlOrMeta|shortcut.Modifiers.Alt)];section.addRelatedKeys(keys,WebInspector.UIString("Go back/forward in panel history"));var toggleConsoleLabel=WebInspector.UIString("Toggle console");if(WebInspector.experimentsSettings.openConsoleWithCtrlTilde.isEnabled())
|
| -section.addKey(shortcut.makeDescriptor(shortcut.Keys.Esc),toggleConsoleLabel);else
|
| -section.addKey(shortcut.makeDescriptor(shortcut.Keys.Tilde,shortcut.Modifiers.CtrlOrMeta),toggleConsoleLabel);section.addKey(shortcut.makeDescriptor("f",shortcut.Modifiers.CtrlOrMeta),WebInspector.UIString("Search"));var advancedSearchShortcut=WebInspector.AdvancedSearchController.createShortcut();section.addKey(advancedSearchShortcut,WebInspector.UIString("Search across all sources"));var inspectElementModeShortcut=WebInspector.InspectElementModeController.createShortcut();section.addKey(inspectElementModeShortcut,WebInspector.UIString("Select node to inspect"));var openResourceShortcut=WebInspector.KeyboardShortcut.makeDescriptor("o",WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta);section.addKey(openResourceShortcut,WebInspector.UIString("Go to source"));if(WebInspector.isMac()){keys=[shortcut.makeDescriptor("g",shortcut.Modifiers.Meta),shortcut.makeDescriptor("g",shortcut.Modifiers.Meta|shortcut.Modifiers.Shift)];section.addRelatedKeys(keys,WebInspector.UIString("Find next/previous"));}
|
| +{var shortcut=WebInspector.KeyboardShortcut;var section=WebInspector.shortcutsScreen.section(WebInspector.UIString("All Panels"));var keys=[shortcut.makeDescriptor("[",shortcut.Modifiers.CtrlOrMeta),shortcut.makeDescriptor("]",shortcut.Modifiers.CtrlOrMeta)];section.addRelatedKeys(keys,WebInspector.UIString("Go to the panel to the left/right"));keys=[shortcut.makeDescriptor("[",shortcut.Modifiers.CtrlOrMeta|shortcut.Modifiers.Alt),shortcut.makeDescriptor("]",shortcut.Modifiers.CtrlOrMeta|shortcut.Modifiers.Alt)];section.addRelatedKeys(keys,WebInspector.UIString("Go back/forward in panel history"));section.addKey(shortcut.makeDescriptor(shortcut.Keys.Esc),WebInspector.UIString("Toggle console"));section.addKey(shortcut.makeDescriptor("f",shortcut.Modifiers.CtrlOrMeta),WebInspector.UIString("Search"));var advancedSearchShortcut=WebInspector.AdvancedSearchController.createShortcut();section.addKey(advancedSearchShortcut,WebInspector.UIString("Search across all sources"));var inspectElementModeShortcut=WebInspector.InspectElementModeController.createShortcut();section.addKey(inspectElementModeShortcut,WebInspector.UIString("Select node to inspect"));var openResourceShortcut=WebInspector.KeyboardShortcut.makeDescriptor("o",WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta);section.addKey(openResourceShortcut,WebInspector.UIString("Go to source"));if(WebInspector.isMac()){keys=[shortcut.makeDescriptor("g",shortcut.Modifiers.Meta),shortcut.makeDescriptor("g",shortcut.Modifiers.Meta|shortcut.Modifiers.Shift)];section.addRelatedKeys(keys,WebInspector.UIString("Find next/previous"));}
|
| var goToShortcut=WebInspector.GoToLineDialog.createShortcut();section.addKey(goToShortcut,WebInspector.UIString("Go to line"));keys=[shortcut.Keys.F1,shortcut.makeDescriptor("?")];section.addAlternateKeys(keys,WebInspector.UIString("Show general settings"));}
|
| WebInspector.documentKeyDown=function(event)
|
| -{if(WebInspector.currentFocusElement()&&WebInspector.currentFocusElement().handleKeyEvent){WebInspector.currentFocusElement().handleKeyEvent(event);if(event.handled){event.consume(true);return;}}
|
| +{const helpKey=WebInspector.isMac()?"U+003F":"U+00BF";if(event.keyIdentifier==="F1"||(event.keyIdentifier===helpKey&&event.shiftKey&&(!WebInspector.isBeingEdited(event.target)||event.metaKey))){this.settingsController.showSettingsScreen(WebInspector.SettingsScreen.Tabs.General);event.consume(true);return;}
|
| +if(WebInspector.currentFocusElement()&&WebInspector.currentFocusElement().handleKeyEvent){WebInspector.currentFocusElement().handleKeyEvent(event);if(event.handled){event.consume(true);return;}}
|
| if(WebInspector.inspectorView.currentPanel()){WebInspector.inspectorView.currentPanel().handleShortcut(event);if(event.handled){event.consume(true);return;}}
|
| if(WebInspector.searchController.handleShortcut(event))
|
| return;if(WebInspector.advancedSearchController.handleShortcut(event))
|
| return;if(WebInspector.inspectElementModeController&&WebInspector.inspectElementModeController.handleShortcut(event))
|
| return;switch(event.keyIdentifier){case"U+004F":case"U+0050":if(!event.shiftKey&&!event.altKey&&WebInspector.KeyboardShortcut.eventHasCtrlOrMeta(event)){WebInspector.showPanel("scripts").showGoToSourceDialog();event.consume(true);}
|
| -break;case"U+0052":if(WebInspector.KeyboardShortcut.eventHasCtrlOrMeta(event)){DebuggerAgent.setSkipAllPauses(true,true);PageAgent.reload(event.shiftKey);event.consume(true);}
|
| +break;case"U+0052":if(WebInspector.KeyboardShortcut.eventHasCtrlOrMeta(event)){PageAgent.reload(event.shiftKey);event.consume(true);}
|
| if(window.DEBUG&&event.altKey){WebInspector.reload();return;}
|
| break;case"F5":if(!WebInspector.isMac()){PageAgent.reload(event.ctrlKey||event.shiftKey);event.consume(true);}
|
| break;}
|
| @@ -829,13 +834,10 @@
|
| break;case 48:if(isValidZoomShortcut&&!event.shiftKey){WebInspector._resetZoom();event.consume(true);}
|
| break;}}
|
| WebInspector.postDocumentKeyDown=function(event)
|
| -{const helpKey=WebInspector.isMac()?"U+003F":"U+00BF";if(event.keyIdentifier==="F1"||(event.keyIdentifier===helpKey&&event.shiftKey&&(!WebInspector.isBeingEdited(event.target)||event.metaKey))){this.settingsController.showSettingsScreen(WebInspector.SettingsScreen.Tabs.General);event.consume(true);return;}
|
| -const Esc="U+001B";if(event.handled)
|
| -return;var openConsoleWithCtrlTildeEnabled=WebInspector.experimentsSettings.openConsoleWithCtrlTilde.isEnabled();if(event.keyIdentifier===Esc){if(WebInspector.searchController.isSearchVisible()){WebInspector.searchController.closeSearch();return;}
|
| +{var Esc="U+001B";if(event.handled)
|
| +return;if(event.keyIdentifier===Esc){if(WebInspector.searchController.isSearchVisible()){WebInspector.searchController.closeSearch();return;}
|
| if(!this._toggleConsoleButton.toggled&&WebInspector.drawer.visible)
|
| -this.closeViewInDrawer();else if(this._toggleConsoleButton.toggled||!openConsoleWithCtrlTildeEnabled)
|
| -this._toggleConsoleButtonClicked();}
|
| -if(WebInspector.experimentsSettings.openConsoleWithCtrlTilde.isEnabled()){if(event.keyCode===WebInspector.KeyboardShortcut.Keys.Tilde.code&&WebInspector.KeyboardShortcut.eventHasCtrlOrMeta(event))
|
| +this.closeViewInDrawer();else
|
| this._toggleConsoleButtonClicked();}}
|
| WebInspector.documentCanCopy=function(event)
|
| {if(WebInspector.inspectorView.currentPanel()&&WebInspector.inspectorView.currentPanel().handleCopyEvent)
|
| @@ -877,11 +879,6 @@
|
| {var object=WebInspector.RemoteObject.fromPayload(payload);if(object.subtype==="node"){function callback(nodeId)
|
| {WebInspector._updateFocusedNode(nodeId);object.release();}
|
| object.pushNodeToFrontend(callback);return;}
|
| -if(object.type==="function"){function didGetDetails(error,response)
|
| -{object.release();if(error){console.error(error);return;}
|
| -var uiLocation=WebInspector.debuggerModel.rawLocationToUILocation(response.location);if(!uiLocation)
|
| -return;WebInspector.showPanel("scripts").showUILocation(uiLocation);}
|
| -DebuggerAgent.getFunctionDetails(object.objectId,didGetDetails.bind(this));return;}
|
| if(hints.databaseId)
|
| WebInspector.showPanel("resources").selectDatabase(WebInspector.databaseModel.databaseForId(hints.databaseId));else if(hints.domStorageId)
|
| WebInspector.showPanel("resources").selectDOMStorage(WebInspector.domStorageModel.storageForId(hints.domStorageId));else if(hints.copyToClipboard)
|
| @@ -995,7 +992,7 @@
|
| result.push("InspectorBackend.registerEvent(\""+domain.domain+"."+event.name+"\", ["+paramsText.join(", ")+"]);");}
|
| result.push("InspectorBackend.register"+domain.domain+"Dispatcher = InspectorBackend.registerDomainDispatcher.bind(InspectorBackend, \""+domain.domain+"\");");}
|
| return result.join("\n");}
|
| -InspectorBackend=new InspectorBackendClass();InspectorBackend.registerInspectorDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Inspector");InspectorBackend.registerEvent("Inspector.evaluateForTestInFrontend",["testCallId","script"]);InspectorBackend.registerEvent("Inspector.inspect",["object","hints"]);InspectorBackend.registerEvent("Inspector.detached",["reason"]);InspectorBackend.registerEvent("Inspector.targetCrashed",[]);InspectorBackend.registerCommand("Inspector.enable",[],[],false);InspectorBackend.registerCommand("Inspector.disable",[],[],false);InspectorBackend.registerCommand("Inspector.reset",[],[],false);InspectorBackend.registerMemoryDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Memory");InspectorBackend.registerEvent("Memory.addNativeSnapshotChunk",["chunk"]);InspectorBackend.registerCommand("Memory.getDOMCounters",[],["documents","nodes","jsEventListeners"],false);InspectorBackend.registerPageDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Page");InspectorBackend.registerEnum("Page.ResourceType",{Document:"Document",Stylesheet:"Stylesheet",Image:"Image",Font:"Font",Script:"Script",XHR:"XHR",WebSocket:"WebSocket",Other:"Other"});InspectorBackend.registerEvent("Page.domContentEventFired",["timestamp"]);InspectorBackend.registerEvent("Page.loadEventFired",["timestamp"]);InspectorBackend.registerEvent("Page.frameAttached",["frameId"]);InspectorBackend.registerEvent("Page.frameNavigated",["frame"]);InspectorBackend.registerEvent("Page.frameDetached",["frameId"]);InspectorBackend.registerEvent("Page.frameStartedLoading",["frameId"]);InspectorBackend.registerEvent("Page.frameStoppedLoading",["frameId"]);InspectorBackend.registerEvent("Page.frameScheduledNavigation",["frameId","delay"]);InspectorBackend.registerEvent("Page.frameClearedScheduledNavigation",["frameId"]);InspectorBackend.registerEvent("Page.javascriptDialogOpening",["message"]);InspectorBackend.registerEvent("Page.javascriptDialogClosed",[]);InspectorBackend.registerEvent("Page.scriptsEnabled",["isEnabled"]);InspectorBackend.registerEvent("Page.screencastFrame",["data","deviceScaleFactor","pageScaleFactor","viewport","offsetTop","offsetBottom"]);InspectorBackend.registerCommand("Page.enable",[],[],false);InspectorBackend.registerCommand("Page.disable",[],[],false);InspectorBackend.registerCommand("Page.addScriptToEvaluateOnLoad",[{"name":"scriptSource","type":"string","optional":false}],["identifier"],false);InspectorBackend.registerCommand("Page.removeScriptToEvaluateOnLoad",[{"name":"identifier","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.reload",[{"name":"ignoreCache","type":"boolean","optional":true},{"name":"scriptToEvaluateOnLoad","type":"string","optional":true},{"name":"scriptPreprocessor","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("Page.navigate",[{"name":"url","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.getCookies",[],["cookies","cookiesString"],false);InspectorBackend.registerCommand("Page.deleteCookie",[{"name":"cookieName","type":"string","optional":false},{"name":"url","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.getResourceTree",[],["frameTree"],false);InspectorBackend.registerCommand("Page.getResourceContent",[{"name":"frameId","type":"string","optional":false},{"name":"url","type":"string","optional":false}],["content","base64Encoded"],false);InspectorBackend.registerCommand("Page.searchInResource",[{"name":"frameId","type":"string","optional":false},{"name":"url","type":"string","optional":false},{"name":"query","type":"string","optional":false},{"name":"caseSensitive","type":"boolean","optional":true},{"name":"isRegex","type":"boolean","optional":true}],["result"],false);InspectorBackend.registerCommand("Page.searchInResources",[{"name":"text","type":"string","optional":false},{"name":"caseSensitive","type":"boolean","optional":true},{"name":"isRegex","type":"boolean","optional":true}],["result"],false);InspectorBackend.registerCommand("Page.setDocumentContent",[{"name":"frameId","type":"string","optional":false},{"name":"html","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.setDeviceMetricsOverride",[{"name":"width","type":"number","optional":false},{"name":"height","type":"number","optional":false},{"name":"fontScaleFactor","type":"number","optional":false},{"name":"fitWindow","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setShowPaintRects",[{"name":"result","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setShowDebugBorders",[{"name":"show","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setShowFPSCounter",[{"name":"show","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setContinuousPaintingEnabled",[{"name":"enabled","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setShowScrollBottleneckRects",[{"name":"show","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.getScriptExecutionStatus",[],["result"],false);InspectorBackend.registerCommand("Page.setScriptExecutionDisabled",[{"name":"value","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setGeolocationOverride",[{"name":"latitude","type":"number","optional":true},{"name":"longitude","type":"number","optional":true},{"name":"accuracy","type":"number","optional":true}],[],false);InspectorBackend.registerCommand("Page.clearGeolocationOverride",[],[],false);InspectorBackend.registerCommand("Page.setDeviceOrientationOverride",[{"name":"alpha","type":"number","optional":false},{"name":"beta","type":"number","optional":false},{"name":"gamma","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Page.clearDeviceOrientationOverride",[],[],false);InspectorBackend.registerCommand("Page.setTouchEmulationEnabled",[{"name":"enabled","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setEmulatedMedia",[{"name":"media","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.captureScreenshot",[{"name":"format","type":"string","optional":true},{"name":"quality","type":"number","optional":true},{"name":"maxWidth","type":"number","optional":true},{"name":"maxHeight","type":"number","optional":true}],["data","deviceScaleFactor","pageScaleFactor","viewport"],false);InspectorBackend.registerCommand("Page.startScreencast",[{"name":"format","type":"string","optional":true},{"name":"quality","type":"number","optional":true},{"name":"maxWidth","type":"number","optional":true},{"name":"maxHeight","type":"number","optional":true}],[],false);InspectorBackend.registerCommand("Page.stopScreencast",[],[],false);InspectorBackend.registerCommand("Page.handleJavaScriptDialog",[{"name":"accept","type":"boolean","optional":false},{"name":"promptText","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("Page.setShowViewportSizeOnResize",[{"name":"show","type":"boolean","optional":false},{"name":"showGrid","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Page.setForceCompositingMode",[{"name":"force","type":"boolean","optional":false}],[],false);InspectorBackend.registerRuntimeDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Runtime");InspectorBackend.registerEnum("Runtime.RemoteObjectType",{Object:"object",Function:"function",Undefined:"undefined",String:"string",Number:"number",Boolean:"boolean"});InspectorBackend.registerEnum("Runtime.RemoteObjectSubtype",{Array:"array",Null:"null",Node:"node",Regexp:"regexp",Date:"date"});InspectorBackend.registerEnum("Runtime.PropertyPreviewType",{Object:"object",Function:"function",Undefined:"undefined",String:"string",Number:"number",Boolean:"boolean"});InspectorBackend.registerEnum("Runtime.PropertyPreviewSubtype",{Array:"array",Null:"null",Node:"node",Regexp:"regexp",Date:"date"});InspectorBackend.registerEvent("Runtime.executionContextCreated",["context"]);InspectorBackend.registerCommand("Runtime.evaluate",[{"name":"expression","type":"string","optional":false},{"name":"objectGroup","type":"string","optional":true},{"name":"includeCommandLineAPI","type":"boolean","optional":true},{"name":"doNotPauseOnExceptionsAndMuteConsole","type":"boolean","optional":true},{"name":"contextId","type":"number","optional":true},{"name":"returnByValue","type":"boolean","optional":true},{"name":"generatePreview","type":"boolean","optional":true}],["result","wasThrown"],false);InspectorBackend.registerCommand("Runtime.callFunctionOn",[{"name":"objectId","type":"string","optional":false},{"name":"functionDeclaration","type":"string","optional":false},{"name":"arguments","type":"object","optional":true},{"name":"doNotPauseOnExceptionsAndMuteConsole","type":"boolean","optional":true},{"name":"returnByValue","type":"boolean","optional":true},{"name":"generatePreview","type":"boolean","optional":true}],["result","wasThrown"],false);InspectorBackend.registerCommand("Runtime.getProperties",[{"name":"objectId","type":"string","optional":false},{"name":"ownProperties","type":"boolean","optional":true},{"name":"accessorPropertiesOnly","type":"boolean","optional":true}],["result","internalProperties"],false);InspectorBackend.registerCommand("Runtime.releaseObject",[{"name":"objectId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Runtime.releaseObjectGroup",[{"name":"objectGroup","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Runtime.run",[],[],false);InspectorBackend.registerCommand("Runtime.enable",[],[],false);InspectorBackend.registerCommand("Runtime.disable",[],[],false);InspectorBackend.registerConsoleDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Console");InspectorBackend.registerEnum("Console.ConsoleMessageSource",{XML:"xml",Javascript:"javascript",Network:"network",ConsoleAPI:"console-api",Storage:"storage",Appcache:"appcache",Rendering:"rendering",Css:"css",Security:"security",Other:"other",Deprecation:"deprecation"});InspectorBackend.registerEnum("Console.ConsoleMessageLevel",{Log:"log",Warning:"warning",Error:"error",Debug:"debug"});InspectorBackend.registerEnum("Console.ConsoleMessageType",{Log:"log",Dir:"dir",DirXML:"dirxml",Table:"table",Trace:"trace",Clear:"clear",StartGroup:"startGroup",StartGroupCollapsed:"startGroupCollapsed",EndGroup:"endGroup",Assert:"assert",Timing:"timing",Profile:"profile",ProfileEnd:"profileEnd"});InspectorBackend.registerEvent("Console.messageAdded",["message"]);InspectorBackend.registerEvent("Console.messageRepeatCountUpdated",["count","timestamp"]);InspectorBackend.registerEvent("Console.messagesCleared",[]);InspectorBackend.registerCommand("Console.enable",[],[],false);InspectorBackend.registerCommand("Console.disable",[],[],false);InspectorBackend.registerCommand("Console.clearMessages",[],[],false);InspectorBackend.registerCommand("Console.setMonitoringXHREnabled",[{"name":"enabled","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Console.addInspectedNode",[{"name":"nodeId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Console.addInspectedHeapObject",[{"name":"heapObjectId","type":"number","optional":false}],[],false);InspectorBackend.registerNetworkDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Network");InspectorBackend.registerEnum("Network.InitiatorType",{Parser:"parser",Script:"script",Other:"other"});InspectorBackend.registerEvent("Network.requestWillBeSent",["requestId","frameId","loaderId","documentURL","request","timestamp","initiator","redirectResponse"]);InspectorBackend.registerEvent("Network.requestServedFromCache",["requestId"]);InspectorBackend.registerEvent("Network.responseReceived",["requestId","frameId","loaderId","timestamp","type","response"]);InspectorBackend.registerEvent("Network.dataReceived",["requestId","timestamp","dataLength","encodedDataLength"]);InspectorBackend.registerEvent("Network.loadingFinished",["requestId","timestamp"]);InspectorBackend.registerEvent("Network.loadingFailed",["requestId","timestamp","errorText","canceled"]);InspectorBackend.registerEvent("Network.webSocketWillSendHandshakeRequest",["requestId","timestamp","request"]);InspectorBackend.registerEvent("Network.webSocketHandshakeResponseReceived",["requestId","timestamp","response"]);InspectorBackend.registerEvent("Network.webSocketCreated",["requestId","url"]);InspectorBackend.registerEvent("Network.webSocketClosed",["requestId","timestamp"]);InspectorBackend.registerEvent("Network.webSocketFrameReceived",["requestId","timestamp","response"]);InspectorBackend.registerEvent("Network.webSocketFrameError",["requestId","timestamp","errorMessage"]);InspectorBackend.registerEvent("Network.webSocketFrameSent",["requestId","timestamp","response"]);InspectorBackend.registerCommand("Network.enable",[],[],false);InspectorBackend.registerCommand("Network.disable",[],[],false);InspectorBackend.registerCommand("Network.setUserAgentOverride",[{"name":"userAgent","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Network.setExtraHTTPHeaders",[{"name":"headers","type":"object","optional":false}],[],false);InspectorBackend.registerCommand("Network.getResponseBody",[{"name":"requestId","type":"string","optional":false}],["body","base64Encoded"],false);InspectorBackend.registerCommand("Network.replayXHR",[{"name":"requestId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Network.canClearBrowserCache",[],["result"],false);InspectorBackend.registerCommand("Network.clearBrowserCache",[],[],false);InspectorBackend.registerCommand("Network.canClearBrowserCookies",[],["result"],false);InspectorBackend.registerCommand("Network.clearBrowserCookies",[],[],false);InspectorBackend.registerCommand("Network.setCacheDisabled",[{"name":"cacheDisabled","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Network.loadResourceForFrontend",[{"name":"frameId","type":"string","optional":false},{"name":"url","type":"string","optional":false},{"name":"requestHeaders","type":"object","optional":true}],["statusCode","responseHeaders","content"],false);InspectorBackend.registerDatabaseDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Database");InspectorBackend.registerEvent("Database.addDatabase",["database"]);InspectorBackend.registerCommand("Database.enable",[],[],false);InspectorBackend.registerCommand("Database.disable",[],[],false);InspectorBackend.registerCommand("Database.getDatabaseTableNames",[{"name":"databaseId","type":"string","optional":false}],["tableNames"],false);InspectorBackend.registerCommand("Database.executeSQL",[{"name":"databaseId","type":"string","optional":false},{"name":"query","type":"string","optional":false}],["columnNames","values","sqlError"],false);InspectorBackend.registerIndexedDBDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"IndexedDB");InspectorBackend.registerEnum("IndexedDB.KeyType",{Number:"number",String:"string",Date:"date",Array:"array"});InspectorBackend.registerEnum("IndexedDB.KeyPathType",{Null:"null",String:"string",Array:"array"});InspectorBackend.registerCommand("IndexedDB.enable",[],[],false);InspectorBackend.registerCommand("IndexedDB.disable",[],[],false);InspectorBackend.registerCommand("IndexedDB.requestDatabaseNames",[{"name":"securityOrigin","type":"string","optional":false}],["databaseNames"],false);InspectorBackend.registerCommand("IndexedDB.requestDatabase",[{"name":"securityOrigin","type":"string","optional":false},{"name":"databaseName","type":"string","optional":false}],["databaseWithObjectStores"],false);InspectorBackend.registerCommand("IndexedDB.requestData",[{"name":"securityOrigin","type":"string","optional":false},{"name":"databaseName","type":"string","optional":false},{"name":"objectStoreName","type":"string","optional":false},{"name":"indexName","type":"string","optional":false},{"name":"skipCount","type":"number","optional":false},{"name":"pageSize","type":"number","optional":false},{"name":"keyRange","type":"object","optional":true}],["objectStoreDataEntries","hasMore"],false);InspectorBackend.registerCommand("IndexedDB.clearObjectStore",[{"name":"securityOrigin","type":"string","optional":false},{"name":"databaseName","type":"string","optional":false},{"name":"objectStoreName","type":"string","optional":false}],[],false);InspectorBackend.registerDOMStorageDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"DOMStorage");InspectorBackend.registerEvent("DOMStorage.domStorageItemsCleared",["storageId"]);InspectorBackend.registerEvent("DOMStorage.domStorageItemRemoved",["storageId","key"]);InspectorBackend.registerEvent("DOMStorage.domStorageItemAdded",["storageId","key","newValue"]);InspectorBackend.registerEvent("DOMStorage.domStorageItemUpdated",["storageId","key","oldValue","newValue"]);InspectorBackend.registerCommand("DOMStorage.enable",[],[],false);InspectorBackend.registerCommand("DOMStorage.disable",[],[],false);InspectorBackend.registerCommand("DOMStorage.getDOMStorageItems",[{"name":"storageId","type":"object","optional":false}],["entries"],false);InspectorBackend.registerCommand("DOMStorage.setDOMStorageItem",[{"name":"storageId","type":"object","optional":false},{"name":"key","type":"string","optional":false},{"name":"value","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMStorage.removeDOMStorageItem",[{"name":"storageId","type":"object","optional":false},{"name":"key","type":"string","optional":false}],[],false);InspectorBackend.registerApplicationCacheDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"ApplicationCache");InspectorBackend.registerEvent("ApplicationCache.applicationCacheStatusUpdated",["frameId","manifestURL","status"]);InspectorBackend.registerEvent("ApplicationCache.networkStateUpdated",["isNowOnline"]);InspectorBackend.registerCommand("ApplicationCache.getFramesWithManifests",[],["frameIds"],false);InspectorBackend.registerCommand("ApplicationCache.enable",[],[],false);InspectorBackend.registerCommand("ApplicationCache.getManifestForFrame",[{"name":"frameId","type":"string","optional":false}],["manifestURL"],false);InspectorBackend.registerCommand("ApplicationCache.getApplicationCacheForFrame",[{"name":"frameId","type":"string","optional":false}],["applicationCache"],false);InspectorBackend.registerFileSystemDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"FileSystem");InspectorBackend.registerCommand("FileSystem.enable",[],[],false);InspectorBackend.registerCommand("FileSystem.disable",[],[],false);InspectorBackend.registerCommand("FileSystem.requestFileSystemRoot",[{"name":"origin","type":"string","optional":false},{"name":"type","type":"string","optional":false}],["errorCode","root"],false);InspectorBackend.registerCommand("FileSystem.requestDirectoryContent",[{"name":"url","type":"string","optional":false}],["errorCode","entries"],false);InspectorBackend.registerCommand("FileSystem.requestMetadata",[{"name":"url","type":"string","optional":false}],["errorCode","metadata"],false);InspectorBackend.registerCommand("FileSystem.requestFileContent",[{"name":"url","type":"string","optional":false},{"name":"readAsText","type":"boolean","optional":false},{"name":"start","type":"number","optional":true},{"name":"end","type":"number","optional":true},{"name":"charset","type":"string","optional":true}],["errorCode","content","charset"],false);InspectorBackend.registerCommand("FileSystem.deleteEntry",[{"name":"url","type":"string","optional":false}],["errorCode"],false);InspectorBackend.registerDOMDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"DOM");InspectorBackend.registerEvent("DOM.documentUpdated",[]);InspectorBackend.registerEvent("DOM.inspectNodeRequested",["nodeId"]);InspectorBackend.registerEvent("DOM.setChildNodes",["parentId","nodes"]);InspectorBackend.registerEvent("DOM.attributeModified",["nodeId","name","value"]);InspectorBackend.registerEvent("DOM.attributeRemoved",["nodeId","name"]);InspectorBackend.registerEvent("DOM.inlineStyleInvalidated",["nodeIds"]);InspectorBackend.registerEvent("DOM.characterDataModified",["nodeId","characterData"]);InspectorBackend.registerEvent("DOM.childNodeCountUpdated",["nodeId","childNodeCount"]);InspectorBackend.registerEvent("DOM.childNodeInserted",["parentNodeId","previousNodeId","node"]);InspectorBackend.registerEvent("DOM.childNodeRemoved",["parentNodeId","nodeId"]);InspectorBackend.registerEvent("DOM.shadowRootPushed",["hostId","root"]);InspectorBackend.registerEvent("DOM.shadowRootPopped",["hostId","rootId"]);InspectorBackend.registerCommand("DOM.getDocument",[],["root"],false);InspectorBackend.registerCommand("DOM.requestChildNodes",[{"name":"nodeId","type":"number","optional":false},{"name":"depth","type":"number","optional":true}],[],false);InspectorBackend.registerCommand("DOM.querySelector",[{"name":"nodeId","type":"number","optional":false},{"name":"selector","type":"string","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.querySelectorAll",[{"name":"nodeId","type":"number","optional":false},{"name":"selector","type":"string","optional":false}],["nodeIds"],false);InspectorBackend.registerCommand("DOM.setNodeName",[{"name":"nodeId","type":"number","optional":false},{"name":"name","type":"string","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.setNodeValue",[{"name":"nodeId","type":"number","optional":false},{"name":"value","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.removeNode",[{"name":"nodeId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("DOM.setAttributeValue",[{"name":"nodeId","type":"number","optional":false},{"name":"name","type":"string","optional":false},{"name":"value","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.setAttributesAsText",[{"name":"nodeId","type":"number","optional":false},{"name":"text","type":"string","optional":false},{"name":"name","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("DOM.removeAttribute",[{"name":"nodeId","type":"number","optional":false},{"name":"name","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.getEventListenersForNode",[{"name":"nodeId","type":"number","optional":false},{"name":"objectGroup","type":"string","optional":true}],["listeners"],false);InspectorBackend.registerCommand("DOM.getOuterHTML",[{"name":"nodeId","type":"number","optional":false}],["outerHTML"],false);InspectorBackend.registerCommand("DOM.setOuterHTML",[{"name":"nodeId","type":"number","optional":false},{"name":"outerHTML","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.performSearch",[{"name":"query","type":"string","optional":false}],["searchId","resultCount"],false);InspectorBackend.registerCommand("DOM.getSearchResults",[{"name":"searchId","type":"string","optional":false},{"name":"fromIndex","type":"number","optional":false},{"name":"toIndex","type":"number","optional":false}],["nodeIds"],false);InspectorBackend.registerCommand("DOM.discardSearchResults",[{"name":"searchId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.requestNode",[{"name":"objectId","type":"string","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.setInspectModeEnabled",[{"name":"enabled","type":"boolean","optional":false},{"name":"inspectShadowDOM","type":"boolean","optional":true},{"name":"highlightConfig","type":"object","optional":true}],[],false);InspectorBackend.registerCommand("DOM.highlightRect",[{"name":"x","type":"number","optional":false},{"name":"y","type":"number","optional":false},{"name":"width","type":"number","optional":false},{"name":"height","type":"number","optional":false},{"name":"color","type":"object","optional":true},{"name":"outlineColor","type":"object","optional":true}],[],false);InspectorBackend.registerCommand("DOM.highlightQuad",[{"name":"quad","type":"object","optional":false},{"name":"color","type":"object","optional":true},{"name":"outlineColor","type":"object","optional":true}],[],false);InspectorBackend.registerCommand("DOM.highlightNode",[{"name":"highlightConfig","type":"object","optional":false},{"name":"nodeId","type":"number","optional":true},{"name":"objectId","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("DOM.hideHighlight",[],[],false);InspectorBackend.registerCommand("DOM.highlightFrame",[{"name":"frameId","type":"string","optional":false},{"name":"contentColor","type":"object","optional":true},{"name":"contentOutlineColor","type":"object","optional":true}],[],false);InspectorBackend.registerCommand("DOM.pushNodeByPathToFrontend",[{"name":"path","type":"string","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.pushNodeByBackendIdToFrontend",[{"name":"backendNodeId","type":"number","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.releaseBackendNodeIds",[{"name":"nodeGroup","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.resolveNode",[{"name":"nodeId","type":"number","optional":false},{"name":"objectGroup","type":"string","optional":true}],["object"],false);InspectorBackend.registerCommand("DOM.getAttributes",[{"name":"nodeId","type":"number","optional":false}],["attributes"],false);InspectorBackend.registerCommand("DOM.moveTo",[{"name":"nodeId","type":"number","optional":false},{"name":"targetNodeId","type":"number","optional":false},{"name":"insertBeforeNodeId","type":"number","optional":true}],["nodeId"],false);InspectorBackend.registerCommand("DOM.undo",[],[],false);InspectorBackend.registerCommand("DOM.redo",[],[],false);InspectorBackend.registerCommand("DOM.markUndoableState",[],[],false);InspectorBackend.registerCommand("DOM.focus",[{"name":"nodeId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("DOM.setFileInputFiles",[{"name":"nodeId","type":"number","optional":false},{"name":"files","type":"object","optional":false}],[],false);InspectorBackend.registerCommand("DOM.getBoxModel",[{"name":"nodeId","type":"number","optional":false}],["model"],false);InspectorBackend.registerCommand("DOM.getNodeForLocation",[{"name":"x","type":"number","optional":false},{"name":"y","type":"number","optional":false}],["nodeId"],false);InspectorBackend.registerCSSDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"CSS");InspectorBackend.registerEnum("CSS.StyleSheetOrigin",{User:"user",UserAgent:"user-agent",Inspector:"inspector",Regular:"regular"});InspectorBackend.registerEnum("CSS.CSSPropertyStatus",{Active:"active",Inactive:"inactive",Disabled:"disabled",Style:"style"});InspectorBackend.registerEnum("CSS.CSSMediaSource",{MediaRule:"mediaRule",ImportRule:"importRule",LinkedSheet:"linkedSheet",InlineSheet:"inlineSheet"});InspectorBackend.registerEnum("CSS.RegionRegionOverset",{Overset:"overset",Fit:"fit",Empty:"empty"});InspectorBackend.registerEvent("CSS.mediaQueryResultChanged",[]);InspectorBackend.registerEvent("CSS.styleSheetChanged",["styleSheetId"]);InspectorBackend.registerEvent("CSS.styleSheetAdded",["header"]);InspectorBackend.registerEvent("CSS.styleSheetRemoved",["styleSheetId"]);InspectorBackend.registerEvent("CSS.namedFlowCreated",["namedFlow"]);InspectorBackend.registerEvent("CSS.namedFlowRemoved",["documentNodeId","flowName"]);InspectorBackend.registerEvent("CSS.regionLayoutUpdated",["namedFlow"]);InspectorBackend.registerEvent("CSS.regionOversetChanged",["namedFlow"]);InspectorBackend.registerCommand("CSS.enable",[],[],false);InspectorBackend.registerCommand("CSS.disable",[],[],false);InspectorBackend.registerCommand("CSS.getMatchedStylesForNode",[{"name":"nodeId","type":"number","optional":false},{"name":"includePseudo","type":"boolean","optional":true},{"name":"includeInherited","type":"boolean","optional":true}],["matchedCSSRules","pseudoElements","inherited"],false);InspectorBackend.registerCommand("CSS.getInlineStylesForNode",[{"name":"nodeId","type":"number","optional":false}],["inlineStyle","attributesStyle"],false);InspectorBackend.registerCommand("CSS.getComputedStyleForNode",[{"name":"nodeId","type":"number","optional":false}],["computedStyle"],false);InspectorBackend.registerCommand("CSS.getPlatformFontsForNode",[{"name":"nodeId","type":"number","optional":false}],["cssFamilyName","fonts"],false);InspectorBackend.registerCommand("CSS.getAllStyleSheets",[],["headers"],false);InspectorBackend.registerCommand("CSS.getStyleSheet",[{"name":"styleSheetId","type":"string","optional":false}],["styleSheet"],false);InspectorBackend.registerCommand("CSS.getStyleSheetText",[{"name":"styleSheetId","type":"string","optional":false}],["text"],false);InspectorBackend.registerCommand("CSS.setStyleSheetText",[{"name":"styleSheetId","type":"string","optional":false},{"name":"text","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("CSS.setStyleText",[{"name":"styleId","type":"object","optional":false},{"name":"text","type":"string","optional":false}],["style"],false);InspectorBackend.registerCommand("CSS.setPropertyText",[{"name":"styleId","type":"object","optional":false},{"name":"propertyIndex","type":"number","optional":false},{"name":"text","type":"string","optional":false},{"name":"overwrite","type":"boolean","optional":false}],["style"],false);InspectorBackend.registerCommand("CSS.toggleProperty",[{"name":"styleId","type":"object","optional":false},{"name":"propertyIndex","type":"number","optional":false},{"name":"disable","type":"boolean","optional":false}],["style"],false);InspectorBackend.registerCommand("CSS.setRuleSelector",[{"name":"ruleId","type":"object","optional":false},{"name":"selector","type":"string","optional":false}],["rule"],false);InspectorBackend.registerCommand("CSS.addRule",[{"name":"contextNodeId","type":"number","optional":false},{"name":"selector","type":"string","optional":false}],["rule"],false);InspectorBackend.registerCommand("CSS.getSupportedCSSProperties",[],["cssProperties"],false);InspectorBackend.registerCommand("CSS.forcePseudoState",[{"name":"nodeId","type":"number","optional":false},{"name":"forcedPseudoClasses","type":"object","optional":false}],[],false);InspectorBackend.registerCommand("CSS.getNamedFlowCollection",[{"name":"documentNodeId","type":"number","optional":false}],["namedFlows"],false);InspectorBackend.registerTimelineDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Timeline");InspectorBackend.registerEvent("Timeline.eventRecorded",["record"]);InspectorBackend.registerCommand("Timeline.start",[{"name":"maxCallStackDepth","type":"number","optional":true},{"name":"includeDomCounters","type":"boolean","optional":true},{"name":"includeNativeMemoryStatistics","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Timeline.stop",[],[],false);InspectorBackend.registerDebuggerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Debugger");InspectorBackend.registerEnum("Debugger.ScopeType",{Global:"global",Local:"local",With:"with",Closure:"closure",Catch:"catch"});InspectorBackend.registerEvent("Debugger.globalObjectCleared",[]);InspectorBackend.registerEvent("Debugger.scriptParsed",["scriptId","url","startLine","startColumn","endLine","endColumn","isContentScript","sourceMapURL","hasSourceURL"]);InspectorBackend.registerEvent("Debugger.scriptFailedToParse",["url","scriptSource","startLine","errorLine","errorMessage"]);InspectorBackend.registerEvent("Debugger.breakpointResolved",["breakpointId","location"]);InspectorBackend.registerEvent("Debugger.paused",["callFrames","reason","data","hitBreakpoints"]);InspectorBackend.registerEvent("Debugger.resumed",[]);InspectorBackend.registerCommand("Debugger.enable",[],[],false);InspectorBackend.registerCommand("Debugger.disable",[],[],false);InspectorBackend.registerCommand("Debugger.setBreakpointsActive",[{"name":"active","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Debugger.setSkipAllPauses",[{"name":"skipped","type":"boolean","optional":false},{"name":"untilReload","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Debugger.setBreakpointByUrl",[{"name":"lineNumber","type":"number","optional":false},{"name":"url","type":"string","optional":true},{"name":"urlRegex","type":"string","optional":true},{"name":"columnNumber","type":"number","optional":true},{"name":"condition","type":"string","optional":true},{"name":"isAntibreakpoint","type":"boolean","optional":true}],["breakpointId","locations"],false);InspectorBackend.registerCommand("Debugger.setBreakpoint",[{"name":"location","type":"object","optional":false},{"name":"condition","type":"string","optional":true}],["breakpointId","actualLocation"],false);InspectorBackend.registerCommand("Debugger.removeBreakpoint",[{"name":"breakpointId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Debugger.continueToLocation",[{"name":"location","type":"object","optional":false},{"name":"interstatementLocation","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Debugger.stepOver",[],[],false);InspectorBackend.registerCommand("Debugger.stepInto",[],[],false);InspectorBackend.registerCommand("Debugger.stepOut",[],[],false);InspectorBackend.registerCommand("Debugger.pause",[],[],false);InspectorBackend.registerCommand("Debugger.resume",[],[],false);InspectorBackend.registerCommand("Debugger.searchInContent",[{"name":"scriptId","type":"string","optional":false},{"name":"query","type":"string","optional":false},{"name":"caseSensitive","type":"boolean","optional":true},{"name":"isRegex","type":"boolean","optional":true}],["result"],false);InspectorBackend.registerCommand("Debugger.canSetScriptSource",[],["result"],false);InspectorBackend.registerCommand("Debugger.setScriptSource",[{"name":"scriptId","type":"string","optional":false},{"name":"scriptSource","type":"string","optional":false},{"name":"preview","type":"boolean","optional":true}],["callFrames","result"],true);InspectorBackend.registerCommand("Debugger.restartFrame",[{"name":"callFrameId","type":"string","optional":false}],["callFrames","result"],false);InspectorBackend.registerCommand("Debugger.getScriptSource",[{"name":"scriptId","type":"string","optional":false}],["scriptSource"],false);InspectorBackend.registerCommand("Debugger.getFunctionDetails",[{"name":"functionId","type":"string","optional":false}],["details"],false);InspectorBackend.registerCommand("Debugger.setPauseOnExceptions",[{"name":"state","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Debugger.evaluateOnCallFrame",[{"name":"callFrameId","type":"string","optional":false},{"name":"expression","type":"string","optional":false},{"name":"objectGroup","type":"string","optional":true},{"name":"includeCommandLineAPI","type":"boolean","optional":true},{"name":"doNotPauseOnExceptionsAndMuteConsole","type":"boolean","optional":true},{"name":"returnByValue","type":"boolean","optional":true},{"name":"generatePreview","type":"boolean","optional":true}],["result","wasThrown"],false);InspectorBackend.registerCommand("Debugger.compileScript",[{"name":"expression","type":"string","optional":false},{"name":"sourceURL","type":"string","optional":false}],["scriptId","syntaxErrorMessage"],false);InspectorBackend.registerCommand("Debugger.runScript",[{"name":"scriptId","type":"string","optional":false},{"name":"contextId","type":"number","optional":true},{"name":"objectGroup","type":"string","optional":true},{"name":"doNotPauseOnExceptionsAndMuteConsole","type":"boolean","optional":true}],["result","wasThrown"],false);InspectorBackend.registerCommand("Debugger.setOverlayMessage",[{"name":"message","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("Debugger.setVariableValue",[{"name":"scopeNumber","type":"number","optional":false},{"name":"variableName","type":"string","optional":false},{"name":"newValue","type":"object","optional":false},{"name":"callFrameId","type":"string","optional":true},{"name":"functionObjectId","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("Debugger.getStepInPositions",[{"name":"callFrameId","type":"string","optional":false}],["stepInPositions"],false);InspectorBackend.registerCommand("Debugger.getBacktrace",[],["callFrames"],false);InspectorBackend.registerCommand("Debugger.skipStackFrames",[{"name":"script","type":"string","optional":true}],[],false);InspectorBackend.registerDOMDebuggerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"DOMDebugger");InspectorBackend.registerEnum("DOMDebugger.DOMBreakpointType",{SubtreeModified:"subtree-modified",AttributeModified:"attribute-modified",NodeRemoved:"node-removed"});InspectorBackend.registerCommand("DOMDebugger.setDOMBreakpoint",[{"name":"nodeId","type":"number","optional":false},{"name":"type","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.removeDOMBreakpoint",[{"name":"nodeId","type":"number","optional":false},{"name":"type","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.setEventListenerBreakpoint",[{"name":"eventName","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.removeEventListenerBreakpoint",[{"name":"eventName","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.setInstrumentationBreakpoint",[{"name":"eventName","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.removeInstrumentationBreakpoint",[{"name":"eventName","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.setXHRBreakpoint",[{"name":"url","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.removeXHRBreakpoint",[{"name":"url","type":"string","optional":false}],[],false);InspectorBackend.registerProfilerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Profiler");InspectorBackend.registerEvent("Profiler.addProfileHeader",["header"]);InspectorBackend.registerEvent("Profiler.setRecordingProfile",["isProfiling"]);InspectorBackend.registerEvent("Profiler.resetProfiles",[]);InspectorBackend.registerCommand("Profiler.enable",[],[],false);InspectorBackend.registerCommand("Profiler.disable",[],[],false);InspectorBackend.registerCommand("Profiler.setSamplingInterval",[{"name":"interval","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Profiler.start",[],[],false);InspectorBackend.registerCommand("Profiler.stop",[],["header"],false);InspectorBackend.registerCommand("Profiler.getProfileHeaders",[],["headers"],false);InspectorBackend.registerCommand("Profiler.getCPUProfile",[{"name":"uid","type":"number","optional":false}],["profile"],false);InspectorBackend.registerCommand("Profiler.removeProfile",[{"name":"type","type":"string","optional":false},{"name":"uid","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Profiler.clearProfiles",[],[],false);InspectorBackend.registerHeapProfilerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"HeapProfiler");InspectorBackend.registerEvent("HeapProfiler.addProfileHeader",["header"]);InspectorBackend.registerEvent("HeapProfiler.addHeapSnapshotChunk",["uid","chunk"]);InspectorBackend.registerEvent("HeapProfiler.finishHeapSnapshot",["uid"]);InspectorBackend.registerEvent("HeapProfiler.resetProfiles",[]);InspectorBackend.registerEvent("HeapProfiler.reportHeapSnapshotProgress",["done","total"]);InspectorBackend.registerEvent("HeapProfiler.lastSeenObjectId",["lastSeenObjectId","timestamp"]);InspectorBackend.registerEvent("HeapProfiler.heapStatsUpdate",["statsUpdate"]);InspectorBackend.registerCommand("HeapProfiler.getProfileHeaders",[],["headers"],false);InspectorBackend.registerCommand("HeapProfiler.startTrackingHeapObjects",[],[],false);InspectorBackend.registerCommand("HeapProfiler.stopTrackingHeapObjects",[],[],false);InspectorBackend.registerCommand("HeapProfiler.getHeapSnapshot",[{"name":"uid","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("HeapProfiler.removeProfile",[{"name":"uid","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("HeapProfiler.clearProfiles",[],[],false);InspectorBackend.registerCommand("HeapProfiler.takeHeapSnapshot",[{"name":"reportProgress","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("HeapProfiler.collectGarbage",[],[],false);InspectorBackend.registerCommand("HeapProfiler.getObjectByHeapObjectId",[{"name":"objectId","type":"string","optional":false},{"name":"objectGroup","type":"string","optional":true}],["result"],false);InspectorBackend.registerCommand("HeapProfiler.getHeapObjectId",[{"name":"objectId","type":"string","optional":false}],["heapSnapshotObjectId"],false);InspectorBackend.registerWorkerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Worker");InspectorBackend.registerEvent("Worker.workerCreated",["workerId","url","inspectorConnected"]);InspectorBackend.registerEvent("Worker.workerTerminated",["workerId"]);InspectorBackend.registerEvent("Worker.dispatchMessageFromWorker",["workerId","message"]);InspectorBackend.registerEvent("Worker.disconnectedFromWorker",[]);InspectorBackend.registerCommand("Worker.enable",[],[],false);InspectorBackend.registerCommand("Worker.disable",[],[],false);InspectorBackend.registerCommand("Worker.sendMessageToWorker",[{"name":"workerId","type":"number","optional":false},{"name":"message","type":"object","optional":false}],[],false);InspectorBackend.registerCommand("Worker.canInspectWorkers",[],["result"],false);InspectorBackend.registerCommand("Worker.connectToWorker",[{"name":"workerId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Worker.disconnectFromWorker",[{"name":"workerId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Worker.setAutoconnectToWorkers",[{"name":"value","type":"boolean","optional":false}],[],false);InspectorBackend.registerCanvasDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Canvas");InspectorBackend.registerEnum("Canvas.CallArgumentType",{Object:"object",Function:"function",Undefined:"undefined",String:"string",Number:"number",Boolean:"boolean"});InspectorBackend.registerEnum("Canvas.CallArgumentSubtype",{Array:"array",Null:"null",Node:"node",Regexp:"regexp",Date:"date"});InspectorBackend.registerEvent("Canvas.contextCreated",["frameId"]);InspectorBackend.registerEvent("Canvas.traceLogsRemoved",["frameId","traceLogId"]);InspectorBackend.registerCommand("Canvas.enable",[],[],false);InspectorBackend.registerCommand("Canvas.disable",[],[],false);InspectorBackend.registerCommand("Canvas.dropTraceLog",[{"name":"traceLogId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Canvas.hasUninstrumentedCanvases",[],["result"],false);InspectorBackend.registerCommand("Canvas.captureFrame",[{"name":"frameId","type":"string","optional":true}],["traceLogId"],false);InspectorBackend.registerCommand("Canvas.startCapturing",[{"name":"frameId","type":"string","optional":true}],["traceLogId"],false);InspectorBackend.registerCommand("Canvas.stopCapturing",[{"name":"traceLogId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Canvas.getTraceLog",[{"name":"traceLogId","type":"string","optional":false},{"name":"startOffset","type":"number","optional":true},{"name":"maxLength","type":"number","optional":true}],["traceLog"],false);InspectorBackend.registerCommand("Canvas.replayTraceLog",[{"name":"traceLogId","type":"string","optional":false},{"name":"stepNo","type":"number","optional":false}],["resourceState","replayTime"],false);InspectorBackend.registerCommand("Canvas.getResourceState",[{"name":"traceLogId","type":"string","optional":false},{"name":"resourceId","type":"string","optional":false}],["resourceState"],false);InspectorBackend.registerCommand("Canvas.evaluateTraceLogCallArgument",[{"name":"traceLogId","type":"string","optional":false},{"name":"callIndex","type":"number","optional":false},{"name":"argumentIndex","type":"number","optional":false},{"name":"objectGroup","type":"string","optional":true}],["result","resourceState"],false);InspectorBackend.registerInputDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Input");InspectorBackend.registerEnum("Input.TouchPointState",{TouchPressed:"touchPressed",TouchReleased:"touchReleased",TouchMoved:"touchMoved",TouchStationary:"touchStationary",TouchCancelled:"touchCancelled"});InspectorBackend.registerCommand("Input.dispatchKeyEvent",[{"name":"type","type":"string","optional":false},{"name":"modifiers","type":"number","optional":true},{"name":"timestamp","type":"number","optional":true},{"name":"text","type":"string","optional":true},{"name":"unmodifiedText","type":"string","optional":true},{"name":"keyIdentifier","type":"string","optional":true},{"name":"windowsVirtualKeyCode","type":"number","optional":true},{"name":"nativeVirtualKeyCode","type":"number","optional":true},{"name":"macCharCode","type":"number","optional":true},{"name":"autoRepeat","type":"boolean","optional":true},{"name":"isKeypad","type":"boolean","optional":true},{"name":"isSystemKey","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Input.dispatchMouseEvent",[{"name":"type","type":"string","optional":false},{"name":"x","type":"number","optional":false},{"name":"y","type":"number","optional":false},{"name":"modifiers","type":"number","optional":true},{"name":"timestamp","type":"number","optional":true},{"name":"button","type":"string","optional":true},{"name":"clickCount","type":"number","optional":true},{"name":"deviceSpace","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Input.dispatchTouchEvent",[{"name":"type","type":"string","optional":false},{"name":"touchPoints","type":"object","optional":false},{"name":"modifiers","type":"number","optional":true},{"name":"timestamp","type":"number","optional":true}],[],false);InspectorBackend.registerCommand("Input.dispatchGestureEvent",[{"name":"type","type":"string","optional":false},{"name":"x","type":"number","optional":false},{"name":"y","type":"number","optional":false},{"name":"timestamp","type":"number","optional":true},{"name":"deltaX","type":"number","optional":true},{"name":"deltaY","type":"number","optional":true},{"name":"pinchScale","type":"number","optional":true}],[],false);InspectorBackend.registerLayerTreeDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"LayerTree");InspectorBackend.registerEvent("LayerTree.layerTreeDidChange",[]);InspectorBackend.registerCommand("LayerTree.enable",[],[],false);InspectorBackend.registerCommand("LayerTree.disable",[],[],false);InspectorBackend.registerCommand("LayerTree.getLayers",[{"name":"nodeId","type":"number","optional":true}],["layers"],false);InspectorBackend.registerCommand("LayerTree.compositingReasons",[{"name":"layerId","type":"string","optional":false}],["compositingReasons"],false);InspectorBackend.registerTracingDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Tracing");InspectorBackend.registerEvent("Tracing.dataCollected",["value"]);InspectorBackend.registerEvent("Tracing.tracingComplete",[]);InspectorBackend.registerCommand("Tracing.start",[{"name":"categories","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Tracing.end",[],[],false);if(!window.InspectorExtensionRegistry){WebInspector.InspectorExtensionRegistryStub=function()
|
| +InspectorBackend=new InspectorBackendClass();InspectorBackend.registerInspectorDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Inspector");InspectorBackend.registerEvent("Inspector.evaluateForTestInFrontend",["testCallId","script"]);InspectorBackend.registerEvent("Inspector.inspect",["object","hints"]);InspectorBackend.registerEvent("Inspector.detached",["reason"]);InspectorBackend.registerEvent("Inspector.targetCrashed",[]);InspectorBackend.registerCommand("Inspector.enable",[],[],false);InspectorBackend.registerCommand("Inspector.disable",[],[],false);InspectorBackend.registerCommand("Inspector.reset",[],[],false);InspectorBackend.registerMemoryDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Memory");InspectorBackend.registerEvent("Memory.addNativeSnapshotChunk",["chunk"]);InspectorBackend.registerCommand("Memory.getDOMCounters",[],["documents","nodes","jsEventListeners"],false);InspectorBackend.registerPageDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Page");InspectorBackend.registerEnum("Page.ResourceType",{Document:"Document",Stylesheet:"Stylesheet",Image:"Image",Font:"Font",Script:"Script",XHR:"XHR",WebSocket:"WebSocket",Other:"Other"});InspectorBackend.registerEvent("Page.domContentEventFired",["timestamp"]);InspectorBackend.registerEvent("Page.loadEventFired",["timestamp"]);InspectorBackend.registerEvent("Page.frameNavigated",["frame"]);InspectorBackend.registerEvent("Page.frameDetached",["frameId"]);InspectorBackend.registerEvent("Page.frameStartedLoading",["frameId"]);InspectorBackend.registerEvent("Page.frameStoppedLoading",["frameId"]);InspectorBackend.registerEvent("Page.frameScheduledNavigation",["frameId","delay"]);InspectorBackend.registerEvent("Page.frameClearedScheduledNavigation",["frameId"]);InspectorBackend.registerEvent("Page.javascriptDialogOpening",["message"]);InspectorBackend.registerEvent("Page.javascriptDialogClosed",[]);InspectorBackend.registerEvent("Page.scriptsEnabled",["isEnabled"]);InspectorBackend.registerCommand("Page.enable",[],[],false);InspectorBackend.registerCommand("Page.disable",[],[],false);InspectorBackend.registerCommand("Page.addScriptToEvaluateOnLoad",[{"name":"scriptSource","type":"string","optional":false}],["identifier"],false);InspectorBackend.registerCommand("Page.removeScriptToEvaluateOnLoad",[{"name":"identifier","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.reload",[{"name":"ignoreCache","type":"boolean","optional":true},{"name":"scriptToEvaluateOnLoad","type":"string","optional":true},{"name":"scriptPreprocessor","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("Page.navigate",[{"name":"url","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.getCookies",[],["cookies","cookiesString"],false);InspectorBackend.registerCommand("Page.deleteCookie",[{"name":"cookieName","type":"string","optional":false},{"name":"url","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.getResourceTree",[],["frameTree"],false);InspectorBackend.registerCommand("Page.getResourceContent",[{"name":"frameId","type":"string","optional":false},{"name":"url","type":"string","optional":false}],["content","base64Encoded"],false);InspectorBackend.registerCommand("Page.searchInResource",[{"name":"frameId","type":"string","optional":false},{"name":"url","type":"string","optional":false},{"name":"query","type":"string","optional":false},{"name":"caseSensitive","type":"boolean","optional":true},{"name":"isRegex","type":"boolean","optional":true}],["result"],false);InspectorBackend.registerCommand("Page.searchInResources",[{"name":"text","type":"string","optional":false},{"name":"caseSensitive","type":"boolean","optional":true},{"name":"isRegex","type":"boolean","optional":true}],["result"],false);InspectorBackend.registerCommand("Page.setDocumentContent",[{"name":"frameId","type":"string","optional":false},{"name":"html","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.setDeviceMetricsOverride",[{"name":"width","type":"number","optional":false},{"name":"height","type":"number","optional":false},{"name":"fontScaleFactor","type":"number","optional":false},{"name":"fitWindow","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setShowPaintRects",[{"name":"result","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setShowDebugBorders",[{"name":"show","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setShowFPSCounter",[{"name":"show","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setContinuousPaintingEnabled",[{"name":"enabled","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setShowScrollBottleneckRects",[{"name":"show","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.getScriptExecutionStatus",[],["result"],false);InspectorBackend.registerCommand("Page.setScriptExecutionDisabled",[{"name":"value","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setGeolocationOverride",[{"name":"latitude","type":"number","optional":true},{"name":"longitude","type":"number","optional":true},{"name":"accuracy","type":"number","optional":true}],[],false);InspectorBackend.registerCommand("Page.clearGeolocationOverride",[],[],false);InspectorBackend.registerCommand("Page.setDeviceOrientationOverride",[{"name":"alpha","type":"number","optional":false},{"name":"beta","type":"number","optional":false},{"name":"gamma","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Page.clearDeviceOrientationOverride",[],[],false);InspectorBackend.registerCommand("Page.setTouchEmulationEnabled",[{"name":"enabled","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Page.setEmulatedMedia",[{"name":"media","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Page.captureScreenshot",[],["data"],false);InspectorBackend.registerCommand("Page.handleJavaScriptDialog",[{"name":"accept","type":"boolean","optional":false},{"name":"promptText","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("Page.setShowViewportSizeOnResize",[{"name":"show","type":"boolean","optional":false},{"name":"showGrid","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Page.setForceCompositingMode",[{"name":"force","type":"boolean","optional":false}],[],false);InspectorBackend.registerRuntimeDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Runtime");InspectorBackend.registerEnum("Runtime.RemoteObjectType",{Object:"object",Function:"function",Undefined:"undefined",String:"string",Number:"number",Boolean:"boolean"});InspectorBackend.registerEnum("Runtime.RemoteObjectSubtype",{Array:"array",Null:"null",Node:"node",Regexp:"regexp",Date:"date"});InspectorBackend.registerEnum("Runtime.PropertyPreviewType",{Object:"object",Function:"function",Undefined:"undefined",String:"string",Number:"number",Boolean:"boolean"});InspectorBackend.registerEnum("Runtime.PropertyPreviewSubtype",{Array:"array",Null:"null",Node:"node",Regexp:"regexp",Date:"date"});InspectorBackend.registerEvent("Runtime.executionContextCreated",["context"]);InspectorBackend.registerCommand("Runtime.evaluate",[{"name":"expression","type":"string","optional":false},{"name":"objectGroup","type":"string","optional":true},{"name":"includeCommandLineAPI","type":"boolean","optional":true},{"name":"doNotPauseOnExceptionsAndMuteConsole","type":"boolean","optional":true},{"name":"contextId","type":"number","optional":true},{"name":"returnByValue","type":"boolean","optional":true},{"name":"generatePreview","type":"boolean","optional":true}],["result","wasThrown"],false);InspectorBackend.registerCommand("Runtime.callFunctionOn",[{"name":"objectId","type":"string","optional":false},{"name":"functionDeclaration","type":"string","optional":false},{"name":"arguments","type":"object","optional":true},{"name":"doNotPauseOnExceptionsAndMuteConsole","type":"boolean","optional":true},{"name":"returnByValue","type":"boolean","optional":true},{"name":"generatePreview","type":"boolean","optional":true}],["result","wasThrown"],false);InspectorBackend.registerCommand("Runtime.getProperties",[{"name":"objectId","type":"string","optional":false},{"name":"ownProperties","type":"boolean","optional":true},{"name":"accessorPropertiesOnly","type":"boolean","optional":true}],["result","internalProperties"],false);InspectorBackend.registerCommand("Runtime.releaseObject",[{"name":"objectId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Runtime.releaseObjectGroup",[{"name":"objectGroup","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Runtime.run",[],[],false);InspectorBackend.registerCommand("Runtime.enable",[],[],false);InspectorBackend.registerCommand("Runtime.disable",[],[],false);InspectorBackend.registerConsoleDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Console");InspectorBackend.registerEnum("Console.ConsoleMessageSource",{XML:"xml",Javascript:"javascript",Network:"network",ConsoleAPI:"console-api",Storage:"storage",Appcache:"appcache",Rendering:"rendering",Css:"css",Security:"security",Other:"other",Deprecation:"deprecation"});InspectorBackend.registerEnum("Console.ConsoleMessageLevel",{Log:"log",Warning:"warning",Error:"error",Debug:"debug"});InspectorBackend.registerEnum("Console.ConsoleMessageType",{Log:"log",Dir:"dir",DirXML:"dirxml",Table:"table",Trace:"trace",Clear:"clear",StartGroup:"startGroup",StartGroupCollapsed:"startGroupCollapsed",EndGroup:"endGroup",Assert:"assert",Timing:"timing",Profile:"profile",ProfileEnd:"profileEnd"});InspectorBackend.registerEvent("Console.messageAdded",["message"]);InspectorBackend.registerEvent("Console.messageRepeatCountUpdated",["count","timestamp"]);InspectorBackend.registerEvent("Console.messagesCleared",[]);InspectorBackend.registerCommand("Console.enable",[],[],false);InspectorBackend.registerCommand("Console.disable",[],[],false);InspectorBackend.registerCommand("Console.clearMessages",[],[],false);InspectorBackend.registerCommand("Console.setMonitoringXHREnabled",[{"name":"enabled","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Console.addInspectedNode",[{"name":"nodeId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Console.addInspectedHeapObject",[{"name":"heapObjectId","type":"number","optional":false}],[],false);InspectorBackend.registerNetworkDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Network");InspectorBackend.registerEnum("Network.InitiatorType",{Parser:"parser",Script:"script",Other:"other"});InspectorBackend.registerEvent("Network.requestWillBeSent",["requestId","frameId","loaderId","documentURL","request","timestamp","initiator","redirectResponse"]);InspectorBackend.registerEvent("Network.requestServedFromCache",["requestId"]);InspectorBackend.registerEvent("Network.responseReceived",["requestId","frameId","loaderId","timestamp","type","response"]);InspectorBackend.registerEvent("Network.dataReceived",["requestId","timestamp","dataLength","encodedDataLength"]);InspectorBackend.registerEvent("Network.loadingFinished",["requestId","timestamp"]);InspectorBackend.registerEvent("Network.loadingFailed",["requestId","timestamp","errorText","canceled"]);InspectorBackend.registerEvent("Network.requestServedFromMemoryCache",["requestId","frameId","loaderId","documentURL","timestamp","initiator","resource"]);InspectorBackend.registerEvent("Network.webSocketWillSendHandshakeRequest",["requestId","timestamp","request"]);InspectorBackend.registerEvent("Network.webSocketHandshakeResponseReceived",["requestId","timestamp","response"]);InspectorBackend.registerEvent("Network.webSocketCreated",["requestId","url"]);InspectorBackend.registerEvent("Network.webSocketClosed",["requestId","timestamp"]);InspectorBackend.registerEvent("Network.webSocketFrameReceived",["requestId","timestamp","response"]);InspectorBackend.registerEvent("Network.webSocketFrameError",["requestId","timestamp","errorMessage"]);InspectorBackend.registerEvent("Network.webSocketFrameSent",["requestId","timestamp","response"]);InspectorBackend.registerCommand("Network.enable",[],[],false);InspectorBackend.registerCommand("Network.disable",[],[],false);InspectorBackend.registerCommand("Network.setUserAgentOverride",[{"name":"userAgent","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Network.setExtraHTTPHeaders",[{"name":"headers","type":"object","optional":false}],[],false);InspectorBackend.registerCommand("Network.getResponseBody",[{"name":"requestId","type":"string","optional":false}],["body","base64Encoded"],false);InspectorBackend.registerCommand("Network.replayXHR",[{"name":"requestId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Network.canClearBrowserCache",[],["result"],false);InspectorBackend.registerCommand("Network.clearBrowserCache",[],[],false);InspectorBackend.registerCommand("Network.canClearBrowserCookies",[],["result"],false);InspectorBackend.registerCommand("Network.clearBrowserCookies",[],[],false);InspectorBackend.registerCommand("Network.setCacheDisabled",[{"name":"cacheDisabled","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Network.loadResourceForFrontend",[{"name":"frameId","type":"string","optional":false},{"name":"url","type":"string","optional":false},{"name":"requestHeaders","type":"object","optional":true}],["statusCode","responseHeaders","content"],false);InspectorBackend.registerDatabaseDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Database");InspectorBackend.registerEvent("Database.addDatabase",["database"]);InspectorBackend.registerCommand("Database.enable",[],[],false);InspectorBackend.registerCommand("Database.disable",[],[],false);InspectorBackend.registerCommand("Database.getDatabaseTableNames",[{"name":"databaseId","type":"string","optional":false}],["tableNames"],false);InspectorBackend.registerCommand("Database.executeSQL",[{"name":"databaseId","type":"string","optional":false},{"name":"query","type":"string","optional":false}],["columnNames","values","sqlError"],false);InspectorBackend.registerIndexedDBDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"IndexedDB");InspectorBackend.registerEnum("IndexedDB.KeyType",{Number:"number",String:"string",Date:"date",Array:"array"});InspectorBackend.registerEnum("IndexedDB.KeyPathType",{Null:"null",String:"string",Array:"array"});InspectorBackend.registerCommand("IndexedDB.enable",[],[],false);InspectorBackend.registerCommand("IndexedDB.disable",[],[],false);InspectorBackend.registerCommand("IndexedDB.requestDatabaseNames",[{"name":"securityOrigin","type":"string","optional":false}],["databaseNames"],false);InspectorBackend.registerCommand("IndexedDB.requestDatabase",[{"name":"securityOrigin","type":"string","optional":false},{"name":"databaseName","type":"string","optional":false}],["databaseWithObjectStores"],false);InspectorBackend.registerCommand("IndexedDB.requestData",[{"name":"securityOrigin","type":"string","optional":false},{"name":"databaseName","type":"string","optional":false},{"name":"objectStoreName","type":"string","optional":false},{"name":"indexName","type":"string","optional":false},{"name":"skipCount","type":"number","optional":false},{"name":"pageSize","type":"number","optional":false},{"name":"keyRange","type":"object","optional":true}],["objectStoreDataEntries","hasMore"],false);InspectorBackend.registerCommand("IndexedDB.clearObjectStore",[{"name":"securityOrigin","type":"string","optional":false},{"name":"databaseName","type":"string","optional":false},{"name":"objectStoreName","type":"string","optional":false}],[],false);InspectorBackend.registerDOMStorageDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"DOMStorage");InspectorBackend.registerEvent("DOMStorage.domStorageItemsCleared",["storageId"]);InspectorBackend.registerEvent("DOMStorage.domStorageItemRemoved",["storageId","key"]);InspectorBackend.registerEvent("DOMStorage.domStorageItemAdded",["storageId","key","newValue"]);InspectorBackend.registerEvent("DOMStorage.domStorageItemUpdated",["storageId","key","oldValue","newValue"]);InspectorBackend.registerCommand("DOMStorage.enable",[],[],false);InspectorBackend.registerCommand("DOMStorage.disable",[],[],false);InspectorBackend.registerCommand("DOMStorage.getValue",[{"name":"storageId","type":"object","optional":false},{"name":"key","type":"string","optional":false}],["value"],false);InspectorBackend.registerCommand("DOMStorage.getDOMStorageItems",[{"name":"storageId","type":"object","optional":false}],["entries"],false);InspectorBackend.registerCommand("DOMStorage.setDOMStorageItem",[{"name":"storageId","type":"object","optional":false},{"name":"key","type":"string","optional":false},{"name":"value","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMStorage.removeDOMStorageItem",[{"name":"storageId","type":"object","optional":false},{"name":"key","type":"string","optional":false}],[],false);InspectorBackend.registerApplicationCacheDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"ApplicationCache");InspectorBackend.registerEvent("ApplicationCache.applicationCacheStatusUpdated",["frameId","manifestURL","status"]);InspectorBackend.registerEvent("ApplicationCache.networkStateUpdated",["isNowOnline"]);InspectorBackend.registerCommand("ApplicationCache.getFramesWithManifests",[],["frameIds"],false);InspectorBackend.registerCommand("ApplicationCache.enable",[],[],false);InspectorBackend.registerCommand("ApplicationCache.getManifestForFrame",[{"name":"frameId","type":"string","optional":false}],["manifestURL"],false);InspectorBackend.registerCommand("ApplicationCache.getApplicationCacheForFrame",[{"name":"frameId","type":"string","optional":false}],["applicationCache"],false);InspectorBackend.registerFileSystemDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"FileSystem");InspectorBackend.registerCommand("FileSystem.enable",[],[],false);InspectorBackend.registerCommand("FileSystem.disable",[],[],false);InspectorBackend.registerCommand("FileSystem.requestFileSystemRoot",[{"name":"origin","type":"string","optional":false},{"name":"type","type":"string","optional":false}],["errorCode","root"],false);InspectorBackend.registerCommand("FileSystem.requestDirectoryContent",[{"name":"url","type":"string","optional":false}],["errorCode","entries"],false);InspectorBackend.registerCommand("FileSystem.requestMetadata",[{"name":"url","type":"string","optional":false}],["errorCode","metadata"],false);InspectorBackend.registerCommand("FileSystem.requestFileContent",[{"name":"url","type":"string","optional":false},{"name":"readAsText","type":"boolean","optional":false},{"name":"start","type":"number","optional":true},{"name":"end","type":"number","optional":true},{"name":"charset","type":"string","optional":true}],["errorCode","content","charset"],false);InspectorBackend.registerCommand("FileSystem.deleteEntry",[{"name":"url","type":"string","optional":false}],["errorCode"],false);InspectorBackend.registerDOMDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"DOM");InspectorBackend.registerEvent("DOM.documentUpdated",[]);InspectorBackend.registerEvent("DOM.inspectNodeRequested",["nodeId"]);InspectorBackend.registerEvent("DOM.setChildNodes",["parentId","nodes"]);InspectorBackend.registerEvent("DOM.attributeModified",["nodeId","name","value"]);InspectorBackend.registerEvent("DOM.attributeRemoved",["nodeId","name"]);InspectorBackend.registerEvent("DOM.inlineStyleInvalidated",["nodeIds"]);InspectorBackend.registerEvent("DOM.characterDataModified",["nodeId","characterData"]);InspectorBackend.registerEvent("DOM.childNodeCountUpdated",["nodeId","childNodeCount"]);InspectorBackend.registerEvent("DOM.childNodeInserted",["parentNodeId","previousNodeId","node"]);InspectorBackend.registerEvent("DOM.childNodeRemoved",["parentNodeId","nodeId"]);InspectorBackend.registerEvent("DOM.shadowRootPushed",["hostId","root"]);InspectorBackend.registerEvent("DOM.shadowRootPopped",["hostId","rootId"]);InspectorBackend.registerCommand("DOM.getDocument",[],["root"],false);InspectorBackend.registerCommand("DOM.requestChildNodes",[{"name":"nodeId","type":"number","optional":false},{"name":"depth","type":"number","optional":true}],[],false);InspectorBackend.registerCommand("DOM.querySelector",[{"name":"nodeId","type":"number","optional":false},{"name":"selector","type":"string","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.querySelectorAll",[{"name":"nodeId","type":"number","optional":false},{"name":"selector","type":"string","optional":false}],["nodeIds"],false);InspectorBackend.registerCommand("DOM.setNodeName",[{"name":"nodeId","type":"number","optional":false},{"name":"name","type":"string","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.setNodeValue",[{"name":"nodeId","type":"number","optional":false},{"name":"value","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.removeNode",[{"name":"nodeId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("DOM.setAttributeValue",[{"name":"nodeId","type":"number","optional":false},{"name":"name","type":"string","optional":false},{"name":"value","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.setAttributesAsText",[{"name":"nodeId","type":"number","optional":false},{"name":"text","type":"string","optional":false},{"name":"name","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("DOM.removeAttribute",[{"name":"nodeId","type":"number","optional":false},{"name":"name","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.getEventListenersForNode",[{"name":"nodeId","type":"number","optional":false},{"name":"objectGroup","type":"string","optional":true}],["listeners"],false);InspectorBackend.registerCommand("DOM.getOuterHTML",[{"name":"nodeId","type":"number","optional":false}],["outerHTML"],false);InspectorBackend.registerCommand("DOM.setOuterHTML",[{"name":"nodeId","type":"number","optional":false},{"name":"outerHTML","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.performSearch",[{"name":"query","type":"string","optional":false}],["searchId","resultCount"],false);InspectorBackend.registerCommand("DOM.getSearchResults",[{"name":"searchId","type":"string","optional":false},{"name":"fromIndex","type":"number","optional":false},{"name":"toIndex","type":"number","optional":false}],["nodeIds"],false);InspectorBackend.registerCommand("DOM.discardSearchResults",[{"name":"searchId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.requestNode",[{"name":"objectId","type":"string","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.setInspectModeEnabled",[{"name":"enabled","type":"boolean","optional":false},{"name":"inspectShadowDOM","type":"boolean","optional":true},{"name":"highlightConfig","type":"object","optional":true}],[],false);InspectorBackend.registerCommand("DOM.highlightRect",[{"name":"x","type":"number","optional":false},{"name":"y","type":"number","optional":false},{"name":"width","type":"number","optional":false},{"name":"height","type":"number","optional":false},{"name":"color","type":"object","optional":true},{"name":"outlineColor","type":"object","optional":true}],[],false);InspectorBackend.registerCommand("DOM.highlightQuad",[{"name":"quad","type":"object","optional":false},{"name":"color","type":"object","optional":true},{"name":"outlineColor","type":"object","optional":true}],[],false);InspectorBackend.registerCommand("DOM.highlightNode",[{"name":"highlightConfig","type":"object","optional":false},{"name":"nodeId","type":"number","optional":true},{"name":"objectId","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("DOM.hideHighlight",[],[],false);InspectorBackend.registerCommand("DOM.highlightFrame",[{"name":"frameId","type":"string","optional":false},{"name":"contentColor","type":"object","optional":true},{"name":"contentOutlineColor","type":"object","optional":true}],[],false);InspectorBackend.registerCommand("DOM.pushNodeByPathToFrontend",[{"name":"path","type":"string","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.pushNodeByBackendIdToFrontend",[{"name":"backendNodeId","type":"number","optional":false}],["nodeId"],false);InspectorBackend.registerCommand("DOM.releaseBackendNodeIds",[{"name":"nodeGroup","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOM.resolveNode",[{"name":"nodeId","type":"number","optional":false},{"name":"objectGroup","type":"string","optional":true}],["object"],false);InspectorBackend.registerCommand("DOM.getAttributes",[{"name":"nodeId","type":"number","optional":false}],["attributes"],false);InspectorBackend.registerCommand("DOM.moveTo",[{"name":"nodeId","type":"number","optional":false},{"name":"targetNodeId","type":"number","optional":false},{"name":"insertBeforeNodeId","type":"number","optional":true}],["nodeId"],false);InspectorBackend.registerCommand("DOM.undo",[],[],false);InspectorBackend.registerCommand("DOM.redo",[],[],false);InspectorBackend.registerCommand("DOM.markUndoableState",[],[],false);InspectorBackend.registerCommand("DOM.focus",[{"name":"nodeId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("DOM.setFileInputFiles",[{"name":"nodeId","type":"number","optional":false},{"name":"files","type":"object","optional":false}],[],false);InspectorBackend.registerCSSDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"CSS");InspectorBackend.registerEnum("CSS.StyleSheetOrigin",{User:"user",UserAgent:"user-agent",Inspector:"inspector",Regular:"regular"});InspectorBackend.registerEnum("CSS.CSSPropertyStatus",{Active:"active",Inactive:"inactive",Disabled:"disabled",Style:"style"});InspectorBackend.registerEnum("CSS.CSSMediaSource",{MediaRule:"mediaRule",ImportRule:"importRule",LinkedSheet:"linkedSheet",InlineSheet:"inlineSheet"});InspectorBackend.registerEnum("CSS.RegionRegionOverset",{Overset:"overset",Fit:"fit",Empty:"empty"});InspectorBackend.registerEvent("CSS.mediaQueryResultChanged",[]);InspectorBackend.registerEvent("CSS.styleSheetChanged",["styleSheetId"]);InspectorBackend.registerEvent("CSS.styleSheetAdded",["header"]);InspectorBackend.registerEvent("CSS.styleSheetRemoved",["styleSheetId"]);InspectorBackend.registerEvent("CSS.namedFlowCreated",["namedFlow"]);InspectorBackend.registerEvent("CSS.namedFlowRemoved",["documentNodeId","flowName"]);InspectorBackend.registerEvent("CSS.regionLayoutUpdated",["namedFlow"]);InspectorBackend.registerEvent("CSS.regionOversetChanged",["namedFlow"]);InspectorBackend.registerCommand("CSS.enable",[],[],false);InspectorBackend.registerCommand("CSS.disable",[],[],false);InspectorBackend.registerCommand("CSS.getMatchedStylesForNode",[{"name":"nodeId","type":"number","optional":false},{"name":"includePseudo","type":"boolean","optional":true},{"name":"includeInherited","type":"boolean","optional":true}],["matchedCSSRules","pseudoElements","inherited"],false);InspectorBackend.registerCommand("CSS.getInlineStylesForNode",[{"name":"nodeId","type":"number","optional":false}],["inlineStyle","attributesStyle"],false);InspectorBackend.registerCommand("CSS.getComputedStyleForNode",[{"name":"nodeId","type":"number","optional":false}],["computedStyle"],false);InspectorBackend.registerCommand("CSS.getAllStyleSheets",[],["headers"],false);InspectorBackend.registerCommand("CSS.getStyleSheet",[{"name":"styleSheetId","type":"string","optional":false}],["styleSheet"],false);InspectorBackend.registerCommand("CSS.getStyleSheetText",[{"name":"styleSheetId","type":"string","optional":false}],["text"],false);InspectorBackend.registerCommand("CSS.setStyleSheetText",[{"name":"styleSheetId","type":"string","optional":false},{"name":"text","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("CSS.setStyleText",[{"name":"styleId","type":"object","optional":false},{"name":"text","type":"string","optional":false}],["style"],false);InspectorBackend.registerCommand("CSS.setPropertyText",[{"name":"styleId","type":"object","optional":false},{"name":"propertyIndex","type":"number","optional":false},{"name":"text","type":"string","optional":false},{"name":"overwrite","type":"boolean","optional":false}],["style"],false);InspectorBackend.registerCommand("CSS.toggleProperty",[{"name":"styleId","type":"object","optional":false},{"name":"propertyIndex","type":"number","optional":false},{"name":"disable","type":"boolean","optional":false}],["style"],false);InspectorBackend.registerCommand("CSS.setRuleSelector",[{"name":"ruleId","type":"object","optional":false},{"name":"selector","type":"string","optional":false}],["rule"],false);InspectorBackend.registerCommand("CSS.addRule",[{"name":"contextNodeId","type":"number","optional":false},{"name":"selector","type":"string","optional":false}],["rule"],false);InspectorBackend.registerCommand("CSS.getSupportedCSSProperties",[],["cssProperties"],false);InspectorBackend.registerCommand("CSS.forcePseudoState",[{"name":"nodeId","type":"number","optional":false},{"name":"forcedPseudoClasses","type":"object","optional":false}],[],false);InspectorBackend.registerCommand("CSS.getNamedFlowCollection",[{"name":"documentNodeId","type":"number","optional":false}],["namedFlows"],false);InspectorBackend.registerTimelineDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Timeline");InspectorBackend.registerEvent("Timeline.eventRecorded",["record"]);InspectorBackend.registerEvent("Timeline.timelineStarted",["timestampsBase","startTime"]);InspectorBackend.registerCommand("Timeline.start",[{"name":"maxCallStackDepth","type":"number","optional":true},{"name":"includeDomCounters","type":"boolean","optional":true},{"name":"includeNativeMemoryStatistics","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Timeline.stop",[],[],false);InspectorBackend.registerDebuggerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Debugger");InspectorBackend.registerEnum("Debugger.ScopeType",{Global:"global",Local:"local",With:"with",Closure:"closure",Catch:"catch"});InspectorBackend.registerEvent("Debugger.globalObjectCleared",[]);InspectorBackend.registerEvent("Debugger.scriptParsed",["scriptId","url","startLine","startColumn","endLine","endColumn","isContentScript","sourceMapURL","hasSourceURL"]);InspectorBackend.registerEvent("Debugger.scriptFailedToParse",["url","scriptSource","startLine","errorLine","errorMessage"]);InspectorBackend.registerEvent("Debugger.breakpointResolved",["breakpointId","location"]);InspectorBackend.registerEvent("Debugger.paused",["callFrames","reason","data","hitBreakpoints"]);InspectorBackend.registerEvent("Debugger.resumed",[]);InspectorBackend.registerCommand("Debugger.enable",[],[],false);InspectorBackend.registerCommand("Debugger.disable",[],[],false);InspectorBackend.registerCommand("Debugger.setBreakpointsActive",[{"name":"active","type":"boolean","optional":false}],[],false);InspectorBackend.registerCommand("Debugger.setBreakpointByUrl",[{"name":"lineNumber","type":"number","optional":false},{"name":"url","type":"string","optional":true},{"name":"urlRegex","type":"string","optional":true},{"name":"columnNumber","type":"number","optional":true},{"name":"condition","type":"string","optional":true},{"name":"isAntibreakpoint","type":"boolean","optional":true}],["breakpointId","locations"],false);InspectorBackend.registerCommand("Debugger.setBreakpoint",[{"name":"location","type":"object","optional":false},{"name":"condition","type":"string","optional":true}],["breakpointId","actualLocation"],false);InspectorBackend.registerCommand("Debugger.removeBreakpoint",[{"name":"breakpointId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Debugger.continueToLocation",[{"name":"location","type":"object","optional":false},{"name":"interstatementLocation","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Debugger.stepOver",[],[],false);InspectorBackend.registerCommand("Debugger.stepInto",[],[],false);InspectorBackend.registerCommand("Debugger.stepOut",[],[],false);InspectorBackend.registerCommand("Debugger.pause",[],[],false);InspectorBackend.registerCommand("Debugger.resume",[],[],false);InspectorBackend.registerCommand("Debugger.searchInContent",[{"name":"scriptId","type":"string","optional":false},{"name":"query","type":"string","optional":false},{"name":"caseSensitive","type":"boolean","optional":true},{"name":"isRegex","type":"boolean","optional":true}],["result"],false);InspectorBackend.registerCommand("Debugger.canSetScriptSource",[],["result"],false);InspectorBackend.registerCommand("Debugger.setScriptSource",[{"name":"scriptId","type":"string","optional":false},{"name":"scriptSource","type":"string","optional":false},{"name":"preview","type":"boolean","optional":true}],["callFrames","result"],true);InspectorBackend.registerCommand("Debugger.restartFrame",[{"name":"callFrameId","type":"string","optional":false}],["callFrames","result"],false);InspectorBackend.registerCommand("Debugger.getScriptSource",[{"name":"scriptId","type":"string","optional":false}],["scriptSource"],false);InspectorBackend.registerCommand("Debugger.getFunctionDetails",[{"name":"functionId","type":"string","optional":false}],["details"],false);InspectorBackend.registerCommand("Debugger.setPauseOnExceptions",[{"name":"state","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Debugger.evaluateOnCallFrame",[{"name":"callFrameId","type":"string","optional":false},{"name":"expression","type":"string","optional":false},{"name":"objectGroup","type":"string","optional":true},{"name":"includeCommandLineAPI","type":"boolean","optional":true},{"name":"doNotPauseOnExceptionsAndMuteConsole","type":"boolean","optional":true},{"name":"returnByValue","type":"boolean","optional":true},{"name":"generatePreview","type":"boolean","optional":true}],["result","wasThrown"],false);InspectorBackend.registerCommand("Debugger.compileScript",[{"name":"expression","type":"string","optional":false},{"name":"sourceURL","type":"string","optional":false}],["scriptId","syntaxErrorMessage"],false);InspectorBackend.registerCommand("Debugger.runScript",[{"name":"scriptId","type":"string","optional":false},{"name":"contextId","type":"number","optional":true},{"name":"objectGroup","type":"string","optional":true},{"name":"doNotPauseOnExceptionsAndMuteConsole","type":"boolean","optional":true}],["result","wasThrown"],false);InspectorBackend.registerCommand("Debugger.setOverlayMessage",[{"name":"message","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("Debugger.setVariableValue",[{"name":"scopeNumber","type":"number","optional":false},{"name":"variableName","type":"string","optional":false},{"name":"newValue","type":"object","optional":false},{"name":"callFrameId","type":"string","optional":true},{"name":"functionObjectId","type":"string","optional":true}],[],false);InspectorBackend.registerCommand("Debugger.getStepInPositions",[{"name":"callFrameId","type":"string","optional":false}],["stepInPositions"],false);InspectorBackend.registerCommand("Debugger.getBacktrace",[],["callFrames"],false);InspectorBackend.registerCommand("Debugger.skipStackFrames",[{"name":"script","type":"string","optional":true}],[],false);InspectorBackend.registerDOMDebuggerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"DOMDebugger");InspectorBackend.registerEnum("DOMDebugger.DOMBreakpointType",{SubtreeModified:"subtree-modified",AttributeModified:"attribute-modified",NodeRemoved:"node-removed"});InspectorBackend.registerCommand("DOMDebugger.setDOMBreakpoint",[{"name":"nodeId","type":"number","optional":false},{"name":"type","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.removeDOMBreakpoint",[{"name":"nodeId","type":"number","optional":false},{"name":"type","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.setEventListenerBreakpoint",[{"name":"eventName","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.removeEventListenerBreakpoint",[{"name":"eventName","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.setInstrumentationBreakpoint",[{"name":"eventName","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.removeInstrumentationBreakpoint",[{"name":"eventName","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.setXHRBreakpoint",[{"name":"url","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("DOMDebugger.removeXHRBreakpoint",[{"name":"url","type":"string","optional":false}],[],false);InspectorBackend.registerProfilerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Profiler");InspectorBackend.registerEvent("Profiler.addProfileHeader",["header"]);InspectorBackend.registerEvent("Profiler.setRecordingProfile",["isProfiling"]);InspectorBackend.registerEvent("Profiler.resetProfiles",[]);InspectorBackend.registerCommand("Profiler.enable",[],[],false);InspectorBackend.registerCommand("Profiler.disable",[],[],false);InspectorBackend.registerCommand("Profiler.start",[],[],false);InspectorBackend.registerCommand("Profiler.stop",[],["header"],false);InspectorBackend.registerCommand("Profiler.getProfileHeaders",[],["headers"],false);InspectorBackend.registerCommand("Profiler.getCPUProfile",[{"name":"uid","type":"number","optional":false}],["profile"],false);InspectorBackend.registerCommand("Profiler.removeProfile",[{"name":"type","type":"string","optional":false},{"name":"uid","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Profiler.clearProfiles",[],[],false);InspectorBackend.registerHeapProfilerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"HeapProfiler");InspectorBackend.registerEvent("HeapProfiler.addProfileHeader",["header"]);InspectorBackend.registerEvent("HeapProfiler.addHeapSnapshotChunk",["uid","chunk"]);InspectorBackend.registerEvent("HeapProfiler.finishHeapSnapshot",["uid"]);InspectorBackend.registerEvent("HeapProfiler.resetProfiles",[]);InspectorBackend.registerEvent("HeapProfiler.reportHeapSnapshotProgress",["done","total"]);InspectorBackend.registerEvent("HeapProfiler.lastSeenObjectId",["lastSeenObjectId","timestamp"]);InspectorBackend.registerEvent("HeapProfiler.heapStatsUpdate",["statsUpdate"]);InspectorBackend.registerCommand("HeapProfiler.getProfileHeaders",[],["headers"],false);InspectorBackend.registerCommand("HeapProfiler.startTrackingHeapObjects",[],[],false);InspectorBackend.registerCommand("HeapProfiler.stopTrackingHeapObjects",[],[],false);InspectorBackend.registerCommand("HeapProfiler.getHeapSnapshot",[{"name":"uid","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("HeapProfiler.removeProfile",[{"name":"uid","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("HeapProfiler.clearProfiles",[],[],false);InspectorBackend.registerCommand("HeapProfiler.takeHeapSnapshot",[{"name":"reportProgress","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("HeapProfiler.collectGarbage",[],[],false);InspectorBackend.registerCommand("HeapProfiler.getObjectByHeapObjectId",[{"name":"objectId","type":"string","optional":false},{"name":"objectGroup","type":"string","optional":true}],["result"],false);InspectorBackend.registerCommand("HeapProfiler.getHeapObjectId",[{"name":"objectId","type":"string","optional":false}],["heapSnapshotObjectId"],false);InspectorBackend.registerWorkerDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Worker");InspectorBackend.registerEvent("Worker.workerCreated",["workerId","url","inspectorConnected"]);InspectorBackend.registerEvent("Worker.workerTerminated",["workerId"]);InspectorBackend.registerEvent("Worker.dispatchMessageFromWorker",["workerId","message"]);InspectorBackend.registerEvent("Worker.disconnectedFromWorker",[]);InspectorBackend.registerCommand("Worker.enable",[],[],false);InspectorBackend.registerCommand("Worker.disable",[],[],false);InspectorBackend.registerCommand("Worker.sendMessageToWorker",[{"name":"workerId","type":"number","optional":false},{"name":"message","type":"object","optional":false}],[],false);InspectorBackend.registerCommand("Worker.canInspectWorkers",[],["result"],false);InspectorBackend.registerCommand("Worker.connectToWorker",[{"name":"workerId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Worker.disconnectFromWorker",[{"name":"workerId","type":"number","optional":false}],[],false);InspectorBackend.registerCommand("Worker.setAutoconnectToWorkers",[{"name":"value","type":"boolean","optional":false}],[],false);InspectorBackend.registerCanvasDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Canvas");InspectorBackend.registerEnum("Canvas.CallArgumentType",{Object:"object",Function:"function",Undefined:"undefined",String:"string",Number:"number",Boolean:"boolean"});InspectorBackend.registerEnum("Canvas.CallArgumentSubtype",{Array:"array",Null:"null",Node:"node",Regexp:"regexp",Date:"date"});InspectorBackend.registerEvent("Canvas.contextCreated",["frameId"]);InspectorBackend.registerEvent("Canvas.traceLogsRemoved",["frameId","traceLogId"]);InspectorBackend.registerCommand("Canvas.enable",[],[],false);InspectorBackend.registerCommand("Canvas.disable",[],[],false);InspectorBackend.registerCommand("Canvas.dropTraceLog",[{"name":"traceLogId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Canvas.hasUninstrumentedCanvases",[],["result"],false);InspectorBackend.registerCommand("Canvas.captureFrame",[{"name":"frameId","type":"string","optional":true}],["traceLogId"],false);InspectorBackend.registerCommand("Canvas.startCapturing",[{"name":"frameId","type":"string","optional":true}],["traceLogId"],false);InspectorBackend.registerCommand("Canvas.stopCapturing",[{"name":"traceLogId","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Canvas.getTraceLog",[{"name":"traceLogId","type":"string","optional":false},{"name":"startOffset","type":"number","optional":true},{"name":"maxLength","type":"number","optional":true}],["traceLog"],false);InspectorBackend.registerCommand("Canvas.replayTraceLog",[{"name":"traceLogId","type":"string","optional":false},{"name":"stepNo","type":"number","optional":false}],["resourceState","replayTime"],false);InspectorBackend.registerCommand("Canvas.getResourceState",[{"name":"traceLogId","type":"string","optional":false},{"name":"resourceId","type":"string","optional":false}],["resourceState"],false);InspectorBackend.registerCommand("Canvas.evaluateTraceLogCallArgument",[{"name":"traceLogId","type":"string","optional":false},{"name":"callIndex","type":"number","optional":false},{"name":"argumentIndex","type":"number","optional":false},{"name":"objectGroup","type":"string","optional":true}],["result","resourceState"],false);InspectorBackend.registerInputDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Input");InspectorBackend.registerEnum("Input.TouchPointState",{TouchPressed:"touchPressed",TouchReleased:"touchReleased",TouchMoved:"touchMoved",TouchStationary:"touchStationary",TouchCancelled:"touchCancelled"});InspectorBackend.registerCommand("Input.dispatchKeyEvent",[{"name":"type","type":"string","optional":false},{"name":"modifiers","type":"number","optional":true},{"name":"timestamp","type":"number","optional":true},{"name":"text","type":"string","optional":true},{"name":"unmodifiedText","type":"string","optional":true},{"name":"keyIdentifier","type":"string","optional":true},{"name":"windowsVirtualKeyCode","type":"number","optional":true},{"name":"nativeVirtualKeyCode","type":"number","optional":true},{"name":"macCharCode","type":"number","optional":true},{"name":"autoRepeat","type":"boolean","optional":true},{"name":"isKeypad","type":"boolean","optional":true},{"name":"isSystemKey","type":"boolean","optional":true}],[],false);InspectorBackend.registerCommand("Input.dispatchMouseEvent",[{"name":"type","type":"string","optional":false},{"name":"x","type":"number","optional":false},{"name":"y","type":"number","optional":false},{"name":"modifiers","type":"number","optional":true},{"name":"timestamp","type":"number","optional":true},{"name":"button","type":"string","optional":true},{"name":"clickCount","type":"number","optional":true}],[],false);InspectorBackend.registerCommand("Input.dispatchTouchEvent",[{"name":"type","type":"string","optional":false},{"name":"touchPoints","type":"object","optional":false},{"name":"modifiers","type":"number","optional":true},{"name":"timestamp","type":"number","optional":true}],[],false);InspectorBackend.registerLayerTreeDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"LayerTree");InspectorBackend.registerEvent("LayerTree.layerTreeDidChange",[]);InspectorBackend.registerCommand("LayerTree.enable",[],[],false);InspectorBackend.registerCommand("LayerTree.disable",[],[],false);InspectorBackend.registerCommand("LayerTree.getLayers",[{"name":"nodeId","type":"number","optional":true}],["layers"],false);InspectorBackend.registerTracingDispatcher=InspectorBackend.registerDomainDispatcher.bind(InspectorBackend,"Tracing");InspectorBackend.registerEvent("Tracing.dataCollected",["value"]);InspectorBackend.registerEvent("Tracing.tracingComplete",[]);InspectorBackend.registerCommand("Tracing.start",[{"name":"categories","type":"string","optional":false}],[],false);InspectorBackend.registerCommand("Tracing.end",[],[],false);if(!window.InspectorExtensionRegistry){WebInspector.InspectorExtensionRegistryStub=function()
|
| {}
|
| WebInspector.InspectorExtensionRegistryStub.prototype={getExtensionsAsync:function()
|
| {}}
|
| @@ -1069,7 +1066,7 @@
|
| WebInspector.notifications=new WebInspector.Object();var Preferences={maxInlineTextChildLength:80,minConsoleHeight:75,minSidebarWidth:100,minSidebarHeight:75,minElementsSidebarWidth:200,minElementsSidebarHeight:200,minScriptsSidebarWidth:200,applicationTitle:"Developer Tools - %s",experimentsEnabled:false}
|
| var Capabilities={canInspectWorkers:false}
|
| WebInspector.Settings=function()
|
| -{this._eventSupport=new WebInspector.Object();this._registry=({});this.colorFormat=this.createSetting("colorFormat","original");this.consoleHistory=this.createSetting("consoleHistory",[]);this.domWordWrap=this.createSetting("domWordWrap",true);this.eventListenersFilter=this.createSetting("eventListenersFilter","all");this.lastActivePanel=this.createSetting("lastActivePanel","elements");this.lastViewedScriptFile=this.createSetting("lastViewedScriptFile","application");this.monitoringXHREnabled=this.createSetting("monitoringXHREnabled",false);this.preserveConsoleLog=this.createSetting("preserveConsoleLog",false);this.resourcesLargeRows=this.createSetting("resourcesLargeRows",true);this.resourcesSortOptions=this.createSetting("resourcesSortOptions",{timeOption:"responseTime",sizeOption:"transferSize"});this.resourceViewTab=this.createSetting("resourceViewTab","preview");this.showInheritedComputedStyleProperties=this.createSetting("showInheritedComputedStyleProperties",false);this.showUserAgentStyles=this.createSetting("showUserAgentStyles",true);this.watchExpressions=this.createSetting("watchExpressions",[]);this.breakpoints=this.createSetting("breakpoints",[]);this.eventListenerBreakpoints=this.createSetting("eventListenerBreakpoints",[]);this.domBreakpoints=this.createSetting("domBreakpoints",[]);this.xhrBreakpoints=this.createSetting("xhrBreakpoints",[]);this.jsSourceMapsEnabled=this.createSetting("sourceMapsEnabled",true);this.cssSourceMapsEnabled=this.createSetting("cssSourceMapsEnabled",true);this.cacheDisabled=this.createSetting("cacheDisabled",false);this.enableOverridesOnStartup=this.createSetting("enableOverridesOnStartup",false);this.overrideUserAgent=this.createSetting("overrideUserAgent",false);this.userAgent=this.createSetting("userAgent","");this.overrideDeviceMetrics=this.createSetting("overrideDeviceMetrics",false);this.deviceMetrics=this.createSetting("deviceMetrics","");this.deviceFitWindow=this.createSetting("deviceFitWindow",false);this.emulateTouchEvents=this.createSetting("emulateTouchEvents",false);this.showShadowDOM=this.createSetting("showShadowDOM",false);this.zoomLevel=this.createSetting("zoomLevel",0);this.savedURLs=this.createSetting("savedURLs",{});this.javaScriptDisabled=this.createSetting("javaScriptDisabled",false);this.overrideGeolocation=this.createSetting("overrideGeolocation",false);this.geolocationOverride=this.createSetting("geolocationOverride","");this.overrideDeviceOrientation=this.createSetting("overrideDeviceOrientation",false);this.deviceOrientationOverride=this.createSetting("deviceOrientationOverride","");this.showAdvancedHeapSnapshotProperties=this.createSetting("showAdvancedHeapSnapshotProperties",false);this.highResolutionCpuProfiling=this.createSetting("highResolutionCpuProfiling",false);this.searchInContentScripts=this.createSetting("searchInContentScripts",false);this.textEditorIndent=this.createSetting("textEditorIndent"," ");this.textEditorAutoDetectIndent=this.createSetting("textEditorAutoIndentIndent",true);this.lastDockState=this.createSetting("lastDockState","");this.cssReloadEnabled=this.createSetting("cssReloadEnabled",false);this.showCpuOnTimelineRuler=this.createSetting("showCpuOnTimelineRuler",false);this.timelineStackFramesToCapture=this.createSetting("timelineStackFramesToCapture",30);this.timelineLimitStackFramesFlag=this.createSetting("timelineLimitStackFramesFlag",false);this.showMetricsRulers=this.createSetting("showMetricsRulers",false);this.overrideCSSMedia=this.createSetting("overrideCSSMedia",false);this.emulatedCSSMedia=this.createSetting("emulatedCSSMedia","print");this.workerInspectorWidth=this.createSetting("workerInspectorWidth",600);this.workerInspectorHeight=this.createSetting("workerInspectorHeight",600);this.messageURLFilters=this.createSetting("messageURLFilters",{});this.messageSourceFilters=this.createSetting("messageSourceFilters",{"CSS":true});this.messageLevelFilters=this.createSetting("messageLevelFilters",{});this.splitVerticallyWhenDockedToRight=this.createSetting("splitVerticallyWhenDockedToRight",true);this.visiblePanels=this.createSetting("visiblePanels",{});this.shortcutPanelSwitch=this.createSetting("shortcutPanelSwitch",false);this.showWhitespacesInEditor=this.createSetting("showWhitespacesInEditor",false);this.skipStackFramesSwitch=this.createSetting("skipStackFramesSwitch",false);this.skipStackFramesPattern=this.createSetting("skipStackFramesPattern","");}
|
| +{this._eventSupport=new WebInspector.Object();this._registry=({});this.colorFormat=this.createSetting("colorFormat","original");this.consoleHistory=this.createSetting("consoleHistory",[]);this.domWordWrap=this.createSetting("domWordWrap",true);this.eventListenersFilter=this.createSetting("eventListenersFilter","all");this.lastActivePanel=this.createSetting("lastActivePanel","elements");this.lastViewedScriptFile=this.createSetting("lastViewedScriptFile","application");this.monitoringXHREnabled=this.createSetting("monitoringXHREnabled",false);this.preserveConsoleLog=this.createSetting("preserveConsoleLog",false);this.resourcesLargeRows=this.createSetting("resourcesLargeRows",true);this.resourcesSortOptions=this.createSetting("resourcesSortOptions",{timeOption:"responseTime",sizeOption:"transferSize"});this.resourceViewTab=this.createSetting("resourceViewTab","preview");this.showInheritedComputedStyleProperties=this.createSetting("showInheritedComputedStyleProperties",false);this.showUserAgentStyles=this.createSetting("showUserAgentStyles",true);this.watchExpressions=this.createSetting("watchExpressions",[]);this.breakpoints=this.createSetting("breakpoints",[]);this.eventListenerBreakpoints=this.createSetting("eventListenerBreakpoints",[]);this.domBreakpoints=this.createSetting("domBreakpoints",[]);this.xhrBreakpoints=this.createSetting("xhrBreakpoints",[]);this.jsSourceMapsEnabled=this.createSetting("sourceMapsEnabled",true);this.cssSourceMapsEnabled=this.createSetting("cssSourceMapsEnabled",true);this.cacheDisabled=this.createSetting("cacheDisabled",false);this.enableOverridesOnStartup=this.createSetting("enableOverridesOnStartup",false);this.overrideUserAgent=this.createSetting("overrideUserAgent",false);this.userAgent=this.createSetting("userAgent","");this.overrideDeviceMetrics=this.createSetting("overrideDeviceMetrics",false);this.deviceMetrics=this.createSetting("deviceMetrics","");this.deviceFitWindow=this.createSetting("deviceFitWindow",false);this.emulateTouchEvents=this.createSetting("emulateTouchEvents",false);this.showShadowDOM=this.createSetting("showShadowDOM",false);this.zoomLevel=this.createSetting("zoomLevel",0);this.savedURLs=this.createSetting("savedURLs",{});this.javaScriptDisabled=this.createSetting("javaScriptDisabled",false);this.overrideGeolocation=this.createSetting("overrideGeolocation",false);this.geolocationOverride=this.createSetting("geolocationOverride","");this.overrideDeviceOrientation=this.createSetting("overrideDeviceOrientation",false);this.deviceOrientationOverride=this.createSetting("deviceOrientationOverride","");this.showAdvancedHeapSnapshotProperties=this.createSetting("showAdvancedHeapSnapshotProperties",false);this.searchInContentScripts=this.createSetting("searchInContentScripts",false);this.textEditorIndent=this.createSetting("textEditorIndent"," ");this.textEditorAutoDetectIndent=this.createSetting("textEditorAutoIndentIndent",true);this.lastDockState=this.createSetting("lastDockState","");this.cssReloadEnabled=this.createSetting("cssReloadEnabled",false);this.showCpuOnTimelineRuler=this.createSetting("showCpuOnTimelineRuler",false);this.timelineStackFramesToCapture=this.createSetting("timelineStackFramesToCapture",30);this.timelineLimitStackFramesFlag=this.createSetting("timelineLimitStackFramesFlag",false);this.showMetricsRulers=this.createSetting("showMetricsRulers",false);this.overrideCSSMedia=this.createSetting("overrideCSSMedia",false);this.emulatedCSSMedia=this.createSetting("emulatedCSSMedia","print");this.workerInspectorWidth=this.createSetting("workerInspectorWidth",600);this.workerInspectorHeight=this.createSetting("workerInspectorHeight",600);this.messageURLFilters=this.createSetting("messageURLFilters",{});this.messageSourceFilters=this.createSetting("messageSourceFilters",{"CSS":true});this.messageLevelFilters=this.createSetting("messageLevelFilters",{});this.splitVerticallyWhenDockedToRight=this.createSetting("splitVerticallyWhenDockedToRight",true);this.visiblePanels=this.createSetting("visiblePanels",{});this.shortcutPanelSwitch=this.createSetting("shortcutPanelSwitch",false);this.portForwardings=this.createSetting("portForwardings",[]);this.showWhitespacesInEditor=this.createSetting("showWhitespacesInEditor",false);this.skipStackFramesSwitch=this.createSetting("skipStackFramesSwitch",false);this.skipStackFramesPattern=this.createSetting("skipStackFramesPattern","");}
|
| WebInspector.Settings.prototype={createSetting:function(key,defaultValue)
|
| {if(!this._registry[key])
|
| this._registry[key]=new WebInspector.Setting(key,defaultValue,this._eventSupport,window.localStorage);return this._registry[key];},createBackendSetting:function(key,defaultValue,setterCallback)
|
| @@ -1093,7 +1090,7 @@
|
| {if(error){WebInspector.log("Error applying setting "+this._name+": "+error);this._eventSupport.dispatchEventToListeners(this._name,this._value);return;}
|
| WebInspector.Setting.prototype.set.call(this,value);}
|
| this._setterCallback(value,callback.bind(this));},__proto__:WebInspector.Setting.prototype};WebInspector.ExperimentsSettings=function()
|
| -{this._setting=WebInspector.settings.createSetting("experiments",{});this._experiments=[];this._enabledForTest={};this.fileSystemInspection=this._createExperiment("fileSystemInspection","FileSystem inspection");this.canvasInspection=this._createExperiment("canvasInspection ","Canvas inspection");this.cssRegions=this._createExperiment("cssRegions","CSS Regions Support");this.showOverridesInDrawer=this._createExperiment("showOverridesInDrawer","Show Overrides in drawer");this.customizableToolbar=this._createExperiment("customizableToolbar","Enable toolbar customization");this.drawerOverlay=this._createExperiment("drawerOverlay","Open console as overlay");this.frameworksDebuggingSupport=this._createExperiment("frameworksDebuggingSupport","Enable frameworks debugging support");this.layersPanel=this._createExperiment("layersPanel","Show Layers panel");this.screencast=this._createExperiment("screencast","Enable screencast");this.stepIntoSelection=this._createExperiment("stepIntoSelection","Show step-in candidates while debugging.");this.openConsoleWithCtrlTilde=this._createExperiment("openConsoleWithCtrlTilde","Open console with Ctrl/Cmd+Tilde, not Esc");this._cleanUpSetting();}
|
| +{this._setting=WebInspector.settings.createSetting("experiments",{});this._experiments=[];this._enabledForTest={};this.fileSystemInspection=this._createExperiment("fileSystemInspection","FileSystem inspection");this.canvasInspection=this._createExperiment("canvasInspection ","Canvas inspection");this.cssRegions=this._createExperiment("cssRegions","CSS Regions Support");this.showOverridesInDrawer=this._createExperiment("showOverridesInDrawer","Show Overrides in drawer");this.customizableToolbar=this._createExperiment("customizableToolbar","Enable toolbar customization");this.tethering=this._createExperiment("tethering","Enable port forwarding");this.drawerOverlay=this._createExperiment("drawerOverlay","Open console as overlay");this.frameworksDebuggingSupport=this._createExperiment("frameworksDebuggingSupport","Enable frameworks debugging support");this.refreshFileSystemsOnFocus=this._createExperiment("refreshFileSystemsOnFocus","Refresh file system folders on window focus");this.scrollBeyondEndOfFile=this._createExperiment("scrollBeyondEndOfFile","Support scrolling beyond end of file");this._cleanUpSetting();}
|
| WebInspector.ExperimentsSettings.prototype={get experiments()
|
| {return this._experiments.slice();},get experimentsEnabled()
|
| {return Preferences.experimentsEnabled||("experiments"in WebInspector.queryParamsObject);},_createExperiment:function(experimentName,experimentTitle)
|
| @@ -1243,11 +1240,9 @@
|
| {var elementDragEnd=WebInspector._elementEndDraggingEventListener;WebInspector._cancelDragEvents(event);event.preventDefault();if(elementDragEnd)
|
| elementDragEnd(event);}
|
| WebInspector.GlassPane=function()
|
| -{this.element=document.createElement("div");this.element.style.cssText="position:absolute;top:0;bottom:0;left:0;right:0;background-color:transparent;z-index:1000;";this.element.id="glass-pane";document.body.appendChild(this.element);WebInspector._glassPane=this;}
|
| +{this.element=document.createElement("div");this.element.style.cssText="position:absolute;top:0;bottom:0;left:0;right:0;background-color:transparent;z-index:1000;";this.element.id="glass-pane-for-drag";document.body.appendChild(this.element);WebInspector._glassPane=this;}
|
| WebInspector.GlassPane.prototype={dispose:function()
|
| -{delete WebInspector._glassPane;if(WebInspector.HelpScreen.isVisible())
|
| -WebInspector.HelpScreen.focus();else
|
| -WebInspector.inspectorView.focus();this.element.remove();}}
|
| +{delete WebInspector._glassPane;WebInspector.inspectorView.focus();this.element.remove();}}
|
| WebInspector.animateStyle=function(animations,duration,callback)
|
| {var startTime=new Date().getTime();var hasCompleted=false;const animationsLength=animations.length;const propertyUnit={opacity:""};const defaultUnit="px";for(var i=0;i<animationsLength;++i){var animation=animations[i];var element=null,start=null,end=null,key=null;for(key in animation){if(key==="element")
|
| element=animation[key];else if(key==="start")
|
| @@ -1332,8 +1327,6 @@
|
| {e.consume();}
|
| if(isMultiline){loadScript("CodeMirrorTextEditor.js");cssLoadView=new WebInspector.CodeMirrorCSSLoadView();cssLoadView.show(element);WebInspector.setCurrentFocusElement(element);element.addEventListener("copy",consumeCopy,false);codeMirror=window.CodeMirror(element,{mode:config.mode,lineWrapping:config.lineWrapping,smartIndent:config.smartIndent,autofocus:true,theme:config.theme,value:oldText});codeMirror.getWrapperElement().addStyleClass("source-code");codeMirror.on("cursorActivity",function(cm){cm.display.cursor.scrollIntoViewIfNeeded(false);});}else{element.addStyleClass("editing");oldTabIndex=element.getAttribute("tabIndex");if(typeof oldTabIndex!=="number"||oldTabIndex<0)
|
| element.tabIndex=0;WebInspector.setCurrentFocusElement(element);}
|
| -function setWidth(width)
|
| -{const padding=30;codeMirror.getWrapperElement().style.width=(width-codeMirror.getWrapperElement().offsetLeft-padding)+"px";codeMirror.refresh();}
|
| function blurEventListener(e){if(!isMultiline||!e||!e.relatedTarget||!e.relatedTarget.isSelfOrDescendant(element))
|
| editingCommitted.call(element);}
|
| function getContent(element){if(isMultiline)
|
| @@ -1366,7 +1359,7 @@
|
| function keyDownEventListener(event)
|
| {var handler=config.customFinishHandler||defaultFinishHandler;var result=handler(event);handleEditingResult(result,event);}
|
| element.addEventListener("blur",blurEventListener,isMultiline);element.addEventListener("keydown",keyDownEventListener,true);if(pasteCallback)
|
| -element.addEventListener("paste",pasteEventListener,true);return{cancel:editingCancelled.bind(element),commit:editingCommitted.bind(element),codeMirror:codeMirror,setWidth:setWidth};}
|
| +element.addEventListener("paste",pasteEventListener,true);return{cancel:editingCancelled.bind(element),commit:editingCommitted.bind(element),codeMirror:codeMirror};}
|
| Number.secondsToString=function(seconds,higherResolution)
|
| {if(!isFinite(seconds))
|
| return"-";if(seconds===0)
|
| @@ -1488,12 +1481,8 @@
|
| WebInspector.CodeMirrorCSSLoadView.prototype={__proto__:WebInspector.View.prototype};(function(){function windowLoaded()
|
| {window.addEventListener("focus",WebInspector._windowFocused,false);window.addEventListener("blur",WebInspector._windowBlurred,false);document.addEventListener("focus",WebInspector._focusChanged.bind(this),true);window.removeEventListener("DOMContentLoaded",windowLoaded,false);}
|
| window.addEventListener("DOMContentLoaded",windowLoaded,false);})();WebInspector.HelpScreen=function(title)
|
| -{WebInspector.View.call(this);this.markAsRoot();this.registerRequiredCSS("helpScreen.css");this.element.className="help-window-outer";this.element.addEventListener("keydown",this._onKeyDown.bind(this),false);this.element.tabIndex=0;if(title){var mainWindow=this.element.createChild("div","help-window-main");var captionWindow=mainWindow.createChild("div","help-window-caption");captionWindow.appendChild(this._createCloseButton());this.contentElement=mainWindow.createChild("div","help-content");captionWindow.createChild("h1","help-window-title").textContent=title;}}
|
| -WebInspector.HelpScreen._visibleScreen=null;WebInspector.HelpScreen.isVisible=function()
|
| -{return!!WebInspector.HelpScreen._visibleScreen;}
|
| -WebInspector.HelpScreen.focus=function()
|
| -{WebInspector.HelpScreen._visibleScreen.element.focus();}
|
| -WebInspector.HelpScreen.prototype={_createCloseButton:function()
|
| +{WebInspector.View.call(this);this.markAsRoot();this.registerRequiredCSS("helpScreen.css");this.element.className="help-window-outer";this.element.addEventListener("keydown",this._onKeyDown.bind(this),false);this.element.tabIndex=0;this.element.addEventListener("focus",this._onBlur.bind(this),false);if(title){var mainWindow=this.element.createChild("div","help-window-main");var captionWindow=mainWindow.createChild("div","help-window-caption");captionWindow.appendChild(this._createCloseButton());this.contentElement=mainWindow.createChild("div","help-content");captionWindow.createChild("h1","help-window-title").textContent=title;}}
|
| +WebInspector.HelpScreen._visibleScreen=null;WebInspector.HelpScreen.prototype={_createCloseButton:function()
|
| {var closeButton=document.createElement("div");closeButton.className="help-close-button close-button-gray";closeButton.addEventListener("click",this.hide.bind(this),false);return closeButton;},showModal:function()
|
| {var visibleHelpScreen=WebInspector.HelpScreen._visibleScreen;if(visibleHelpScreen===this)
|
| return;if(visibleHelpScreen)
|
| @@ -1501,7 +1490,9 @@
|
| {if(!this.isShowing())
|
| return;WebInspector.HelpScreen._visibleScreen=null;WebInspector.restoreFocusFromElement(this.element);this.detach();},isClosingKey:function(keyCode)
|
| {return[WebInspector.KeyboardShortcut.Keys.Enter.code,WebInspector.KeyboardShortcut.Keys.Esc.code,WebInspector.KeyboardShortcut.Keys.Space.code,].indexOf(keyCode)>=0;},_onKeyDown:function(event)
|
| -{if(this.isShowing()&&this.isClosingKey(event.keyCode)){this.hide();event.consume();}},__proto__:WebInspector.View.prototype}
|
| +{if(this.isShowing()&&this.isClosingKey(event.keyCode)){this.hide();event.consume();}},_onBlur:function(event)
|
| +{if(this.isShowing()&&!this.element.isSelfOrAncestor(event.target))
|
| +WebInspector.setCurrentFocusElement(this.element);},__proto__:WebInspector.View.prototype}
|
| WebInspector.HelpScreenUntilReload=function(title,message)
|
| {WebInspector.HelpScreen.call(this,title);var p=this.contentElement.createChild("p");p.addStyleClass("help-section");p.textContent=message;WebInspector.debuggerModel.addEventListener(WebInspector.DebuggerModel.Events.GlobalObjectCleared,this.hide,this);}
|
| WebInspector.HelpScreenUntilReload.prototype={willHide:function()
|
| @@ -1537,7 +1528,6 @@
|
| return;var lastSlashIndex=url.lastIndexOf("/");var fileNameSuffix=(lastSlashIndex===-1)?url:url.substring(lastSlashIndex+1);var blob=new Blob(content,{type:"application/octet-stream"});var objectUrl=window.URL.createObjectURL(blob);window.location=objectUrl+"#/"+fileNameSuffix;function cleanup()
|
| {window.URL.revokeObjectURL(objectUrl);}
|
| setTimeout(cleanup,3000);},sendMessageToBackend:function(message)
|
| -{},sendMessageToEmbedder:function(message)
|
| {},recordActionTaken:function(actionCode)
|
| {},recordPanelShown:function(panelCode)
|
| {},recordSettingChanged:function(settingCode)
|
| @@ -1698,8 +1688,7 @@
|
| WebInspector.KeyboardShortcut=function()
|
| {}
|
| WebInspector.KeyboardShortcut.Modifiers={None:0,Shift:1,Ctrl:2,Alt:4,Meta:8,get CtrlOrMeta()
|
| -{return WebInspector.isMac()?this.Meta:this.Ctrl;}};WebInspector.KeyboardShortcut.Key;WebInspector.KeyboardShortcut.Keys={Backspace:{code:8,name:"\u21a4"},Tab:{code:9,name:{mac:"\u21e5",other:"Tab"}},Enter:{code:13,name:{mac:"\u21a9",other:"Enter"}},Esc:{code:27,name:{mac:"\u238b",other:"Esc"}},Space:{code:32,name:"Space"},PageUp:{code:33,name:{mac:"\u21de",other:"PageUp"}},PageDown:{code:34,name:{mac:"\u21df",other:"PageDown"}},End:{code:35,name:{mac:"\u2197",other:"End"}},Home:{code:36,name:{mac:"\u2196",other:"Home"}},Left:{code:37,name:"\u2190"},Up:{code:38,name:"\u2191"},Right:{code:39,name:"\u2192"},Down:{code:40,name:"\u2193"},Delete:{code:46,name:"Del"},Zero:{code:48,name:"0"},F1:{code:112,name:"F1"},F2:{code:113,name:"F2"},F3:{code:114,name:"F3"},F4:{code:115,name:"F4"},F5:{code:116,name:"F5"},F6:{code:117,name:"F6"},F7:{code:118,name:"F7"},F8:{code:119,name:"F8"},F9:{code:120,name:"F9"},F10:{code:121,name:"F10"},F11:{code:122,name:"F11"},F12:{code:123,name:"F12"},Semicolon:{code:186,name:";"},Plus:{code:187,name:"+"},Comma:{code:188,name:","},Minus:{code:189,name:"-"},Period:{code:190,name:"."},Slash:{code:191,name:"/"},Apostrophe:{code:192,name:"`"},Backslash:{code:220,name:"\\"},SingleQuote:{code:222,name:"\'"},H:{code:72,name:"H"},Ctrl:{code:17,name:"Ctrl"},Meta:{code:91,name:"Meta"},Tilde:{code:192,name:"Tilde"},get CtrlOrMeta()
|
| -{return WebInspector.isMac()?this.Meta:this.Ctrl;},};WebInspector.KeyboardShortcut.makeKey=function(keyCode,modifiers)
|
| +{return WebInspector.isMac()?this.Meta:this.Ctrl;}};WebInspector.KeyboardShortcut.Key;WebInspector.KeyboardShortcut.Keys={Backspace:{code:8,name:"\u21a4"},Tab:{code:9,name:{mac:"\u21e5",other:"Tab"}},Enter:{code:13,name:{mac:"\u21a9",other:"Enter"}},Esc:{code:27,name:{mac:"\u238b",other:"Esc"}},Space:{code:32,name:"Space"},PageUp:{code:33,name:{mac:"\u21de",other:"PageUp"}},PageDown:{code:34,name:{mac:"\u21df",other:"PageDown"}},End:{code:35,name:{mac:"\u2197",other:"End"}},Home:{code:36,name:{mac:"\u2196",other:"Home"}},Left:{code:37,name:"\u2190"},Up:{code:38,name:"\u2191"},Right:{code:39,name:"\u2192"},Down:{code:40,name:"\u2193"},Delete:{code:46,name:"Del"},Zero:{code:48,name:"0"},F1:{code:112,name:"F1"},F2:{code:113,name:"F2"},F3:{code:114,name:"F3"},F4:{code:115,name:"F4"},F5:{code:116,name:"F5"},F6:{code:117,name:"F6"},F7:{code:118,name:"F7"},F8:{code:119,name:"F8"},F9:{code:120,name:"F9"},F10:{code:121,name:"F10"},F11:{code:122,name:"F11"},F12:{code:123,name:"F12"},Semicolon:{code:186,name:";"},Plus:{code:187,name:"+"},Comma:{code:188,name:","},Minus:{code:189,name:"-"},Period:{code:190,name:"."},Slash:{code:191,name:"/"},Apostrophe:{code:192,name:"`"},SingleQuote:{code:222,name:"\'"},H:{code:72,name:"H"},Ctrl:{code:17,name:"Ctrl"},Meta:{code:91,name:"Meta"},};WebInspector.KeyboardShortcut.makeKey=function(keyCode,modifiers)
|
| {if(typeof keyCode==="string")
|
| keyCode=keyCode.charCodeAt(0)-32;modifiers=modifiers||WebInspector.KeyboardShortcut.Modifiers.None;return WebInspector.KeyboardShortcut._makeKeyFromCodeAndModifiers(keyCode,modifiers);}
|
| WebInspector.KeyboardShortcut.makeKeyFromEvent=function(keyboardEvent)
|
| @@ -1916,7 +1905,7 @@
|
| return;this.contentElement=contentElement;if(WebInspector.Popover._popover)
|
| WebInspector.Popover._popover.detach();WebInspector.Popover._popover=this;var preferredSize=view?view.measurePreferredSize():this.contentElement.measurePreferredSize();preferredWidth=preferredWidth||preferredSize.width;preferredHeight=preferredHeight||preferredSize.height;WebInspector.View.prototype.show.call(this,document.body);if(view)
|
| view.show(this._contentDiv);else
|
| -this._contentDiv.appendChild(this.contentElement);this._positionElement(anchor,preferredWidth,preferredHeight,arrowDirection);if(this._popoverHelper){this._contentDiv.addEventListener("mousemove",this._popoverHelper._killHidePopoverTimer.bind(this._popoverHelper),true);this.element.addEventListener("mouseout",this._popoverHelper._popoverMouseOut.bind(this._popoverHelper),true);}},hide:function()
|
| +this._contentDiv.appendChild(this.contentElement);this._positionElement(anchor,preferredWidth,preferredHeight,arrowDirection);if(this._popoverHelper){contentElement.addEventListener("mousemove",this._popoverHelper._killHidePopoverTimer.bind(this._popoverHelper),true);this.element.addEventListener("mouseout",this._popoverHelper._popoverMouseOut.bind(this._popoverHelper),true);}},hide:function()
|
| {this.detach();delete WebInspector.Popover._popover;},get disposed()
|
| {return this._disposed;},dispose:function()
|
| {if(this.isShowing())
|
| @@ -2096,7 +2085,7 @@
|
| {return this._iconClass;},_setIconClass:function(iconClass,iconTooltip)
|
| {if(iconClass===this._iconClass&&iconTooltip===this._iconTooltip)
|
| return;this._iconClass=iconClass;this._iconTooltip=iconTooltip;if(this._iconElement)
|
| -this._iconElement.remove();if(this._iconClass&&this._tabElement)
|
| +this._iconElement.remove();if(this._iconClass)
|
| this._iconElement=this._createIconElement(this._tabElement,this._titleElement);delete this._measuredWidth;},get view()
|
| {return this._view;},set view(view)
|
| {this._view=view;},get tooltip()
|
| @@ -2116,8 +2105,8 @@
|
| tabElement.createChild("div","close-button-gray");if(measuring)
|
| tabElement.addStyleClass("measuring");else{this._tabElement=tabElement;tabElement.addEventListener("click",this._tabClicked.bind(this),false);tabElement.addEventListener("mousedown",this._tabMouseDown.bind(this),false);if(this._closeable){tabElement.addEventListener("contextmenu",this._tabContextMenu.bind(this),false);WebInspector.installDragHandle(tabElement,this._startTabDragging.bind(this),this._tabDragging.bind(this),this._endTabDragging.bind(this),"pointer");}}
|
| return tabElement;},_tabClicked:function(event)
|
| -{var middleButton=event.button===1;var shouldClose=this._closeable&&(middleButton||event.target.hasStyleClass("close-button-gray"));if(!shouldClose)
|
| -return;this._closeTabs([this.id]);event.consume(true);},_tabMouseDown:function(event)
|
| +{if(this._closeable&&(event.button===1||event.target.hasStyleClass("close-button-gray")))
|
| +this._closeTabs([this.id]);},_tabMouseDown:function(event)
|
| {if(event.target.hasStyleClass("close-button-gray")||event.button===1)
|
| return;this._tabbedPane.selectTab(this.id,true);},_closeTabs:function(ids)
|
| {if(this._delegate){this._delegate.closeTabs(this._tabbedPane,ids);return;}
|
| @@ -2171,8 +2160,7 @@
|
| WebInspector.Drawer.AnimationType={Immediately:0,Normal:1,Slow:2}
|
| WebInspector.Drawer.prototype={get visible()
|
| {return!!this._view;},_constrainHeight:function(height)
|
| -{return Number.constrain(height,Preferences.minConsoleHeight,window.innerHeight-this._mainElement.totalOffsetTop()-Preferences.minConsoleHeight);},isHiding:function()
|
| -{return this._isHiding;},show:function(view,animationType)
|
| +{return Number.constrain(height,Preferences.minConsoleHeight,window.innerHeight-this._mainElement.totalOffsetTop()-Preferences.minConsoleHeight);},show:function(view,animationType)
|
| {WebInspector.searchController.cancelSearch();this.immediatelyFinishAnimation();var drawerWasVisible=this.visible;if(this._view){this._view.detach();this._drawerContentsElement.removeChildren();}
|
| this._view=view;var statusBarItems=this._view.statusBarItems||[];this._viewStatusBar.removeChildren();for(var i=0;i<statusBarItems.length;++i)
|
| this._viewStatusBar.appendChild(statusBarItems[i]);document.body.addStyleClass("drawer-visible");this._floatingStatusBarContainer.insertBefore(document.getElementById("panel-status-bar"),this._floatingStatusBarContainer.firstElementChild);this._bottomStatusBar.appendChild(this._viewStatusBar);this._view.detach();this._view.markAsRoot();this._view.show(this._drawerContentsElement);if(drawerWasVisible)
|
| @@ -2184,10 +2172,10 @@
|
| this._currentAnimation=WebInspector.animateStyle(animations,this._animationDuration(animationType),animationCallback.bind(this));if(animationType===WebInspector.Drawer.AnimationType.Immediately)
|
| this._currentAnimation.forceComplete();},hide:function(animationType)
|
| {WebInspector.searchController.cancelSearch();this.immediatelyFinishAnimation();if(!this.visible)
|
| -return;this._isHiding=true;this._savedHeight=this.element.offsetHeight;WebInspector.restoreFocusFromElement(this.element);document.body.removeStyleClass("drawer-visible");WebInspector.inspectorView.currentPanel().statusBarResized();document.body.addStyleClass("drawer-visible");var animations=[{element:this.element,end:{height:0}},{element:this._floatingStatusBarContainer,start:{"padding-left":0},end:{"padding-left":this._bottomStatusBar.offsetLeft}},{element:this._viewStatusBar,start:{opacity:1},end:{opacity:0}},{element:this._elementToAdjust,end:{bottom:0}}];function animationCallback(finished)
|
| +return;this._savedHeight=this.element.offsetHeight;WebInspector.restoreFocusFromElement(this.element);document.body.removeStyleClass("drawer-visible");WebInspector.inspectorView.currentPanel().statusBarResized();document.body.addStyleClass("drawer-visible");var animations=[{element:this.element,end:{height:0}},{element:this._floatingStatusBarContainer,start:{"padding-left":0},end:{"padding-left":this._bottomStatusBar.offsetLeft}},{element:this._viewStatusBar,start:{opacity:1},end:{opacity:0}},{element:this._elementToAdjust,end:{bottom:0}}];function animationCallback(finished)
|
| {if(WebInspector.inspectorView.currentPanel())
|
| WebInspector.inspectorView.currentPanel().doResize();if(!finished)
|
| -return;this._view.detach();delete this._view;this._bottomStatusBar.removeChildren();this._bottomStatusBar.appendChild(document.getElementById("panel-status-bar"));this._drawerContentsElement.removeChildren();document.body.removeStyleClass("drawer-visible");delete this._currentAnimation;this._elementToAdjust.style.bottom=0;delete this._isHiding;}
|
| +return;this._view.detach();delete this._view;this._bottomStatusBar.removeChildren();this._bottomStatusBar.appendChild(document.getElementById("panel-status-bar"));this._drawerContentsElement.removeChildren();document.body.removeStyleClass("drawer-visible");delete this._currentAnimation;this._elementToAdjust.style.bottom=0;}
|
| this._currentAnimation=WebInspector.animateStyle(animations,this._animationDuration(animationType),animationCallback.bind(this));if(animationType===WebInspector.Drawer.AnimationType.Immediately)
|
| this._currentAnimation.forceComplete();},resize:function()
|
| {if(!this.visible)
|
| @@ -2213,8 +2201,7 @@
|
| {delete this._enablingConsole;}
|
| ConsoleAgent.enable(callback.bind(this));},enablingConsole:function()
|
| {return!!this._enablingConsole;},addMessage:function(msg,isFromBackend)
|
| -{if(isFromBackend&&WebInspector.SourceMap.hasSourceMapRequestHeader(msg.request()))
|
| -return;msg.index=this.messages.length;this.messages.push(msg);this._incrementErrorWarningCount(msg);if(isFromBackend)
|
| +{msg.index=this.messages.length;this.messages.push(msg);this._incrementErrorWarningCount(msg);if(isFromBackend)
|
| this._previousMessage=msg;this._interruptRepeatCount=!isFromBackend;this.dispatchEventToListeners(WebInspector.ConsoleModel.Events.MessageAdded,msg);},_incrementErrorWarningCount:function(msg)
|
| {switch(msg.level){case WebInspector.ConsoleMessage.MessageLevel.Warning:this.warnings+=msg.repeatDelta;break;case WebInspector.ConsoleMessage.MessageLevel.Error:this.errors+=msg.repeatDelta;break;}},requestClearMessages:function()
|
| {ConsoleAgent.clearMessages();this.clearMessages();},clearMessages:function()
|
| @@ -2242,8 +2229,7 @@
|
| this._console.clearMessages();}}
|
| WebInspector.console=null;WebInspector.ConsoleMessageImpl=function(source,level,message,linkifier,type,url,line,column,repeatCount,parameters,stackTrace,requestId,isOutdated)
|
| {WebInspector.ConsoleMessage.call(this,source,level,url,line,column,repeatCount);this._linkifier=linkifier;this.type=type||WebInspector.ConsoleMessage.MessageType.Log;this._messageText=message;this._parameters=parameters;this._stackTrace=stackTrace;this._request=requestId?WebInspector.networkLog.requestForId(requestId):null;this._isOutdated=isOutdated;this._dataGrids=[];this._dataGridParents=new Map();this._customFormatters={"object":this._formatParameterAsObject,"array":this._formatParameterAsArray,"node":this._formatParameterAsNode,"string":this._formatParameterAsString};}
|
| -WebInspector.ConsoleMessageImpl.prototype={request:function()
|
| -{return this._request;},wasShown:function()
|
| +WebInspector.ConsoleMessageImpl.prototype={wasShown:function()
|
| {for(var i=0;this._dataGrids&&i<this._dataGrids.length;++i){var dataGrid=this._dataGrids[i];var parentElement=this._dataGridParents.get(dataGrid)||null;dataGrid.show(parentElement);}},willHide:function()
|
| {for(var i=0;this._dataGrids&&i<this._dataGrids.length;++i){var dataGrid=this._dataGrids[i];this._dataGridParents.put(dataGrid,dataGrid.element.parentElement);dataGrid.detach();}},_formatMessage:function()
|
| {this._formattedMessage=document.createElement("span");this._formattedMessage.className="console-message-text source-code";if(this.source===WebInspector.ConsoleMessage.MessageSource.ConsoleAPI){switch(this.type){case WebInspector.ConsoleMessage.MessageType.Trace:this._messageElement=this._format(this._parameters||["console.trace()"]);break;case WebInspector.ConsoleMessage.MessageType.Clear:this._messageElement=document.createTextNode(WebInspector.UIString("Console was cleared"));this._formattedMessage.addStyleClass("console-info");break;case WebInspector.ConsoleMessage.MessageType.Assert:var args=[WebInspector.UIString("Assertion failed:")];if(this._parameters)
|
| @@ -2252,7 +2238,7 @@
|
| this._messageElement.appendChild(document.createTextNode(" "+this._request.localizedFailDescription));else
|
| this._messageElement.appendChild(document.createTextNode(" "+this._request.statusCode+" ("+this._request.statusText+")"));}else{var fragment=WebInspector.linkifyStringAsFragmentWithCustomLinkifier(this._messageText,WebInspector.linkifyRequestAsNode.bind(null,this._request));this._messageElement.appendChild(fragment);}}else{if(this.url){var isExternal=!WebInspector.resourceForURL(this.url)&&!WebInspector.workspace.uiSourceCodeForURL(this.url);this._anchorElement=WebInspector.linkifyURLAsNode(this.url,this.url,"console-message-url",isExternal);}
|
| this._messageElement=this._format([this._messageText]);}}else{var args=this._parameters||[this._messageText];this._messageElement=this._format(args);}
|
| -if(this.source!==WebInspector.ConsoleMessage.MessageSource.Network||this._request){if(this._stackTrace&&this._stackTrace.length&&this._stackTrace[0].scriptId){this._anchorElement=this._linkifyCallFrame(this._stackTrace[0]);}else if(this.url&&this.url!=="undefined"){this._anchorElement=this._linkifyLocation(this.url,this.line,this.column);}}
|
| +if(this.source!==WebInspector.ConsoleMessage.MessageSource.Network||this._request){if(this._stackTrace&&this._stackTrace.length&&this._stackTrace[0].url){this._anchorElement=this._linkifyCallFrame(this._stackTrace[0]);}else if(this.url&&this.url!=="undefined"){this._anchorElement=this._linkifyLocation(this.url,this.line,this.column);}}
|
| this._formattedMessage.appendChild(this._messageElement);if(this._anchorElement){this._formattedMessage.appendChild(document.createTextNode(" "));this._formattedMessage.appendChild(this._anchorElement);}
|
| var dumpStackTrace=!!this._stackTrace&&this._stackTrace.length&&(this.source===WebInspector.ConsoleMessage.MessageSource.Network||this.level===WebInspector.ConsoleMessage.MessageLevel.Error||this.type===WebInspector.ConsoleMessage.MessageType.Trace);if(dumpStackTrace){var ol=document.createElement("ol");ol.className="outline-disclosure";var treeOutline=new TreeOutline(ol);var content=this._formattedMessage;var root=new TreeElement(content,null,true);content.treeElementForTest=root;treeOutline.appendChild(root);if(this.type===WebInspector.ConsoleMessage.MessageType.Trace)
|
| root.expand();this._populateStackTraceTreeElement(root);this._formattedMessage=ol;}
|
| @@ -2262,7 +2248,7 @@
|
| this._formatMessage();return this._formattedMessage;},request:function()
|
| {return this._request;},_linkifyLocation:function(url,lineNumber,columnNumber)
|
| {lineNumber=lineNumber?lineNumber-1:0;columnNumber=columnNumber?columnNumber-1:0;return this._linkifier.linkifyLocation(url,lineNumber,columnNumber,"console-message-url");},_linkifyCallFrame:function(callFrame)
|
| -{var lineNumber=callFrame.lineNumber?callFrame.lineNumber-1:0;var columnNumber=callFrame.columnNumber?callFrame.columnNumber-1:0;var rawLocation=new WebInspector.DebuggerModel.Location(callFrame.scriptId,lineNumber,columnNumber);return this._linkifier.linkifyRawLocation(rawLocation,"console-message-url");},isErrorOrWarning:function()
|
| +{return this._linkifyLocation(callFrame.url,callFrame.lineNumber,callFrame.columnNumber);},isErrorOrWarning:function()
|
| {return(this.level===WebInspector.ConsoleMessage.MessageLevel.Warning||this.level===WebInspector.ConsoleMessage.MessageLevel.Error);},_format:function(parameters)
|
| {var formattedResult=document.createElement("span");if(!parameters.length)
|
| return formattedResult;for(var i=0;i<parameters.length;++i){if(parameters[i]instanceof WebInspector.RemoteObject)
|
| @@ -2300,7 +2286,7 @@
|
| span.textContent=property.value;return span;},_formatParameterAsNode:function(object,elem)
|
| {function printNode(nodeId)
|
| {if(!nodeId){this._formatParameterAsObject(object,elem,false);return;}
|
| -var treeOutline=new WebInspector.ElementsTreeOutline(false,false);treeOutline.setVisible(true);treeOutline.rootDOMNode=WebInspector.domAgent.nodeForId(nodeId);treeOutline.element.addStyleClass("outline-disclosure");if(!treeOutline.children[0].hasChildren)
|
| +var treeOutline=new WebInspector.ElementsTreeOutline(false,false,true);treeOutline.setVisible(true);treeOutline.rootDOMNode=WebInspector.domAgent.nodeForId(nodeId);treeOutline.element.addStyleClass("outline-disclosure");if(!treeOutline.children[0].hasChildren)
|
| treeOutline.element.addStyleClass("single-node");elem.appendChild(treeOutline.element);treeOutline.element.treeElementForTest=treeOutline.children[0];}
|
| object.pushNodeToFrontend(printNode.bind(this));},useArrayPreviewInFormatter:function(array)
|
| {return this.type!==WebInspector.ConsoleMessage.MessageType.DirXML&&!!array.preview;},_formatParameterAsArray:function(array,elem)
|
| @@ -2310,9 +2296,8 @@
|
| array.getOwnProperties(this._printArray.bind(this,array,elem));},_formatParameterAsTable:function(parameters)
|
| {var element=document.createElement("span");var table=parameters[0];if(!table||!table.preview)
|
| return element;var columnNames=[];var preview=table.preview;var rows=[];for(var i=0;i<preview.properties.length;++i){var rowProperty=preview.properties[i];var rowPreview=rowProperty.valuePreview;if(!rowPreview)
|
| -continue;var rowValue={};const maxColumnsToRender=20;for(var j=0;j<rowPreview.properties.length;++j){var cellProperty=rowPreview.properties[j];var columnRendered=columnNames.indexOf(cellProperty.name)!=-1;if(!columnRendered){if(columnNames.length===maxColumnsToRender)
|
| -continue;columnRendered=true;columnNames.push(cellProperty.name);}
|
| -if(columnRendered)
|
| +continue;var rowValue={};const maxColumnsToRender=20;for(var j=0;j<rowPreview.properties.length&&j<maxColumnsToRender;++j){var cellProperty=rowPreview.properties[j];if(columnNames.indexOf(cellProperty.name)===-1){if(columnNames.length===maxColumnsToRender)
|
| +continue;columnNames.push(cellProperty.name);}
|
| rowValue[cellProperty.name]=this._renderPropertyPreview(cellProperty);}
|
| rows.push([rowProperty.name,rowValue]);}
|
| var flatValues=[];for(var i=0;i<rows.length;++i){var rowName=rows[i][0];var rowValue=rows[i][1];flatValues.push(rowName);for(var j=0;j<columnNames.length;++j)
|
| @@ -2371,7 +2356,7 @@
|
| if(this.type===WebInspector.ConsoleMessage.MessageType.StartGroup||this.type===WebInspector.ConsoleMessage.MessageType.StartGroupCollapsed)
|
| element.addStyleClass("console-group-title");element.appendChild(this.formattedMessage);if(this.repeatCount>1)
|
| this.updateRepeatCount();return element;},_populateStackTraceTreeElement:function(parentTreeElement)
|
| -{for(var i=0;i<this._stackTrace.length;i++){var frame=this._stackTrace[i];var content=document.createElement("div");var messageTextElement=document.createElement("span");messageTextElement.className="console-message-text source-code";var functionName=frame.functionName||WebInspector.UIString("(anonymous function)");messageTextElement.appendChild(document.createTextNode(functionName));content.appendChild(messageTextElement);if(frame.scriptId){content.appendChild(document.createTextNode(" "));var urlElement=this._linkifyCallFrame(frame);content.appendChild(urlElement);}
|
| +{for(var i=0;i<this._stackTrace.length;i++){var frame=this._stackTrace[i];var content=document.createElement("div");var messageTextElement=document.createElement("span");messageTextElement.className="console-message-text source-code";var functionName=frame.functionName||WebInspector.UIString("(anonymous function)");messageTextElement.appendChild(document.createTextNode(functionName));content.appendChild(messageTextElement);if(frame.url){content.appendChild(document.createTextNode(" "));var urlElement=this._linkifyCallFrame(frame);content.appendChild(urlElement);}
|
| var treeElement=new TreeElement(content);parentTreeElement.appendChild(treeElement);}},updateRepeatCount:function(){if(!this._element)
|
| return;if(!this.repeatCountElement){this.repeatCountElement=document.createElement("span");this.repeatCountElement.className="bubble";this._element.insertBefore(this.repeatCountElement,this._element.firstChild);this._element.addStyleClass("repeated-message");}
|
| this.repeatCountElement.textContent=this.repeatCount;},toString:function()
|
| @@ -2471,15 +2456,9 @@
|
| return;event.consume(true);this.prompt.clearAutoComplete(true);var str=this.prompt.text;if(!str.length)
|
| return;this._appendCommand(str,"",true,false);},_printResult:function(result,wasThrown,originatingCommand)
|
| {if(!result)
|
| -return;function addMessage(url,lineNumber,columnNumber)
|
| -{var message=new WebInspector.ConsoleCommandResult(result,wasThrown,originatingCommand,this._linkifier,url,lineNumber,columnNumber);WebInspector.console.addMessage(message);}
|
| -if(result.type!=="function"){addMessage.call(this);return;}
|
| -DebuggerAgent.getFunctionDetails(result.objectId,didGetDetails.bind(this));function didGetDetails(error,response)
|
| -{if(error){console.error(error);addMessage.call(this);return;}
|
| -var url;var lineNumber;var columnNumber;var script=WebInspector.debuggerModel.scriptForId(response.location.scriptId);console.assert(script);if(script.sourceURL){url=script.sourceURL;lineNumber=response.location.lineNumber+1;columnNumber=response.location.columnNumber+1;}
|
| -addMessage.call(this,url,lineNumber,columnNumber);}},_appendCommand:function(text,newPromptText,useCommandLineAPI,showResultOnly)
|
| +return;var message=new WebInspector.ConsoleCommandResult(result,wasThrown,originatingCommand,this._linkifier);WebInspector.console.addMessage(message);},_appendCommand:function(text,newPromptText,useCommandLineAPI,showResultOnly)
|
| {if(!showResultOnly){var commandMessage=new WebInspector.ConsoleCommand(text);WebInspector.console.addMessage(commandMessage);}
|
| -this.prompt.text=newPromptText;function printResult(result,wasThrown,valueResult)
|
| +this.prompt.text=newPromptText;function printResult(result,wasThrown)
|
| {if(!result)
|
| return;if(!showResultOnly){this.prompt.pushHistoryItem(text);WebInspector.settings.consoleHistory.set(this.prompt.historyData.slice(-30));}
|
| this._printResult(result,wasThrown,commandMessage);}
|
| @@ -2555,8 +2534,8 @@
|
| {if(!this._element){this._element=document.createElement("div");this._element.command=this;this._element.className="console-user-command";this._formatCommand();this._element.appendChild(this._formattedCommand);}
|
| return this._element;},_formatCommand:function()
|
| {this._formattedCommand=document.createElement("span");this._formattedCommand.className="console-message-text source-code";this._formattedCommand.textContent=this.text;},__proto__:WebInspector.ConsoleMessage.prototype}
|
| -WebInspector.ConsoleCommandResult=function(result,wasThrown,originatingCommand,linkifier,url,lineNumber,columnNumber)
|
| -{var level=(wasThrown?WebInspector.ConsoleMessage.MessageLevel.Error:WebInspector.ConsoleMessage.MessageLevel.Log);this.originatingCommand=originatingCommand;WebInspector.ConsoleMessageImpl.call(this,WebInspector.ConsoleMessage.MessageSource.JS,level,"",linkifier,WebInspector.ConsoleMessage.MessageType.Result,url,lineNumber,columnNumber,undefined,[result]);}
|
| +WebInspector.ConsoleCommandResult=function(result,wasThrown,originatingCommand,linkifier)
|
| +{var level=(wasThrown?WebInspector.ConsoleMessage.MessageLevel.Error:WebInspector.ConsoleMessage.MessageLevel.Log);this.originatingCommand=originatingCommand;WebInspector.ConsoleMessageImpl.call(this,WebInspector.ConsoleMessage.MessageSource.JS,level,"",linkifier,WebInspector.ConsoleMessage.MessageType.Result,undefined,undefined,undefined,undefined,[result]);}
|
| WebInspector.ConsoleCommandResult.prototype={useArrayPreviewInFormatter:function(array)
|
| {return false;},toMessageElement:function()
|
| {var element=WebInspector.ConsoleMessageImpl.prototype.toMessageElement.call(this);element.addStyleClass("console-user-command-result");return element;},__proto__:WebInspector.ConsoleMessageImpl.prototype}
|
| @@ -2994,8 +2973,7 @@
|
| path=path.substring(0,indexOfQuery);var lastSlashIndex=path.lastIndexOf("/");return lastSlashIndex!==-1?path.substring(0,lastSlashIndex):"";},get type()
|
| {return this._type;},set type(x)
|
| {this._type=x;},get domain()
|
| -{return this._parsedURL.host;},get scheme()
|
| -{return this._parsedURL.scheme;},get redirectSource()
|
| +{return this._parsedURL.host;},get redirectSource()
|
| {if(this.redirects&&this.redirects.length>0)
|
| return this.redirects[this.redirects.length-1];return this._redirectSource;},set redirectSource(x)
|
| {this._redirectSource=x;delete this._initiatorInfo;},get requestHeaders()
|
| @@ -3144,7 +3122,7 @@
|
| return false;return historyItem.loaderId===WebInspector.resourceTreeModel.mainFrame.loaderId;}
|
| historyItems=historyItems.filter(filterOutStale);if(!historyItems.length)
|
| return;for(var i=0;i<historyItems.length;++i){var content=window.localStorage[historyItems[i].key];var timestamp=new Date(historyItems[i].timestamp);var revision=new WebInspector.Revision(this,content,timestamp);this.history.push(revision);}
|
| -this._content=this.history[this.history.length-1].content;this._hasCommittedChanges=true;this._contentLoaded=true;this._mimeType=this.canonicalMimeType();},_clearRevisionHistory:function()
|
| +this._content=this.history[this.history.length-1].content;this._contentLoaded=true;this._mimeType=this.canonicalMimeType();},_clearRevisionHistory:function()
|
| {if(!window.localStorage)
|
| return;var registry=WebInspector.Revision._revisionHistoryRegistry();var historyItems=registry[this.url];for(var i=0;historyItems&&i<historyItems.length;++i)
|
| delete window.localStorage[historyItems[i].key];delete registry[this.url];window.localStorage["revision-history"]=JSON.stringify(registry);},revertToOriginal:function()
|
| @@ -3277,12 +3255,7 @@
|
| {if(error||!computedPayload)
|
| userCallback(null);else
|
| userCallback(WebInspector.CSSStyleDeclaration.parseComputedStylePayload(computedPayload));}
|
| -CSSAgent.getComputedStyleForNode(nodeId,callback.bind(null,userCallback));},getPlatformFontsForNode:function(nodeId,callback)
|
| -{function platformFontsCallback(error,cssFamilyName,fonts)
|
| -{if(error)
|
| -callback(null,null);else
|
| -callback(cssFamilyName,fonts);}
|
| -CSSAgent.getPlatformFontsForNode(nodeId,platformFontsCallback);},getInlineStylesAsync:function(nodeId,userCallback)
|
| +CSSAgent.getComputedStyleForNode(nodeId,callback.bind(null,userCallback));},getInlineStylesAsync:function(nodeId,userCallback)
|
| {function callback(userCallback,error,inlinePayload,attributesStylePayload)
|
| {if(error||!inlinePayload)
|
| userCallback(null,null);else
|
| @@ -3577,7 +3550,8 @@
|
| return true;if(typeof networkRequest.type==="undefined"||networkRequest.type===WebInspector.resourceTypes.Other||networkRequest.type===WebInspector.resourceTypes.XHR||networkRequest.type===WebInspector.resourceTypes.WebSocket)
|
| return true;if(!networkRequest.mimeType)
|
| return true;if(networkRequest.mimeType in WebInspector.NetworkManager._MIMETypes)
|
| -return networkRequest.type.name()in WebInspector.NetworkManager._MIMETypes[networkRequest.mimeType];return false;},_isNull:function(response)
|
| +return networkRequest.type.name()in WebInspector.NetworkManager._MIMETypes[networkRequest.mimeType];return false;},_updateNetworkRequestWithCachedResource:function(networkRequest,cachedResource)
|
| +{networkRequest.type=WebInspector.resourceTypes[cachedResource.type];networkRequest.resourceSize=cachedResource.bodySize;this._updateNetworkRequestWithResponse(networkRequest,cachedResource.response);},_isNull:function(response)
|
| {if(!response)
|
| return true;return!response.status&&!response.mimeType&&(!response.headers||!Object.keys(response.headers).length);},requestWillBeSent:function(requestId,frameId,loaderId,documentURL,request,time,initiator,redirectResponse)
|
| {var networkRequest=this._inflightRequestsById[requestId];if(networkRequest){if(!redirectResponse)
|
| @@ -3594,7 +3568,8 @@
|
| {var networkRequest=this._inflightRequestsById[requestId];if(!networkRequest)
|
| return;this._finishNetworkRequest(networkRequest,finishTime);},loadingFailed:function(requestId,time,localizedDescription,canceled)
|
| {var networkRequest=this._inflightRequestsById[requestId];if(!networkRequest)
|
| -return;networkRequest.failed=true;networkRequest.canceled=canceled;networkRequest.localizedFailDescription=localizedDescription;this._finishNetworkRequest(networkRequest,time);},webSocketCreated:function(requestId,requestURL)
|
| +return;networkRequest.failed=true;networkRequest.canceled=canceled;networkRequest.localizedFailDescription=localizedDescription;this._finishNetworkRequest(networkRequest,time);},requestServedFromMemoryCache:function(requestId,frameId,loaderId,documentURL,time,initiator,cachedResource)
|
| +{var networkRequest=this._createNetworkRequest(requestId,frameId,loaderId,cachedResource.url,documentURL,initiator);this._updateNetworkRequestWithCachedResource(networkRequest,cachedResource);networkRequest.cached=true;networkRequest.requestMethod="GET";this._startNetworkRequest(networkRequest);networkRequest.startTime=networkRequest.responseReceivedTime=time;this._finishNetworkRequest(networkRequest,time);},webSocketCreated:function(requestId,requestURL)
|
| {var networkRequest=new WebInspector.NetworkRequest(requestId,requestURL,"","","");networkRequest.type=WebInspector.resourceTypes.WebSocket;this._startNetworkRequest(networkRequest);},webSocketWillSendHandshakeRequest:function(requestId,time,request)
|
| {var networkRequest=this._inflightRequestsById[requestId];if(!networkRequest)
|
| return;networkRequest.requestMethod="GET";networkRequest.requestHeaders=this._headersMapToHeadersArray(request.headers);networkRequest.startTime=time;this._updateNetworkRequest(networkRequest);},webSocketHandshakeResponseReceived:function(requestId,time,response)
|
| @@ -3635,7 +3610,7 @@
|
| {this.id=++WebInspector.PageLoad._lastIdentifier;this.url=mainRequest.url;this.startTime=mainRequest.startTime;}
|
| WebInspector.PageLoad._lastIdentifier=0;WebInspector.ResourceTreeModel=function(networkManager)
|
| {networkManager.addEventListener(WebInspector.NetworkManager.EventTypes.RequestFinished,this._onRequestFinished,this);networkManager.addEventListener(WebInspector.NetworkManager.EventTypes.RequestUpdateDropped,this._onRequestUpdateDropped,this);WebInspector.console.addEventListener(WebInspector.ConsoleModel.Events.MessageAdded,this._consoleMessageAdded,this);WebInspector.console.addEventListener(WebInspector.ConsoleModel.Events.RepeatCountUpdated,this._consoleMessageAdded,this);WebInspector.console.addEventListener(WebInspector.ConsoleModel.Events.ConsoleCleared,this._consoleCleared,this);PageAgent.enable();NetworkAgent.enable();this._fetchResourceTree();InspectorBackend.registerPageDispatcher(new WebInspector.PageDispatcher(this));this._pendingConsoleMessages={};this._securityOriginFrameCount={};}
|
| -WebInspector.ResourceTreeModel.EventTypes={FrameAdded:"FrameAdded",FrameNavigated:"FrameNavigated",FrameDetached:"FrameDetached",MainFrameNavigated:"MainFrameNavigated",MainFrameCreatedOrNavigated:"MainFrameCreatedOrNavigated",ResourceAdded:"ResourceAdded",WillLoadCachedResources:"WillLoadCachedResources",CachedResourcesLoaded:"CachedResourcesLoaded",DOMContentLoaded:"DOMContentLoaded",Load:"Load",InspectedURLChanged:"InspectedURLChanged",SecurityOriginAdded:"SecurityOriginAdded",SecurityOriginRemoved:"SecurityOriginRemoved",ScreencastFrame:"ScreencastFrame",}
|
| +WebInspector.ResourceTreeModel.EventTypes={FrameAdded:"FrameAdded",FrameNavigated:"FrameNavigated",FrameDetached:"FrameDetached",MainFrameNavigated:"MainFrameNavigated",MainFrameCreatedOrNavigated:"MainFrameCreatedOrNavigated",ResourceAdded:"ResourceAdded",WillLoadCachedResources:"WillLoadCachedResources",CachedResourcesLoaded:"CachedResourcesLoaded",DOMContentLoaded:"DOMContentLoaded",Load:"Load",InspectedURLChanged:"InspectedURLChanged",SecurityOriginAdded:"SecurityOriginAdded",SecurityOriginRemoved:"SecurityOriginRemoved"}
|
| WebInspector.ResourceTreeModel.prototype={_fetchResourceTree:function()
|
| {this._frames={};delete this._cachedResourcesProcessed;PageAgent.getResourceTree(this._processCachedResources.bind(this));},_processCachedResources:function(error,mainFramePayload)
|
| {if(error){console.error(JSON.stringify(error));return;}
|
| @@ -3736,8 +3711,7 @@
|
| {this._resourceTreeModel=resourceTreeModel;}
|
| WebInspector.PageDispatcher.prototype={domContentEventFired:function(time)
|
| {this._resourceTreeModel.dispatchEventToListeners(WebInspector.ResourceTreeModel.EventTypes.DOMContentLoaded,time);},loadEventFired:function(time)
|
| -{this._resourceTreeModel.dispatchEventToListeners(WebInspector.ResourceTreeModel.EventTypes.Load,time);},frameAttached:function(frameId)
|
| -{},frameNavigated:function(frame)
|
| +{this._resourceTreeModel.dispatchEventToListeners(WebInspector.ResourceTreeModel.EventTypes.Load,time);},frameNavigated:function(frame)
|
| {this._resourceTreeModel._frameNavigated(frame);},frameDetached:function(frameId)
|
| {this._resourceTreeModel._frameDetached(frameId);},frameStartedLoading:function(frameId)
|
| {},frameStoppedLoading:function(frameId)
|
| @@ -3746,8 +3720,7 @@
|
| {},javascriptDialogOpening:function(message)
|
| {},javascriptDialogClosed:function()
|
| {},scriptsEnabled:function(isEnabled)
|
| -{WebInspector.settings.javaScriptDisabled.set(!isEnabled);},screencastFrame:function(data,deviceScaleFactor,pageScaleFactor,viewport,offsetTop,offsetBottom)
|
| -{this._resourceTreeModel.dispatchEventToListeners(WebInspector.ResourceTreeModel.EventTypes.ScreencastFrame,{data:data,deviceScaleFactor:deviceScaleFactor,pageScaleFactor:pageScaleFactor,viewport:viewport,offsetTop:offsetTop,offsetBottom:offsetBottom});}}
|
| +{WebInspector.settings.javaScriptDisabled.set(!isEnabled);}}
|
| WebInspector.resourceTreeModel=null;WebInspector.ParsedURL=function(url)
|
| {this.isValid=false;this.url=url;this.scheme="";this.host="";this.port="";this.path="";this.queryParams="";this.fragment="";this.folderPathComponents="";this.lastPathComponent="";var match=url.match(/^([A-Za-z][A-Za-z0-9+.-]*):\/\/([^\/:]*)(?::([\d]+))?(?:(\/[^#]*)(?:#(.*))?)?$/i);if(match){this.isValid=true;this.scheme=match[1].toLowerCase();this.host=match[2];this.port=match[3];this.path=match[4]||"/";this.fragment=match[5];}else{if(this.url.startsWith("data:")){this.scheme="data";return;}
|
| if(this.url==="about:blank"){this.scheme="about";return;}
|
| @@ -3848,7 +3821,7 @@
|
| WebInspector.ResourceType.mimeTypesForExtensions={"js":"text/javascript","css":"text/css","html":"text/html","htm":"text/html","xml":"application/xml","xsl":"application/xml","asp":"application/x-aspx","aspx":"application/x-aspx","jsp":"application/x-jsp","c":"text/x-c++src","cc":"text/x-c++src","cpp":"text/x-c++src","h":"text/x-c++src","m":"text/x-c++src","mm":"text/x-c++src","coffee":"text/x-coffeescript","dart":"text/javascript","ts":"text/typescript","json":"application/json","gyp":"application/json","gypi":"application/json","cs":"text/x-csharp","java":"text/x-java","php":"text/x-php","phtml":"application/x-httpd-php","py":"text/x-python","sh":"text/x-sh","scss":"text/x-scss"}
|
| WebInspector.TimelineManager=function()
|
| {WebInspector.Object.call(this);this._dispatcher=new WebInspector.TimelineDispatcher(this);this._enablementCount=0;}
|
| -WebInspector.TimelineManager.EventTypes={TimelineStarted:"TimelineStarted",TimelineStopped:"TimelineStopped",TimelineEventRecorded:"TimelineEventRecorded"}
|
| +WebInspector.TimelineManager.EventTypes={TimelineStarted:"TimelineStarted",TimelineStopped:"TimelineStopped",TimelineStartEvent:"TimelineStartEvent",TimelineEventRecorded:"TimelineEventRecorded"}
|
| WebInspector.TimelineManager.prototype={start:function(maxCallStackDepth,includeDomCounters,includeNativeMemoryStatistics)
|
| {this._enablementCount++;if(this._enablementCount===1)
|
| TimelineAgent.start(maxCallStackDepth,includeDomCounters,includeNativeMemoryStatistics,this._started.bind(this));},stop:function()
|
| @@ -3859,7 +3832,8 @@
|
| {this.dispatchEventToListeners(WebInspector.TimelineManager.EventTypes.TimelineStopped);},__proto__:WebInspector.Object.prototype}
|
| WebInspector.TimelineDispatcher=function(manager)
|
| {this._manager=manager;InspectorBackend.registerTimelineDispatcher(this);}
|
| -WebInspector.TimelineDispatcher.prototype={eventRecorded:function(record)
|
| +WebInspector.TimelineDispatcher.prototype={timelineStarted:function(timestampsBase,startTime)
|
| +{var event={timestampsBase:timestampsBase,startTime:startTime};this._manager.dispatchEventToListeners(WebInspector.TimelineManager.EventTypes.TimelineStartEvent,event);},eventRecorded:function(record)
|
| {this._manager.dispatchEventToListeners(WebInspector.TimelineManager.EventTypes.TimelineEventRecorded,record);}}
|
| WebInspector.timelineManager;WebInspector.OverridesSupport=function()
|
| {this._overridesActive=WebInspector.settings.enableOverridesOnStartup.get();this._updateAllOverrides();WebInspector.settings.overrideUserAgent.addChangeListener(this._userAgentChanged,this);WebInspector.settings.userAgent.addChangeListener(this._userAgentChanged,this);WebInspector.settings.overrideDeviceMetrics.addChangeListener(this._deviceMetricsChanged,this);WebInspector.settings.deviceMetrics.addChangeListener(this._deviceMetricsChanged,this);WebInspector.settings.deviceFitWindow.addChangeListener(this._deviceMetricsChanged,this);WebInspector.settings.overrideGeolocation.addChangeListener(this._geolocationPositionChanged,this);WebInspector.settings.geolocationOverride.addChangeListener(this._geolocationPositionChanged,this);WebInspector.settings.overrideDeviceOrientation.addChangeListener(this._deviceOrientationChanged,this);WebInspector.settings.deviceOrientationOverride.addChangeListener(this._deviceOrientationChanged,this);WebInspector.settings.emulateTouchEvents.addChangeListener(this._emulateTouchEventsChanged,this);WebInspector.settings.overrideCSSMedia.addChangeListener(this._cssMediaChanged,this);WebInspector.settings.emulatedCSSMedia.addChangeListener(this._cssMediaChanged,this);}
|
| @@ -3970,32 +3944,66 @@
|
| WebInspector.DatabaseDispatcher.prototype={addDatabase:function(payload)
|
| {this._model._addDatabase(new WebInspector.Database(this._model,payload.id,payload.domain,payload.name,payload.version));}}
|
| WebInspector.databaseModel=null;WebInspector.DOMStorage=function(securityOrigin,isLocalStorage)
|
| -{this._securityOrigin=securityOrigin;this._isLocalStorage=isLocalStorage;}
|
| +{this._securityOrigin=securityOrigin;this._isLocalStorage=isLocalStorage;this._storageHistory=new WebInspector.DOMStorageHistory(this);}
|
| WebInspector.DOMStorage.storageId=function(securityOrigin,isLocalStorage)
|
| {return{securityOrigin:securityOrigin,isLocalStorage:isLocalStorage};}
|
| -WebInspector.DOMStorage.Events={DOMStorageItemsCleared:"DOMStorageItemsCleared",DOMStorageItemRemoved:"DOMStorageItemRemoved",DOMStorageItemAdded:"DOMStorageItemAdded",DOMStorageItemUpdated:"DOMStorageItemUpdated"}
|
| WebInspector.DOMStorage.prototype={get id()
|
| {return WebInspector.DOMStorage.storageId(this._securityOrigin,this._isLocalStorage);},get securityOrigin()
|
| {return this._securityOrigin;},get isLocalStorage()
|
| {return this._isLocalStorage;},getItems:function(callback)
|
| {DOMStorageAgent.getDOMStorageItems(this.id,callback);},setItem:function(key,value)
|
| -{DOMStorageAgent.setDOMStorageItem(this.id,key,value);},removeItem:function(key)
|
| -{DOMStorageAgent.removeDOMStorageItem(this.id,key);},__proto__:WebInspector.Object.prototype}
|
| +{this._storageHistory.perform(new WebInspector.DOMStorageSetItemAction(this,key,value));},removeItem:function(key)
|
| +{this._storageHistory.perform(new WebInspector.DOMStorageRemoveItemAction(this,key));},undo:function()
|
| +{this._storageHistory.undo();},redo:function()
|
| +{this._storageHistory.redo();}}
|
| +WebInspector.DOMStorageAction=function(domStorage)
|
| +{this._domStorage=domStorage;}
|
| +WebInspector.DOMStorageAction.prototype={perform:function(callback)
|
| +{},undo:function()
|
| +{},redo:function()
|
| +{}}
|
| +WebInspector.DOMStorageRemoveItemAction=function(domStorage,key)
|
| +{WebInspector.DOMStorageAction.call(this,domStorage);this._key=key;}
|
| +WebInspector.DOMStorageRemoveItemAction.prototype={perform:function(callback)
|
| +{DOMStorageAgent.getValue(this._domStorage.id,this._key,valueReceived.bind(this));function valueReceived(error,value)
|
| +{if(error)
|
| +return;this._value=value;this.redo();callback();}},undo:function()
|
| +{DOMStorageAgent.setDOMStorageItem(this._domStorage.id,this._key,this._value);},redo:function()
|
| +{DOMStorageAgent.removeDOMStorageItem(this._domStorage.id,this._key);},__proto__:WebInspector.DOMStorageAction.prototype}
|
| +WebInspector.DOMStorageSetItemAction=function(domStorage,key,value)
|
| +{WebInspector.DOMStorageAction.call(this,domStorage);this._key=key;this._value=value;}
|
| +WebInspector.DOMStorageSetItemAction.prototype={perform:function(callback)
|
| +{DOMStorageAgent.getValue(this._domStorage.id,this._key,valueReceived.bind(this));function valueReceived(error,value)
|
| +{if(error)
|
| +return;if(typeof value==="undefined")
|
| +delete this._exists;else{this._exists=true;this._oldValue=value;}
|
| +this.redo();callback();}},undo:function()
|
| +{if(!this._exists)
|
| +DOMStorageAgent.removeDOMStorageItem(this._domStorage.id,this._key);else
|
| +DOMStorageAgent.setDOMStorageItem(this._domStorage.id,this._key,this._oldValue);},redo:function()
|
| +{DOMStorageAgent.setDOMStorageItem(this._domStorage.id,this._key,this._value);},__proto__:WebInspector.DOMStorageAction.prototype}
|
| +WebInspector.DOMStorageHistory=function(domStorage)
|
| +{this._domStorage=domStorage;this._actions=[];this._undoableActionIndex=-1;}
|
| +WebInspector.DOMStorageHistory.MAX_UNDO_STACK_DEPTH=256;WebInspector.DOMStorageHistory.prototype={perform:function(action)
|
| +{if(!action)
|
| +return;action.perform(actionCompleted.bind(this));function actionCompleted()
|
| +{if(this._undoableActionIndex+1===WebInspector.DOMStorageHistory.MAX_UNDO_STACK_DEPTH){this._actions.shift();--this._undoableActionIndex;}else if(this._undoableActionIndex+1<this._actions.length)
|
| +this._actions.splice(this._undoableActionIndex+1);this._actions.push(action);++this._undoableActionIndex;}},undo:function()
|
| +{if(this._undoableActionIndex<0)
|
| +return;var action=this._actions[this._undoableActionIndex];console.assert(action);action.undo();--this._undoableActionIndex;},redo:function()
|
| +{if(this._undoableActionIndex>=this._actions.length-1)
|
| +return;var action=this._actions[++this._undoableActionIndex];console.assert(action);action.redo();}}
|
| WebInspector.DOMStorageModel=function()
|
| {this._storages={};InspectorBackend.registerDOMStorageDispatcher(new WebInspector.DOMStorageDispatcher(this));DOMStorageAgent.enable();WebInspector.resourceTreeModel.addEventListener(WebInspector.ResourceTreeModel.EventTypes.SecurityOriginAdded,this._securityOriginAdded,this);WebInspector.resourceTreeModel.addEventListener(WebInspector.ResourceTreeModel.EventTypes.SecurityOriginRemoved,this._securityOriginRemoved,this);}
|
| -WebInspector.DOMStorageModel.Events={DOMStorageAdded:"DOMStorageAdded",DOMStorageRemoved:"DOMStorageRemoved"}
|
| +WebInspector.DOMStorageModel.Events={DOMStorageAdded:"DOMStorageAdded",DOMStorageRemoved:"DOMStorageRemoved",DOMStorageItemsCleared:"DOMStorageItemsCleared",DOMStorageItemRemoved:"DOMStorageItemRemoved",DOMStorageItemAdded:"DOMStorageItemAdded",DOMStorageItemUpdated:"DOMStorageItemUpdated"}
|
| WebInspector.DOMStorageModel.prototype={_securityOriginAdded:function(event)
|
| {var securityOrigin=(event.data);var localStorageKey=this._storageKey(securityOrigin,true);console.assert(!this._storages[localStorageKey]);var localStorage=new WebInspector.DOMStorage(securityOrigin,true);this._storages[localStorageKey]=localStorage;this.dispatchEventToListeners(WebInspector.DOMStorageModel.Events.DOMStorageAdded,localStorage);var sessionStorageKey=this._storageKey(securityOrigin,false);console.assert(!this._storages[sessionStorageKey]);var sessionStorage=new WebInspector.DOMStorage(securityOrigin,false);this._storages[sessionStorageKey]=sessionStorage;this.dispatchEventToListeners(WebInspector.DOMStorageModel.Events.DOMStorageAdded,sessionStorage);},_securityOriginRemoved:function(event)
|
| {var securityOrigin=(event.data);var localStorageKey=this._storageKey(securityOrigin,true);var localStorage=this._storages[localStorageKey];console.assert(localStorage);delete this._storages[localStorageKey];this.dispatchEventToListeners(WebInspector.DOMStorageModel.Events.DOMStorageRemoved,localStorage);var sessionStorageKey=this._storageKey(securityOrigin,false);var sessionStorage=this._storages[sessionStorageKey];console.assert(sessionStorage);delete this._storages[sessionStorageKey];this.dispatchEventToListeners(WebInspector.DOMStorageModel.Events.DOMStorageRemoved,sessionStorage);},_storageKey:function(securityOrigin,isLocalStorage)
|
| {return JSON.stringify(WebInspector.DOMStorage.storageId(securityOrigin,isLocalStorage));},_domStorageItemsCleared:function(storageId)
|
| -{var domStorage=this.storageForId(storageId);if(!domStorage)
|
| -return;var eventData={};domStorage.dispatchEventToListeners(WebInspector.DOMStorage.Events.DOMStorageItemsCleared,eventData);},_domStorageItemRemoved:function(storageId,key)
|
| -{var domStorage=this.storageForId(storageId);if(!domStorage)
|
| -return;var eventData={key:key};domStorage.dispatchEventToListeners(WebInspector.DOMStorage.Events.DOMStorageItemRemoved,eventData);},_domStorageItemAdded:function(storageId,key,value)
|
| -{var domStorage=this.storageForId(storageId);if(!domStorage)
|
| -return;var eventData={key:key,value:value};domStorage.dispatchEventToListeners(WebInspector.DOMStorage.Events.DOMStorageItemAdded,eventData);},_domStorageItemUpdated:function(storageId,key,oldValue,value)
|
| -{var domStorage=this.storageForId(storageId);if(!domStorage)
|
| -return;var eventData={key:key,oldValue:oldValue,value:value};domStorage.dispatchEventToListeners(WebInspector.DOMStorage.Events.DOMStorageItemUpdated,eventData);},storageForId:function(storageId)
|
| +{var domStorage=this.storageForId(storageId);var storageData={storage:domStorage};this.dispatchEventToListeners(WebInspector.DOMStorageModel.Events.DOMStorageItemsCleared,storageData);},_domStorageItemRemoved:function(storageId,key)
|
| +{var domStorage=this.storageForId(storageId);var storageData={storage:domStorage,key:key};this.dispatchEventToListeners(WebInspector.DOMStorageModel.Events.DOMStorageItemRemoved,storageData);},_domStorageItemAdded:function(storageId,key,newValue)
|
| +{var domStorage=this.storageForId(storageId);var storageData={storage:domStorage,key:key,newValue:newValue};this.dispatchEventToListeners(WebInspector.DOMStorageModel.Events.DOMStorageItemAdded,storageData);},_domStorageItemUpdated:function(storageId,key,oldValue,newValue)
|
| +{var domStorage=this.storageForId(storageId);var storageData={storage:domStorage,key:key,oldValue:oldValue,newValue:newValue};this.dispatchEventToListeners(WebInspector.DOMStorageModel.Events.DOMStorageItemUpdated,storageData);},storageForId:function(storageId)
|
| {return this._storages[JSON.stringify(storageId)];},storages:function()
|
| {var result=[];for(var id in this._storages)
|
| result.push(this._storages[id]);return result;},__proto__:WebInspector.Object.prototype}
|
| @@ -4003,9 +4011,9 @@
|
| {this._model=model;}
|
| WebInspector.DOMStorageDispatcher.prototype={domStorageItemsCleared:function(storageId)
|
| {this._model._domStorageItemsCleared(storageId);},domStorageItemRemoved:function(storageId,key)
|
| -{this._model._domStorageItemRemoved(storageId,key);},domStorageItemAdded:function(storageId,key,value)
|
| -{this._model._domStorageItemAdded(storageId,key,value);},domStorageItemUpdated:function(storageId,key,oldValue,value)
|
| -{this._model._domStorageItemUpdated(storageId,key,oldValue,value);},}
|
| +{this._model._domStorageItemRemoved(storageId,key);},domStorageItemAdded:function(storageId,key,newValue)
|
| +{this._model._domStorageItemAdded(storageId,key,newValue);},domStorageItemUpdated:function(storageId,key,oldValue,newValue)
|
| +{this._model._domStorageItemUpdated(storageId,key,oldValue,newValue);},}
|
| WebInspector.domStorageModel=null;WebInspector.DataGrid=function(columnsArray,editCallback,deleteCallback,refreshCallback,contextMenuCallback)
|
| {WebInspector.View.call(this);this.registerRequiredCSS("dataGrid.css");this.element.className="data-grid";this.element.tabIndex=0;this.element.addEventListener("keydown",this._keyDown.bind(this),false);this._headerTable=document.createElement("table");this._headerTable.className="header";this._headerTableHeaders={};this._dataTable=document.createElement("table");this._dataTable.className="data";this._dataTable.addEventListener("mousedown",this._mouseDownInDataTable.bind(this),true);this._dataTable.addEventListener("click",this._clickInDataTable.bind(this),true);this._dataTable.addEventListener("contextmenu",this._contextMenuInDataTable.bind(this),true);if(editCallback)
|
| this._dataTable.addEventListener("dblclick",this._ondblclick.bind(this),false);this._editCallback=editCallback;this._deleteCallback=deleteCallback;this._refreshCallback=refreshCallback;this._contextMenuCallback=contextMenuCallback;this._scrollContainer=document.createElement("div");this._scrollContainer.className="data-container";this._scrollContainer.appendChild(this._dataTable);this.element.appendChild(this._headerTable);this.element.appendChild(this._scrollContainer);var headerRow=document.createElement("tr");var columnGroup=document.createElement("colgroup");columnGroup.span=columnsArray.length;var fillerRow=document.createElement("tr");fillerRow.className="filler";this._columnsArray=columnsArray;this.columns={};for(var i=0;i<columnsArray.length;++i){var column=columnsArray[i];column.ordinal=i;var columnIdentifier=column.identifier=column.id||i;this.columns[columnIdentifier]=column;if(column.disclosure)
|
| @@ -4625,13 +4633,11 @@
|
| {WebInspector.TabbedPane.call(this);this.setRetainTabsOrder(true);this.element.addStyleClass("sidebar-tabbed-pane");this.registerRequiredCSS("sidebarPane.css");}
|
| WebInspector.SidebarTabbedPane.prototype={addPane:function(pane)
|
| {var title=pane.title();this.appendTab(title,title,pane);pane.element.appendChild(pane.titleElement);pane.setExpandCallback(this.selectTab.bind(this,title));},__proto__:WebInspector.TabbedPane.prototype}
|
| -WebInspector.ElementsTreeOutline=function(omitRootDOMNode,selectEnabled,contextMenuCallback,setPseudoClassCallback)
|
| -{this.element=document.createElement("ol");this.element.className="elements-tree-outline";this.element.addEventListener("mousedown",this._onmousedown.bind(this),false);this.element.addEventListener("mousemove",this._onmousemove.bind(this),false);this.element.addEventListener("mouseout",this._onmouseout.bind(this),false);this.element.addEventListener("dragstart",this._ondragstart.bind(this),false);this.element.addEventListener("dragover",this._ondragover.bind(this),false);this.element.addEventListener("dragleave",this._ondragleave.bind(this),false);this.element.addEventListener("drop",this._ondrop.bind(this),false);this.element.addEventListener("dragend",this._ondragend.bind(this),false);this.element.addEventListener("keydown",this._onkeydown.bind(this),false);TreeOutline.call(this,this.element);this._includeRootDOMNode=!omitRootDOMNode;this._selectEnabled=selectEnabled;this._rootDOMNode=null;this._selectedDOMNode=null;this._eventSupport=new WebInspector.Object();this._visible=false;this.element.addEventListener("contextmenu",this._contextMenuEventFired.bind(this),true);this._contextMenuCallback=contextMenuCallback;this._setPseudoClassCallback=setPseudoClassCallback;this._createNodeDecorators();}
|
| -WebInspector.ElementsTreeOutline.Events={SelectedNodeChanged:"SelectedNodeChanged",ElementsTreeUpdated:"ElementsTreeUpdated"}
|
| +WebInspector.ElementsTreeOutline=function(omitRootDOMNode,selectEnabled,showInElementsPanelEnabled,contextMenuCallback,setPseudoClassCallback)
|
| +{this.element=document.createElement("ol");this.element.className="elements-tree-outline";this.element.addEventListener("mousedown",this._onmousedown.bind(this),false);this.element.addEventListener("mousemove",this._onmousemove.bind(this),false);this.element.addEventListener("mouseout",this._onmouseout.bind(this),false);this.element.addEventListener("dragstart",this._ondragstart.bind(this),false);this.element.addEventListener("dragover",this._ondragover.bind(this),false);this.element.addEventListener("dragleave",this._ondragleave.bind(this),false);this.element.addEventListener("drop",this._ondrop.bind(this),false);this.element.addEventListener("dragend",this._ondragend.bind(this),false);this.element.addEventListener("keydown",this._onkeydown.bind(this),false);TreeOutline.call(this,this.element);this._includeRootDOMNode=!omitRootDOMNode;this._selectEnabled=selectEnabled;this._showInElementsPanelEnabled=showInElementsPanelEnabled;this._rootDOMNode=null;this._selectDOMNode=null;this._eventSupport=new WebInspector.Object();this._visible=false;this.element.addEventListener("contextmenu",this._contextMenuEventFired.bind(this),true);this._contextMenuCallback=contextMenuCallback;this._setPseudoClassCallback=setPseudoClassCallback;this._createNodeDecorators();}
|
| +WebInspector.ElementsTreeOutline.Events={SelectedNodeChanged:"SelectedNodeChanged"}
|
| WebInspector.ElementsTreeOutline.MappedCharToEntity={"\u00a0":"nbsp","\u2002":"ensp","\u2003":"emsp","\u2009":"thinsp","\u200a":"#8202","\u200b":"#8203","\u200c":"zwnj","\u200d":"zwj","\u200e":"lrm","\u200f":"rlm","\u202a":"#8234","\u202b":"#8235","\u202c":"#8236","\u202d":"#8237","\u202e":"#8238"}
|
| -WebInspector.ElementsTreeOutline.prototype={setVisibleWidth:function(width)
|
| -{this._visibleWidth=width;if(this._multilineEditing)
|
| -this._multilineEditing.setWidth(this._visibleWidth);},_createNodeDecorators:function()
|
| +WebInspector.ElementsTreeOutline.prototype={_createNodeDecorators:function()
|
| {this._nodeDecorators=[];this._nodeDecorators.push(new WebInspector.ElementsTreeOutline.PseudoStateDecorator());},wireToDomAgent:function()
|
| {this._elementsTreeUpdater=new WebInspector.ElementsTreeUpdater(this);},setVisible:function(visible)
|
| {this._visible=visible;if(!this._visible)
|
| @@ -4659,8 +4665,7 @@
|
| {var treeElement=this.findTreeElement(node);if(treeElement)
|
| treeElement.updateTitle();var children=treeElement.children;var closingTagElement=children[children.length-1];if(closingTagElement&&closingTagElement._elementCloseTag)
|
| closingTagElement.updateTitle();},_selectedNodeChanged:function()
|
| -{this._eventSupport.dispatchEventToListeners(WebInspector.ElementsTreeOutline.Events.SelectedNodeChanged,this._selectedDOMNode);},_fireElementsTreeUpdated:function(nodes)
|
| -{this._eventSupport.dispatchEventToListeners(WebInspector.ElementsTreeOutline.Events.ElementsTreeUpdated,nodes);},findTreeElement:function(node)
|
| +{this._eventSupport.dispatchEventToListeners(WebInspector.ElementsTreeOutline.Events.SelectedNodeChanged,this._selectedDOMNode);},findTreeElement:function(node)
|
| {function isAncestorNode(ancestor,node)
|
| {return ancestor.isAncestor(node);}
|
| function parentNode(node)
|
| @@ -4709,14 +4714,17 @@
|
| this._doMove(treeElement);},_doMove:function(treeElement)
|
| {if(!this._treeElementBeingDragged)
|
| return;var parentNode;var anchorNode;if(treeElement._elementCloseTag){parentNode=treeElement._node;}else{var dragTargetNode=treeElement._node;parentNode=dragTargetNode.parentNode;anchorNode=dragTargetNode;}
|
| -var wasExpanded=this._treeElementBeingDragged.expanded;this._treeElementBeingDragged._node.moveTo(parentNode,anchorNode,this._selectNodeAfterEdit.bind(this,wasExpanded));delete this._treeElementBeingDragged;},_ondragend:function(event)
|
| +var wasExpanded=this._treeElementBeingDragged.expanded;this._treeElementBeingDragged._node.moveTo(parentNode,anchorNode,this._selectNodeAfterEdit.bind(this,null,wasExpanded));delete this._treeElementBeingDragged;},_ondragend:function(event)
|
| {event.preventDefault();this._clearDragOverTreeElementMarker();delete this._treeElementBeingDragged;},_clearDragOverTreeElementMarker:function()
|
| {if(this._dragOverTreeElement){this._dragOverTreeElement.updateSelection();this._dragOverTreeElement.listItemElement.removeStyleClass("elements-drag-over");delete this._dragOverTreeElement;}},_onkeydown:function(event)
|
| {var keyboardEvent=(event);var node=this.selectedDOMNode();var treeElement=this.getCachedTreeElement(node);if(!treeElement)
|
| return;if(!treeElement._editing&&WebInspector.KeyboardShortcut.hasNoModifiers(keyboardEvent)&&keyboardEvent.keyCode===WebInspector.KeyboardShortcut.Keys.H.code){this._toggleHideShortcut(node);event.consume(true);return;}},_contextMenuEventFired:function(event)
|
| +{if(!this._showInElementsPanelEnabled)
|
| +return;var treeElement=this._treeElementFromEvent(event);if(!treeElement)
|
| +return;function focusElement()
|
| +{WebInspector.showPanel("elements");WebInspector.domAgent.inspectElement(treeElement._node.id);}
|
| +var contextMenu=new WebInspector.ContextMenu(event);contextMenu.appendItem(WebInspector.UIString(WebInspector.useLowerCaseMenuTitles()?"Reveal in Elements panel":"Reveal in Elements Panel"),focusElement.bind(this));contextMenu.show();},populateContextMenu:function(contextMenu,event)
|
| {var treeElement=this._treeElementFromEvent(event);if(!treeElement)
|
| -return;var contextMenu=new WebInspector.ContextMenu(event);contextMenu.appendApplicableItems(treeElement._node);contextMenu.show();},populateContextMenu:function(contextMenu,event)
|
| -{var treeElement=this._treeElementFromEvent(event);if(!treeElement)
|
| return;var isTag=treeElement._node.nodeType()===Node.ELEMENT_NODE;var textNode=event.target.enclosingNodeOrSelfWithClass("webkit-html-text-node");if(textNode&&textNode.hasStyleClass("bogus"))
|
| textNode=null;var commentNode=event.target.enclosingNodeOrSelfWithClass("webkit-html-comment");contextMenu.appendApplicableItems(event.target);if(textNode){contextMenu.appendSeparator();treeElement._populateTextContextMenu(contextMenu,textNode);}else if(isTag){contextMenu.appendSeparator();treeElement._populateTagContextMenu(contextMenu,event);}else if(commentNode){contextMenu.appendSeparator();treeElement._populateNodeContextMenu(contextMenu,textNode);}},_updateModifiedNodes:function()
|
| {if(this._elementsTreeUpdater)
|
| @@ -4725,14 +4733,14 @@
|
| this._contextMenuCallback(contextMenu,node);},handleShortcut:function(event)
|
| {var node=this.selectedDOMNode();var treeElement=this.getCachedTreeElement(node);if(!node||!treeElement)
|
| return;if(event.keyIdentifier==="F2"){this._toggleEditAsHTML(node);event.handled=true;return;}
|
| -if(WebInspector.KeyboardShortcut.eventHasCtrlOrMeta(event)&&node.parentNode){if(event.keyIdentifier==="Up"&&node.previousSibling){node.moveTo(node.parentNode,node.previousSibling,this._selectNodeAfterEdit.bind(this,treeElement.expanded));event.handled=true;return;}
|
| -if(event.keyIdentifier==="Down"&&node.nextSibling){node.moveTo(node.parentNode,node.nextSibling.nextSibling,this._selectNodeAfterEdit.bind(this,treeElement.expanded));event.handled=true;return;}}},_toggleEditAsHTML:function(node)
|
| +if(WebInspector.KeyboardShortcut.eventHasCtrlOrMeta(event)&&node.parentNode){if(event.keyIdentifier==="Up"&&node.previousSibling){node.moveTo(node.parentNode,node.previousSibling,this._selectNodeAfterEdit.bind(this,null,treeElement.expanded));event.handled=true;return;}
|
| +if(event.keyIdentifier==="Down"&&node.nextSibling){node.moveTo(node.parentNode,node.nextSibling.nextSibling,this._selectNodeAfterEdit.bind(this,null,treeElement.expanded));event.handled=true;return;}}},_toggleEditAsHTML:function(node)
|
| {var treeElement=this.getCachedTreeElement(node);if(!treeElement)
|
| return;if(treeElement._editing&&treeElement._htmlEditElement&&WebInspector.isBeingEdited(treeElement._htmlEditElement))
|
| treeElement._editing.commit();else
|
| -treeElement._editAsHTML();},_selectNodeAfterEdit:function(wasExpanded,error,nodeId)
|
| +treeElement._editAsHTML();},_selectNodeAfterEdit:function(fallbackNode,wasExpanded,error,nodeId)
|
| {if(error)
|
| -return;this._updateModifiedNodes();var newNode=nodeId?WebInspector.domAgent.nodeForId(nodeId):null;if(!newNode)
|
| +return;this._updateModifiedNodes();var newNode=WebInspector.domAgent.nodeForId(nodeId)||fallbackNode;if(!newNode)
|
| return;this.selectDOMNode(newNode,true);var newTreeItem=this.findTreeElement(newNode);if(wasExpanded){if(newTreeItem)
|
| newTreeItem.expand();}
|
| return newTreeItem;},_toggleHideShortcut:function(node,userCallback)
|
| @@ -4918,10 +4926,10 @@
|
| this._childrenListNode.style.display="none";this.listItemElement.appendChild(this._htmlEditElement);this.treeOutline.childrenListElement.parentElement.addEventListener("mousedown",consume,false);this.updateSelection();function commit(element,newValue)
|
| {commitCallback(initialValue,newValue);dispose.call(this);}
|
| function dispose()
|
| -{delete this._editing;delete this.treeOutline._multilineEditing;this.listItemElement.removeChild(this._htmlEditElement);delete this._htmlEditElement;if(this._childrenListNode)
|
| +{delete this._editing;this.listItemElement.removeChild(this._htmlEditElement);delete this._htmlEditElement;if(this._childrenListNode)
|
| this._childrenListNode.style.removeProperty("display");var child=this.listItemElement.firstChild;while(child){child.style.removeProperty("display");child=child.nextSibling;}
|
| -this.treeOutline.childrenListElement.parentElement.removeEventListener("mousedown",consume,false);this.updateSelection();this.treeOutline.element.focus();}
|
| -var config=new WebInspector.EditingConfig(commit.bind(this),dispose.bind(this));config.setMultilineOptions(initialValue,{name:"xml",htmlMode:true},"web-inspector-html",WebInspector.settings.domWordWrap.get(),true);this._editing=WebInspector.startEditing(this._htmlEditElement,config);this._editing.setWidth(this.treeOutline._visibleWidth);this.treeOutline._multilineEditing=this._editing;},_attributeEditingCommitted:function(element,newText,oldText,attributeName,moveDirection)
|
| +this.treeOutline.childrenListElement.parentElement.removeEventListener("mousedown",consume,false);this.updateSelection();}
|
| +var config=new WebInspector.EditingConfig(commit.bind(this),dispose.bind(this));config.setMultilineOptions(initialValue,{name:"xml",htmlMode:true},"web-inspector-html",WebInspector.settings.domWordWrap.get(),true);this._editing=WebInspector.startEditing(this._htmlEditElement,config);},_attributeEditingCommitted:function(element,newText,oldText,attributeName,moveDirection)
|
| {delete this._editing;var treeOutline=this.treeOutline;function moveToNextAttributeIfNeeded(error)
|
| {if(error)
|
| this._editingCancelled(element,attributeName);if(!moveDirection)
|
| @@ -4951,7 +4959,7 @@
|
| newText=newText.trim();if(newText===oldText){cancel();return;}
|
| var treeOutline=this.treeOutline;var wasExpanded=this.expanded;function changeTagNameCallback(error,nodeId)
|
| {if(error||!nodeId){cancel();return;}
|
| -var newTreeItem=treeOutline._selectNodeAfterEdit(wasExpanded,error,nodeId);moveToNextAttributeIfNeeded.call(newTreeItem);}
|
| +var newTreeItem=treeOutline._selectNodeAfterEdit(null,wasExpanded,error,nodeId);moveToNextAttributeIfNeeded.call(newTreeItem);}
|
| this._node.setNodeName(newText,changeTagNameCallback);},_textNodeEditingCommitted:function(textNode,element,newText)
|
| {delete this._editing;function callback()
|
| {this.updateTitle();}
|
| @@ -5045,7 +5053,7 @@
|
| {WebInspector.domAgent.addEventListener(WebInspector.DOMAgent.Events.NodeInserted,this._nodeInserted,this);WebInspector.domAgent.addEventListener(WebInspector.DOMAgent.Events.NodeRemoved,this._nodeRemoved,this);WebInspector.domAgent.addEventListener(WebInspector.DOMAgent.Events.AttrModified,this._attributesUpdated,this);WebInspector.domAgent.addEventListener(WebInspector.DOMAgent.Events.AttrRemoved,this._attributesUpdated,this);WebInspector.domAgent.addEventListener(WebInspector.DOMAgent.Events.CharacterDataModified,this._characterDataModified,this);WebInspector.domAgent.addEventListener(WebInspector.DOMAgent.Events.DocumentUpdated,this._documentUpdated,this);WebInspector.domAgent.addEventListener(WebInspector.DOMAgent.Events.ChildNodeCountUpdated,this._childNodeCountUpdated,this);this._treeOutline=treeOutline;this._recentlyModifiedNodes=new Map();}
|
| WebInspector.ElementsTreeUpdater.prototype={_nodeModified:function(node,isUpdated,parentNode)
|
| {if(this._treeOutline._visible)
|
| -this._updateModifiedNodesSoon();var entry=this._recentlyModifiedNodes.get(node);if(!entry){entry=new WebInspector.ElementsTreeUpdater.UpdateEntry(isUpdated,parentNode);this._recentlyModifiedNodes.put(node,entry);return;}
|
| +this._updateModifiedNodesSoon();var entry=(this._recentlyModifiedNodes.get(node));if(!entry){entry=new WebInspector.ElementsTreeUpdater.UpdateEntry(isUpdated,parentNode);this._recentlyModifiedNodes.put(node,entry);return;}
|
| entry.isUpdated|=isUpdated;if(parentNode)
|
| entry.parent=parentNode;},_documentUpdated:function(event)
|
| {var inspectedRootDocument=event.data;this._reset();if(!inspectedRootDocument)
|
| @@ -5060,14 +5068,15 @@
|
| return;this._updateModifiedNodesTimeout=setTimeout(this._updateModifiedNodes.bind(this),50);},_updateModifiedNodes:function()
|
| {if(this._updateModifiedNodesTimeout){clearTimeout(this._updateModifiedNodesTimeout);delete this._updateModifiedNodesTimeout;}
|
| var updatedParentTreeElements=[];var hidePanelWhileUpdating=this._recentlyModifiedNodes.size()>10;if(hidePanelWhileUpdating){var treeOutlineContainerElement=this._treeOutline.element.parentNode;this._treeOutline.element.addStyleClass("hidden");var originalScrollTop=treeOutlineContainerElement?treeOutlineContainerElement.scrollTop:0;}
|
| -var nodes=this._recentlyModifiedNodes.keys();for(var i=0,size=nodes.length;i<size;++i){var node=nodes[i];var entry=this._recentlyModifiedNodes.get(node);var parent=entry.parent;if(parent===this._treeOutline._rootDOMNode){this._treeOutline.update();this._treeOutline.element.removeStyleClass("hidden");return;}
|
| +var keys=this._recentlyModifiedNodes.keys();for(var i=0,size=keys.length;i<size;++i){var node=keys[i];var entry=this._recentlyModifiedNodes.get(node);var parent=entry.parent;if(parent===this._treeOutline._rootDOMNode){this._treeOutline.update();this._treeOutline.element.removeStyleClass("hidden");return;}
|
| if(entry.isUpdated){var nodeItem=this._treeOutline.findTreeElement(node);if(nodeItem)
|
| nodeItem.updateTitle();}
|
| -var parentNodeItem=parent?this._treeOutline.findTreeElement(parent):null;if(parentNodeItem&&!parentNodeItem.alreadyUpdatedChildren){parentNodeItem.updateChildren();parentNodeItem.alreadyUpdatedChildren=true;updatedParentTreeElements.push(parentNodeItem);}}
|
| +if(!parent)
|
| +continue;var parentNodeItem=this._treeOutline.findTreeElement(parent);if(parentNodeItem&&!parentNodeItem.alreadyUpdatedChildren){parentNodeItem.updateChildren();parentNodeItem.alreadyUpdatedChildren=true;updatedParentTreeElements.push(parentNodeItem);}}
|
| for(var i=0;i<updatedParentTreeElements.length;++i)
|
| delete updatedParentTreeElements[i].alreadyUpdatedChildren;if(hidePanelWhileUpdating){this._treeOutline.element.removeStyleClass("hidden");if(originalScrollTop)
|
| treeOutlineContainerElement.scrollTop=originalScrollTop;this._treeOutline.updateSelection();}
|
| -this._recentlyModifiedNodes.clear();this._treeOutline._fireElementsTreeUpdated(nodes);},_reset:function()
|
| +this._recentlyModifiedNodes.clear();},_reset:function()
|
| {this._treeOutline.rootDOMNode=null;this._treeOutline.selectDOMNode(null,false);WebInspector.domAgent.hideDOMNodeHighlight();this._recentlyModifiedNodes.clear();}}
|
| WebInspector.ElementsTreeUpdater.UpdateEntry=function(isUpdated,parent)
|
| {this.isUpdated=isUpdated;if(parent)
|
| @@ -5476,19 +5485,18 @@
|
| this.renderAsBlock();}
|
| WebInspector.ObjectPropertyPrompt.prototype={__proto__:WebInspector.TextPrompt.prototype}
|
| WebInspector.ObjectPopoverHelper=function(panelElement,getAnchor,queryObject,onHide,disableOnClick)
|
| -{WebInspector.PopoverHelper.call(this,panelElement,getAnchor,this._showObjectPopover.bind(this),this._onHideObjectPopover.bind(this),disableOnClick);this._queryObject=queryObject;this._onHideCallback=onHide;this._popoverObjectGroup="popover";panelElement.addEventListener("scroll",this.hidePopover.bind(this),true);};WebInspector.ObjectPopoverHelper.prototype={setRemoteObjectFormatter:function(formatter)
|
| -{this._remoteObjectFormatter=formatter;},_showObjectPopover:function(element,popover)
|
| +{WebInspector.PopoverHelper.call(this,panelElement,getAnchor,this._showObjectPopover.bind(this),this._onHideObjectPopover.bind(this),disableOnClick);this._queryObject=queryObject;this._onHideCallback=onHide;this._popoverObjectGroup="popover";panelElement.addEventListener("scroll",this.hidePopover.bind(this),true);};WebInspector.ObjectPopoverHelper.prototype={_showObjectPopover:function(element,popover)
|
| {function showObjectPopover(result,wasThrown,anchorOverride)
|
| {if(popover.disposed)
|
| return;if(wasThrown){this.hidePopover();return;}
|
| -var anchorElement=anchorOverride||element;var description=(this._remoteObjectFormatter&&this._remoteObjectFormatter(result))||result.description;var popoverContentElement=null;if(result.type!=="object"){popoverContentElement=document.createElement("span");popoverContentElement.className="monospace console-formatted-"+result.type;popoverContentElement.style.whiteSpace="pre";popoverContentElement.textContent=description;if(result.type==="function"){function didGetDetails(error,response)
|
| +var anchorElement=anchorOverride||element;var popoverContentElement=null;if(result.type!=="object"){popoverContentElement=document.createElement("span");popoverContentElement.className="monospace console-formatted-"+result.type;popoverContentElement.style.whiteSpace="pre";popoverContentElement.textContent=result.description;if(result.type==="function"){function didGetDetails(error,response)
|
| {if(error){console.error(error);return;}
|
| var container=document.createElement("div");container.className="inline-block";var title=container.createChild("div","function-popover-title source-code");var functionName=title.createChild("span","function-name");functionName.textContent=response.name||response.inferredName||response.displayName||WebInspector.UIString("(anonymous function)");this._linkifier=new WebInspector.Linkifier();var rawLocation=(response.location);var link=this._linkifier.linkifyRawLocation(rawLocation,"function-location-link");if(link)
|
| title.appendChild(link);container.appendChild(popoverContentElement);popover.show(container,anchorElement);}
|
| DebuggerAgent.getFunctionDetails(result.objectId,didGetDetails.bind(this));return;}
|
| if(result.type==="string")
|
| popoverContentElement.textContent="\""+popoverContentElement.textContent+"\"";popover.show(popoverContentElement,anchorElement);}else{if(result.subtype==="node")
|
| -result.highlightAsDOMNode();popoverContentElement=document.createElement("div");this._titleElement=document.createElement("div");this._titleElement.className="source-frame-popover-title monospace";this._titleElement.textContent=description;popoverContentElement.appendChild(this._titleElement);var section=new WebInspector.ObjectPropertiesSection(result);if(description.substr(0,4)==="HTML"){this._sectionUpdateProperties=section.updateProperties.bind(section);section.updateProperties=this._updateHTMLId.bind(this);}
|
| +result.highlightAsDOMNode();popoverContentElement=document.createElement("div");this._titleElement=document.createElement("div");this._titleElement.className="source-frame-popover-title monospace";this._titleElement.textContent=result.description;popoverContentElement.appendChild(this._titleElement);var section=new WebInspector.ObjectPropertiesSection(result);if(result.description.substr(0,4)==="HTML"){this._sectionUpdateProperties=section.updateProperties.bind(section);section.updateProperties=this._updateHTMLId.bind(this);}
|
| section.expanded=true;section.element.addStyleClass("source-frame-popover-tree");section.headerElement.addStyleClass("hidden");popoverContentElement.appendChild(section.element);const popoverWidth=300;const popoverHeight=250;popover.show(popoverContentElement,anchorElement,popoverWidth,popoverHeight);}}
|
| this._queryObject(element,showObjectPopover.bind(this),this._popoverObjectGroup);},_onHideObjectPopover:function()
|
| {WebInspector.domAgent.hideDOMNodeHighlight();if(this._linkifier){this._linkifier.reset();delete this._linkifier;}
|
| @@ -5737,8 +5745,8 @@
|
| this._state=false;else
|
| this._state=0;this.title=title;this.className=className;this._visible=true;}
|
| WebInspector.StatusBarButton.prototype={_clicked:function()
|
| -{this.dispatchEventToListeners("click");if(this._longClickInterval){clearInterval(this._longClickInterval);delete this._longClickInterval;}},_applyEnabledState:function()
|
| -{this.element.disabled=!this._enabled;if(this._longClickInterval){clearInterval(this._longClickInterval);delete this._longClickInterval;}},enabled:function()
|
| +{this.dispatchEventToListeners("click");if(this._longClickInterval)
|
| +clearInterval(this._longClickInterval);},enabled:function()
|
| {return this._enabled;},get title()
|
| {return this._title;},set title(x)
|
| {if(this._title===x)
|
| @@ -5756,24 +5764,18 @@
|
| {return this._visible;},set visible(x)
|
| {if(this._visible===x)
|
| return;this.element.enableStyleClass("hidden",!x);this._visible=x;},makeLongClickEnabled:function()
|
| -{var boundMouseDown=mouseDown.bind(this);var boundMouseUp=mouseUp.bind(this);this.element.addEventListener("mousedown",boundMouseDown,false);this.element.addEventListener("mouseout",boundMouseUp,false);this.element.addEventListener("mouseup",boundMouseUp,false);var longClicks=0;this._longClickData={mouseUp:boundMouseUp,mouseDown:boundMouseDown};function mouseDown(e)
|
| +{this.element.addEventListener("mousedown",mouseDown.bind(this),false);this.element.addEventListener("mouseout",mouseUp.bind(this),false);this.element.addEventListener("mouseup",mouseUp.bind(this),false);var longClicks=0;function mouseDown(e)
|
| {if(e.which!==1)
|
| return;longClicks=0;this._longClickInterval=setInterval(longClicked.bind(this),200);}
|
| function mouseUp(e)
|
| {if(e.which!==1)
|
| -return;if(this._longClickInterval){clearInterval(this._longClickInterval);delete this._longClickInterval;}}
|
| +return;if(this._longClickInterval)
|
| +clearInterval(this._longClickInterval);}
|
| function longClicked()
|
| -{++longClicks;this.dispatchEventToListeners(longClicks===1?"longClickDown":"longClickPress");}},unmakeLongClickEnabled:function()
|
| -{if(!this._longClickData)
|
| -return;this.element.removeEventListener("mousedown",this._longClickData.mouseDown,false);this.element.removeEventListener("mouseout",this._longClickData.mouseUp,false);this.element.removeEventListener("mouseup",this._longClickData.mouseUp,false);delete this._longClickData;},setLongClickOptionsEnabled:function(buttonsProvider)
|
| -{if(buttonsProvider){if(!this._longClickOptionsData){this.makeLongClickEnabled();this.longClickGlyph=document.createElement("div");this.longClickGlyph.className="fill long-click-glyph";this.element.appendChild(this.longClickGlyph);this.longClickGlyphShadow=document.createElement("div");this.longClickGlyphShadow.className="fill long-click-glyph shadow";this.element.appendChild(this.longClickGlyphShadow);var longClickDownListener=this._showOptions.bind(this);this.addEventListener("longClickDown",longClickDownListener,this);this._longClickOptionsData={glyphElement:this.longClickGlyph,glyphShadowElement:this.longClickGlyphShadow,longClickDownListener:longClickDownListener};}
|
| -this._longClickOptionsData.buttonsProvider=buttonsProvider;}else{if(!this._longClickOptionsData)
|
| -return;this.element.removeChild(this._longClickOptionsData.glyphElement);this.element.removeChild(this._longClickOptionsData.glyphShadowElement);this.removeEventListener("longClickDown",this._longClickOptionsData.longClickDownListener,this);delete this._longClickOptionsData;this.unmakeLongClickEnabled();}},_showOptions:function()
|
| -{var buttons=this._longClickOptionsData.buttonsProvider();var mainButtonClone=new WebInspector.StatusBarButton(this.title,this.className,this.states);mainButtonClone.addEventListener("click",this._clicked,this);mainButtonClone.state=this.state;buttons.push(mainButtonClone);var mouseUpListener=mouseUp.bind(this);document.documentElement.addEventListener("mouseup",mouseUpListener,false);var optionsGlassPane=new WebInspector.GlassPane();var optionsBarElement=optionsGlassPane.element.createChild("div","alternate-status-bar-buttons-bar");const buttonHeight=23;var hostButtonPosition=this.element.totalOffset();var topNotBottom=hostButtonPosition.top<document.documentElement.offsetHeight/2;if(topNotBottom)
|
| -buttons=buttons.reverse();optionsBarElement.style.height=(buttonHeight*buttons.length)+"px";if(topNotBottom)
|
| -optionsBarElement.style.top=(hostButtonPosition.top+1)+"px";else
|
| -optionsBarElement.style.top=(hostButtonPosition.top-(buttonHeight*(buttons.length-1)))+"px";optionsBarElement.style.left=(hostButtonPosition.left+1)+"px";var boundMouseOver=mouseOver.bind(this);var boundMouseOut=mouseOut.bind(this);for(var i=0;i<buttons.length;++i){buttons[i].element.addEventListener("mousemove",boundMouseOver,false);buttons[i].element.addEventListener("mouseout",boundMouseOut,false);optionsBarElement.appendChild(buttons[i].element);}
|
| -var hostButtonIndex=topNotBottom?0:buttons.length-1;buttons[hostButtonIndex].element.addStyleClass("emulate-active");function mouseOver(e)
|
| +{++longClicks;this.dispatchEventToListeners(longClicks===1?"longClickDown":"longClickPress");}},makeLongClickOptionsEnabled:function(buttonsProvider)
|
| +{this.makeLongClickEnabled();this.longClickGlyph=document.createElement("div");this.longClickGlyph.className="fill long-click-glyph";this.element.appendChild(this.longClickGlyph);this.longClickGlyphShadow=document.createElement("div");this.longClickGlyphShadow.className="fill long-click-glyph shadow";this.element.appendChild(this.longClickGlyphShadow);this.addEventListener("longClickDown",this._showOptions.bind(this,buttonsProvider),this);},_showOptions:function(buttonsProvider)
|
| +{var buttons=buttonsProvider();var mainButtonClone=new WebInspector.StatusBarButton(this.title,this.className,this.states);mainButtonClone.addEventListener("click",this._clicked,this);mainButtonClone.state=this.state;buttons.push(mainButtonClone);var mouseUpListener=mouseUp.bind(this);document.documentElement.addEventListener("mouseup",mouseUpListener,false);var optionsGlassPane=new WebInspector.GlassPane();var optionsBarElement=optionsGlassPane.element.createChild("div","alternate-status-bar-buttons-bar");const buttonHeight=24;optionsBarElement.style.height=(buttonHeight*buttons.length)+"px";optionsBarElement.style.left=(this.element.offsetLeft+1)+"px";var boundMouseOver=mouseOver.bind(this);var boundMouseOut=mouseOut.bind(this);for(var i=0;i<buttons.length;++i){buttons[i].element.addEventListener("mousemove",boundMouseOver,false);buttons[i].element.addEventListener("mouseout",boundMouseOut,false);optionsBarElement.appendChild(buttons[i].element);}
|
| +buttons[buttons.length-1].element.addStyleClass("emulate-active");function mouseOver(e)
|
| {if(e.which!==1)
|
| return;var buttonElement=e.target.enclosingNodeOrSelfWithClass("status-bar-item");buttonElement.addStyleClass("emulate-active");}
|
| function mouseOut(e)
|
| @@ -5786,8 +5788,7 @@
|
| {WebInspector.StatusBarItem.call(this,document.createElement("span"));this.element.className="status-bar-select-container";this._selectElement=this.element.createChild("select","status-bar-item");this.element.createChild("div","status-bar-select-arrow");if(changeHandler)
|
| this._selectElement.addEventListener("change",changeHandler,false);if(className)
|
| this._selectElement.addStyleClass(className);}
|
| -WebInspector.StatusBarComboBox.prototype={selectElement:function()
|
| -{return this._selectElement;},size:function()
|
| +WebInspector.StatusBarComboBox.prototype={size:function()
|
| {return this._selectElement.childElementCount;},addOption:function(option)
|
| {this._selectElement.appendChild(option);},createOption:function(label,title,value)
|
| {var option=this._selectElement.createChild("option");option.text=label;if(title)
|
| @@ -5966,7 +5967,8 @@
|
| {this._resource=resource;WebInspector.SourceFrame.call(this,resource);}
|
| WebInspector.ResourceSourceFrame.prototype={get resource()
|
| {return this._resource;},populateTextAreaContextMenu:function(contextMenu,lineNumber)
|
| -{contextMenu.appendApplicableItems(this._resource);},__proto__:WebInspector.SourceFrame.prototype}
|
| +{contextMenu.appendApplicableItems(this._resource);if(this._resource.request)
|
| +contextMenu.appendApplicableItems(this._resource.request);},__proto__:WebInspector.SourceFrame.prototype}
|
| WebInspector.ResourceSourceFrameFallback=function(resource)
|
| {WebInspector.View.call(this);this._resource=resource;this.element.addStyleClass("fill");this.element.addStyleClass("script-view");this._content=this.element.createChild("div","script-view-fallback monospace");}
|
| WebInspector.ResourceSourceFrameFallback.prototype={wasShown:function()
|
| @@ -6322,7 +6324,7 @@
|
| this.evaluate(expression,evaluateOptions,onEvaluate);return parentElement;},node:function(expression,evaluateOptions)
|
| {var parentElement=document.createElement("div");function onNodeAvailable(nodeId)
|
| {if(!nodeId)
|
| -return;var treeOutline=new WebInspector.ElementsTreeOutline(false,false);treeOutline.rootDOMNode=WebInspector.domAgent.nodeForId(nodeId);treeOutline.element.addStyleClass("outline-disclosure");treeOutline.setVisible(true);parentElement.appendChild(treeOutline.element);}
|
| +return;var treeOutline=new WebInspector.ElementsTreeOutline(false,false,true);treeOutline.rootDOMNode=WebInspector.domAgent.nodeForId(nodeId);treeOutline.element.addStyleClass("outline-disclosure");treeOutline.setVisible(true);parentElement.appendChild(treeOutline.element);}
|
| function onEvaluate(remoteObject)
|
| {remoteObject.pushNodeToFrontend(onNodeAvailable);}
|
| this.evaluate(expression,evaluateOptions,onEvaluate);return parentElement;}}
|
| @@ -6380,7 +6382,7 @@
|
| return false;var lineNumber=details.lineNumber;if(typeof lineNumber==="number")
|
| lineNumber+=1;port.postMessage({command:"open-resource",resource:this._makeResource(contentProvider),lineNumber:lineNumber});return true;},_onReload:function(message)
|
| {var options=(message.options||{});NetworkAgent.setUserAgentOverride(typeof options.userAgent==="string"?options.userAgent:"");var injectedScript;if(options.injectedScript)
|
| -injectedScript="(function(){"+options.injectedScript+"})()";var preprocessingScript=options.preprocessingScript;PageAgent.reload(!!options.ignoreCache,injectedScript,preprocessingScript);return this._status.OK();},_onEvaluateOnInspectedPage:function(message,port)
|
| +injectedScript="(function(){"+options.injectedScript+"})()";PageAgent.reload(!!options.ignoreCache,injectedScript);return this._status.OK();},_onEvaluateOnInspectedPage:function(message,port)
|
| {function callback(error,resultPayload,wasThrown)
|
| {var result;if(error)
|
| result=this._status.E_PROTOCOLERROR(error.toString());else if(wasThrown)
|
| @@ -6553,7 +6555,7 @@
|
| WebInspector.EmptyView=function(text)
|
| {WebInspector.View.call(this);this._text=text;}
|
| WebInspector.EmptyView.prototype={wasShown:function()
|
| -{this.element.className="empty-view";this.element.textContent=this._text;},set text(text)
|
| +{this.element.className="storage-empty-view";this.element.textContent=this._text;},set text(text)
|
| {this._text=text;if(this.isShowing())
|
| this.element.textContent=this._text;},__proto__:WebInspector.View.prototype}
|
| WebInspector.Formatter=function()
|
| @@ -6598,14 +6600,14 @@
|
| {var index=positions1.upperBound(position)-1;var convertedPosition=positions2[index]+position-positions1[index];if(index<positions2.length-1&&convertedPosition>positions2[index+1])
|
| convertedPosition=positions2[index+1];return convertedPosition;}}
|
| WebInspector.DOMSyntaxHighlighter=function(mimeType,stripExtraWhitespace)
|
| -{loadScript("CodeMirrorTextEditor.js");this._mimeType=mimeType;this._stripExtraWhitespace=stripExtraWhitespace;}
|
| +{this._tokenizer=WebInspector.SourceTokenizer.Registry.getInstance().getTokenizer(mimeType);this._stripExtraWhitespace=stripExtraWhitespace;}
|
| WebInspector.DOMSyntaxHighlighter.prototype={createSpan:function(content,className)
|
| -{var span=document.createElement("span");span.className="cm-"+className;if(this._stripExtraWhitespace&&className!=="whitespace")
|
| +{var span=document.createElement("span");span.className="webkit-"+className;if(this._stripExtraWhitespace&&className!=="whitespace")
|
| content=content.replace(/^[\n\r]*/,"").replace(/\s*$/,"");span.appendChild(document.createTextNode(content));return span;},syntaxHighlightNode:function(node)
|
| -{var lines=node.textContent.split("\n");node.removeChildren();var tokenize=WebInspector.CodeMirrorUtils.createTokenizer(this._mimeType);for(var i=lines[0].length?0:1;i<lines.length;++i){var line=lines[i];var plainTextStart=0;function processToken(token,tokenType,column,newColumn)
|
| -{if(tokenType){if(column>plainTextStart){var plainText=line.substring(plainTextStart,column);node.appendChild(document.createTextNode(plainText));}
|
| -node.appendChild(this.createSpan(token,tokenType));plainTextStart=newColumn;}}
|
| -tokenize(line,processToken.bind(this));if(plainTextStart<line.length){var plainText=line.substring(plainTextStart,line.length);node.appendChild(document.createTextNode(plainText));}
|
| +{this._tokenizer.condition=this._tokenizer.createInitialCondition();var lines=node.textContent.split("\n");node.removeChildren();for(var i=lines[0].length?0:1;i<lines.length;++i){var line=lines[i];var plainTextStart=0;this._tokenizer.line=line;var column=0;do{var newColumn=this._tokenizer.nextToken(column);var tokenType=this._tokenizer.tokenType;if(tokenType){if(column>plainTextStart){var plainText=line.substring(plainTextStart,column);node.appendChild(document.createTextNode(plainText));}
|
| +var token=line.substring(column,newColumn);node.appendChild(this.createSpan(token,tokenType));plainTextStart=newColumn;}
|
| +column=newColumn;}while(column<line.length)
|
| +if(plainTextStart<line.length){var plainText=line.substring(plainTextStart,line.length);node.appendChild(document.createTextNode(plainText));}
|
| if(i<lines.length-1)
|
| node.appendChild(document.createElement("br"));}}}
|
| WebInspector.TextRange=function(startLine,startColumn,endLine,endColumn)
|
| @@ -6634,6 +6636,166 @@
|
| return-1;return 0;},shift:function(lineOffset)
|
| {return new WebInspector.TextRange(this.startLine+lineOffset,this.startColumn,this.endLine+lineOffset,this.endColumn);},toString:function()
|
| {return JSON.stringify(this);}}
|
| +WebInspector.TextEditorCommand=function(newRange,originalText,originalSelection)
|
| +{this.newRange=newRange;this.originalText=originalText;this.originalSelection=originalSelection;}
|
| +WebInspector.TextEditorModel=function()
|
| +{this._lines=[""];this._attributes=[];this._undoStack=[];this._noPunctuationRegex=/[^ !%&()*+,-.:;<=>?\[\]\^{|}~]+/;this._lineBreak="\n";}
|
| +WebInspector.TextEditorModel.Events={TextChanged:"TextChanged"}
|
| +WebInspector.TextEditorModel.endsWithBracketRegex=/[{(\[]\s*$/;WebInspector.TextEditorModel.prototype={isClean:function()
|
| +{return this._cleanState===this._undoStack.length;},markClean:function()
|
| +{this._cleanState=this._undoStack.length;},get linesCount()
|
| +{return this._lines.length;},text:function()
|
| +{return this._lines.join(this._lineBreak);},range:function()
|
| +{return new WebInspector.TextRange(0,0,this._lines.length-1,this._lines[this._lines.length-1].length);},get lineBreak()
|
| +{return this._lineBreak;},line:function(lineNumber)
|
| +{if(lineNumber>=this._lines.length)
|
| +throw"Out of bounds:"+lineNumber;return this._lines[lineNumber];},lineLength:function(lineNumber)
|
| +{return this._lines[lineNumber].length;},setText:function(text)
|
| +{this._resetUndoStack();text=text||"";this._attributes=[];var range=this.range();this._lineBreak=/\r\n/.test(text)?"\r\n":"\n";var newRange=this._innerSetText(range,text);this.dispatchEventToListeners(WebInspector.TextEditorModel.Events.TextChanged,{oldRange:range,newRange:newRange});},_rangeHasOneCharacter:function(range)
|
| +{if(range.startLine===range.endLine&&range.endColumn-range.startColumn===1)
|
| +return true;if(range.endLine-range.startLine===1&&range.endColumn===0&&range.startColumn===this.lineLength(range.startLine))
|
| +return true;return false;},_isEditRangeUndoBoundary:function(range,text,originalSelection)
|
| +{if(originalSelection&&!originalSelection.isEmpty())
|
| +return true;if(text)
|
| +return text.length>1||!range.isEmpty();return!this._rangeHasOneCharacter(range);},_isEditRangeAdjacentToLastCommand:function(range,text)
|
| +{if(!this._lastCommand)
|
| +return true;if(!text){return this._lastCommand.newRange.immediatelyPrecedes(range)||this._lastCommand.newRange.immediatelyFollows(range);}
|
| +return text.indexOf("\n")===-1&&this._lastCommand.newRange.immediatelyPrecedes(range);},editRange:function(range,text,originalSelection)
|
| +{var undoBoundary=this._isEditRangeUndoBoundary(range,text,originalSelection);if(undoBoundary||!this._isEditRangeAdjacentToLastCommand(range,text))
|
| +this._markUndoableState();var newRange=this._innerEditRange(range,text,originalSelection);if(undoBoundary)
|
| +this._markUndoableState();return newRange;},_innerEditRange:function(range,text,originalSelection)
|
| +{var originalText=this.copyRange(range);var newRange=this._innerSetText(range,text);this._lastCommand=this._pushUndoableCommand(newRange,originalText,originalSelection||range);this.dispatchEventToListeners(WebInspector.TextEditorModel.Events.TextChanged,{oldRange:range,newRange:newRange,editRange:true});return newRange;},_innerSetText:function(range,text)
|
| +{this._eraseRange(range);if(text==="")
|
| +return new WebInspector.TextRange(range.startLine,range.startColumn,range.startLine,range.startColumn);var newLines=text.split(/\r?\n/);var prefix=this._lines[range.startLine].substring(0,range.startColumn);var suffix=this._lines[range.startLine].substring(range.startColumn);var postCaret=prefix.length;if(newLines.length===1){this._setLine(range.startLine,prefix+newLines[0]+suffix);postCaret+=newLines[0].length;}else{this._setLine(range.startLine,prefix+newLines[0]);this._insertLines(range,newLines);this._setLine(range.startLine+newLines.length-1,newLines[newLines.length-1]+suffix);postCaret=newLines[newLines.length-1].length;}
|
| +return new WebInspector.TextRange(range.startLine,range.startColumn,range.startLine+newLines.length-1,postCaret);},_insertLines:function(range,newLines)
|
| +{var lines=new Array(this._lines.length+newLines.length-1);for(var i=0;i<=range.startLine;++i)
|
| +lines[i]=this._lines[i];for(var i=1;i<newLines.length;++i)
|
| +lines[range.startLine+i]=newLines[i];for(var i=range.startLine+newLines.length;i<lines.length;++i)
|
| +lines[i]=this._lines[i-newLines.length+1];this._lines=lines;var attributes=new Array(lines.length);var insertionIndex=range.startColumn?range.startLine+1:range.startLine;for(var i=0;i<insertionIndex;++i)
|
| +attributes[i]=this._attributes[i];for(var i=insertionIndex+newLines.length-1;i<attributes.length;++i)
|
| +attributes[i]=this._attributes[i-newLines.length+1];this._attributes=attributes;},_eraseRange:function(range)
|
| +{if(range.isEmpty())
|
| +return;var prefix=this._lines[range.startLine].substring(0,range.startColumn);var suffix=this._lines[range.endLine].substring(range.endColumn);if(range.endLine>range.startLine){this._lines.splice(range.startLine+1,range.endLine-range.startLine);this._attributes.splice(range.startColumn?range.startLine+1:range.startLine,range.endLine-range.startLine);}
|
| +this._setLine(range.startLine,prefix+suffix);},_setLine:function(lineNumber,text)
|
| +{this._lines[lineNumber]=text;},wordRange:function(lineNumber,column)
|
| +{return new WebInspector.TextRange(lineNumber,this.wordStart(lineNumber,column,true),lineNumber,this.wordEnd(lineNumber,column,true));},wordStart:function(lineNumber,column,gapless)
|
| +{var line=this._lines[lineNumber];var prefix=line.substring(0,column).split("").reverse().join("");var prefixMatch=this._noPunctuationRegex.exec(prefix);return prefixMatch&&(!gapless||prefixMatch.index===0)?column-prefixMatch.index-prefixMatch[0].length:column;},wordEnd:function(lineNumber,column,gapless)
|
| +{var line=this._lines[lineNumber];var suffix=line.substring(column);var suffixMatch=this._noPunctuationRegex.exec(suffix);return suffixMatch&&(!gapless||suffixMatch.index===0)?column+suffixMatch.index+suffixMatch[0].length:column;},copyRange:function(range)
|
| +{if(!range)
|
| +range=this.range();var clip=[];if(range.startLine===range.endLine){clip.push(this._lines[range.startLine].substring(range.startColumn,range.endColumn));return clip.join(this._lineBreak);}
|
| +clip.push(this._lines[range.startLine].substring(range.startColumn));for(var i=range.startLine+1;i<range.endLine;++i)
|
| +clip.push(this._lines[i]);clip.push(this._lines[range.endLine].substring(0,range.endColumn));return clip.join(this._lineBreak);},setAttribute:function(line,name,value)
|
| +{var attrs=this._attributes[line];if(!attrs){attrs={};this._attributes[line]=attrs;}
|
| +attrs[name]=value;},getAttribute:function(line,name)
|
| +{var attrs=this._attributes[line];return attrs?attrs[name]:null;},removeAttribute:function(line,name)
|
| +{var attrs=this._attributes[line];if(attrs)
|
| +delete attrs[name];},_pushUndoableCommand:function(newRange,originalText,originalSelection)
|
| +{var command=new WebInspector.TextEditorCommand(newRange.clone(),originalText,originalSelection);if(this._inUndo)
|
| +this._redoStack.push(command);else{if(!this._inRedo){this._redoStack=[];if(typeof this._cleanState==="number"&&this._cleanState>this._undoStack.length)
|
| +delete this._cleanState;}
|
| +this._undoStack.push(command);}
|
| +return command;},undo:function()
|
| +{if(!this._undoStack.length)
|
| +return null;this._markRedoableState();this._inUndo=true;var range=this._doUndo(this._undoStack);delete this._inUndo;return range;},redo:function()
|
| +{if(!this._redoStack||!this._redoStack.length)
|
| +return null;this._markUndoableState();this._inRedo=true;var range=this._doUndo(this._redoStack);delete this._inRedo;return range?range.collapseToEnd():null;},_doUndo:function(stack)
|
| +{var range=null;for(var i=stack.length-1;i>=0;--i){var command=stack[i];stack.length=i;this._innerEditRange(command.newRange,command.originalText);range=command.originalSelection;if(i>0&&stack[i-1].explicit)
|
| +return range;}
|
| +return range;},_markUndoableState:function()
|
| +{if(this._undoStack.length)
|
| +this._undoStack[this._undoStack.length-1].explicit=true;},_markRedoableState:function()
|
| +{if(this._redoStack.length)
|
| +this._redoStack[this._redoStack.length-1].explicit=true;},_resetUndoStack:function()
|
| +{delete this._cleanState;this._undoStack=[];this._redoStack=[];},indentLines:function(range)
|
| +{this._markUndoableState();var indent=WebInspector.settings.textEditorIndent.get();var newRange=range.clone();if(range.startColumn)
|
| +newRange.startColumn+=indent.length;var indentEndLine=range.endLine;if(range.endColumn)
|
| +newRange.endColumn+=indent.length;else
|
| +indentEndLine--;for(var lineNumber=range.startLine;lineNumber<=indentEndLine;lineNumber++)
|
| +this._innerEditRange(WebInspector.TextRange.createFromLocation(lineNumber,0),indent);return newRange;},unindentLines:function(range)
|
| +{this._markUndoableState();var indent=WebInspector.settings.textEditorIndent.get();var indentLength=indent===WebInspector.TextUtils.Indent.TabCharacter?4:indent.length;var lineIndentRegex=new RegExp("^ {1,"+indentLength+"}");var newRange=range.clone();var indentEndLine=range.endLine;if(!range.endColumn)
|
| +indentEndLine--;for(var lineNumber=range.startLine;lineNumber<=indentEndLine;lineNumber++){var line=this.line(lineNumber);var firstCharacter=line.charAt(0);var lineIndentLength;if(firstCharacter===" ")
|
| +lineIndentLength=line.match(lineIndentRegex)[0].length;else if(firstCharacter==="\t")
|
| +lineIndentLength=1;else
|
| +continue;this._innerEditRange(new WebInspector.TextRange(lineNumber,0,lineNumber,lineIndentLength),"");if(lineNumber===range.startLine)
|
| +newRange.startColumn=Math.max(0,newRange.startColumn-lineIndentLength);if(lineNumber===range.endLine)
|
| +newRange.endColumn=Math.max(0,newRange.endColumn-lineIndentLength);}
|
| +return newRange;},slice:function(from,to)
|
| +{var textModel=new WebInspector.TextEditorModel();textModel._lines=this._lines.slice(from,to);textModel._lineBreak=this._lineBreak;return textModel;},growRangeLeft:function(range)
|
| +{var result=range.clone();if(result.startColumn)
|
| +--result.startColumn;else if(result.startLine)
|
| +result.startColumn=this.lineLength(--result.startLine);return result;},growRangeRight:function(range)
|
| +{var result=range.clone();if(result.endColumn<this.lineLength(result.endLine))
|
| +++result.endColumn;else if(result.endLine<this.linesCount){result.endColumn=0;++result.endLine;}
|
| +return result;},__proto__:WebInspector.Object.prototype}
|
| +WebInspector.TextEditorModel.BraceMatcher=function(textModel)
|
| +{this._textModel=textModel;}
|
| +WebInspector.TextEditorModel.BraceMatcher.prototype={_braceRanges:function(lineNumber)
|
| +{if(lineNumber>=this._textModel.linesCount||lineNumber<0)
|
| +return null;var attribute=this._textModel.getAttribute(lineNumber,"highlight");if(!attribute)
|
| +return null;else
|
| +return attribute.braces;},_matches:function(braceTokenLeft,braceTokenRight)
|
| +{return((braceTokenLeft==="brace-start"&&braceTokenRight==="brace-end")||(braceTokenLeft==="block-start"&&braceTokenRight==="block-end"));},findLeftCandidate:function(lineNumber,column,maxBraceIteration)
|
| +{var braces=this._braceRanges(lineNumber);if(!braces)
|
| +return null;var braceIndex=braces.length-1;while(braceIndex>=0&&braces[braceIndex].startColumn>column)
|
| +--braceIndex;var brace=braceIndex>=0?braces[braceIndex]:null;if(brace&&brace.startColumn===column&&(brace.token==="block-end"||brace.token==="brace-end"))
|
| +--braceIndex;var stack=[];maxBraceIteration=maxBraceIteration||Number.MAX_VALUE;while(--maxBraceIteration){if(braceIndex<0){while((braces=this._braceRanges(--lineNumber))&&!braces.length){};if(!braces)
|
| +return null;braceIndex=braces.length-1;}
|
| +brace=braces[braceIndex];if(brace.token==="block-end"||brace.token==="brace-end")
|
| +stack.push(brace.token);else if(stack.length===0)
|
| +return{lineNumber:lineNumber,column:brace.startColumn,token:brace.token};else if(!this._matches(brace.token,stack.pop()))
|
| +return null;--braceIndex;}
|
| +return null;},findRightCandidate:function(lineNumber,column,maxBraceIteration)
|
| +{var braces=this._braceRanges(lineNumber);if(!braces)
|
| +return null;var braceIndex=0;while(braceIndex<braces.length&&braces[braceIndex].startColumn<column)
|
| +++braceIndex;var brace=braceIndex<braces.length?braces[braceIndex]:null;if(brace&&brace.startColumn===column&&(brace.token==="block-start"||brace.token==="brace-start"))
|
| +++braceIndex;var stack=[];maxBraceIteration=maxBraceIteration||Number.MAX_VALUE;while(--maxBraceIteration){if(braceIndex>=braces.length){while((braces=this._braceRanges(++lineNumber))&&!braces.length){};if(!braces)
|
| +return null;braceIndex=0;}
|
| +brace=braces[braceIndex];if(brace.token==="block-start"||brace.token==="brace-start")
|
| +stack.push(brace.token);else if(stack.length===0)
|
| +return{lineNumber:lineNumber,column:brace.startColumn,token:brace.token};else if(!this._matches(stack.pop(),brace.token))
|
| +return null;++braceIndex;}
|
| +return null;},enclosingBraces:function(lineNumber,column,maxBraceIteration)
|
| +{var leftBraceLocation=this.findLeftCandidate(lineNumber,column,maxBraceIteration);if(!leftBraceLocation)
|
| +return null;var rightBraceLocation=this.findRightCandidate(lineNumber,column,maxBraceIteration);if(!rightBraceLocation)
|
| +return null;if(!this._matches(leftBraceLocation.token,rightBraceLocation.token))
|
| +return null;return{leftBrace:leftBraceLocation,rightBrace:rightBraceLocation};},}
|
| +WebInspector.TextEditorHighlighter=function(textModel,damageCallback)
|
| +{this._textModel=textModel;this._mimeType="text/html";this._tokenizer=WebInspector.SourceTokenizer.Registry.getInstance().getTokenizer(this._mimeType);this._damageCallback=damageCallback;this._highlightChunkLimit=1000;this._highlightLineLimit=500;}
|
| +WebInspector.TextEditorHighlighter._MaxLineCount=10000;WebInspector.TextEditorHighlighter.prototype={get mimeType()
|
| +{return this._mimeType;},set mimeType(mimeType)
|
| +{var tokenizer=WebInspector.SourceTokenizer.Registry.getInstance().getTokenizer(mimeType);if(tokenizer){this._tokenizer=tokenizer;this._mimeType=mimeType;}},set highlightChunkLimit(highlightChunkLimit)
|
| +{this._highlightChunkLimit=highlightChunkLimit;},setHighlightLineLimit:function(highlightLineLimit)
|
| +{this._highlightLineLimit=highlightLineLimit;},highlight:function(endLine,forceRun)
|
| +{if(this._textModel.linesCount>WebInspector.TextEditorHighlighter._MaxLineCount)
|
| +return;var state=this._textModel.getAttribute(endLine-1,"highlight");if(state&&state.postConditionStringified){return;}
|
| +this._requestedEndLine=endLine;if(this._highlightTimer&&!forceRun){return;}
|
| +var startLine=endLine;while(startLine>0){state=this._textModel.getAttribute(startLine-1,"highlight");if(state&&state.postConditionStringified)
|
| +break;startLine--;}
|
| +this._highlightInChunks(startLine,endLine);},updateHighlight:function(startLine,endLine)
|
| +{if(this._textModel.linesCount>WebInspector.TextEditorHighlighter._MaxLineCount)
|
| +return;this._clearHighlightState(startLine);if(startLine){var state=this._textModel.getAttribute(startLine-1,"highlight");if(!state||!state.postConditionStringified){return false;}}
|
| +var restored=this._highlightLines(startLine,endLine);if(!restored){for(var i=this._lastHighlightedLine;i<this._textModel.linesCount;++i){var state=this._textModel.getAttribute(i,"highlight");if(!state&&i>endLine)
|
| +break;this._textModel.setAttribute(i,"highlight-outdated",state);this._textModel.removeAttribute(i,"highlight");}
|
| +if(this._highlightTimer){clearTimeout(this._highlightTimer);this._requestedEndLine=endLine;this._highlightTimer=setTimeout(this._highlightInChunks.bind(this,this._lastHighlightedLine,this._requestedEndLine),10);}}
|
| +return restored;},_highlightInChunks:function(startLine,endLine)
|
| +{delete this._highlightTimer;var state=this._textModel.getAttribute(this._requestedEndLine-1,"highlight");if(state&&state.postConditionStringified)
|
| +return;if(this._requestedEndLine!==endLine){this._highlightTimer=setTimeout(this._highlightInChunks.bind(this,startLine,this._requestedEndLine),100);return;}
|
| +if(this._requestedEndLine>this._textModel.linesCount)
|
| +this._requestedEndLine=this._textModel.linesCount;this._highlightLines(startLine,this._requestedEndLine);if(this._lastHighlightedLine<this._requestedEndLine)
|
| +this._highlightTimer=setTimeout(this._highlightInChunks.bind(this,this._lastHighlightedLine,this._requestedEndLine),10);},_highlightLines:function(startLine,endLine)
|
| +{var state=this._textModel.getAttribute(startLine-1,"highlight");var postConditionStringified=state?state.postConditionStringified:JSON.stringify(this._tokenizer.createInitialCondition());var tokensCount=0;for(var lineNumber=startLine;lineNumber<endLine;++lineNumber){state=this._selectHighlightState(lineNumber,postConditionStringified);if(state.postConditionStringified){postConditionStringified=state.postConditionStringified;}else{var lastHighlightedColumn=0;if(state.midConditionStringified){lastHighlightedColumn=state.lastHighlightedColumn;postConditionStringified=state.midConditionStringified;}
|
| +var line=this._textModel.line(lineNumber);this._tokenizer.line=line;this._tokenizer.condition=JSON.parse(postConditionStringified);state.ranges=state.ranges||[];state.braces=state.braces||[];do{var newColumn=this._tokenizer.nextToken(lastHighlightedColumn);var tokenType=this._tokenizer.tokenType;if(tokenType&&lastHighlightedColumn<this._highlightLineLimit){if(tokenType==="brace-start"||tokenType==="brace-end"||tokenType==="block-start"||tokenType==="block-end"){state.braces.push({startColumn:lastHighlightedColumn,endColumn:newColumn-1,token:tokenType});}else{state.ranges.push({startColumn:lastHighlightedColumn,endColumn:newColumn-1,token:tokenType});}}
|
| +lastHighlightedColumn=newColumn;if(++tokensCount>this._highlightChunkLimit)
|
| +break;}while(lastHighlightedColumn<line.length);postConditionStringified=JSON.stringify(this._tokenizer.condition);if(lastHighlightedColumn<line.length){state.lastHighlightedColumn=lastHighlightedColumn;state.midConditionStringified=postConditionStringified;break;}else{delete state.lastHighlightedColumn;delete state.midConditionStringified;state.postConditionStringified=postConditionStringified;}}
|
| +var nextLineState=this._textModel.getAttribute(lineNumber+1,"highlight");if(nextLineState&&nextLineState.preConditionStringified===state.postConditionStringified){++lineNumber;this._damageCallback(startLine,lineNumber);for(;lineNumber<endLine;++lineNumber){state=this._textModel.getAttribute(lineNumber,"highlight");if(!state||!state.postConditionStringified)
|
| +break;}
|
| +this._lastHighlightedLine=lineNumber;return true;}}
|
| +this._damageCallback(startLine,lineNumber);this._lastHighlightedLine=lineNumber;return false;},_selectHighlightState:function(lineNumber,preConditionStringified)
|
| +{var state=this._textModel.getAttribute(lineNumber,"highlight");if(state&&state.preConditionStringified===preConditionStringified)
|
| +return state;var outdatedState=this._textModel.getAttribute(lineNumber,"highlight-outdated");if(outdatedState&&outdatedState.preConditionStringified===preConditionStringified){this._textModel.setAttribute(lineNumber,"highlight",outdatedState);this._textModel.setAttribute(lineNumber,"highlight-outdated",state);return outdatedState;}
|
| +if(state)
|
| +this._textModel.setAttribute(lineNumber,"highlight-outdated",state);state={};state.preConditionStringified=preConditionStringified;this._textModel.setAttribute(lineNumber,"highlight",state);return state;},_clearHighlightState:function(lineNumber)
|
| +{this._textModel.removeAttribute(lineNumber,"highlight");this._textModel.removeAttribute(lineNumber,"highlight-outdated");}}
|
| WebInspector.TextUtils={isStopChar:function(char)
|
| {return(char>" "&&char<"0")||(char>"9"&&char<"A")||(char>"Z"&&char<"_")||(char>"_"&&char<"a")||(char>"z"&&char<="~");},isWordChar:function(char)
|
| {return!WebInspector.TextUtils.isStopChar(char)&&!WebInspector.TextUtils.isSpaceChar(char);},isSpaceChar:function(char)
|
| @@ -6650,6 +6812,365 @@
|
| if(startWord!==-1)
|
| words.push(text.substring(startWord));return words;},}
|
| WebInspector.TextUtils._SpaceCharRegex=/\s/;WebInspector.TextUtils.Indent={TwoSpaces:" ",FourSpaces:" ",EightSpaces:" ",TabCharacter:"\t"}
|
| +WebInspector.SourceTokenizer=function()
|
| +{this.tokenType=null;}
|
| +WebInspector.SourceTokenizer.prototype={set line(line){this._line=line;},set condition(condition)
|
| +{this._condition=condition;},get condition()
|
| +{return this._condition;},getLexCondition:function()
|
| +{return this.condition.lexCondition;},setLexCondition:function(lexCondition)
|
| +{this.condition.lexCondition=lexCondition;},_charAt:function(cursor)
|
| +{return cursor<this._line.length?this._line.charAt(cursor):"\n";},createInitialCondition:function()
|
| +{},nextToken:function(cursor)
|
| +{}}
|
| +WebInspector.SourceTokenizer.Registry=function(){this._tokenizers={};this._tokenizerConstructors={"text/css":"SourceCSSTokenizer","text/html":"SourceHTMLTokenizer","text/javascript":"SourceJavaScriptTokenizer","text/x-scss":"SourceCSSTokenizer"};}
|
| +WebInspector.SourceTokenizer.Registry.getInstance=function()
|
| +{if(!WebInspector.SourceTokenizer.Registry._instance)
|
| +WebInspector.SourceTokenizer.Registry._instance=new WebInspector.SourceTokenizer.Registry();return WebInspector.SourceTokenizer.Registry._instance;}
|
| +WebInspector.SourceTokenizer.Registry.prototype={getTokenizer:function(mimeType)
|
| +{if(!this._tokenizerConstructors[mimeType])
|
| +return null;var tokenizerClass=this._tokenizerConstructors[mimeType];var tokenizer=this._tokenizers[tokenizerClass];if(!tokenizer){tokenizer=new WebInspector[tokenizerClass]();this._tokenizers[tokenizerClass]=tokenizer;}
|
| +return tokenizer;}}
|
| +WebInspector.SourceCSSTokenizer=function()
|
| +{WebInspector.SourceTokenizer.call(this);this._propertyKeywords=WebInspector.CSSMetadata.cssPropertiesMetainfoKeySet();this._colorKeywords=WebInspector.CSSMetadata.colors();this._valueKeywords=["above","absolute","activeborder","activecaption","afar","after-white-space","ahead","alias","all","all-scroll","alternate","always","amharic","amharic-abegede","antialiased","appworkspace","arabic-indic","armenian","asterisks","auto","avoid","background","backwards","baseline","below","bidi-override","binary","bengali","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break-all","break-word","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","cambodian","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-earthly-branch","cjk-heavenly-stem","cjk-ideographic","clear","clip","close-quote","col-resize","collapse","compact","condensed","contain","content","content-box","context-menu","continuous","copy","cover","crop","cross","crosshair","currentcolor","cursive","dashed","decimal","decimal-leading-zero","default","default-button","destination-atop","destination-in","destination-out","destination-over","devanagari","disc","discard","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipsis","embed","end","ethiopic","ethiopic-abegede","ethiopic-abegede-am-et","ethiopic-abegede-gez","ethiopic-abegede-ti-er","ethiopic-abegede-ti-et","ethiopic-halehame-aa-er","ethiopic-halehame-aa-et","ethiopic-halehame-am-et","ethiopic-halehame-gez","ethiopic-halehame-om-et","ethiopic-halehame-sid-et","ethiopic-halehame-so-et","ethiopic-halehame-ti-er","ethiopic-halehame-ti-et","ethiopic-halehame-tig","ew-resize","expanded","extra-condensed","extra-expanded","fantasy","fast","fill","fixed","flat","footnotes","forwards","from","geometricPrecision","georgian","graytext","groove","gujarati","gurmukhi","hand","hangul","hangul-consonant","hebrew","help","hidden","hide","higher","highlight","highlighttext","hiragana","hiragana-iroha","horizontal","hsl","hsla","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-table","inset","inside","intrinsic","invert","italic","justify","kannada","katakana","katakana-iroha","khmer","landscape","lao","large","larger","left","level","lighter","line-through","linear","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-alpha","lower-armenian","lower-greek","lower-hexadecimal","lower-latin","lower-norwegian","lower-roman","lowercase","ltr","malayalam","match","media-controls-background","media-current-time-display","media-fullscreen-button","media-mute-button","media-play-button","media-return-to-realtime-button","media-rewind-button","media-seek-back-button","media-seek-forward-button","media-slider","media-sliderthumb","media-time-remaining-display","media-volume-slider","media-volume-slider-container","media-volume-sliderthumb","medium","menu","menulist","menulist-button","menulist-text","menulist-textfield","menutext","message-box","middle","min-intrinsic","mix","mongolian","monospace","move","multiple","myanmar","n-resize","narrower","navy","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","nw-resize","nwse-resize","oblique","octal","open-quote","optimizeLegibility","optimizeSpeed","oriya","oromo","outset","outside","overlay","overline","padding","padding-box","painted","paused","persian","plus-darker","plus-lighter","pointer","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radio","read-only","read-write","read-write-plaintext-only","relative","repeat","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","round","row-resize","rtl","run-in","running","s-resize","sans-serif","scroll","scrollbar","se-resize","searchfield","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","semi-condensed","semi-expanded","separate","serif","show","sidama","single","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","solid","somali","source-atop","source-in","source-out","source-over","space","square","square-button","start","static","status-bar","stretch","stroke","sub","subpixel-antialiased","super","sw-resize","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","telugu","text","text-bottom","text-top","textarea","textfield","thai","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","tibetan","tigre","tigrinya-er","tigrinya-er-abegede","tigrinya-et","tigrinya-et-abegede","to","top","transparent","ultra-condensed","ultra-expanded","underline","up","upper-alpha","upper-armenian","upper-greek","upper-hexadecimal","upper-latin","upper-norwegian","upper-roman","uppercase","urdu","url","vertical","vertical-text","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","white","wider","window","windowframe","windowtext","x-large","x-small","xor","xx-large","xx-small","yellow","-wap-marquee","-webkit-activelink","-webkit-auto","-webkit-baseline-middle","-webkit-body","-webkit-box","-webkit-center","-webkit-control","-webkit-focus-ring-color","-webkit-grab","-webkit-grabbing","-webkit-gradient","-webkit-inline-box","-webkit-left","-webkit-link","-webkit-marquee","-webkit-mini-control","-webkit-nowrap","-webkit-pictograph","-webkit-right","-webkit-small-control","-webkit-text","-webkit-xxx-large","-webkit-zoom-in","-webkit-zoom-out",].keySet();this._scssValueKeywords=["abs","adjust-color","adjust-hue","alpha","append","ceil","change-color","comparable","complement","darken","desaturate","fade-in","fade-out","floor","grayscale","hue","ie-hex-str","invert","join","length","lighten","lightness","max","min","mix","nth","opacify","opacity","percentage","quote","round","saturate","saturation","scale-color","transparentize","type-of","unit","unitless","unquote","zip"].keySet();this._lexConditions={INITIAL:0,COMMENT:1,DSTRING:2,SSTRING:3};this._parseConditions={INITIAL:0,PROPERTY:1,PROPERTY_VALUE:2,AT_RULE:3,AT_MEDIA_RULE:4};this.case_INITIAL=1000;this.case_COMMENT=1002;this.case_DSTRING=1003;this.case_SSTRING=1004;this.condition=this.createInitialCondition();}
|
| +WebInspector.SourceCSSTokenizer.SCSSAtRelatedKeywords=["from","if","in","through"].keySet();WebInspector.SourceCSSTokenizer.MediaTypes=["all","aural","braille","embossed","handheld","import","print","projection","screen","tty","tv"].keySet();WebInspector.SourceCSSTokenizer.prototype={createInitialCondition:function()
|
| +{return{lexCondition:this._lexConditions.INITIAL,parseCondition:this._parseConditions.INITIAL};},_stringToken:function(cursor,stringEnds)
|
| +{if(this._isPropertyValue())
|
| +this.tokenType="css-string";else
|
| +this.tokenType=null;return cursor;},_isPropertyValue:function()
|
| +{return this._condition.parseCondition===this._parseConditions.PROPERTY_VALUE||this._condition.parseCondition===this._parseConditions.AT_RULE;},_setParseCondition:function(condition)
|
| +{this._condition.parseCondition=condition;},nextToken:function(cursor)
|
| +{var cursorOnEnter=cursor;var gotoCase=1;var YYMARKER;while(1){switch(gotoCase)
|
| +{case 1:var yych;var yyaccept=0;if(this.getLexCondition()<2){if(this.getLexCondition()<1){{gotoCase=this.case_INITIAL;continue;};}else{{gotoCase=this.case_COMMENT;continue;};}}else{if(this.getLexCondition()<3){{gotoCase=this.case_DSTRING;continue;};}else{{gotoCase=this.case_SSTRING;continue;};}}
|
| +case this.case_COMMENT:yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=4;continue;};{gotoCase=3;continue;};}else{if(yych<='\r'){gotoCase=4;continue;};if(yych=='*'){gotoCase=6;continue;};{gotoCase=3;continue;};}
|
| +case 2:{this.tokenType="css-comment";return cursor;}
|
| +case 3:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=12;continue;};case 4:++cursor;{this.tokenType=null;return cursor;}
|
| +case 6:yyaccept=1;yych=this._charAt(YYMARKER=++cursor);if(yych=='*'){gotoCase=9;continue;};if(yych!='/'){gotoCase=11;continue;};case 7:++cursor;this.setLexCondition(this._lexConditions.INITIAL);{this.tokenType="css-comment";return cursor;}
|
| +case 9:++cursor;yych=this._charAt(cursor);if(yych=='*'){gotoCase=9;continue;};if(yych=='/'){gotoCase=7;continue;};case 11:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);case 12:if(yych<='\f'){if(yych=='\n'){gotoCase=2;continue;};{gotoCase=11;continue;};}else{if(yych<='\r'){gotoCase=2;continue;};if(yych=='*'){gotoCase=9;continue;};{gotoCase=11;continue;};}
|
| +case this.case_DSTRING:yych=this._charAt(cursor);if(yych<='\r'){if(yych=='\n'){gotoCase=17;continue;};if(yych<='\f'){gotoCase=16;continue;};{gotoCase=17;continue;};}else{if(yych<='"'){if(yych<='!'){gotoCase=16;continue;};{gotoCase=19;continue;};}else{if(yych=='\\'){gotoCase=21;continue;};{gotoCase=16;continue;};}}
|
| +case 15:{return this._stringToken(cursor);}
|
| +case 16:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=23;continue;};case 17:++cursor;case 18:{this.tokenType=null;return cursor;}
|
| +case 19:++cursor;case 20:this.setLexCondition(this._lexConditions.INITIAL);{return this._stringToken(cursor,true);}
|
| +case 21:yych=this._charAt(++cursor);if(yych<='e'){if(yych<='\''){if(yych=='"'){gotoCase=22;continue;};if(yych<='&'){gotoCase=18;continue;};}else{if(yych<='\\'){if(yych<='['){gotoCase=18;continue;};}else{if(yych!='b'){gotoCase=18;continue;};}}}else{if(yych<='r'){if(yych<='m'){if(yych>='g'){gotoCase=18;continue;};}else{if(yych<='n'){gotoCase=22;continue;};if(yych<='q'){gotoCase=18;continue;};}}else{if(yych<='t'){if(yych<='s'){gotoCase=18;continue;};}else{if(yych!='v'){gotoCase=18;continue;};}}}
|
| +case 22:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);case 23:if(yych<='\r'){if(yych=='\n'){gotoCase=15;continue;};if(yych<='\f'){gotoCase=22;continue;};{gotoCase=15;continue;};}else{if(yych<='"'){if(yych<='!'){gotoCase=22;continue;};{gotoCase=26;continue;};}else{if(yych!='\\'){gotoCase=22;continue;};}}
|
| +++cursor;yych=this._charAt(cursor);if(yych<='e'){if(yych<='\''){if(yych=='"'){gotoCase=22;continue;};if(yych>='\''){gotoCase=22;continue;};}else{if(yych<='\\'){if(yych>='\\'){gotoCase=22;continue;};}else{if(yych=='b'){gotoCase=22;continue;};}}}else{if(yych<='r'){if(yych<='m'){if(yych<='f'){gotoCase=22;continue;};}else{if(yych<='n'){gotoCase=22;continue;};if(yych>='r'){gotoCase=22;continue;};}}else{if(yych<='t'){if(yych>='t'){gotoCase=22;continue;};}else{if(yych=='v'){gotoCase=22;continue;};}}}
|
| +cursor=YYMARKER;{gotoCase=15;continue;};case 26:++cursor;yych=this._charAt(cursor);{gotoCase=20;continue;};case this.case_INITIAL:yych=this._charAt(cursor);if(yych<=':'){if(yych<='&'){if(yych<='"'){if(yych<=' '){gotoCase=29;continue;};if(yych<='!'){gotoCase=31;continue;};{gotoCase=33;continue;};}else{if(yych<='#'){gotoCase=34;continue;};if(yych<='$'){gotoCase=35;continue;};if(yych>='&'){gotoCase=31;continue;};}}else{if(yych<='-'){if(yych<='\''){gotoCase=36;continue;};if(yych>='-'){gotoCase=37;continue;};}else{if(yych<='.'){gotoCase=38;continue;};if(yych<='/'){gotoCase=39;continue;};if(yych<='9'){gotoCase=40;continue;};{gotoCase=42;continue;};}}}else{if(yych<=']'){if(yych<='='){if(yych<=';'){gotoCase=44;continue;};if(yych>='='){gotoCase=31;continue;};}else{if(yych<='?'){gotoCase=29;continue;};if(yych!='\\'){gotoCase=31;continue;};}}else{if(yych<='z'){if(yych=='_'){gotoCase=31;continue;};if(yych>='a'){gotoCase=31;continue;};}else{if(yych<='{'){gotoCase=46;continue;};if(yych=='}'){gotoCase=48;continue;};}}}
|
| +case 29:++cursor;case 30:{this.tokenType=null;return cursor;}
|
| +case 31:++cursor;yych=this._charAt(cursor);{gotoCase=51;continue;};case 32:{var token=this._line.substring(cursorOnEnter,cursor);this.tokenType=null;if(this._condition.parseCondition===this._parseConditions.INITIAL||this._condition.parseCondition===this._parseConditions.PROPERTY){if(token.charAt(0)==="@"){this.tokenType="css-at-rule";this._setParseCondition(token==="@media"?this._parseConditions.AT_MEDIA_RULE:this._parseConditions.AT_RULE);this._condition.atKeyword=token;}else if(this._condition.parseCondition===this._parseConditions.INITIAL)
|
| +this.tokenType="css-selector";else if(this._propertyKeywords.hasOwnProperty(token))
|
| +this.tokenType="css-property";}else if(this._condition.parseCondition===this._parseConditions.AT_MEDIA_RULE||this._condition.parseCondition===this._parseConditions.AT_RULE){if(WebInspector.SourceCSSTokenizer.SCSSAtRelatedKeywords.hasOwnProperty(token))
|
| +this.tokenType="css-at-rule";else if(WebInspector.SourceCSSTokenizer.MediaTypes.hasOwnProperty(token))
|
| +this.tokenType="css-keyword";}
|
| +if(this.tokenType)
|
| +return cursor;if(this._isPropertyValue()){var firstChar=token.charAt(0);if(firstChar==="$")
|
| +this.tokenType="scss-variable";else if(firstChar==="!")
|
| +this.tokenType="css-bang-keyword";else if(this._condition.atKeyword==="@extend")
|
| +this.tokenType="css-selector";else if(this._valueKeywords.hasOwnProperty(token)||this._scssValueKeywords.hasOwnProperty(token))
|
| +this.tokenType="css-keyword";else if(this._colorKeywords.hasOwnProperty(token)){this.tokenType="css-color";}}else if(this._condition.parseCondition!==this._parseConditions.PROPERTY_VALUE)
|
| +this.tokenType="css-selector";return cursor;}
|
| +case 33:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych<='.'){if(yych<='!'){if(yych<='\f'){if(yych=='\n'){gotoCase=32;continue;};{gotoCase=132;continue;};}else{if(yych<='\r'){gotoCase=32;continue;};if(yych<=' '){gotoCase=132;continue;};{gotoCase=130;continue;};}}else{if(yych<='\''){if(yych<='"'){gotoCase=116;continue;};if(yych<='%'){gotoCase=132;continue;};{gotoCase=130;continue;};}else{if(yych=='-'){gotoCase=130;continue;};{gotoCase=132;continue;};}}}else{if(yych<='\\'){if(yych<='='){if(yych<='9'){gotoCase=130;continue;};if(yych<='<'){gotoCase=132;continue;};{gotoCase=130;continue;};}else{if(yych<='?'){gotoCase=132;continue;};if(yych<='['){gotoCase=130;continue;};{gotoCase=134;continue;};}}else{if(yych<='_'){if(yych=='^'){gotoCase=132;continue;};{gotoCase=130;continue;};}else{if(yych<='`'){gotoCase=132;continue;};if(yych<='z'){gotoCase=130;continue;};{gotoCase=132;continue;};}}}
|
| +case 34:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=30;continue;};if(yych<='9'){gotoCase=127;continue;};{gotoCase=30;continue;};}else{if(yych<='Z'){gotoCase=127;continue;};if(yych<='`'){gotoCase=30;continue;};if(yych<='z'){gotoCase=127;continue;};{gotoCase=30;continue;};}
|
| +case 35:yych=this._charAt(++cursor);if(yych<='<'){if(yych<='\''){if(yych<=' '){gotoCase=30;continue;};if(yych<='"'){gotoCase=124;continue;};if(yych<='%'){gotoCase=30;continue;};{gotoCase=124;continue;};}else{if(yych<='-'){if(yych<=','){gotoCase=30;continue;};{gotoCase=124;continue;};}else{if(yych<='.'){gotoCase=30;continue;};if(yych<='9'){gotoCase=124;continue;};{gotoCase=30;continue;};}}}else{if(yych<=']'){if(yych<='?'){if(yych<='='){gotoCase=124;continue;};{gotoCase=30;continue;};}else{if(yych=='\\'){gotoCase=30;continue;};{gotoCase=124;continue;};}}else{if(yych<='_'){if(yych<='^'){gotoCase=30;continue;};{gotoCase=124;continue;};}else{if(yych<='`'){gotoCase=30;continue;};if(yych<='z'){gotoCase=124;continue;};{gotoCase=30;continue;};}}}
|
| +case 36:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych<='.'){if(yych<='"'){if(yych<='\f'){if(yych=='\n'){gotoCase=32;continue;};{gotoCase=118;continue;};}else{if(yych<='\r'){gotoCase=32;continue;};if(yych<=' '){gotoCase=118;continue;};{gotoCase=114;continue;};}}else{if(yych<='\''){if(yych<='%'){gotoCase=118;continue;};if(yych<='&'){gotoCase=114;continue;};{gotoCase=116;continue;};}else{if(yych=='-'){gotoCase=114;continue;};{gotoCase=118;continue;};}}}else{if(yych<='\\'){if(yych<='='){if(yych<='9'){gotoCase=114;continue;};if(yych<='<'){gotoCase=118;continue;};{gotoCase=114;continue;};}else{if(yych<='?'){gotoCase=118;continue;};if(yych<='['){gotoCase=114;continue;};{gotoCase=120;continue;};}}else{if(yych<='_'){if(yych=='^'){gotoCase=118;continue;};{gotoCase=114;continue;};}else{if(yych<='`'){gotoCase=118;continue;};if(yych<='z'){gotoCase=114;continue;};{gotoCase=118;continue;};}}}
|
| +case 37:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych=='.'){gotoCase=67;continue;};if(yych<='/'){gotoCase=51;continue;};if(yych<='9'){gotoCase=52;continue;};{gotoCase=51;continue;};case 38:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=30;continue;};if(yych<='9'){gotoCase=70;continue;};{gotoCase=30;continue;};case 39:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych=='*'){gotoCase=106;continue;};{gotoCase=51;continue;};case 40:yyaccept=1;yych=this._charAt(YYMARKER=++cursor);switch(yych){case'!':case'"':case'&':case'\'':case'-':case'/':case'=':case'@':case'A':case'B':case'C':case'D':case'E':case'F':case'G':case'I':case'J':case'K':case'L':case'M':case'N':case'O':case'P':case'Q':case'R':case'S':case'T':case'U':case'V':case'W':case'X':case'Y':case'Z':case'[':case']':case'a':case'b':case'f':case'h':case'j':case'l':case'n':case'o':case'q':case'u':case'v':case'w':case'x':case'y':case'z':{gotoCase=50;continue;};case'%':{gotoCase=69;continue;};case'.':{gotoCase=67;continue;};case'0':case'1':case'2':case'3':case'4':case'5':case'6':case'7':case'8':case'9':{gotoCase=52;continue;};case'H':{gotoCase=54;continue;};case'_':{gotoCase=55;continue;};case'c':{gotoCase=56;continue;};case'd':{gotoCase=57;continue;};case'e':{gotoCase=58;continue;};case'g':{gotoCase=59;continue;};case'i':{gotoCase=60;continue;};case'k':{gotoCase=61;continue;};case'm':{gotoCase=62;continue;};case'p':{gotoCase=63;continue;};case'r':{gotoCase=64;continue;};case's':{gotoCase=65;continue;};case't':{gotoCase=66;continue;};default:{gotoCase=41;continue;};}
|
| +case 41:{if(this._isPropertyValue())
|
| +this.tokenType="css-number";else
|
| +this.tokenType=null;return cursor;}
|
| +case 42:++cursor;{this.tokenType=null;if(this._condition.parseCondition===this._parseConditions.PROPERTY||this._condition.parseCondition===this._parseConditions.INITIAL)
|
| +this._setParseCondition(this._parseConditions.PROPERTY_VALUE);return cursor;}
|
| +case 44:++cursor;{this.tokenType=null;this._setParseCondition(this._condition.openBraces?this._parseConditions.PROPERTY:this._parseConditions.INITIAL);delete this._condition.atKeyword;return cursor;}
|
| +case 46:++cursor;{this.tokenType="block-start";this._condition.openBraces=(this._condition.openBraces||0)+1;if(this._condition.parseCondition===this._parseConditions.AT_MEDIA_RULE)
|
| +this._setParseCondition(this._parseConditions.INITIAL);else
|
| +this._setParseCondition(this._parseConditions.PROPERTY);return cursor;}
|
| +case 48:++cursor;{this.tokenType="block-end";if(this._condition.openBraces>0)
|
| +--this._condition.openBraces;this._setParseCondition(this._condition.openBraces?this._parseConditions.PROPERTY:this._parseConditions.INITIAL);delete this._condition.atKeyword;return cursor;}
|
| +case 50:++cursor;yych=this._charAt(cursor);case 51:if(yych<='<'){if(yych<='\''){if(yych<=' '){gotoCase=32;continue;};if(yych<='"'){gotoCase=50;continue;};if(yych<='%'){gotoCase=32;continue;};{gotoCase=50;continue;};}else{if(yych<='-'){if(yych<=','){gotoCase=32;continue;};{gotoCase=50;continue;};}else{if(yych<='.'){gotoCase=32;continue;};if(yych<='9'){gotoCase=50;continue;};{gotoCase=32;continue;};}}}else{if(yych<=']'){if(yych<='?'){if(yych<='='){gotoCase=50;continue;};{gotoCase=32;continue;};}else{if(yych=='\\'){gotoCase=32;continue;};{gotoCase=50;continue;};}}else{if(yych<='_'){if(yych<='^'){gotoCase=32;continue;};{gotoCase=50;continue;};}else{if(yych<='`'){gotoCase=32;continue;};if(yych<='z'){gotoCase=50;continue;};{gotoCase=32;continue;};}}}
|
| +case 52:yyaccept=1;YYMARKER=++cursor;yych=this._charAt(cursor);switch(yych){case'!':case'"':case'&':case'\'':case'-':case'/':case'=':case'@':case'A':case'B':case'C':case'D':case'E':case'F':case'G':case'I':case'J':case'K':case'L':case'M':case'N':case'O':case'P':case'Q':case'R':case'S':case'T':case'U':case'V':case'W':case'X':case'Y':case'Z':case'[':case']':case'a':case'b':case'f':case'h':case'j':case'l':case'n':case'o':case'q':case'u':case'v':case'w':case'x':case'y':case'z':{gotoCase=50;continue;};case'%':{gotoCase=69;continue;};case'.':{gotoCase=67;continue;};case'0':case'1':case'2':case'3':case'4':case'5':case'6':case'7':case'8':case'9':{gotoCase=52;continue;};case'H':{gotoCase=54;continue;};case'_':{gotoCase=55;continue;};case'c':{gotoCase=56;continue;};case'd':{gotoCase=57;continue;};case'e':{gotoCase=58;continue;};case'g':{gotoCase=59;continue;};case'i':{gotoCase=60;continue;};case'k':{gotoCase=61;continue;};case'm':{gotoCase=62;continue;};case'p':{gotoCase=63;continue;};case'r':{gotoCase=64;continue;};case's':{gotoCase=65;continue;};case't':{gotoCase=66;continue;};default:{gotoCase=41;continue;};}
|
| +case 54:yych=this._charAt(++cursor);if(yych=='z'){gotoCase=65;continue;};{gotoCase=51;continue;};case 55:yych=this._charAt(++cursor);if(yych=='_'){gotoCase=103;continue;};{gotoCase=51;continue;};case 56:yych=this._charAt(++cursor);if(yych=='m'){gotoCase=65;continue;};{gotoCase=51;continue;};case 57:yych=this._charAt(++cursor);if(yych=='e'){gotoCase=102;continue;};{gotoCase=51;continue;};case 58:yych=this._charAt(++cursor);if(yych=='m'){gotoCase=65;continue;};if(yych=='x'){gotoCase=65;continue;};{gotoCase=51;continue;};case 59:yych=this._charAt(++cursor);if(yych=='r'){gotoCase=100;continue;};{gotoCase=51;continue;};case 60:yych=this._charAt(++cursor);if(yych=='n'){gotoCase=65;continue;};{gotoCase=51;continue;};case 61:yych=this._charAt(++cursor);if(yych=='H'){gotoCase=99;continue;};{gotoCase=51;continue;};case 62:yych=this._charAt(++cursor);if(yych=='m'){gotoCase=65;continue;};if(yych=='s'){gotoCase=65;continue;};{gotoCase=51;continue;};case 63:yych=this._charAt(++cursor);if(yych<='s'){if(yych=='c'){gotoCase=65;continue;};{gotoCase=51;continue;};}else{if(yych<='t'){gotoCase=65;continue;};if(yych=='x'){gotoCase=65;continue;};{gotoCase=51;continue;};}
|
| +case 64:yych=this._charAt(++cursor);if(yych=='a'){gotoCase=97;continue;};if(yych=='e'){gotoCase=98;continue;};{gotoCase=51;continue;};case 65:yych=this._charAt(++cursor);if(yych<='<'){if(yych<='\''){if(yych<=' '){gotoCase=41;continue;};if(yych<='"'){gotoCase=50;continue;};if(yych<='%'){gotoCase=41;continue;};{gotoCase=50;continue;};}else{if(yych<='-'){if(yych<=','){gotoCase=41;continue;};{gotoCase=50;continue;};}else{if(yych<='.'){gotoCase=41;continue;};if(yych<='9'){gotoCase=50;continue;};{gotoCase=41;continue;};}}}else{if(yych<=']'){if(yych<='?'){if(yych<='='){gotoCase=50;continue;};{gotoCase=41;continue;};}else{if(yych=='\\'){gotoCase=41;continue;};{gotoCase=50;continue;};}}else{if(yych<='_'){if(yych<='^'){gotoCase=41;continue;};{gotoCase=50;continue;};}else{if(yych<='`'){gotoCase=41;continue;};if(yych<='z'){gotoCase=50;continue;};{gotoCase=41;continue;};}}}
|
| +case 66:yych=this._charAt(++cursor);if(yych=='u'){gotoCase=95;continue;};{gotoCase=51;continue;};case 67:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=68;continue;};if(yych<='9'){gotoCase=70;continue;};case 68:cursor=YYMARKER;if(yyaccept<=0){{gotoCase=32;continue;};}else{{gotoCase=41;continue;};}
|
| +case 69:yych=this._charAt(++cursor);{gotoCase=41;continue;};case 70:yyaccept=1;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='f'){if(yych<='H'){if(yych<='/'){if(yych=='%'){gotoCase=69;continue;};{gotoCase=41;continue;};}else{if(yych<='9'){gotoCase=70;continue;};if(yych<='G'){gotoCase=41;continue;};{gotoCase=82;continue;};}}else{if(yych<='b'){if(yych=='_'){gotoCase=74;continue;};{gotoCase=41;continue;};}else{if(yych<='c'){gotoCase=76;continue;};if(yych<='d'){gotoCase=79;continue;};if(yych>='f'){gotoCase=41;continue;};}}}else{if(yych<='m'){if(yych<='i'){if(yych<='g'){gotoCase=80;continue;};if(yych<='h'){gotoCase=41;continue;};{gotoCase=78;continue;};}else{if(yych=='k'){gotoCase=83;continue;};if(yych<='l'){gotoCase=41;continue;};{gotoCase=77;continue;};}}else{if(yych<='q'){if(yych=='p'){gotoCase=75;continue;};{gotoCase=41;continue;};}else{if(yych<='r'){gotoCase=73;continue;};if(yych<='s'){gotoCase=69;continue;};if(yych<='t'){gotoCase=81;continue;};{gotoCase=41;continue;};}}}
|
| +yych=this._charAt(++cursor);if(yych=='m'){gotoCase=69;continue;};if(yych=='x'){gotoCase=69;continue;};{gotoCase=68;continue;};case 73:yych=this._charAt(++cursor);if(yych=='a'){gotoCase=93;continue;};if(yych=='e'){gotoCase=94;continue;};{gotoCase=68;continue;};case 74:yych=this._charAt(++cursor);if(yych=='_'){gotoCase=90;continue;};{gotoCase=68;continue;};case 75:yych=this._charAt(++cursor);if(yych<='s'){if(yych=='c'){gotoCase=69;continue;};{gotoCase=68;continue;};}else{if(yych<='t'){gotoCase=69;continue;};if(yych=='x'){gotoCase=69;continue;};{gotoCase=68;continue;};}
|
| +case 76:yych=this._charAt(++cursor);if(yych=='m'){gotoCase=69;continue;};{gotoCase=68;continue;};case 77:yych=this._charAt(++cursor);if(yych=='m'){gotoCase=69;continue;};if(yych=='s'){gotoCase=69;continue;};{gotoCase=68;continue;};case 78:yych=this._charAt(++cursor);if(yych=='n'){gotoCase=69;continue;};{gotoCase=68;continue;};case 79:yych=this._charAt(++cursor);if(yych=='e'){gotoCase=89;continue;};{gotoCase=68;continue;};case 80:yych=this._charAt(++cursor);if(yych=='r'){gotoCase=87;continue;};{gotoCase=68;continue;};case 81:yych=this._charAt(++cursor);if(yych=='u'){gotoCase=85;continue;};{gotoCase=68;continue;};case 82:yych=this._charAt(++cursor);if(yych=='z'){gotoCase=69;continue;};{gotoCase=68;continue;};case 83:yych=this._charAt(++cursor);if(yych!='H'){gotoCase=68;continue;};yych=this._charAt(++cursor);if(yych=='z'){gotoCase=69;continue;};{gotoCase=68;continue;};case 85:yych=this._charAt(++cursor);if(yych!='r'){gotoCase=68;continue;};yych=this._charAt(++cursor);if(yych=='n'){gotoCase=69;continue;};{gotoCase=68;continue;};case 87:yych=this._charAt(++cursor);if(yych!='a'){gotoCase=68;continue;};yych=this._charAt(++cursor);if(yych=='d'){gotoCase=69;continue;};{gotoCase=68;continue;};case 89:yych=this._charAt(++cursor);if(yych=='g'){gotoCase=69;continue;};{gotoCase=68;continue;};case 90:yych=this._charAt(++cursor);if(yych!='q'){gotoCase=68;continue;};yych=this._charAt(++cursor);if(yych!='e'){gotoCase=68;continue;};yych=this._charAt(++cursor);if(yych=='m'){gotoCase=69;continue;};{gotoCase=68;continue;};case 93:yych=this._charAt(++cursor);if(yych=='d'){gotoCase=69;continue;};{gotoCase=68;continue;};case 94:yych=this._charAt(++cursor);if(yych=='m'){gotoCase=69;continue;};{gotoCase=68;continue;};case 95:yych=this._charAt(++cursor);if(yych!='r'){gotoCase=51;continue;};yych=this._charAt(++cursor);if(yych=='n'){gotoCase=65;continue;};{gotoCase=51;continue;};case 97:yych=this._charAt(++cursor);if(yych=='d'){gotoCase=65;continue;};{gotoCase=51;continue;};case 98:yych=this._charAt(++cursor);if(yych=='m'){gotoCase=65;continue;};{gotoCase=51;continue;};case 99:yych=this._charAt(++cursor);if(yych=='z'){gotoCase=65;continue;};{gotoCase=51;continue;};case 100:yych=this._charAt(++cursor);if(yych!='a'){gotoCase=51;continue;};yych=this._charAt(++cursor);if(yych=='d'){gotoCase=65;continue;};{gotoCase=51;continue;};case 102:yych=this._charAt(++cursor);if(yych=='g'){gotoCase=65;continue;};{gotoCase=51;continue;};case 103:yych=this._charAt(++cursor);if(yych!='q'){gotoCase=51;continue;};yych=this._charAt(++cursor);if(yych!='e'){gotoCase=51;continue;};yych=this._charAt(++cursor);if(yych=='m'){gotoCase=65;continue;};{gotoCase=51;continue;};case 106:++cursor;yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=110;continue;};{gotoCase=106;continue;};}else{if(yych<='\r'){gotoCase=110;continue;};if(yych!='*'){gotoCase=106;continue;};}
|
| +case 108:++cursor;yych=this._charAt(cursor);if(yych=='*'){gotoCase=108;continue;};if(yych=='/'){gotoCase=112;continue;};{gotoCase=106;continue;};case 110:++cursor;this.setLexCondition(this._lexConditions.COMMENT);{this.tokenType="css-comment";return cursor;}
|
| +case 112:++cursor;{this.tokenType="css-comment";return cursor;}
|
| +case 114:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='.'){if(yych<='"'){if(yych<='\f'){if(yych=='\n'){gotoCase=32;continue;};{gotoCase=118;continue;};}else{if(yych<='\r'){gotoCase=32;continue;};if(yych<=' '){gotoCase=118;continue;};{gotoCase=114;continue;};}}else{if(yych<='\''){if(yych<='%'){gotoCase=118;continue;};if(yych<='&'){gotoCase=114;continue;};}else{if(yych=='-'){gotoCase=114;continue;};{gotoCase=118;continue;};}}}else{if(yych<='\\'){if(yych<='='){if(yych<='9'){gotoCase=114;continue;};if(yych<='<'){gotoCase=118;continue;};{gotoCase=114;continue;};}else{if(yych<='?'){gotoCase=118;continue;};if(yych<='['){gotoCase=114;continue;};{gotoCase=120;continue;};}}else{if(yych<='_'){if(yych=='^'){gotoCase=118;continue;};{gotoCase=114;continue;};}else{if(yych<='`'){gotoCase=118;continue;};if(yych<='z'){gotoCase=114;continue;};{gotoCase=118;continue;};}}}
|
| +case 116:++cursor;if((yych=this._charAt(cursor))<='<'){if(yych<='\''){if(yych<=' '){gotoCase=117;continue;};if(yych<='"'){gotoCase=50;continue;};if(yych>='&'){gotoCase=50;continue;};}else{if(yych<='-'){if(yych>='-'){gotoCase=50;continue;};}else{if(yych<='.'){gotoCase=117;continue;};if(yych<='9'){gotoCase=50;continue;};}}}else{if(yych<=']'){if(yych<='?'){if(yych<='='){gotoCase=50;continue;};}else{if(yych!='\\'){gotoCase=50;continue;};}}else{if(yych<='_'){if(yych>='_'){gotoCase=50;continue;};}else{if(yych<='`'){gotoCase=117;continue;};if(yych<='z'){gotoCase=50;continue;};}}}
|
| +case 117:{return this._stringToken(cursor,true);}
|
| +case 118:++cursor;yych=this._charAt(cursor);if(yych<='\r'){if(yych=='\n'){gotoCase=68;continue;};if(yych<='\f'){gotoCase=118;continue;};{gotoCase=68;continue;};}else{if(yych<='\''){if(yych<='&'){gotoCase=118;continue;};{gotoCase=123;continue;};}else{if(yych!='\\'){gotoCase=118;continue;};}}
|
| +case 120:++cursor;yych=this._charAt(cursor);if(yych<='a'){if(yych<='!'){if(yych<='\n'){if(yych<='\t'){gotoCase=68;continue;};}else{if(yych!='\r'){gotoCase=68;continue;};}}else{if(yych<='\''){if(yych<='"'){gotoCase=118;continue;};if(yych<='&'){gotoCase=68;continue;};{gotoCase=118;continue;};}else{if(yych=='\\'){gotoCase=118;continue;};{gotoCase=68;continue;};}}}else{if(yych<='q'){if(yych<='f'){if(yych<='b'){gotoCase=118;continue;};if(yych<='e'){gotoCase=68;continue;};{gotoCase=118;continue;};}else{if(yych=='n'){gotoCase=118;continue;};{gotoCase=68;continue;};}}else{if(yych<='t'){if(yych=='s'){gotoCase=68;continue;};{gotoCase=118;continue;};}else{if(yych=='v'){gotoCase=118;continue;};{gotoCase=68;continue;};}}}
|
| +++cursor;this.setLexCondition(this._lexConditions.SSTRING);{return this._stringToken(cursor);}
|
| +case 123:yych=this._charAt(++cursor);{gotoCase=117;continue;};case 124:++cursor;yych=this._charAt(cursor);if(yych<='<'){if(yych<='\''){if(yych<=' '){gotoCase=126;continue;};if(yych<='"'){gotoCase=124;continue;};if(yych>='&'){gotoCase=124;continue;};}else{if(yych<='-'){if(yych>='-'){gotoCase=124;continue;};}else{if(yych<='.'){gotoCase=126;continue;};if(yych<='9'){gotoCase=124;continue;};}}}else{if(yych<=']'){if(yych<='?'){if(yych<='='){gotoCase=124;continue;};}else{if(yych!='\\'){gotoCase=124;continue;};}}else{if(yych<='_'){if(yych>='_'){gotoCase=124;continue;};}else{if(yych<='`'){gotoCase=126;continue;};if(yych<='z'){gotoCase=124;continue;};}}}
|
| +case 126:{if(this._condition.parseCondition===this._condition.parseCondition.INITIAL||this._condition.parseCondition===this._condition.parseCondition.AT_RULE)
|
| +this._setParseCondition(this._parseConditions.PROPERTY);this.tokenType="scss-variable";return cursor;}
|
| +case 127:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=129;continue;};if(yych<='9'){gotoCase=127;continue;};}else{if(yych<='Z'){gotoCase=127;continue;};if(yych<='`'){gotoCase=129;continue;};if(yych<='z'){gotoCase=127;continue;};}
|
| +case 129:{if(this._isPropertyValue())
|
| +this.tokenType="css-color";else if(this._condition.parseCondition===this._parseConditions.INITIAL)
|
| +this.tokenType="css-selector";else
|
| +this.tokenType=null;return cursor;}
|
| +case 130:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='.'){if(yych<='!'){if(yych<='\f'){if(yych=='\n'){gotoCase=32;continue;};}else{if(yych<='\r'){gotoCase=32;continue;};if(yych>='!'){gotoCase=130;continue;};}}else{if(yych<='\''){if(yych<='"'){gotoCase=116;continue;};if(yych>='&'){gotoCase=130;continue;};}else{if(yych=='-'){gotoCase=130;continue;};}}}else{if(yych<='\\'){if(yych<='='){if(yych<='9'){gotoCase=130;continue;};if(yych>='='){gotoCase=130;continue;};}else{if(yych<='?'){gotoCase=132;continue;};if(yych<='['){gotoCase=130;continue;};{gotoCase=134;continue;};}}else{if(yych<='_'){if(yych!='^'){gotoCase=130;continue;};}else{if(yych<='`'){gotoCase=132;continue;};if(yych<='z'){gotoCase=130;continue;};}}}
|
| +case 132:++cursor;yych=this._charAt(cursor);if(yych<='\r'){if(yych=='\n'){gotoCase=68;continue;};if(yych<='\f'){gotoCase=132;continue;};{gotoCase=68;continue;};}else{if(yych<='"'){if(yych<='!'){gotoCase=132;continue;};{gotoCase=123;continue;};}else{if(yych!='\\'){gotoCase=132;continue;};}}
|
| +case 134:++cursor;yych=this._charAt(cursor);if(yych<='a'){if(yych<='!'){if(yych<='\n'){if(yych<='\t'){gotoCase=68;continue;};}else{if(yych!='\r'){gotoCase=68;continue;};}}else{if(yych<='\''){if(yych<='"'){gotoCase=132;continue;};if(yych<='&'){gotoCase=68;continue;};{gotoCase=132;continue;};}else{if(yych=='\\'){gotoCase=132;continue;};{gotoCase=68;continue;};}}}else{if(yych<='q'){if(yych<='f'){if(yych<='b'){gotoCase=132;continue;};if(yych<='e'){gotoCase=68;continue;};{gotoCase=132;continue;};}else{if(yych=='n'){gotoCase=132;continue;};{gotoCase=68;continue;};}}else{if(yych<='t'){if(yych=='s'){gotoCase=68;continue;};{gotoCase=132;continue;};}else{if(yych=='v'){gotoCase=132;continue;};{gotoCase=68;continue;};}}}
|
| +++cursor;this.setLexCondition(this._lexConditions.DSTRING);{return this._stringToken(cursor);}
|
| +case this.case_SSTRING:yych=this._charAt(cursor);if(yych<='\r'){if(yych=='\n'){gotoCase=141;continue;};if(yych<='\f'){gotoCase=140;continue;};{gotoCase=141;continue;};}else{if(yych<='\''){if(yych<='&'){gotoCase=140;continue;};{gotoCase=143;continue;};}else{if(yych=='\\'){gotoCase=145;continue;};{gotoCase=140;continue;};}}
|
| +case 139:{return this._stringToken(cursor);}
|
| +case 140:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=147;continue;};case 141:++cursor;case 142:{this.tokenType=null;return cursor;}
|
| +case 143:++cursor;case 144:this.setLexCondition(this._lexConditions.INITIAL);{return this._stringToken(cursor,true);}
|
| +case 145:yych=this._charAt(++cursor);if(yych<='e'){if(yych<='\''){if(yych=='"'){gotoCase=146;continue;};if(yych<='&'){gotoCase=142;continue;};}else{if(yych<='\\'){if(yych<='['){gotoCase=142;continue;};}else{if(yych!='b'){gotoCase=142;continue;};}}}else{if(yych<='r'){if(yych<='m'){if(yych>='g'){gotoCase=142;continue;};}else{if(yych<='n'){gotoCase=146;continue;};if(yych<='q'){gotoCase=142;continue;};}}else{if(yych<='t'){if(yych<='s'){gotoCase=142;continue;};}else{if(yych!='v'){gotoCase=142;continue;};}}}
|
| +case 146:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);case 147:if(yych<='\r'){if(yych=='\n'){gotoCase=139;continue;};if(yych<='\f'){gotoCase=146;continue;};{gotoCase=139;continue;};}else{if(yych<='\''){if(yych<='&'){gotoCase=146;continue;};{gotoCase=150;continue;};}else{if(yych!='\\'){gotoCase=146;continue;};}}
|
| +++cursor;yych=this._charAt(cursor);if(yych<='e'){if(yych<='\''){if(yych=='"'){gotoCase=146;continue;};if(yych>='\''){gotoCase=146;continue;};}else{if(yych<='\\'){if(yych>='\\'){gotoCase=146;continue;};}else{if(yych=='b'){gotoCase=146;continue;};}}}else{if(yych<='r'){if(yych<='m'){if(yych<='f'){gotoCase=146;continue;};}else{if(yych<='n'){gotoCase=146;continue;};if(yych>='r'){gotoCase=146;continue;};}}else{if(yych<='t'){if(yych>='t'){gotoCase=146;continue;};}else{if(yych=='v'){gotoCase=146;continue;};}}}
|
| +cursor=YYMARKER;{gotoCase=139;continue;};case 150:++cursor;yych=this._charAt(cursor);{gotoCase=144;continue;};}}},__proto__:WebInspector.SourceTokenizer.prototype}
|
| +WebInspector.SourceHTMLTokenizer=function()
|
| +{WebInspector.SourceTokenizer.call(this);this._lexConditions={INITIAL:0,COMMENT:1,DOCTYPE:2,TAG:3,DSTRING:4,SSTRING:5};this.case_INITIAL=1000;this.case_COMMENT=1001;this.case_DOCTYPE=1002;this.case_TAG=1003;this.case_DSTRING=1004;this.case_SSTRING=1005;this._parseConditions={INITIAL:0,ATTRIBUTE:1,ATTRIBUTE_VALUE:2,LINKIFY:4,A_NODE:8,SCRIPT:16,STYLE:32};this.condition=this.createInitialCondition();}
|
| +WebInspector.SourceHTMLTokenizer.prototype={createInitialCondition:function()
|
| +{return{lexCondition:this._lexConditions.INITIAL,parseCondition:this._parseConditions.INITIAL};},set line(line){if(this._condition.internalJavaScriptTokenizerCondition){var match=/<\/script/i.exec(line);if(match){this._internalJavaScriptTokenizer.line=line.substring(0,match.index);}else
|
| +this._internalJavaScriptTokenizer.line=line;}else if(this._condition.internalCSSTokenizerCondition){var match=/<\/style/i.exec(line);if(match){this._internalCSSTokenizer.line=line.substring(0,match.index);}else
|
| +this._internalCSSTokenizer.line=line;}
|
| +this._line=line;},_isExpectingAttribute:function()
|
| +{return this._condition.parseCondition&this._parseConditions.ATTRIBUTE;},_isExpectingAttributeValue:function()
|
| +{return this._condition.parseCondition&this._parseConditions.ATTRIBUTE_VALUE;},_setExpectingAttribute:function()
|
| +{if(this._isExpectingAttributeValue())
|
| +this._condition.parseCondition^=this._parseConditions.ATTRIBUTE_VALUE;this._condition.parseCondition|=this._parseConditions.ATTRIBUTE;},_setExpectingAttributeValue:function()
|
| +{if(this._isExpectingAttribute())
|
| +this._condition.parseCondition^=this._parseConditions.ATTRIBUTE;this._condition.parseCondition|=this._parseConditions.ATTRIBUTE_VALUE;},_stringToken:function(cursor,stringEnds)
|
| +{if(!this._isExpectingAttributeValue()){this.tokenType=null;return cursor;}
|
| +this.tokenType=this._attrValueTokenType();if(stringEnds)
|
| +this._setExpectingAttribute();return cursor;},_attrValueTokenType:function()
|
| +{if(this._condition.parseCondition&this._parseConditions.LINKIFY){if(this._condition.parseCondition&this._parseConditions.A_NODE)
|
| +return"html-external-link";return"html-resource-link";}
|
| +return"html-attribute-value";},get _internalJavaScriptTokenizer()
|
| +{return WebInspector.SourceTokenizer.Registry.getInstance().getTokenizer("text/javascript");},get _internalCSSTokenizer()
|
| +{return WebInspector.SourceTokenizer.Registry.getInstance().getTokenizer("text/css");},scriptStarted:function(cursor)
|
| +{this._condition.internalJavaScriptTokenizerCondition=this._internalJavaScriptTokenizer.createInitialCondition();},scriptEnded:function(cursor)
|
| +{},styleSheetStarted:function(cursor)
|
| +{this._condition.internalCSSTokenizerCondition=this._internalCSSTokenizer.createInitialCondition();},styleSheetEnded:function(cursor)
|
| +{},nextToken:function(cursor)
|
| +{if(this._condition.internalJavaScriptTokenizerCondition){this.line=this._line;if(cursor!==this._internalJavaScriptTokenizer._line.length){this._internalJavaScriptTokenizer.condition=this._condition.internalJavaScriptTokenizerCondition;var result=this._internalJavaScriptTokenizer.nextToken(cursor);this.tokenType=this._internalJavaScriptTokenizer.tokenType;this._condition.internalJavaScriptTokenizerCondition=this._internalJavaScriptTokenizer.condition;return result;}else if(cursor!==this._line.length)
|
| +delete this._condition.internalJavaScriptTokenizerCondition;}else if(this._condition.internalCSSTokenizerCondition){this.line=this._line;if(cursor!==this._internalCSSTokenizer._line.length){this._internalCSSTokenizer.condition=this._condition.internalCSSTokenizerCondition;var result=this._internalCSSTokenizer.nextToken(cursor);this.tokenType=this._internalCSSTokenizer.tokenType;this._condition.internalCSSTokenizerCondition=this._internalCSSTokenizer.condition;return result;}else if(cursor!==this._line.length)
|
| +delete this._condition.internalCSSTokenizerCondition;}
|
| +var cursorOnEnter=cursor;var gotoCase=1;var YYMARKER;while(1){switch(gotoCase)
|
| +{case 1:var yych;var yyaccept=0;if(this.getLexCondition()<3){if(this.getLexCondition()<1){{gotoCase=this.case_INITIAL;continue;};}else{if(this.getLexCondition()<2){{gotoCase=this.case_COMMENT;continue;};}else{{gotoCase=this.case_DOCTYPE;continue;};}}}else{if(this.getLexCondition()<4){{gotoCase=this.case_TAG;continue;};}else{if(this.getLexCondition()<5){{gotoCase=this.case_DSTRING;continue;};}else{{gotoCase=this.case_SSTRING;continue;};}}}
|
| +case this.case_COMMENT:yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=4;continue;};{gotoCase=3;continue;};}else{if(yych<='\r'){gotoCase=4;continue;};if(yych=='-'){gotoCase=6;continue;};{gotoCase=3;continue;};}
|
| +case 2:{this.tokenType="html-comment";return cursor;}
|
| +case 3:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=9;continue;};case 4:++cursor;case 5:{this.tokenType=null;return cursor;}
|
| +case 6:yyaccept=1;yych=this._charAt(YYMARKER=++cursor);if(yych!='-'){gotoCase=5;continue;};case 7:++cursor;yych=this._charAt(cursor);if(yych=='>'){gotoCase=10;continue;};case 8:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);case 9:if(yych<='\f'){if(yych=='\n'){gotoCase=2;continue;};{gotoCase=8;continue;};}else{if(yych<='\r'){gotoCase=2;continue;};if(yych=='-'){gotoCase=12;continue;};{gotoCase=8;continue;};}
|
| +case 10:++cursor;this.setLexCondition(this._lexConditions.INITIAL);{this.tokenType="html-comment";return cursor;}
|
| +case 12:++cursor;yych=this._charAt(cursor);if(yych=='-'){gotoCase=7;continue;};cursor=YYMARKER;if(yyaccept<=0){{gotoCase=2;continue;};}else{{gotoCase=5;continue;};}
|
| +case this.case_DOCTYPE:yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=18;continue;};{gotoCase=17;continue;};}else{if(yych<='\r'){gotoCase=18;continue;};if(yych=='>'){gotoCase=20;continue;};{gotoCase=17;continue;};}
|
| +case 16:{this.tokenType="html-doctype";return cursor;}
|
| +case 17:yych=this._charAt(++cursor);{gotoCase=23;continue;};case 18:++cursor;{this.tokenType=null;return cursor;}
|
| +case 20:++cursor;this.setLexCondition(this._lexConditions.INITIAL);{this.tokenType="html-doctype";return cursor;}
|
| +case 22:++cursor;yych=this._charAt(cursor);case 23:if(yych<='\f'){if(yych=='\n'){gotoCase=16;continue;};{gotoCase=22;continue;};}else{if(yych<='\r'){gotoCase=16;continue;};if(yych=='>'){gotoCase=16;continue;};{gotoCase=22;continue;};}
|
| +case this.case_DSTRING:yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=28;continue;};{gotoCase=27;continue;};}else{if(yych<='\r'){gotoCase=28;continue;};if(yych=='"'){gotoCase=30;continue;};{gotoCase=27;continue;};}
|
| +case 26:{return this._stringToken(cursor);}
|
| +case 27:yych=this._charAt(++cursor);{gotoCase=34;continue;};case 28:++cursor;{this.tokenType=null;return cursor;}
|
| +case 30:++cursor;case 31:this.setLexCondition(this._lexConditions.TAG);{return this._stringToken(cursor,true);}
|
| +case 32:yych=this._charAt(++cursor);{gotoCase=31;continue;};case 33:++cursor;yych=this._charAt(cursor);case 34:if(yych<='\f'){if(yych=='\n'){gotoCase=26;continue;};{gotoCase=33;continue;};}else{if(yych<='\r'){gotoCase=26;continue;};if(yych=='"'){gotoCase=32;continue;};{gotoCase=33;continue;};}
|
| +case this.case_INITIAL:yych=this._charAt(cursor);if(yych=='<'){gotoCase=39;continue;};++cursor;{this.tokenType=null;return cursor;}
|
| +case 39:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych<='/'){if(yych=='!'){gotoCase=44;continue;};if(yych>='/'){gotoCase=41;continue;};}else{if(yych<='S'){if(yych>='S'){gotoCase=42;continue;};}else{if(yych=='s'){gotoCase=42;continue;};}}
|
| +case 40:this.setLexCondition(this._lexConditions.TAG);{if(this._condition.parseCondition&(this._parseConditions.SCRIPT|this._parseConditions.STYLE)){this.setLexCondition(this._lexConditions.INITIAL);this.tokenType=null;return cursor;}
|
| +this._condition.parseCondition=this._parseConditions.INITIAL;this.tokenType="html-tag";return cursor;}
|
| +case 41:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych=='S'){gotoCase=73;continue;};if(yych=='s'){gotoCase=73;continue;};{gotoCase=40;continue;};case 42:yych=this._charAt(++cursor);if(yych<='T'){if(yych=='C'){gotoCase=62;continue;};if(yych>='T'){gotoCase=63;continue;};}else{if(yych<='c'){if(yych>='c'){gotoCase=62;continue;};}else{if(yych=='t'){gotoCase=63;continue;};}}
|
| +case 43:cursor=YYMARKER;{gotoCase=40;continue;};case 44:yych=this._charAt(++cursor);if(yych<='C'){if(yych!='-'){gotoCase=43;continue;};}else{if(yych<='D'){gotoCase=46;continue;};if(yych=='d'){gotoCase=46;continue;};{gotoCase=43;continue;};}
|
| +yych=this._charAt(++cursor);if(yych=='-'){gotoCase=54;continue;};{gotoCase=43;continue;};case 46:yych=this._charAt(++cursor);if(yych=='O'){gotoCase=47;continue;};if(yych!='o'){gotoCase=43;continue;};case 47:yych=this._charAt(++cursor);if(yych=='C'){gotoCase=48;continue;};if(yych!='c'){gotoCase=43;continue;};case 48:yych=this._charAt(++cursor);if(yych=='T'){gotoCase=49;continue;};if(yych!='t'){gotoCase=43;continue;};case 49:yych=this._charAt(++cursor);if(yych=='Y'){gotoCase=50;continue;};if(yych!='y'){gotoCase=43;continue;};case 50:yych=this._charAt(++cursor);if(yych=='P'){gotoCase=51;continue;};if(yych!='p'){gotoCase=43;continue;};case 51:yych=this._charAt(++cursor);if(yych=='E'){gotoCase=52;continue;};if(yych!='e'){gotoCase=43;continue;};case 52:++cursor;this.setLexCondition(this._lexConditions.DOCTYPE);{this.tokenType="html-doctype";return cursor;}
|
| +case 54:++cursor;yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=57;continue;};{gotoCase=54;continue;};}else{if(yych<='\r'){gotoCase=57;continue;};if(yych!='-'){gotoCase=54;continue;};}
|
| +++cursor;yych=this._charAt(cursor);if(yych=='-'){gotoCase=59;continue;};{gotoCase=43;continue;};case 57:++cursor;this.setLexCondition(this._lexConditions.COMMENT);{this.tokenType="html-comment";return cursor;}
|
| +case 59:++cursor;yych=this._charAt(cursor);if(yych!='>'){gotoCase=54;continue;};++cursor;{this.tokenType="html-comment";return cursor;}
|
| +case 62:yych=this._charAt(++cursor);if(yych=='R'){gotoCase=68;continue;};if(yych=='r'){gotoCase=68;continue;};{gotoCase=43;continue;};case 63:yych=this._charAt(++cursor);if(yych=='Y'){gotoCase=64;continue;};if(yych!='y'){gotoCase=43;continue;};case 64:yych=this._charAt(++cursor);if(yych=='L'){gotoCase=65;continue;};if(yych!='l'){gotoCase=43;continue;};case 65:yych=this._charAt(++cursor);if(yych=='E'){gotoCase=66;continue;};if(yych!='e'){gotoCase=43;continue;};case 66:++cursor;this.setLexCondition(this._lexConditions.TAG);{if(this._condition.parseCondition&this._parseConditions.STYLE){this.setLexCondition(this._lexConditions.INITIAL);this.tokenType=null;return cursor;}
|
| +this.tokenType="html-tag";this._condition.parseCondition=this._parseConditions.STYLE;this._setExpectingAttribute();return cursor;}
|
| +case 68:yych=this._charAt(++cursor);if(yych=='I'){gotoCase=69;continue;};if(yych!='i'){gotoCase=43;continue;};case 69:yych=this._charAt(++cursor);if(yych=='P'){gotoCase=70;continue;};if(yych!='p'){gotoCase=43;continue;};case 70:yych=this._charAt(++cursor);if(yych=='T'){gotoCase=71;continue;};if(yych!='t'){gotoCase=43;continue;};case 71:++cursor;this.setLexCondition(this._lexConditions.TAG);{if(this._condition.parseCondition&this._parseConditions.SCRIPT){this.setLexCondition(this._lexConditions.INITIAL);this.tokenType=null;return cursor;}
|
| +this.tokenType="html-tag";this._condition.parseCondition=this._parseConditions.SCRIPT;this._setExpectingAttribute();return cursor;}
|
| +case 73:yych=this._charAt(++cursor);if(yych<='T'){if(yych=='C'){gotoCase=75;continue;};if(yych<='S'){gotoCase=43;continue;};}else{if(yych<='c'){if(yych<='b'){gotoCase=43;continue;};{gotoCase=75;continue;};}else{if(yych!='t'){gotoCase=43;continue;};}}
|
| +yych=this._charAt(++cursor);if(yych=='Y'){gotoCase=81;continue;};if(yych=='y'){gotoCase=81;continue;};{gotoCase=43;continue;};case 75:yych=this._charAt(++cursor);if(yych=='R'){gotoCase=76;continue;};if(yych!='r'){gotoCase=43;continue;};case 76:yych=this._charAt(++cursor);if(yych=='I'){gotoCase=77;continue;};if(yych!='i'){gotoCase=43;continue;};case 77:yych=this._charAt(++cursor);if(yych=='P'){gotoCase=78;continue;};if(yych!='p'){gotoCase=43;continue;};case 78:yych=this._charAt(++cursor);if(yych=='T'){gotoCase=79;continue;};if(yych!='t'){gotoCase=43;continue;};case 79:++cursor;this.setLexCondition(this._lexConditions.TAG);{this.tokenType="html-tag";this._condition.parseCondition=this._parseConditions.INITIAL;this.scriptEnded(cursor-8);return cursor;}
|
| +case 81:yych=this._charAt(++cursor);if(yych=='L'){gotoCase=82;continue;};if(yych!='l'){gotoCase=43;continue;};case 82:yych=this._charAt(++cursor);if(yych=='E'){gotoCase=83;continue;};if(yych!='e'){gotoCase=43;continue;};case 83:++cursor;this.setLexCondition(this._lexConditions.TAG);{this.tokenType="html-tag";this._condition.parseCondition=this._parseConditions.INITIAL;this.styleSheetEnded(cursor-7);return cursor;}
|
| +case this.case_SSTRING:yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=89;continue;};{gotoCase=88;continue;};}else{if(yych<='\r'){gotoCase=89;continue;};if(yych=='\''){gotoCase=91;continue;};{gotoCase=88;continue;};}
|
| +case 87:{return this._stringToken(cursor);}
|
| +case 88:yych=this._charAt(++cursor);{gotoCase=95;continue;};case 89:++cursor;{this.tokenType=null;return cursor;}
|
| +case 91:++cursor;case 92:this.setLexCondition(this._lexConditions.TAG);{return this._stringToken(cursor,true);}
|
| +case 93:yych=this._charAt(++cursor);{gotoCase=92;continue;};case 94:++cursor;yych=this._charAt(cursor);case 95:if(yych<='\f'){if(yych=='\n'){gotoCase=87;continue;};{gotoCase=94;continue;};}else{if(yych<='\r'){gotoCase=87;continue;};if(yych=='\''){gotoCase=93;continue;};{gotoCase=94;continue;};}
|
| +case this.case_TAG:yych=this._charAt(cursor);if(yych<='&'){if(yych<='\r'){if(yych=='\n'){gotoCase=100;continue;};if(yych>='\r'){gotoCase=100;continue;};}else{if(yych<=' '){if(yych>=' '){gotoCase=100;continue;};}else{if(yych=='"'){gotoCase=102;continue;};}}}else{if(yych<='>'){if(yych<=';'){if(yych<='\''){gotoCase=103;continue;};}else{if(yych<='<'){gotoCase=100;continue;};if(yych<='='){gotoCase=104;continue;};{gotoCase=106;continue;};}}else{if(yych<='['){if(yych>='['){gotoCase=100;continue;};}else{if(yych==']'){gotoCase=100;continue;};}}}
|
| +++cursor;yych=this._charAt(cursor);{gotoCase=119;continue;};case 99:{if(this._condition.parseCondition===this._parseConditions.SCRIPT||this._condition.parseCondition===this._parseConditions.STYLE){this.tokenType=null;return cursor;}
|
| +if(this._condition.parseCondition===this._parseConditions.INITIAL){this.tokenType="html-tag";this._setExpectingAttribute();var token=this._line.substring(cursorOnEnter,cursor);if(token==="a")
|
| +this._condition.parseCondition|=this._parseConditions.A_NODE;else if(this._condition.parseCondition&this._parseConditions.A_NODE)
|
| +this._condition.parseCondition^=this._parseConditions.A_NODE;}else if(this._isExpectingAttribute()){var token=this._line.substring(cursorOnEnter,cursor);if(token==="href"||token==="src")
|
| +this._condition.parseCondition|=this._parseConditions.LINKIFY;else if(this._condition.parseCondition|=this._parseConditions.LINKIFY)
|
| +this._condition.parseCondition^=this._parseConditions.LINKIFY;this.tokenType="html-attribute-name";}else if(this._isExpectingAttributeValue())
|
| +this.tokenType=this._attrValueTokenType();else
|
| +this.tokenType=null;return cursor;}
|
| +case 100:++cursor;{this.tokenType=null;return cursor;}
|
| +case 102:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=115;continue;};case 103:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=109;continue;};case 104:++cursor;{if(this._isExpectingAttribute())
|
| +this._setExpectingAttributeValue();this.tokenType=null;return cursor;}
|
| +case 106:++cursor;this.setLexCondition(this._lexConditions.INITIAL);{this.tokenType="html-tag";if(this._condition.parseCondition&this._parseConditions.SCRIPT){this.scriptStarted(cursor);return cursor;}
|
| +if(this._condition.parseCondition&this._parseConditions.STYLE){this.styleSheetStarted(cursor);return cursor;}
|
| +this._condition.parseCondition=this._parseConditions.INITIAL;return cursor;}
|
| +case 108:++cursor;yych=this._charAt(cursor);case 109:if(yych<='\f'){if(yych!='\n'){gotoCase=108;continue;};}else{if(yych<='\r'){gotoCase=110;continue;};if(yych=='\''){gotoCase=112;continue;};{gotoCase=108;continue;};}
|
| +case 110:++cursor;this.setLexCondition(this._lexConditions.SSTRING);{return this._stringToken(cursor);}
|
| +case 112:++cursor;{return this._stringToken(cursor,true);}
|
| +case 114:++cursor;yych=this._charAt(cursor);case 115:if(yych<='\f'){if(yych!='\n'){gotoCase=114;continue;};}else{if(yych<='\r'){gotoCase=116;continue;};if(yych=='"'){gotoCase=112;continue;};{gotoCase=114;continue;};}
|
| +case 116:++cursor;this.setLexCondition(this._lexConditions.DSTRING);{return this._stringToken(cursor);}
|
| +case 118:++cursor;yych=this._charAt(cursor);case 119:if(yych<='"'){if(yych<='\r'){if(yych=='\n'){gotoCase=99;continue;};if(yych<='\f'){gotoCase=118;continue;};{gotoCase=99;continue;};}else{if(yych==' '){gotoCase=99;continue;};if(yych<='!'){gotoCase=118;continue;};{gotoCase=99;continue;};}}else{if(yych<='>'){if(yych=='\''){gotoCase=99;continue;};if(yych<=';'){gotoCase=118;continue;};{gotoCase=99;continue;};}else{if(yych<='['){if(yych<='Z'){gotoCase=118;continue;};{gotoCase=99;continue;};}else{if(yych==']'){gotoCase=99;continue;};{gotoCase=118;continue;};}}}}}},__proto__:WebInspector.SourceTokenizer.prototype}
|
| +WebInspector.SourceJavaScriptTokenizer=function()
|
| +{WebInspector.SourceTokenizer.call(this);this._lexConditions={DIV:0,NODIV:1,COMMENT:2,DSTRING:3,SSTRING:4,REGEX:5};this.case_DIV=1000;this.case_NODIV=1001;this.case_COMMENT=1002;this.case_DSTRING=1003;this.case_SSTRING=1004;this.case_REGEX=1005;this.condition=this.createInitialCondition();}
|
| +WebInspector.SourceJavaScriptTokenizer.Keywords=["null","true","false","break","case","catch","const","default","finally","for","instanceof","new","var","continue","function","return","void","delete","if","this","do","while","else","in","switch","throw","try","typeof","debugger","class","enum","export","extends","import","super","get","set","with"].keySet();WebInspector.SourceJavaScriptTokenizer.GlobalObjectValueProperties={"NaN":"javascript-nan","undefined":"javascript-undef","Infinity":"javascript-inf"};WebInspector.SourceJavaScriptTokenizer.prototype={createInitialCondition:function()
|
| +{return{lexCondition:this._lexConditions.NODIV};},nextToken:function(cursor)
|
| +{var cursorOnEnter=cursor;var gotoCase=1;var YYMARKER;while(1){switch(gotoCase)
|
| +{case 1:var yych;var yyaccept=0;if(this.getLexCondition()<3){if(this.getLexCondition()<1){{gotoCase=this.case_DIV;continue;};}else{if(this.getLexCondition()<2){{gotoCase=this.case_NODIV;continue;};}else{{gotoCase=this.case_COMMENT;continue;};}}}else{if(this.getLexCondition()<4){{gotoCase=this.case_DSTRING;continue;};}else{if(this.getLexCondition()<5){{gotoCase=this.case_SSTRING;continue;};}else{{gotoCase=this.case_REGEX;continue;};}}}
|
| +case this.case_COMMENT:yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=4;continue;};{gotoCase=3;continue;};}else{if(yych<='\r'){gotoCase=4;continue;};if(yych=='*'){gotoCase=6;continue;};{gotoCase=3;continue;};}
|
| +case 2:{this.tokenType="javascript-comment";return cursor;}
|
| +case 3:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=12;continue;};case 4:++cursor;{this.tokenType=null;return cursor;}
|
| +case 6:yyaccept=1;yych=this._charAt(YYMARKER=++cursor);if(yych=='*'){gotoCase=9;continue;};if(yych!='/'){gotoCase=11;continue;};case 7:++cursor;this.setLexCondition(this._lexConditions.NODIV);{this.tokenType="javascript-comment";return cursor;}
|
| +case 9:++cursor;yych=this._charAt(cursor);if(yych=='*'){gotoCase=9;continue;};if(yych=='/'){gotoCase=7;continue;};case 11:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);case 12:if(yych<='\f'){if(yych=='\n'){gotoCase=2;continue;};{gotoCase=11;continue;};}else{if(yych<='\r'){gotoCase=2;continue;};if(yych=='*'){gotoCase=9;continue;};{gotoCase=11;continue;};}
|
| +case this.case_DIV:yych=this._charAt(cursor);if(yych<='9'){if(yych<='\''){if(yych<='"'){if(yych<=String.fromCharCode(0x1F)){gotoCase=15;continue;};if(yych<=' '){gotoCase=17;continue;};if(yych<='!'){gotoCase=19;continue;};{gotoCase=21;continue;};}else{if(yych<='$'){if(yych>='$'){gotoCase=22;continue;};}else{if(yych<='%'){gotoCase=24;continue;};if(yych<='&'){gotoCase=25;continue;};{gotoCase=26;continue;};}}}else{if(yych<=','){if(yych<=')'){if(yych<='('){gotoCase=27;continue;};{gotoCase=28;continue;};}else{if(yych<='*'){gotoCase=30;continue;};if(yych<='+'){gotoCase=31;continue;};{gotoCase=27;continue;};}}else{if(yych<='.'){if(yych<='-'){gotoCase=32;continue;};{gotoCase=33;continue;};}else{if(yych<='/'){gotoCase=34;continue;};if(yych<='0'){gotoCase=36;continue;};{gotoCase=38;continue;};}}}}else{if(yych<='\\'){if(yych<='>'){if(yych<=';'){gotoCase=27;continue;};if(yych<='<'){gotoCase=39;continue;};if(yych<='='){gotoCase=40;continue;};{gotoCase=41;continue;};}else{if(yych<='@'){if(yych<='?'){gotoCase=27;continue;};}else{if(yych<='Z'){gotoCase=22;continue;};if(yych<='['){gotoCase=27;continue;};{gotoCase=42;continue;};}}}else{if(yych<='z'){if(yych<='^'){if(yych<=']'){gotoCase=27;continue;};{gotoCase=43;continue;};}else{if(yych!='`'){gotoCase=22;continue;};}}else{if(yych<='|'){if(yych<='{'){gotoCase=27;continue;};{gotoCase=44;continue;};}else{if(yych<='~'){gotoCase=27;continue;};if(yych>=0x80){gotoCase=22;continue;};}}}}
|
| +case 15:++cursor;case 16:{this.tokenType=null;return cursor;}
|
| +case 17:++cursor;yych=this._charAt(cursor);{gotoCase=119;continue;};case 18:{this.tokenType="whitespace";return cursor;}
|
| +case 19:++cursor;if((yych=this._charAt(cursor))=='='){gotoCase=117;continue;};case 20:this.setLexCondition(this._lexConditions.NODIV);{var token=this._line.charAt(cursorOnEnter);if(token==="{")
|
| +this.tokenType="block-start";else if(token==="}")
|
| +this.tokenType="block-end";else if(token==="(")
|
| +this.tokenType="brace-start";else this.tokenType=null;return cursor;}
|
| +case 21:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych=='\n'){gotoCase=16;continue;};if(yych=='\r'){gotoCase=16;continue;};{gotoCase=109;continue;};case 22:yyaccept=1;yych=this._charAt(YYMARKER=++cursor);{gotoCase=52;continue;};case 23:{var token=this._line.substring(cursorOnEnter,cursor);if(WebInspector.SourceJavaScriptTokenizer.GlobalObjectValueProperties.hasOwnProperty(token))
|
| +this.tokenType=WebInspector.SourceJavaScriptTokenizer.GlobalObjectValueProperties[token];else if(WebInspector.SourceJavaScriptTokenizer.Keywords[token]===true&&token!=="__proto__")
|
| +this.tokenType="javascript-keyword";else
|
| +this.tokenType="javascript-ident";return cursor;}
|
| +case 24:yych=this._charAt(++cursor);if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 25:yych=this._charAt(++cursor);if(yych=='&'){gotoCase=45;continue;};if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 26:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych=='\n'){gotoCase=16;continue;};if(yych=='\r'){gotoCase=16;continue;};{gotoCase=98;continue;};case 27:yych=this._charAt(++cursor);{gotoCase=20;continue;};case 28:++cursor;{this.tokenType="brace-end";return cursor;}
|
| +case 30:yych=this._charAt(++cursor);if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 31:yych=this._charAt(++cursor);if(yych=='+'){gotoCase=45;continue;};if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 32:yych=this._charAt(++cursor);if(yych=='-'){gotoCase=45;continue;};if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 33:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=20;continue;};if(yych<='9'){gotoCase=91;continue;};{gotoCase=20;continue;};case 34:yyaccept=2;yych=this._charAt(YYMARKER=++cursor);if(yych<='.'){if(yych=='*'){gotoCase=80;continue;};}else{if(yych<='/'){gotoCase=82;continue;};if(yych=='='){gotoCase=79;continue;};}
|
| +case 35:this.setLexCondition(this._lexConditions.NODIV);{this.tokenType=null;return cursor;}
|
| +case 36:yyaccept=3;yych=this._charAt(YYMARKER=++cursor);if(yych<='E'){if(yych<='/'){if(yych=='.'){gotoCase=65;continue;};}else{if(yych<='7'){gotoCase=74;continue;};if(yych>='E'){gotoCase=64;continue;};}}else{if(yych<='d'){if(yych=='X'){gotoCase=76;continue;};}else{if(yych<='e'){gotoCase=64;continue;};if(yych=='x'){gotoCase=76;continue;};}}
|
| +case 37:{this.tokenType="javascript-number";return cursor;}
|
| +case 38:yyaccept=3;yych=this._charAt(YYMARKER=++cursor);if(yych<='9'){if(yych=='.'){gotoCase=65;continue;};if(yych<='/'){gotoCase=37;continue;};{gotoCase=62;continue;};}else{if(yych<='E'){if(yych<='D'){gotoCase=37;continue;};{gotoCase=64;continue;};}else{if(yych=='e'){gotoCase=64;continue;};{gotoCase=37;continue;};}}
|
| +case 39:yych=this._charAt(++cursor);if(yych<=';'){gotoCase=20;continue;};if(yych<='<'){gotoCase=61;continue;};if(yych<='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 40:yych=this._charAt(++cursor);if(yych=='='){gotoCase=60;continue;};{gotoCase=20;continue;};case 41:yych=this._charAt(++cursor);if(yych<='<'){gotoCase=20;continue;};if(yych<='='){gotoCase=45;continue;};if(yych<='>'){gotoCase=58;continue;};{gotoCase=20;continue;};case 42:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych=='u'){gotoCase=46;continue;};{gotoCase=16;continue;};case 43:yych=this._charAt(++cursor);if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 44:yych=this._charAt(++cursor);if(yych=='='){gotoCase=45;continue;};if(yych!='|'){gotoCase=20;continue;};case 45:yych=this._charAt(++cursor);{gotoCase=20;continue;};case 46:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych<='9'){gotoCase=48;continue;};}else{if(yych<='F'){gotoCase=48;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych<='f'){gotoCase=48;continue;};}
|
| +case 47:cursor=YYMARKER;if(yyaccept<=1){if(yyaccept<=0){{gotoCase=16;continue;};}else{{gotoCase=23;continue;};}}else{if(yyaccept<=2){{gotoCase=35;continue;};}else{{gotoCase=37;continue;};}}
|
| +case 48:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=49;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 49:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=50;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 50:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=51;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 51:yyaccept=1;YYMARKER=++cursor;yych=this._charAt(cursor);case 52:if(yych<='['){if(yych<='/'){if(yych=='$'){gotoCase=51;continue;};{gotoCase=23;continue;};}else{if(yych<='9'){gotoCase=51;continue;};if(yych<='@'){gotoCase=23;continue;};if(yych<='Z'){gotoCase=51;continue;};{gotoCase=23;continue;};}}else{if(yych<='_'){if(yych<='\\'){gotoCase=53;continue;};if(yych<='^'){gotoCase=23;continue;};{gotoCase=51;continue;};}else{if(yych<='`'){gotoCase=23;continue;};if(yych<='z'){gotoCase=51;continue;};if(yych<=String.fromCharCode(0x7F)){gotoCase=23;continue;};{gotoCase=51;continue;};}}
|
| +case 53:++cursor;yych=this._charAt(cursor);if(yych!='u'){gotoCase=47;continue;};++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=55;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 55:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=56;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 56:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=57;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 57:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych<='9'){gotoCase=51;continue;};{gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=51;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych<='f'){gotoCase=51;continue;};{gotoCase=47;continue;};}
|
| +case 58:yych=this._charAt(++cursor);if(yych<='<'){gotoCase=20;continue;};if(yych<='='){gotoCase=45;continue;};if(yych>='?'){gotoCase=20;continue;};yych=this._charAt(++cursor);if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 60:yych=this._charAt(++cursor);if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 61:yych=this._charAt(++cursor);if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 62:yyaccept=3;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='9'){if(yych=='.'){gotoCase=65;continue;};if(yych<='/'){gotoCase=37;continue;};{gotoCase=62;continue;};}else{if(yych<='E'){if(yych<='D'){gotoCase=37;continue;};}else{if(yych!='e'){gotoCase=37;continue;};}}
|
| +case 64:yych=this._charAt(++cursor);if(yych<=','){if(yych=='+'){gotoCase=71;continue;};{gotoCase=47;continue;};}else{if(yych<='-'){gotoCase=71;continue;};if(yych<='/'){gotoCase=47;continue;};if(yych<='9'){gotoCase=72;continue;};{gotoCase=47;continue;};}
|
| +case 65:yyaccept=3;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='D'){if(yych<='/'){gotoCase=37;continue;};if(yych<='9'){gotoCase=65;continue;};{gotoCase=37;continue;};}else{if(yych<='E'){gotoCase=67;continue;};if(yych!='e'){gotoCase=37;continue;};}
|
| +case 67:yych=this._charAt(++cursor);if(yych<=','){if(yych!='+'){gotoCase=47;continue;};}else{if(yych<='-'){gotoCase=68;continue;};if(yych<='/'){gotoCase=47;continue;};if(yych<='9'){gotoCase=69;continue;};{gotoCase=47;continue;};}
|
| +case 68:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};case 69:++cursor;yych=this._charAt(cursor);if(yych<='/'){gotoCase=37;continue;};if(yych<='9'){gotoCase=69;continue;};{gotoCase=37;continue;};case 71:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};case 72:++cursor;yych=this._charAt(cursor);if(yych<='/'){gotoCase=37;continue;};if(yych<='9'){gotoCase=72;continue;};{gotoCase=37;continue;};case 74:++cursor;yych=this._charAt(cursor);if(yych<='/'){gotoCase=37;continue;};if(yych<='7'){gotoCase=74;continue;};{gotoCase=37;continue;};case 76:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=77;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 77:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=37;continue;};if(yych<='9'){gotoCase=77;continue;};{gotoCase=37;continue;};}else{if(yych<='F'){gotoCase=77;continue;};if(yych<='`'){gotoCase=37;continue;};if(yych<='f'){gotoCase=77;continue;};{gotoCase=37;continue;};}
|
| +case 79:yych=this._charAt(++cursor);{gotoCase=35;continue;};case 80:++cursor;yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=87;continue;};{gotoCase=80;continue;};}else{if(yych<='\r'){gotoCase=87;continue;};if(yych=='*'){gotoCase=85;continue;};{gotoCase=80;continue;};}
|
| +case 82:++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=84;continue;};if(yych!='\r'){gotoCase=82;continue;};case 84:{this.tokenType="javascript-comment";return cursor;}
|
| +case 85:++cursor;yych=this._charAt(cursor);if(yych=='*'){gotoCase=85;continue;};if(yych=='/'){gotoCase=89;continue;};{gotoCase=80;continue;};case 87:++cursor;this.setLexCondition(this._lexConditions.COMMENT);{this.tokenType="javascript-comment";return cursor;}
|
| +case 89:++cursor;{this.tokenType="javascript-comment";return cursor;}
|
| +case 91:yyaccept=3;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='D'){if(yych<='/'){gotoCase=37;continue;};if(yych<='9'){gotoCase=91;continue;};{gotoCase=37;continue;};}else{if(yych<='E'){gotoCase=93;continue;};if(yych!='e'){gotoCase=37;continue;};}
|
| +case 93:yych=this._charAt(++cursor);if(yych<=','){if(yych!='+'){gotoCase=47;continue;};}else{if(yych<='-'){gotoCase=94;continue;};if(yych<='/'){gotoCase=47;continue;};if(yych<='9'){gotoCase=95;continue;};{gotoCase=47;continue;};}
|
| +case 94:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};case 95:++cursor;yych=this._charAt(cursor);if(yych<='/'){gotoCase=37;continue;};if(yych<='9'){gotoCase=95;continue;};{gotoCase=37;continue;};case 97:++cursor;yych=this._charAt(cursor);case 98:if(yych<='\r'){if(yych=='\n'){gotoCase=47;continue;};if(yych<='\f'){gotoCase=97;continue;};{gotoCase=47;continue;};}else{if(yych<='\''){if(yych<='&'){gotoCase=97;continue;};{gotoCase=100;continue;};}else{if(yych!='\\'){gotoCase=97;continue;};}}
|
| +++cursor;yych=this._charAt(cursor);if(yych<='a'){if(yych<='!'){if(yych<='\n'){if(yych<='\t'){gotoCase=47;continue;};{gotoCase=103;continue;};}else{if(yych=='\r'){gotoCase=103;continue;};{gotoCase=47;continue;};}}else{if(yych<='\''){if(yych<='"'){gotoCase=97;continue;};if(yych<='&'){gotoCase=47;continue;};{gotoCase=97;continue;};}else{if(yych=='\\'){gotoCase=97;continue;};{gotoCase=47;continue;};}}}else{if(yych<='q'){if(yych<='f'){if(yych<='b'){gotoCase=97;continue;};if(yych<='e'){gotoCase=47;continue;};{gotoCase=97;continue;};}else{if(yych=='n'){gotoCase=97;continue;};{gotoCase=47;continue;};}}else{if(yych<='t'){if(yych=='s'){gotoCase=47;continue;};{gotoCase=97;continue;};}else{if(yych<='u'){gotoCase=102;continue;};if(yych<='v'){gotoCase=97;continue;};{gotoCase=47;continue;};}}}
|
| +case 100:++cursor;{this.tokenType="javascript-string";return cursor;}
|
| +case 102:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych<='9'){gotoCase=105;continue;};{gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=105;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych<='f'){gotoCase=105;continue;};{gotoCase=47;continue;};}
|
| +case 103:++cursor;this.setLexCondition(this._lexConditions.SSTRING);{this.tokenType="javascript-string";return cursor;}
|
| +case 105:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=106;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 106:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=107;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 107:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych<='9'){gotoCase=97;continue;};{gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=97;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych<='f'){gotoCase=97;continue;};{gotoCase=47;continue;};}
|
| +case 108:++cursor;yych=this._charAt(cursor);case 109:if(yych<='\r'){if(yych=='\n'){gotoCase=47;continue;};if(yych<='\f'){gotoCase=108;continue;};{gotoCase=47;continue;};}else{if(yych<='"'){if(yych<='!'){gotoCase=108;continue;};{gotoCase=100;continue;};}else{if(yych!='\\'){gotoCase=108;continue;};}}
|
| +++cursor;yych=this._charAt(cursor);if(yych<='a'){if(yych<='!'){if(yych<='\n'){if(yych<='\t'){gotoCase=47;continue;};{gotoCase=112;continue;};}else{if(yych=='\r'){gotoCase=112;continue;};{gotoCase=47;continue;};}}else{if(yych<='\''){if(yych<='"'){gotoCase=108;continue;};if(yych<='&'){gotoCase=47;continue;};{gotoCase=108;continue;};}else{if(yych=='\\'){gotoCase=108;continue;};{gotoCase=47;continue;};}}}else{if(yych<='q'){if(yych<='f'){if(yych<='b'){gotoCase=108;continue;};if(yych<='e'){gotoCase=47;continue;};{gotoCase=108;continue;};}else{if(yych=='n'){gotoCase=108;continue;};{gotoCase=47;continue;};}}else{if(yych<='t'){if(yych=='s'){gotoCase=47;continue;};{gotoCase=108;continue;};}else{if(yych<='u'){gotoCase=111;continue;};if(yych<='v'){gotoCase=108;continue;};{gotoCase=47;continue;};}}}
|
| +case 111:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych<='9'){gotoCase=114;continue;};{gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=114;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych<='f'){gotoCase=114;continue;};{gotoCase=47;continue;};}
|
| +case 112:++cursor;this.setLexCondition(this._lexConditions.DSTRING);{this.tokenType="javascript-string";return cursor;}
|
| +case 114:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=115;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 115:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych>=':'){gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=116;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych>='g'){gotoCase=47;continue;};}
|
| +case 116:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=47;continue;};if(yych<='9'){gotoCase=108;continue;};{gotoCase=47;continue;};}else{if(yych<='F'){gotoCase=108;continue;};if(yych<='`'){gotoCase=47;continue;};if(yych<='f'){gotoCase=108;continue;};{gotoCase=47;continue;};}
|
| +case 117:yych=this._charAt(++cursor);if(yych=='='){gotoCase=45;continue;};{gotoCase=20;continue;};case 118:++cursor;yych=this._charAt(cursor);case 119:if(yych==' '){gotoCase=118;continue;};{gotoCase=18;continue;};case this.case_DSTRING:yych=this._charAt(cursor);if(yych<='\r'){if(yych=='\n'){gotoCase=124;continue;};if(yych<='\f'){gotoCase=123;continue;};{gotoCase=124;continue;};}else{if(yych<='"'){if(yych<='!'){gotoCase=123;continue;};{gotoCase=126;continue;};}else{if(yych=='\\'){gotoCase=128;continue;};{gotoCase=123;continue;};}}
|
| +case 122:{this.tokenType="javascript-string";return cursor;}
|
| +case 123:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=130;continue;};case 124:++cursor;case 125:{this.tokenType=null;return cursor;}
|
| +case 126:++cursor;case 127:this.setLexCondition(this._lexConditions.NODIV);{this.tokenType="javascript-string";return cursor;}
|
| +case 128:yyaccept=1;yych=this._charAt(YYMARKER=++cursor);if(yych<='e'){if(yych<='\''){if(yych=='"'){gotoCase=129;continue;};if(yych<='&'){gotoCase=125;continue;};}else{if(yych<='\\'){if(yych<='['){gotoCase=125;continue;};}else{if(yych!='b'){gotoCase=125;continue;};}}}else{if(yych<='r'){if(yych<='m'){if(yych>='g'){gotoCase=125;continue;};}else{if(yych<='n'){gotoCase=129;continue;};if(yych<='q'){gotoCase=125;continue;};}}else{if(yych<='t'){if(yych<='s'){gotoCase=125;continue;};}else{if(yych<='u'){gotoCase=131;continue;};if(yych>='w'){gotoCase=125;continue;};}}}
|
| +case 129:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);case 130:if(yych<='\r'){if(yych=='\n'){gotoCase=122;continue;};if(yych<='\f'){gotoCase=129;continue;};{gotoCase=122;continue;};}else{if(yych<='"'){if(yych<='!'){gotoCase=129;continue;};{gotoCase=137;continue;};}else{if(yych=='\\'){gotoCase=136;continue;};{gotoCase=129;continue;};}}
|
| +case 131:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=132;continue;};if(yych<='9'){gotoCase=133;continue;};}else{if(yych<='F'){gotoCase=133;continue;};if(yych<='`'){gotoCase=132;continue;};if(yych<='f'){gotoCase=133;continue;};}
|
| +case 132:cursor=YYMARKER;if(yyaccept<=0){{gotoCase=122;continue;};}else{{gotoCase=125;continue;};}
|
| +case 133:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=132;continue;};if(yych>=':'){gotoCase=132;continue;};}else{if(yych<='F'){gotoCase=134;continue;};if(yych<='`'){gotoCase=132;continue;};if(yych>='g'){gotoCase=132;continue;};}
|
| +case 134:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=132;continue;};if(yych>=':'){gotoCase=132;continue;};}else{if(yych<='F'){gotoCase=135;continue;};if(yych<='`'){gotoCase=132;continue;};if(yych>='g'){gotoCase=132;continue;};}
|
| +case 135:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=132;continue;};if(yych<='9'){gotoCase=129;continue;};{gotoCase=132;continue;};}else{if(yych<='F'){gotoCase=129;continue;};if(yych<='`'){gotoCase=132;continue;};if(yych<='f'){gotoCase=129;continue;};{gotoCase=132;continue;};}
|
| +case 136:++cursor;yych=this._charAt(cursor);if(yych<='e'){if(yych<='\''){if(yych=='"'){gotoCase=129;continue;};if(yych<='&'){gotoCase=132;continue;};{gotoCase=129;continue;};}else{if(yych<='\\'){if(yych<='['){gotoCase=132;continue;};{gotoCase=129;continue;};}else{if(yych=='b'){gotoCase=129;continue;};{gotoCase=132;continue;};}}}else{if(yych<='r'){if(yych<='m'){if(yych<='f'){gotoCase=129;continue;};{gotoCase=132;continue;};}else{if(yych<='n'){gotoCase=129;continue;};if(yych<='q'){gotoCase=132;continue;};{gotoCase=129;continue;};}}else{if(yych<='t'){if(yych<='s'){gotoCase=132;continue;};{gotoCase=129;continue;};}else{if(yych<='u'){gotoCase=131;continue;};if(yych<='v'){gotoCase=129;continue;};{gotoCase=132;continue;};}}}
|
| +case 137:++cursor;yych=this._charAt(cursor);{gotoCase=127;continue;};case this.case_NODIV:yych=this._charAt(cursor);if(yych<='9'){if(yych<='\''){if(yych<='"'){if(yych<=String.fromCharCode(0x1F)){gotoCase=140;continue;};if(yych<=' '){gotoCase=142;continue;};if(yych<='!'){gotoCase=144;continue;};{gotoCase=146;continue;};}else{if(yych<='$'){if(yych>='$'){gotoCase=147;continue;};}else{if(yych<='%'){gotoCase=149;continue;};if(yych<='&'){gotoCase=150;continue;};{gotoCase=151;continue;};}}}else{if(yych<=','){if(yych<=')'){if(yych<='('){gotoCase=152;continue;};{gotoCase=153;continue;};}else{if(yych<='*'){gotoCase=155;continue;};if(yych<='+'){gotoCase=156;continue;};{gotoCase=152;continue;};}}else{if(yych<='.'){if(yych<='-'){gotoCase=157;continue;};{gotoCase=158;continue;};}else{if(yych<='/'){gotoCase=159;continue;};if(yych<='0'){gotoCase=160;continue;};{gotoCase=162;continue;};}}}}else{if(yych<='\\'){if(yych<='>'){if(yych<=';'){gotoCase=152;continue;};if(yych<='<'){gotoCase=163;continue;};if(yych<='='){gotoCase=164;continue;};{gotoCase=165;continue;};}else{if(yych<='@'){if(yych<='?'){gotoCase=152;continue;};}else{if(yych<='Z'){gotoCase=147;continue;};if(yych<='['){gotoCase=152;continue;};{gotoCase=166;continue;};}}}else{if(yych<='z'){if(yych<='^'){if(yych<=']'){gotoCase=152;continue;};{gotoCase=167;continue;};}else{if(yych!='`'){gotoCase=147;continue;};}}else{if(yych<='|'){if(yych<='{'){gotoCase=152;continue;};{gotoCase=168;continue;};}else{if(yych<='~'){gotoCase=152;continue;};if(yych>=0x80){gotoCase=147;continue;};}}}}
|
| +case 140:++cursor;case 141:{this.tokenType=null;return cursor;}
|
| +case 142:++cursor;yych=this._charAt(cursor);{gotoCase=268;continue;};case 143:{this.tokenType="whitespace";return cursor;}
|
| +case 144:++cursor;if((yych=this._charAt(cursor))=='='){gotoCase=266;continue;};case 145:{var token=this._line.charAt(cursorOnEnter);if(token==="{")
|
| +this.tokenType="block-start";else if(token==="}")
|
| +this.tokenType="block-end";else if(token==="(")
|
| +this.tokenType="brace-start";else this.tokenType=null;return cursor;}
|
| +case 146:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych=='\n'){gotoCase=141;continue;};if(yych=='\r'){gotoCase=141;continue;};{gotoCase=258;continue;};case 147:yyaccept=1;yych=this._charAt(YYMARKER=++cursor);{gotoCase=176;continue;};case 148:this.setLexCondition(this._lexConditions.DIV);{var token=this._line.substring(cursorOnEnter,cursor);if(WebInspector.SourceJavaScriptTokenizer.GlobalObjectValueProperties.hasOwnProperty(token))
|
| +this.tokenType=WebInspector.SourceJavaScriptTokenizer.GlobalObjectValueProperties[token];else if(WebInspector.SourceJavaScriptTokenizer.Keywords[token]===true&&token!=="__proto__")
|
| +this.tokenType="javascript-keyword";else
|
| +this.tokenType="javascript-ident";return cursor;}
|
| +case 149:yych=this._charAt(++cursor);if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 150:yych=this._charAt(++cursor);if(yych=='&'){gotoCase=169;continue;};if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 151:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych=='\n'){gotoCase=141;continue;};if(yych=='\r'){gotoCase=141;continue;};{gotoCase=247;continue;};case 152:yych=this._charAt(++cursor);{gotoCase=145;continue;};case 153:++cursor;this.setLexCondition(this._lexConditions.DIV);{this.tokenType="brace-end";return cursor;}
|
| +case 155:yych=this._charAt(++cursor);if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 156:yych=this._charAt(++cursor);if(yych=='+'){gotoCase=169;continue;};if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 157:yych=this._charAt(++cursor);if(yych=='-'){gotoCase=169;continue;};if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 158:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=145;continue;};if(yych<='9'){gotoCase=240;continue;};{gotoCase=145;continue;};case 159:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych<='*'){if(yych<='\f'){if(yych=='\n'){gotoCase=141;continue;};{gotoCase=203;continue;};}else{if(yych<='\r'){gotoCase=141;continue;};if(yych<=')'){gotoCase=203;continue;};{gotoCase=208;continue;};}}else{if(yych<='Z'){if(yych=='/'){gotoCase=210;continue;};{gotoCase=203;continue;};}else{if(yych<='['){gotoCase=206;continue;};if(yych<='\\'){gotoCase=205;continue;};if(yych<=']'){gotoCase=141;continue;};{gotoCase=203;continue;};}}
|
| +case 160:yyaccept=2;yych=this._charAt(YYMARKER=++cursor);if(yych<='E'){if(yych<='/'){if(yych=='.'){gotoCase=189;continue;};}else{if(yych<='7'){gotoCase=198;continue;};if(yych>='E'){gotoCase=188;continue;};}}else{if(yych<='d'){if(yych=='X'){gotoCase=200;continue;};}else{if(yych<='e'){gotoCase=188;continue;};if(yych=='x'){gotoCase=200;continue;};}}
|
| +case 161:this.setLexCondition(this._lexConditions.DIV);{this.tokenType="javascript-number";return cursor;}
|
| +case 162:yyaccept=2;yych=this._charAt(YYMARKER=++cursor);if(yych<='9'){if(yych=='.'){gotoCase=189;continue;};if(yych<='/'){gotoCase=161;continue;};{gotoCase=186;continue;};}else{if(yych<='E'){if(yych<='D'){gotoCase=161;continue;};{gotoCase=188;continue;};}else{if(yych=='e'){gotoCase=188;continue;};{gotoCase=161;continue;};}}
|
| +case 163:yych=this._charAt(++cursor);if(yych<=';'){gotoCase=145;continue;};if(yych<='<'){gotoCase=185;continue;};if(yych<='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 164:yych=this._charAt(++cursor);if(yych=='='){gotoCase=184;continue;};{gotoCase=145;continue;};case 165:yych=this._charAt(++cursor);if(yych<='<'){gotoCase=145;continue;};if(yych<='='){gotoCase=169;continue;};if(yych<='>'){gotoCase=182;continue;};{gotoCase=145;continue;};case 166:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);if(yych=='u'){gotoCase=170;continue;};{gotoCase=141;continue;};case 167:yych=this._charAt(++cursor);if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 168:yych=this._charAt(++cursor);if(yych=='='){gotoCase=169;continue;};if(yych!='|'){gotoCase=145;continue;};case 169:yych=this._charAt(++cursor);{gotoCase=145;continue;};case 170:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych<='9'){gotoCase=172;continue;};}else{if(yych<='F'){gotoCase=172;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych<='f'){gotoCase=172;continue;};}
|
| +case 171:cursor=YYMARKER;if(yyaccept<=1){if(yyaccept<=0){{gotoCase=141;continue;};}else{{gotoCase=148;continue;};}}else{if(yyaccept<=2){{gotoCase=161;continue;};}else{{gotoCase=223;continue;};}}
|
| +case 172:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=173;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 173:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=174;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 174:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=175;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 175:yyaccept=1;YYMARKER=++cursor;yych=this._charAt(cursor);case 176:if(yych<='['){if(yych<='/'){if(yych=='$'){gotoCase=175;continue;};{gotoCase=148;continue;};}else{if(yych<='9'){gotoCase=175;continue;};if(yych<='@'){gotoCase=148;continue;};if(yych<='Z'){gotoCase=175;continue;};{gotoCase=148;continue;};}}else{if(yych<='_'){if(yych<='\\'){gotoCase=177;continue;};if(yych<='^'){gotoCase=148;continue;};{gotoCase=175;continue;};}else{if(yych<='`'){gotoCase=148;continue;};if(yych<='z'){gotoCase=175;continue;};if(yych<=String.fromCharCode(0x7F)){gotoCase=148;continue;};{gotoCase=175;continue;};}}
|
| +case 177:++cursor;yych=this._charAt(cursor);if(yych!='u'){gotoCase=171;continue;};++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=179;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 179:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=180;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 180:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=181;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 181:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych<='9'){gotoCase=175;continue;};{gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=175;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych<='f'){gotoCase=175;continue;};{gotoCase=171;continue;};}
|
| +case 182:yych=this._charAt(++cursor);if(yych<='<'){gotoCase=145;continue;};if(yych<='='){gotoCase=169;continue;};if(yych>='?'){gotoCase=145;continue;};yych=this._charAt(++cursor);if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 184:yych=this._charAt(++cursor);if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 185:yych=this._charAt(++cursor);if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 186:yyaccept=2;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='9'){if(yych=='.'){gotoCase=189;continue;};if(yych<='/'){gotoCase=161;continue;};{gotoCase=186;continue;};}else{if(yych<='E'){if(yych<='D'){gotoCase=161;continue;};}else{if(yych!='e'){gotoCase=161;continue;};}}
|
| +case 188:yych=this._charAt(++cursor);if(yych<=','){if(yych=='+'){gotoCase=195;continue;};{gotoCase=171;continue;};}else{if(yych<='-'){gotoCase=195;continue;};if(yych<='/'){gotoCase=171;continue;};if(yych<='9'){gotoCase=196;continue;};{gotoCase=171;continue;};}
|
| +case 189:yyaccept=2;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='D'){if(yych<='/'){gotoCase=161;continue;};if(yych<='9'){gotoCase=189;continue;};{gotoCase=161;continue;};}else{if(yych<='E'){gotoCase=191;continue;};if(yych!='e'){gotoCase=161;continue;};}
|
| +case 191:yych=this._charAt(++cursor);if(yych<=','){if(yych!='+'){gotoCase=171;continue;};}else{if(yych<='-'){gotoCase=192;continue;};if(yych<='/'){gotoCase=171;continue;};if(yych<='9'){gotoCase=193;continue;};{gotoCase=171;continue;};}
|
| +case 192:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};case 193:++cursor;yych=this._charAt(cursor);if(yych<='/'){gotoCase=161;continue;};if(yych<='9'){gotoCase=193;continue;};{gotoCase=161;continue;};case 195:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};case 196:++cursor;yych=this._charAt(cursor);if(yych<='/'){gotoCase=161;continue;};if(yych<='9'){gotoCase=196;continue;};{gotoCase=161;continue;};case 198:++cursor;yych=this._charAt(cursor);if(yych<='/'){gotoCase=161;continue;};if(yych<='7'){gotoCase=198;continue;};{gotoCase=161;continue;};case 200:yych=this._charAt(++cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=201;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 201:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=161;continue;};if(yych<='9'){gotoCase=201;continue;};{gotoCase=161;continue;};}else{if(yych<='F'){gotoCase=201;continue;};if(yych<='`'){gotoCase=161;continue;};if(yych<='f'){gotoCase=201;continue;};{gotoCase=161;continue;};}
|
| +case 203:++cursor;yych=this._charAt(cursor);if(yych<='.'){if(yych<='\n'){if(yych<='\t'){gotoCase=203;continue;};{gotoCase=171;continue;};}else{if(yych=='\r'){gotoCase=171;continue;};{gotoCase=203;continue;};}}else{if(yych<='['){if(yych<='/'){gotoCase=226;continue;};if(yych<='Z'){gotoCase=203;continue;};{gotoCase=234;continue;};}else{if(yych<='\\'){gotoCase=233;continue;};if(yych<=']'){gotoCase=171;continue;};{gotoCase=203;continue;};}}
|
| +case 205:yych=this._charAt(++cursor);if(yych=='\n'){gotoCase=171;continue;};if(yych=='\r'){gotoCase=171;continue;};{gotoCase=203;continue;};case 206:++cursor;yych=this._charAt(cursor);if(yych<='*'){if(yych<='\f'){if(yych=='\n'){gotoCase=171;continue;};{gotoCase=206;continue;};}else{if(yych<='\r'){gotoCase=171;continue;};if(yych<=')'){gotoCase=206;continue;};{gotoCase=171;continue;};}}else{if(yych<='['){if(yych=='/'){gotoCase=171;continue;};{gotoCase=206;continue;};}else{if(yych<='\\'){gotoCase=221;continue;};if(yych<=']'){gotoCase=219;continue;};{gotoCase=206;continue;};}}
|
| +case 208:++cursor;yych=this._charAt(cursor);if(yych<='\f'){if(yych=='\n'){gotoCase=215;continue;};{gotoCase=208;continue;};}else{if(yych<='\r'){gotoCase=215;continue;};if(yych=='*'){gotoCase=213;continue;};{gotoCase=208;continue;};}
|
| +case 210:++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=212;continue;};if(yych!='\r'){gotoCase=210;continue;};case 212:{this.tokenType="javascript-comment";return cursor;}
|
| +case 213:++cursor;yych=this._charAt(cursor);if(yych=='*'){gotoCase=213;continue;};if(yych=='/'){gotoCase=217;continue;};{gotoCase=208;continue;};case 215:++cursor;this.setLexCondition(this._lexConditions.COMMENT);{this.tokenType="javascript-comment";return cursor;}
|
| +case 217:++cursor;{this.tokenType="javascript-comment";return cursor;}
|
| +case 219:++cursor;yych=this._charAt(cursor);if(yych<='*'){if(yych<='\f'){if(yych=='\n'){gotoCase=171;continue;};{gotoCase=219;continue;};}else{if(yych<='\r'){gotoCase=171;continue;};if(yych<=')'){gotoCase=219;continue;};{gotoCase=203;continue;};}}else{if(yych<='Z'){if(yych=='/'){gotoCase=226;continue;};{gotoCase=219;continue;};}else{if(yych<='['){gotoCase=224;continue;};if(yych<='\\'){gotoCase=222;continue;};{gotoCase=219;continue;};}}
|
| +case 221:++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=171;continue;};if(yych=='\r'){gotoCase=171;continue;};{gotoCase=206;continue;};case 222:yyaccept=3;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=223;continue;};if(yych!='\r'){gotoCase=219;continue;};case 223:this.setLexCondition(this._lexConditions.REGEX);{this.tokenType="javascript-regexp";return cursor;}
|
| +case 224:++cursor;yych=this._charAt(cursor);if(yych<='*'){if(yych<='\f'){if(yych=='\n'){gotoCase=171;continue;};{gotoCase=224;continue;};}else{if(yych<='\r'){gotoCase=171;continue;};if(yych<=')'){gotoCase=224;continue;};{gotoCase=171;continue;};}}else{if(yych<='['){if(yych=='/'){gotoCase=171;continue;};{gotoCase=224;continue;};}else{if(yych<='\\'){gotoCase=231;continue;};if(yych<=']'){gotoCase=229;continue;};{gotoCase=224;continue;};}}
|
| +case 226:++cursor;yych=this._charAt(cursor);if(yych<='h'){if(yych=='g'){gotoCase=226;continue;};}else{if(yych<='i'){gotoCase=226;continue;};if(yych=='m'){gotoCase=226;continue;};}
|
| +{this.tokenType="javascript-regexp";return cursor;}
|
| +case 229:++cursor;yych=this._charAt(cursor);if(yych<='*'){if(yych<='\f'){if(yych=='\n'){gotoCase=171;continue;};{gotoCase=229;continue;};}else{if(yych<='\r'){gotoCase=171;continue;};if(yych<=')'){gotoCase=229;continue;};{gotoCase=203;continue;};}}else{if(yych<='Z'){if(yych=='/'){gotoCase=226;continue;};{gotoCase=229;continue;};}else{if(yych<='['){gotoCase=224;continue;};if(yych<='\\'){gotoCase=232;continue;};{gotoCase=229;continue;};}}
|
| +case 231:++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=171;continue;};if(yych=='\r'){gotoCase=171;continue;};{gotoCase=224;continue;};case 232:yyaccept=3;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=223;continue;};if(yych=='\r'){gotoCase=223;continue;};{gotoCase=229;continue;};case 233:yyaccept=3;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=223;continue;};if(yych=='\r'){gotoCase=223;continue;};{gotoCase=203;continue;};case 234:++cursor;yych=this._charAt(cursor);if(yych<='*'){if(yych<='\f'){if(yych=='\n'){gotoCase=171;continue;};{gotoCase=234;continue;};}else{if(yych<='\r'){gotoCase=171;continue;};if(yych<=')'){gotoCase=234;continue;};{gotoCase=171;continue;};}}else{if(yych<='['){if(yych=='/'){gotoCase=171;continue;};{gotoCase=234;continue;};}else{if(yych<='\\'){gotoCase=238;continue;};if(yych>='^'){gotoCase=234;continue;};}}
|
| +case 236:++cursor;yych=this._charAt(cursor);if(yych<='*'){if(yych<='\f'){if(yych=='\n'){gotoCase=171;continue;};{gotoCase=236;continue;};}else{if(yych<='\r'){gotoCase=171;continue;};if(yych<=')'){gotoCase=236;continue;};{gotoCase=203;continue;};}}else{if(yych<='Z'){if(yych=='/'){gotoCase=226;continue;};{gotoCase=236;continue;};}else{if(yych<='['){gotoCase=234;continue;};if(yych<='\\'){gotoCase=239;continue;};{gotoCase=236;continue;};}}
|
| +case 238:++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=171;continue;};if(yych=='\r'){gotoCase=171;continue;};{gotoCase=234;continue;};case 239:yyaccept=3;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=223;continue;};if(yych=='\r'){gotoCase=223;continue;};{gotoCase=236;continue;};case 240:yyaccept=2;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='D'){if(yych<='/'){gotoCase=161;continue;};if(yych<='9'){gotoCase=240;continue;};{gotoCase=161;continue;};}else{if(yych<='E'){gotoCase=242;continue;};if(yych!='e'){gotoCase=161;continue;};}
|
| +case 242:yych=this._charAt(++cursor);if(yych<=','){if(yych!='+'){gotoCase=171;continue;};}else{if(yych<='-'){gotoCase=243;continue;};if(yych<='/'){gotoCase=171;continue;};if(yych<='9'){gotoCase=244;continue;};{gotoCase=171;continue;};}
|
| +case 243:yych=this._charAt(++cursor);if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};case 244:++cursor;yych=this._charAt(cursor);if(yych<='/'){gotoCase=161;continue;};if(yych<='9'){gotoCase=244;continue;};{gotoCase=161;continue;};case 246:++cursor;yych=this._charAt(cursor);case 247:if(yych<='\r'){if(yych=='\n'){gotoCase=171;continue;};if(yych<='\f'){gotoCase=246;continue;};{gotoCase=171;continue;};}else{if(yych<='\''){if(yych<='&'){gotoCase=246;continue;};{gotoCase=249;continue;};}else{if(yych!='\\'){gotoCase=246;continue;};}}
|
| +++cursor;yych=this._charAt(cursor);if(yych<='a'){if(yych<='!'){if(yych<='\n'){if(yych<='\t'){gotoCase=171;continue;};{gotoCase=252;continue;};}else{if(yych=='\r'){gotoCase=252;continue;};{gotoCase=171;continue;};}}else{if(yych<='\''){if(yych<='"'){gotoCase=246;continue;};if(yych<='&'){gotoCase=171;continue;};{gotoCase=246;continue;};}else{if(yych=='\\'){gotoCase=246;continue;};{gotoCase=171;continue;};}}}else{if(yych<='q'){if(yych<='f'){if(yych<='b'){gotoCase=246;continue;};if(yych<='e'){gotoCase=171;continue;};{gotoCase=246;continue;};}else{if(yych=='n'){gotoCase=246;continue;};{gotoCase=171;continue;};}}else{if(yych<='t'){if(yych=='s'){gotoCase=171;continue;};{gotoCase=246;continue;};}else{if(yych<='u'){gotoCase=251;continue;};if(yych<='v'){gotoCase=246;continue;};{gotoCase=171;continue;};}}}
|
| +case 249:++cursor;{this.tokenType="javascript-string";return cursor;}
|
| +case 251:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych<='9'){gotoCase=254;continue;};{gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=254;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych<='f'){gotoCase=254;continue;};{gotoCase=171;continue;};}
|
| +case 252:++cursor;this.setLexCondition(this._lexConditions.SSTRING);{this.tokenType="javascript-string";return cursor;}
|
| +case 254:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=255;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 255:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=256;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 256:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych<='9'){gotoCase=246;continue;};{gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=246;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych<='f'){gotoCase=246;continue;};{gotoCase=171;continue;};}
|
| +case 257:++cursor;yych=this._charAt(cursor);case 258:if(yych<='\r'){if(yych=='\n'){gotoCase=171;continue;};if(yych<='\f'){gotoCase=257;continue;};{gotoCase=171;continue;};}else{if(yych<='"'){if(yych<='!'){gotoCase=257;continue;};{gotoCase=249;continue;};}else{if(yych!='\\'){gotoCase=257;continue;};}}
|
| +++cursor;yych=this._charAt(cursor);if(yych<='a'){if(yych<='!'){if(yych<='\n'){if(yych<='\t'){gotoCase=171;continue;};{gotoCase=261;continue;};}else{if(yych=='\r'){gotoCase=261;continue;};{gotoCase=171;continue;};}}else{if(yych<='\''){if(yych<='"'){gotoCase=257;continue;};if(yych<='&'){gotoCase=171;continue;};{gotoCase=257;continue;};}else{if(yych=='\\'){gotoCase=257;continue;};{gotoCase=171;continue;};}}}else{if(yych<='q'){if(yych<='f'){if(yych<='b'){gotoCase=257;continue;};if(yych<='e'){gotoCase=171;continue;};{gotoCase=257;continue;};}else{if(yych=='n'){gotoCase=257;continue;};{gotoCase=171;continue;};}}else{if(yych<='t'){if(yych=='s'){gotoCase=171;continue;};{gotoCase=257;continue;};}else{if(yych<='u'){gotoCase=260;continue;};if(yych<='v'){gotoCase=257;continue;};{gotoCase=171;continue;};}}}
|
| +case 260:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych<='9'){gotoCase=263;continue;};{gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=263;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych<='f'){gotoCase=263;continue;};{gotoCase=171;continue;};}
|
| +case 261:++cursor;this.setLexCondition(this._lexConditions.DSTRING);{this.tokenType="javascript-string";return cursor;}
|
| +case 263:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=264;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 264:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych>=':'){gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=265;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych>='g'){gotoCase=171;continue;};}
|
| +case 265:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=171;continue;};if(yych<='9'){gotoCase=257;continue;};{gotoCase=171;continue;};}else{if(yych<='F'){gotoCase=257;continue;};if(yych<='`'){gotoCase=171;continue;};if(yych<='f'){gotoCase=257;continue;};{gotoCase=171;continue;};}
|
| +case 266:yych=this._charAt(++cursor);if(yych=='='){gotoCase=169;continue;};{gotoCase=145;continue;};case 267:++cursor;yych=this._charAt(cursor);case 268:if(yych==' '){gotoCase=267;continue;};{gotoCase=143;continue;};case this.case_REGEX:yych=this._charAt(cursor);if(yych<='.'){if(yych<='\n'){if(yych<='\t'){gotoCase=272;continue;};{gotoCase=273;continue;};}else{if(yych=='\r'){gotoCase=273;continue;};{gotoCase=272;continue;};}}else{if(yych<='['){if(yych<='/'){gotoCase=275;continue;};if(yych<='Z'){gotoCase=272;continue;};{gotoCase=277;continue;};}else{if(yych<='\\'){gotoCase=278;continue;};if(yych<=']'){gotoCase=273;continue;};{gotoCase=272;continue;};}}
|
| +case 271:{this.tokenType="javascript-regexp";return cursor;}
|
| +case 272:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=280;continue;};case 273:++cursor;case 274:{this.tokenType=null;return cursor;}
|
| +case 275:++cursor;yych=this._charAt(cursor);{gotoCase=286;continue;};case 276:this.setLexCondition(this._lexConditions.NODIV);{this.tokenType="javascript-regexp";return cursor;}
|
| +case 277:yyaccept=1;yych=this._charAt(YYMARKER=++cursor);if(yych<='\r'){if(yych=='\n'){gotoCase=274;continue;};if(yych<='\f'){gotoCase=284;continue;};{gotoCase=274;continue;};}else{if(yych<='*'){if(yych<=')'){gotoCase=284;continue;};{gotoCase=274;continue;};}else{if(yych=='/'){gotoCase=274;continue;};{gotoCase=284;continue;};}}
|
| +case 278:yych=this._charAt(++cursor);if(yych=='\n'){gotoCase=274;continue;};if(yych=='\r'){gotoCase=274;continue;};case 279:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);case 280:if(yych<='.'){if(yych<='\n'){if(yych<='\t'){gotoCase=279;continue;};{gotoCase=271;continue;};}else{if(yych=='\r'){gotoCase=271;continue;};{gotoCase=279;continue;};}}else{if(yych<='['){if(yych<='/'){gotoCase=285;continue;};if(yych<='Z'){gotoCase=279;continue;};{gotoCase=283;continue;};}else{if(yych<='\\'){gotoCase=281;continue;};if(yych<=']'){gotoCase=271;continue;};{gotoCase=279;continue;};}}
|
| +case 281:++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=282;continue;};if(yych!='\r'){gotoCase=279;continue;};case 282:cursor=YYMARKER;if(yyaccept<=0){{gotoCase=271;continue;};}else{{gotoCase=274;continue;};}
|
| +case 283:++cursor;yych=this._charAt(cursor);case 284:if(yych<='*'){if(yych<='\f'){if(yych=='\n'){gotoCase=282;continue;};{gotoCase=283;continue;};}else{if(yych<='\r'){gotoCase=282;continue;};if(yych<=')'){gotoCase=283;continue;};{gotoCase=282;continue;};}}else{if(yych<='['){if(yych=='/'){gotoCase=282;continue;};{gotoCase=283;continue;};}else{if(yych<='\\'){gotoCase=289;continue;};if(yych<=']'){gotoCase=287;continue;};{gotoCase=283;continue;};}}
|
| +case 285:++cursor;yych=this._charAt(cursor);case 286:if(yych<='h'){if(yych=='g'){gotoCase=285;continue;};{gotoCase=276;continue;};}else{if(yych<='i'){gotoCase=285;continue;};if(yych=='m'){gotoCase=285;continue;};{gotoCase=276;continue;};}
|
| +case 287:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);if(yych<='*'){if(yych<='\f'){if(yych=='\n'){gotoCase=271;continue;};{gotoCase=287;continue;};}else{if(yych<='\r'){gotoCase=271;continue;};if(yych<=')'){gotoCase=287;continue;};{gotoCase=279;continue;};}}else{if(yych<='Z'){if(yych=='/'){gotoCase=285;continue;};{gotoCase=287;continue;};}else{if(yych<='['){gotoCase=283;continue;};if(yych<='\\'){gotoCase=290;continue;};{gotoCase=287;continue;};}}
|
| +case 289:++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=282;continue;};if(yych=='\r'){gotoCase=282;continue;};{gotoCase=283;continue;};case 290:++cursor;yych=this._charAt(cursor);if(yych=='\n'){gotoCase=282;continue;};if(yych=='\r'){gotoCase=282;continue;};{gotoCase=287;continue;};case this.case_SSTRING:yych=this._charAt(cursor);if(yych<='\r'){if(yych=='\n'){gotoCase=295;continue;};if(yych<='\f'){gotoCase=294;continue;};{gotoCase=295;continue;};}else{if(yych<='\''){if(yych<='&'){gotoCase=294;continue;};{gotoCase=297;continue;};}else{if(yych=='\\'){gotoCase=299;continue;};{gotoCase=294;continue;};}}
|
| +case 293:{this.tokenType="javascript-string";return cursor;}
|
| +case 294:yyaccept=0;yych=this._charAt(YYMARKER=++cursor);{gotoCase=301;continue;};case 295:++cursor;case 296:{this.tokenType=null;return cursor;}
|
| +case 297:++cursor;case 298:this.setLexCondition(this._lexConditions.NODIV);{this.tokenType="javascript-string";return cursor;}
|
| +case 299:yyaccept=1;yych=this._charAt(YYMARKER=++cursor);if(yych<='e'){if(yych<='\''){if(yych=='"'){gotoCase=300;continue;};if(yych<='&'){gotoCase=296;continue;};}else{if(yych<='\\'){if(yych<='['){gotoCase=296;continue;};}else{if(yych!='b'){gotoCase=296;continue;};}}}else{if(yych<='r'){if(yych<='m'){if(yych>='g'){gotoCase=296;continue;};}else{if(yych<='n'){gotoCase=300;continue;};if(yych<='q'){gotoCase=296;continue;};}}else{if(yych<='t'){if(yych<='s'){gotoCase=296;continue;};}else{if(yych<='u'){gotoCase=302;continue;};if(yych>='w'){gotoCase=296;continue;};}}}
|
| +case 300:yyaccept=0;YYMARKER=++cursor;yych=this._charAt(cursor);case 301:if(yych<='\r'){if(yych=='\n'){gotoCase=293;continue;};if(yych<='\f'){gotoCase=300;continue;};{gotoCase=293;continue;};}else{if(yych<='\''){if(yych<='&'){gotoCase=300;continue;};{gotoCase=308;continue;};}else{if(yych=='\\'){gotoCase=307;continue;};{gotoCase=300;continue;};}}
|
| +case 302:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=303;continue;};if(yych<='9'){gotoCase=304;continue;};}else{if(yych<='F'){gotoCase=304;continue;};if(yych<='`'){gotoCase=303;continue;};if(yych<='f'){gotoCase=304;continue;};}
|
| +case 303:cursor=YYMARKER;if(yyaccept<=0){{gotoCase=293;continue;};}else{{gotoCase=296;continue;};}
|
| +case 304:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=303;continue;};if(yych>=':'){gotoCase=303;continue;};}else{if(yych<='F'){gotoCase=305;continue;};if(yych<='`'){gotoCase=303;continue;};if(yych>='g'){gotoCase=303;continue;};}
|
| +case 305:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=303;continue;};if(yych>=':'){gotoCase=303;continue;};}else{if(yych<='F'){gotoCase=306;continue;};if(yych<='`'){gotoCase=303;continue;};if(yych>='g'){gotoCase=303;continue;};}
|
| +case 306:++cursor;yych=this._charAt(cursor);if(yych<='@'){if(yych<='/'){gotoCase=303;continue;};if(yych<='9'){gotoCase=300;continue;};{gotoCase=303;continue;};}else{if(yych<='F'){gotoCase=300;continue;};if(yych<='`'){gotoCase=303;continue;};if(yych<='f'){gotoCase=300;continue;};{gotoCase=303;continue;};}
|
| +case 307:++cursor;yych=this._charAt(cursor);if(yych<='e'){if(yych<='\''){if(yych=='"'){gotoCase=300;continue;};if(yych<='&'){gotoCase=303;continue;};{gotoCase=300;continue;};}else{if(yych<='\\'){if(yych<='['){gotoCase=303;continue;};{gotoCase=300;continue;};}else{if(yych=='b'){gotoCase=300;continue;};{gotoCase=303;continue;};}}}else{if(yych<='r'){if(yych<='m'){if(yych<='f'){gotoCase=300;continue;};{gotoCase=303;continue;};}else{if(yych<='n'){gotoCase=300;continue;};if(yych<='q'){gotoCase=303;continue;};{gotoCase=300;continue;};}}else{if(yych<='t'){if(yych<='s'){gotoCase=303;continue;};{gotoCase=300;continue;};}else{if(yych<='u'){gotoCase=302;continue;};if(yych<='v'){gotoCase=300;continue;};{gotoCase=303;continue;};}}}
|
| +case 308:++cursor;yych=this._charAt(cursor);{gotoCase=298;continue;};}}},__proto__:WebInspector.SourceTokenizer.prototype}
|
| WebInspector.FileSystemModel=function()
|
| {WebInspector.Object.call(this);this._fileSystemsForOrigin={};WebInspector.resourceTreeModel.addEventListener(WebInspector.ResourceTreeModel.EventTypes.SecurityOriginAdded,this._securityOriginAdded,this);WebInspector.resourceTreeModel.addEventListener(WebInspector.ResourceTreeModel.EventTypes.SecurityOriginRemoved,this._securityOriginRemoved,this);FileSystemAgent.enable();this._reset();}
|
| WebInspector.FileSystemModel.prototype={_reset:function()
|
| @@ -6791,13 +7312,15 @@
|
| {this._closed=true;if(this._writeCallbacks.length)
|
| return;WebInspector.fileManager.removeEventListener(WebInspector.FileManager.EventTypes.AppendedToURL,this._onAppendDone,this);WebInspector.fileManager.close(this._fileName);},_onAppendDone:function(event)
|
| {if(event.data!==this._fileName)
|
| -return;var callback=this._writeCallbacks.shift();if(callback)
|
| -callback(this);if(!this._writeCallbacks.length){if(this._closed){WebInspector.fileManager.removeEventListener(WebInspector.FileManager.EventTypes.AppendedToURL,this._onAppendDone,this);WebInspector.fileManager.close(this._fileName);}}}}
|
| +return;if(!this._writeCallbacks.length){if(this._closed){WebInspector.fileManager.removeEventListener(WebInspector.FileManager.EventTypes.AppendedToURL,this._onAppendDone,this);WebInspector.fileManager.close(this._fileName);}
|
| +return;}
|
| +var callback=this._writeCallbacks.shift();if(callback)
|
| +callback(this);}}
|
| WebInspector.DebuggerModel=function()
|
| {InspectorBackend.registerDebuggerDispatcher(new WebInspector.DebuggerDispatcher(this));this._debuggerPausedDetails=null;this._scripts={};this._scriptsBySourceURL={};this._canSetScriptSource=false;this._breakpointsActive=true;WebInspector.settings.pauseOnExceptionStateString=WebInspector.settings.createSetting("pauseOnExceptionStateString",WebInspector.DebuggerModel.PauseOnExceptionsState.DontPauseOnExceptions);WebInspector.settings.pauseOnExceptionStateString.addChangeListener(this._pauseOnExceptionStateChanged,this);this.enableDebugger();WebInspector.DebuggerModel.applySkipStackFrameSettings();}
|
| WebInspector.DebuggerModel.PauseOnExceptionsState={DontPauseOnExceptions:"none",PauseOnAllExceptions:"all",PauseOnUncaughtExceptions:"uncaught"};WebInspector.DebuggerModel.Location=function(scriptId,lineNumber,columnNumber)
|
| {this.scriptId=scriptId;this.lineNumber=lineNumber;this.columnNumber=columnNumber;}
|
| -WebInspector.DebuggerModel.Events={DebuggerWasEnabled:"DebuggerWasEnabled",DebuggerWasDisabled:"DebuggerWasDisabled",DebuggerPaused:"DebuggerPaused",DebuggerResumed:"DebuggerResumed",ParsedScriptSource:"ParsedScriptSource",FailedToParseScriptSource:"FailedToParseScriptSource",BreakpointResolved:"BreakpointResolved",GlobalObjectCleared:"GlobalObjectCleared",CallFrameSelected:"CallFrameSelected",ConsoleCommandEvaluatedInSelectedCallFrame:"ConsoleCommandEvaluatedInSelectedCallFrame",BreakpointsActiveStateChanged:"BreakpointsActiveStateChanged"}
|
| +WebInspector.DebuggerModel.Events={DebuggerWasEnabled:"DebuggerWasEnabled",DebuggerWasDisabled:"DebuggerWasDisabled",DebuggerPaused:"DebuggerPaused",DebuggerResumed:"DebuggerResumed",ParsedScriptSource:"ParsedScriptSource",FailedToParseScriptSource:"FailedToParseScriptSource",BreakpointResolved:"BreakpointResolved",GlobalObjectCleared:"GlobalObjectCleared",CallFrameSelected:"CallFrameSelected",ExecutionLineChanged:"ExecutionLineChanged",ConsoleCommandEvaluatedInSelectedCallFrame:"ConsoleCommandEvaluatedInSelectedCallFrame",BreakpointsActiveStateChanged:"BreakpointsActiveStateChanged"}
|
| WebInspector.DebuggerModel.BreakReason={DOM:"DOM",EventListener:"EventListener",XHR:"XHR",Exception:"exception",Assert:"assert",CSPViolation:"CSPViolation",DebugCommand:"debugCommand"}
|
| WebInspector.DebuggerModel.prototype={debuggerEnabled:function()
|
| {return!!this._debuggerEnabled;},enableDebugger:function()
|
| @@ -6811,10 +7334,7 @@
|
| {this._debuggerEnabled=true;this._pauseOnExceptionStateChanged();this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.DebuggerWasEnabled);},_pauseOnExceptionStateChanged:function()
|
| {DebuggerAgent.setPauseOnExceptions(WebInspector.settings.pauseOnExceptionStateString.get());},_debuggerWasDisabled:function()
|
| {this._debuggerEnabled=false;this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.DebuggerWasDisabled);},continueToLocation:function(rawLocation)
|
| -{DebuggerAgent.continueToLocation(rawLocation);},stepIntoSelection:function(rawLocation)
|
| -{function callback(requestedLocation,error)
|
| -{if(error)
|
| -return;this._pendingStepIntoLocation=requestedLocation;};DebuggerAgent.continueToLocation(rawLocation,true,callback.bind(this,rawLocation));},setBreakpointByScriptLocation:function(rawLocation,condition,callback)
|
| +{DebuggerAgent.continueToLocation(rawLocation);},setBreakpointByScriptLocation:function(rawLocation,condition,callback)
|
| {var script=this.scriptForId(rawLocation.scriptId);if(script.sourceURL)
|
| this.setBreakpointByURL(script.sourceURL,rawLocation.lineNumber,rawLocation.columnNumber,condition,callback);else
|
| this.setBreakpointBySourceId(rawLocation,condition,callback);},setBreakpointByURL:function(url,lineNumber,columnNumber,condition,callback)
|
| @@ -6834,18 +7354,17 @@
|
| {return this._scripts[scriptId]||null;},scriptsForSourceURL:function(sourceURL)
|
| {if(!sourceURL)
|
| return[];return this._scriptsBySourceURL[sourceURL]||[];},setScriptSource:function(scriptId,newSource,callback)
|
| -{this._scripts[scriptId].editSource(newSource,this._didEditScriptSource.bind(this,scriptId,newSource,callback));},_didEditScriptSource:function(scriptId,newSource,callback,error,errorData,callFrames,needsStepIn)
|
| -{callback(error,errorData);if(needsStepIn)
|
| -DebuggerAgent.stepInto();else if(!error&&callFrames&&callFrames.length)
|
| +{this._scripts[scriptId].editSource(newSource,this._didEditScriptSource.bind(this,scriptId,newSource,callback));},_didEditScriptSource:function(scriptId,newSource,callback,error,errorData,callFrames)
|
| +{callback(error,errorData);if(!error&&callFrames&&callFrames.length)
|
| this._pausedScript(callFrames,this._debuggerPausedDetails.reason,this._debuggerPausedDetails.auxData,this._debuggerPausedDetails.breakpointIds);},get callFrames()
|
| {return this._debuggerPausedDetails?this._debuggerPausedDetails.callFrames:null;},debuggerPausedDetails:function()
|
| {return this._debuggerPausedDetails;},_setDebuggerPausedDetails:function(debuggerPausedDetails)
|
| {if(this._debuggerPausedDetails)
|
| this._debuggerPausedDetails.dispose();this._debuggerPausedDetails=debuggerPausedDetails;if(this._debuggerPausedDetails)
|
| this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.DebuggerPaused,this._debuggerPausedDetails);if(debuggerPausedDetails){this.setSelectedCallFrame(debuggerPausedDetails.callFrames[0]);DebuggerAgent.setOverlayMessage(WebInspector.UIString("Paused in debugger"));}else{this.setSelectedCallFrame(null);DebuggerAgent.setOverlayMessage();}},_pausedScript:function(callFrames,reason,auxData,breakpointIds)
|
| -{if(this._pendingStepIntoLocation){var requestedLocation=this._pendingStepIntoLocation;delete this._pendingStepIntoLocation;if(callFrames.length>0){var topLocation=callFrames[0].location;if(topLocation.lineNumber==requestedLocation.lineNumber&&topLocation.columnNumber==requestedLocation.columnNumber&&topLocation.scriptId==requestedLocation.scriptId){DebuggerAgent.stepInto();return;}}}
|
| -this._setDebuggerPausedDetails(new WebInspector.DebuggerPausedDetails(this,callFrames,reason,auxData,breakpointIds));},_resumedScript:function()
|
| -{this._setDebuggerPausedDetails(null);this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.DebuggerResumed);},_parsedScriptSource:function(scriptId,sourceURL,startLine,startColumn,endLine,endColumn,isContentScript,sourceMapURL,hasSourceURL)
|
| +{this._setDebuggerPausedDetails(new WebInspector.DebuggerPausedDetails(this,callFrames,reason,auxData,breakpointIds));},_resumedScript:function()
|
| +{this._setDebuggerPausedDetails(null);if(this._executionLineLiveLocation)
|
| +this._executionLineLiveLocation.dispose();this._executionLineLiveLocation=null;this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.DebuggerResumed);},_parsedScriptSource:function(scriptId,sourceURL,startLine,startColumn,endLine,endColumn,isContentScript,sourceMapURL,hasSourceURL)
|
| {var script=new WebInspector.Script(scriptId,sourceURL,startLine,startColumn,endLine,endColumn,isContentScript,sourceMapURL,hasSourceURL);this._registerScript(script);this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.ParsedScriptSource,script);},_registerScript:function(script)
|
| {this._scripts[script.scriptId]=script;if(script.isAnonymousScript())
|
| return;var scripts=this._scriptsBySourceURL[script.sourceURL];if(!scripts){scripts=[];this._scriptsBySourceURL[script.sourceURL]=scripts;}
|
| @@ -6859,8 +7378,11 @@
|
| continue;closestScript=script;break;}
|
| return closestScript?new WebInspector.DebuggerModel.Location(closestScript.scriptId,lineNumber,columnNumber):null;},isPaused:function()
|
| {return!!this.debuggerPausedDetails();},setSelectedCallFrame:function(callFrame)
|
| -{this._selectedCallFrame=callFrame;if(!this._selectedCallFrame)
|
| -return;this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.CallFrameSelected,callFrame);},selectedCallFrame:function()
|
| +{if(this._executionLineLiveLocation)
|
| +this._executionLineLiveLocation.dispose();delete this._executionLineLiveLocation;this._selectedCallFrame=callFrame;if(!this._selectedCallFrame)
|
| +return;this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.CallFrameSelected,callFrame);function updateExecutionLine(uiLocation)
|
| +{this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.ExecutionLineChanged,uiLocation);}
|
| +this._executionLineLiveLocation=callFrame.script.createLiveLocation(callFrame.location,updateExecutionLine.bind(this));},selectedCallFrame:function()
|
| {return this._selectedCallFrame;},evaluateOnSelectedCallFrame:function(code,objectGroup,includeCommandLineAPI,doNotPauseOnExceptionsAndMuteConsole,returnByValue,generatePreview,callback)
|
| {function didEvaluate(result,wasThrown)
|
| {if(returnByValue)
|
| @@ -6913,11 +7435,7 @@
|
| {if(!error)
|
| WebInspector.debuggerModel.callStackModified(callFrames,details);if(callback)
|
| callback(error);}
|
| -DebuggerAgent.restartFrame(this._payload.callFrameId,protocolCallback);},getStepIntoLocations:function(callback)
|
| -{if(this._stepInLocations){callback(this._stepInLocations.slice(0));return;}
|
| -function getStepInPositionsCallback(error,stepInPositions){if(error){return;}
|
| -this._stepInLocations=stepInPositions;callback(this._stepInLocations.slice(0));}
|
| -DebuggerAgent.getStepInPositions(this.id,getStepInPositionsCallback.bind(this));},createLiveLocation:function(updateDelegate)
|
| +DebuggerAgent.restartFrame(this._payload.callFrameId,protocolCallback);},createLiveLocation:function(updateDelegate)
|
| {var location=this._script.createLiveLocation(this.location,updateDelegate);this._locations.push(location);return location;},dispose:function(updateDelegate)
|
| {for(var i=0;i<this._locations.length;++i)
|
| this._locations[i].dispose();this._locations=[];}}
|
| @@ -6931,11 +7449,9 @@
|
| {if(!WebInspector.SourceMap.prototype._base64Map){const base64Digits="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";WebInspector.SourceMap.prototype._base64Map={};for(var i=0;i<base64Digits.length;++i)
|
| WebInspector.SourceMap.prototype._base64Map[base64Digits.charAt(i)]=i;}
|
| this._sourceMappingURL=sourceMappingURL;this._reverseMappingsBySourceURL={};this._mappings=[];this._sources={};this._sourceContentByURL={};this._parseMappingPayload(payload);}
|
| -WebInspector.SourceMap._sourceMapRequestHeaderName="X-Source-Map-Request-From";WebInspector.SourceMap._sourceMapRequestHeaderValue="inspector";WebInspector.SourceMap.hasSourceMapRequestHeader=function(request)
|
| -{return request&&request.requestHeaderValue(WebInspector.SourceMap._sourceMapRequestHeaderName)===WebInspector.SourceMap._sourceMapRequestHeaderValue;}
|
| WebInspector.SourceMap.load=function(sourceMapURL,compiledURL,callback)
|
| -{var headers={};headers[WebInspector.SourceMap._sourceMapRequestHeaderName]=WebInspector.SourceMap._sourceMapRequestHeaderValue;NetworkAgent.loadResourceForFrontend(WebInspector.resourceTreeModel.mainFrame.id,sourceMapURL,headers,contentLoaded.bind(this));function contentLoaded(error,statusCode,headers,content)
|
| -{if(error||!content||statusCode>=400){callback(null);return;}
|
| +{NetworkAgent.loadResourceForFrontend(WebInspector.resourceTreeModel.mainFrame.id,sourceMapURL,undefined,contentLoaded.bind(this));function contentLoaded(error,statusCode,headers,content)
|
| +{if(error||!content||statusCode>=400){console.error("Could not load content for "+sourceMapURL+" : "+(error||("HTTP status code: "+statusCode)));callback(null);return;}
|
| if(content.slice(0,3)===")]}")
|
| content=content.substring(content.indexOf('\n'));try{var payload=(JSON.parse(content));var baseURL=sourceMapURL.startsWith("data:")?compiledURL:sourceMapURL;callback(new WebInspector.SourceMap(baseURL,payload));}catch(e){console.error(e.message);callback(null);}}}
|
| WebInspector.SourceMap.prototype={sources:function()
|
| @@ -7002,7 +7518,7 @@
|
| callback([]);},editSource:function(newSource,callback)
|
| {function didEditScriptSource(error,errorData,callFrames,debugData)
|
| {if(!error)
|
| -this._source=newSource;var needsStepIn=!!debugData&&debugData["stack_update_needs_step_in"]===true;callback(error,errorData,callFrames,needsStepIn);if(!error)
|
| +this._source=newSource;callback(error,errorData,callFrames);if(!error)
|
| this.dispatchEventToListeners(WebInspector.Script.Events.ScriptEdited,newSource);}
|
| if(this.scriptId){DebuggerAgent.setScriptSource(this.scriptId,newSource,undefined,didEditScriptSource.bind(this));}else
|
| callback("Script failed to parse");},isInlineScript:function()
|
| @@ -7131,8 +7647,7 @@
|
| return WebInspector.resourceTypes.Stylesheet;if(WebInspector.FileSystemProjectDelegate._documentExtensions[extension])
|
| return WebInspector.resourceTypes.Document;return WebInspector.resourceTypes.Other;},populate:function()
|
| {this._fileSystem.requestFilesRecursive("",this._addFile.bind(this));},refresh:function(path)
|
| -{this._fileSystem.requestFilesRecursive(path,this._addFile.bind(this));},excludeFolder:function(path)
|
| -{WebInspector.isolatedFileSystemManager.mapping().addExcludedFolder(this._fileSystem.path(),path);},createFile:function(path,name,callback)
|
| +{this._fileSystem.requestFilesRecursive(path,this._addFile.bind(this));},createFile:function(path,name,callback)
|
| {this._fileSystem.createFile(path,name,innerCallback.bind(this));function innerCallback(filePath)
|
| {this._addFile(filePath);callback(filePath);}},deleteFile:function(path)
|
| {this._fileSystem.deleteFile(path);this._removeFile(path);},remove:function()
|
| @@ -7150,38 +7665,24 @@
|
| {var projectDelegate=this._projectDelegates[uiSourceCode.project().id()];return projectDelegate.fileSystemPath();},delegate:function(fileSystemPath)
|
| {var projectId=WebInspector.FileSystemProjectDelegate.projectId(fileSystemPath);return this._projectDelegates[projectId];}}
|
| WebInspector.fileSystemWorkspaceProvider=null;WebInspector.FileSystemMapping=function()
|
| -{WebInspector.Object.call(this);this._fileSystemMappingSetting=WebInspector.settings.createSetting("fileSystemMapping",{});this._excludedFoldersSetting=WebInspector.settings.createSetting("workspaceExcludedFolders",{});var defaultCommonExcludedFolders=["/\\.git/","/\\.sass-cache/","/\\.hg/","/\\.idea/","/\\.svn/","/\\.cache/","/\\.project/"];var defaultWinExcludedFolders=["/Thumbs.db$","/ehthumbs.db$","/Desktop.ini$","/\\$RECYCLE.BIN/"];var defaultMacExcludedFolders=["/\\.DS_Store$","/\\.Trashes$","/\\.Spotlight-V100$","/\\.AppleDouble$","/\\.LSOverride$","/Icon$","/\\._.*$"];var defaultLinuxExcludedFolders=["/.*~$"];var defaultExcludedFolders=defaultCommonExcludedFolders;if(WebInspector.isWin())
|
| -defaultExcludedFolders=defaultExcludedFolders.concat(defaultWinExcludedFolders);else if(WebInspector.isMac())
|
| -defaultExcludedFolders=defaultExcludedFolders.concat(defaultMacExcludedFolders);else
|
| -defaultExcludedFolders=defaultExcludedFolders.concat(defaultLinuxExcludedFolders);var defaultExcludedFoldersPattern=defaultExcludedFolders.join("|");WebInspector.settings.workspaceFolderExcludePattern=WebInspector.settings.createSetting("workspaceFolderExcludePattern",defaultExcludedFoldersPattern);this._fileSystemMappings={};this._excludedFolders={};this._loadFromSettings();}
|
| -WebInspector.FileSystemMapping.Events={FileMappingAdded:"FileMappingAdded",FileMappingRemoved:"FileMappingRemoved",ExcludedFolderAdded:"ExcludedFolderAdded",ExcludedFolderRemoved:"ExcludedFolderRemoved"}
|
| +{WebInspector.Object.call(this);this._fileSystemMappingSetting=WebInspector.settings.createSetting("fileSystemMapping",{});this._fileSystemMappings={};this._loadFromSettings();}
|
| +WebInspector.FileSystemMapping.Events={FileMappingAdded:"FileMappingAdded",FileMappingRemoved:"FileMappingRemoved"}
|
| WebInspector.FileSystemMapping.prototype={_loadFromSettings:function()
|
| {var savedMapping=this._fileSystemMappingSetting.get();this._fileSystemMappings={};for(var fileSystemPath in savedMapping){var savedFileSystemMappings=savedMapping[fileSystemPath];this._fileSystemMappings[fileSystemPath]=[];var fileSystemMappings=this._fileSystemMappings[fileSystemPath];for(var i=0;i<savedFileSystemMappings.length;++i){var savedEntry=savedFileSystemMappings[i];var entry=new WebInspector.FileSystemMapping.Entry(savedEntry.fileSystemPath,savedEntry.urlPrefix,savedEntry.pathPrefix);fileSystemMappings.push(entry);}}
|
| -var savedExcludedFolders=this._excludedFoldersSetting.get();this._excludedFolders={};for(var fileSystemPath in savedExcludedFolders){var savedExcludedFoldersForPath=savedExcludedFolders[fileSystemPath];this._excludedFolders[fileSystemPath]=[];var excludedFolders=this._excludedFolders[fileSystemPath];for(var i=0;i<savedExcludedFoldersForPath.length;++i){var savedEntry=savedExcludedFoldersForPath[i];var entry=new WebInspector.FileSystemMapping.ExcludedFolderEntry(savedEntry.fileSystemPath,savedEntry.path);excludedFolders.push(entry);}}
|
| -var workspaceFolderExcludePattern=WebInspector.settings.workspaceFolderExcludePattern.get()
|
| -try{var flags=WebInspector.isWin()?"i":"";this._workspaceFolderExcludeRegex=workspaceFolderExcludePattern?new RegExp(workspaceFolderExcludePattern,flags):null;}catch(e){}
|
| this._rebuildIndexes();},_saveToSettings:function()
|
| -{var savedMapping=this._fileSystemMappings;this._fileSystemMappingSetting.set(savedMapping);var savedExcludedFolders=this._excludedFolders;this._excludedFoldersSetting.set(savedExcludedFolders);this._rebuildIndexes();},_rebuildIndexes:function()
|
| +{var savedMapping=this._fileSystemMappings;this._fileSystemMappingSetting.set(savedMapping);this._rebuildIndexes();},_rebuildIndexes:function()
|
| {this._mappingForURLPrefix={};this._urlPrefixes=[];for(var fileSystemPath in this._fileSystemMappings){var fileSystemMapping=this._fileSystemMappings[fileSystemPath];for(var i=0;i<fileSystemMapping.length;++i){var entry=fileSystemMapping[i];this._mappingForURLPrefix[entry.urlPrefix]=entry;this._urlPrefixes.push(entry.urlPrefix);}}
|
| this._urlPrefixes.sort();},addFileSystem:function(fileSystemPath)
|
| {if(this._fileSystemMappings[fileSystemPath])
|
| return;this._fileSystemMappings[fileSystemPath]=[];this._saveToSettings();},removeFileSystem:function(fileSystemPath)
|
| {if(!this._fileSystemMappings[fileSystemPath])
|
| -return;delete this._fileSystemMappings[fileSystemPath];delete this._excludedFolders[fileSystemPath];this._saveToSettings();},addFileMapping:function(fileSystemPath,urlPrefix,pathPrefix)
|
| +return;delete this._fileSystemMappings[fileSystemPath];this._saveToSettings();},addFileMapping:function(fileSystemPath,urlPrefix,pathPrefix)
|
| {var entry=new WebInspector.FileSystemMapping.Entry(fileSystemPath,urlPrefix,pathPrefix);this._fileSystemMappings[fileSystemPath].push(entry);this._saveToSettings();this.dispatchEventToListeners(WebInspector.FileSystemMapping.Events.FileMappingAdded,entry);},removeFileMapping:function(fileSystemPath,urlPrefix,pathPrefix)
|
| {var entry=this._mappingEntryForPathPrefix(fileSystemPath,pathPrefix);if(!entry)
|
| -return;this._fileSystemMappings[fileSystemPath].remove(entry);this._saveToSettings();this.dispatchEventToListeners(WebInspector.FileSystemMapping.Events.FileMappingRemoved,entry);},addExcludedFolder:function(fileSystemPath,excludedFolderPath)
|
| -{if(!this._excludedFolders[fileSystemPath])
|
| -this._excludedFolders[fileSystemPath]=[];var entry=new WebInspector.FileSystemMapping.ExcludedFolderEntry(fileSystemPath,excludedFolderPath);this._excludedFolders[fileSystemPath].push(entry);this._saveToSettings();this.dispatchEventToListeners(WebInspector.FileSystemMapping.Events.ExcludedFolderAdded,entry);},removeExcludedFolder:function(fileSystemPath,path)
|
| -{var entry=this._excludedFolderEntryForPath(fileSystemPath,path);if(!entry)
|
| -return;this._excludedFolders[fileSystemPath].remove(entry);this._saveToSettings();this.dispatchEventToListeners(WebInspector.FileSystemMapping.Events.ExcludedFolderRemoved,entry);},fileSystemPaths:function()
|
| +return;this._fileSystemMappings[fileSystemPath].remove(entry);this._saveToSettings();this.dispatchEventToListeners(WebInspector.FileSystemMapping.Events.FileMappingRemoved,entry);},fileSystemPaths:function()
|
| {return Object.keys(this._fileSystemMappings);},_mappingEntryForURL:function(url)
|
| {for(var i=this._urlPrefixes.length-1;i>=0;--i){var urlPrefix=this._urlPrefixes[i];if(url.startsWith(urlPrefix))
|
| return this._mappingForURLPrefix[urlPrefix];}
|
| -return null;},_excludedFolderEntryForPath:function(fileSystemPath,path)
|
| -{var entries=this._excludedFolders[fileSystemPath];if(!entries)
|
| -return null;for(var i=0;i<entries.length;++i){if(entries[i].path===path)
|
| -return entries[i];}
|
| return null;},_mappingEntryForPath:function(fileSystemPath,filePath)
|
| {var entries=this._fileSystemMappings[fileSystemPath];if(!entries)
|
| return null;var entry=null;for(var i=0;i<entries.length;++i){var pathPrefix=entries[i].pathPrefix;if(entry&&entry.pathPrefix.length>pathPrefix.length)
|
| @@ -7190,11 +7691,7 @@
|
| return entry;},_mappingEntryForPathPrefix:function(fileSystemPath,pathPrefix)
|
| {var entries=this._fileSystemMappings[fileSystemPath];for(var i=0;i<entries.length;++i){if(pathPrefix===entries[i].pathPrefix)
|
| return entries[i];}
|
| -return null;},isFileExcluded:function(fileSystemPath,folderPath)
|
| -{var excludedFolders=this._excludedFolders[fileSystemPath]||[];for(var i=0;i<excludedFolders.length;++i){var entry=excludedFolders[i];if(entry.path===folderPath)
|
| -return true;}
|
| -return this._workspaceFolderExcludeRegex&&this._workspaceFolderExcludeRegex.test(folderPath);},excludedFolders:function(fileSystemPath)
|
| -{var excludedFolders=this._excludedFolders[fileSystemPath];return excludedFolders?excludedFolders.slice():[];},mappingEntries:function(fileSystemPath)
|
| +return null;},mappingEntries:function(fileSystemPath)
|
| {return this._fileSystemMappings[fileSystemPath].slice();},hasMappingForURL:function(url)
|
| {return!!this._mappingEntryForURL(url);},fileForURL:function(url)
|
| {var entry=this._mappingEntryForURL(url);if(!entry)
|
| @@ -7209,8 +7706,6 @@
|
| var pathPrefix=normalizedFilePath.substr(0,normalizedFilePath.length-commonPathSuffixLength);var urlPrefix=url.substr(0,url.length-commonPathSuffixLength);this.addFileMapping(fileSystemPath,urlPrefix,pathPrefix);},__proto__:WebInspector.Object.prototype}
|
| WebInspector.FileSystemMapping.Entry=function(fileSystemPath,urlPrefix,pathPrefix)
|
| {this.fileSystemPath=fileSystemPath;this.urlPrefix=urlPrefix;this.pathPrefix=pathPrefix;}
|
| -WebInspector.FileSystemMapping.ExcludedFolderEntry=function(fileSystemPath,path)
|
| -{this.fileSystemPath=fileSystemPath;this.path=path;}
|
| WebInspector.IsolatedFileSystem=function(manager,path,name,rootURL)
|
| {this._manager=manager;this._path=path;this._name=name;this._rootURL=rootURL;}
|
| WebInspector.IsolatedFileSystem.errorMessage=function(error)
|
| @@ -7223,10 +7718,9 @@
|
| {this._requestFileSystem(fileSystemLoaded.bind(this));var domFileSystem;function fileSystemLoaded(fs)
|
| {domFileSystem=fs;this._requestEntries(domFileSystem,path,innerCallback.bind(this));}
|
| function innerCallback(entries)
|
| -{for(var i=0;i<entries.length;++i){var entry=entries[i];if(!entry.isDirectory){if(this._manager.mapping().isFileExcluded(this._path,entry.fullPath))
|
| -continue;callback(entry.fullPath.substr(1));}
|
| -else{if(this._manager.mapping().isFileExcluded(this._path,entry.fullPath+"/"))
|
| -continue;this._requestEntries(domFileSystem,entry.fullPath,innerCallback.bind(this));}}}},createFile:function(path,name,callback)
|
| +{for(var i=0;i<entries.length;++i){var entry=entries[i];if(!entry.isDirectory)
|
| +callback(entry.fullPath.substr(1));else
|
| +this._requestEntries(domFileSystem,entry.fullPath,innerCallback.bind(this));}}},createFile:function(path,name,callback)
|
| {this._requestFileSystem(fileSystemLoaded.bind(this));var newFileIndex=1;if(!name)
|
| name="NewFile";var nameCandidate;function fileSystemLoaded(domFileSystem)
|
| {domFileSystem.root.getDirectory(path,null,dirEntryLoaded.bind(this),errorHandler.bind(this));}
|
| @@ -7346,7 +7840,7 @@
|
| {this.parentPath=parentPath;this.name=name;this.originURL=originURL;this.url=url;this.contentType=contentType;this.isEditable=isEditable;this.isContentScript=isContentScript||false;}
|
| WebInspector.ProjectDelegate=function(){}
|
| WebInspector.ProjectDelegate.Events={FileAdded:"FileAdded",FileRemoved:"FileRemoved",Reset:"Reset",}
|
| -WebInspector.ProjectDelegate.prototype={id:function(){},type:function(){},displayName:function(){},requestMetadata:function(path,callback){},requestFileContent:function(path,callback){},canSetFileContent:function(){},setFileContent:function(path,newContent,callback){},canRename:function(){},rename:function(path,newName,callback){},refresh:function(path){},excludeFolder:function(path){},createFile:function(path,name,callback){},deleteFile:function(path){},remove:function(){},searchInFileContent:function(path,query,caseSensitive,isRegex,callback){},searchInContent:function(query,caseSensitive,isRegex,progress,callback){},indexContent:function(progress,callback){}}
|
| +WebInspector.ProjectDelegate.prototype={id:function(){},type:function(){},displayName:function(){},requestMetadata:function(path,callback){},requestFileContent:function(path,callback){},canSetFileContent:function(){},setFileContent:function(path,newContent,callback){},canRename:function(){},rename:function(path,newName,callback){},refresh:function(path){},createFile:function(path,name,callback){},deleteFile:function(path){},remove:function(){},searchInFileContent:function(path,query,caseSensitive,isRegex,callback){},searchInContent:function(query,caseSensitive,isRegex,progress,callback){},indexContent:function(progress,callback){}}
|
| WebInspector.Project=function(workspace,projectDelegate)
|
| {this._uiSourceCodesMap={};this._uiSourceCodesList=[];this._workspace=workspace;this._projectDelegate=projectDelegate;this._displayName=this._projectDelegate.displayName();this._projectDelegate.addEventListener(WebInspector.ProjectDelegate.Events.FileAdded,this._fileAdded,this);this._projectDelegate.addEventListener(WebInspector.ProjectDelegate.Events.FileRemoved,this._fileRemoved,this);this._projectDelegate.addEventListener(WebInspector.ProjectDelegate.Events.Reset,this._reset,this);}
|
| WebInspector.Project.prototype={id:function()
|
| @@ -7356,8 +7850,7 @@
|
| {return this._projectDelegate.type()===WebInspector.projectTypes.Debugger||this._projectDelegate.type()===WebInspector.projectTypes.LiveEdit;},_fileAdded:function(event)
|
| {var fileDescriptor=(event.data);var path=fileDescriptor.parentPath?fileDescriptor.parentPath+"/"+fileDescriptor.name:fileDescriptor.name;var uiSourceCode=this.uiSourceCode(path);if(uiSourceCode)
|
| return;uiSourceCode=new WebInspector.UISourceCode(this,fileDescriptor.parentPath,fileDescriptor.name,fileDescriptor.originURL,fileDescriptor.url,fileDescriptor.contentType,fileDescriptor.isEditable);uiSourceCode.isContentScript=fileDescriptor.isContentScript;this._uiSourceCodesMap[path]={uiSourceCode:uiSourceCode,index:this._uiSourceCodesList.length};this._uiSourceCodesList.push(uiSourceCode);this._workspace.dispatchEventToListeners(WebInspector.Workspace.Events.UISourceCodeAdded,uiSourceCode);},_fileRemoved:function(event)
|
| -{var path=(event.data);this._removeFile(path);},_removeFile:function(path)
|
| -{var uiSourceCode=this.uiSourceCode(path);if(!uiSourceCode)
|
| +{var path=(event.data);var uiSourceCode=this.uiSourceCode(path);if(!uiSourceCode)
|
| return;var entry=this._uiSourceCodesMap[path];var movedUISourceCode=this._uiSourceCodesList[this._uiSourceCodesList.length-1];this._uiSourceCodesList[entry.index]=movedUISourceCode;var movedEntry=this._uiSourceCodesMap[movedUISourceCode.path()];movedEntry.index=entry.index;this._uiSourceCodesList.splice(this._uiSourceCodesList.length-1,1);delete this._uiSourceCodesMap[path];this._workspace.dispatchEventToListeners(WebInspector.Workspace.Events.UISourceCodeRemoved,entry.uiSourceCode);},_reset:function()
|
| {this._workspace.dispatchEventToListeners(WebInspector.Workspace.Events.ProjectWillReset,this);this._uiSourceCodesMap={};this._uiSourceCodesList=[];},uiSourceCode:function(path)
|
| {var entry=this._uiSourceCodesMap[path];return entry?entry.uiSourceCode:null;},uiSourceCodeForOriginURL:function(originURL)
|
| @@ -7375,9 +7868,7 @@
|
| this._projectDelegate.rename(uiSourceCode.path(),newName,innerCallback.bind(this));function innerCallback(success,newName)
|
| {if(!success||!newName){callback(false);return;}
|
| var oldPath=uiSourceCode.path();var newPath=uiSourceCode.parentPath()?uiSourceCode.parentPath()+"/"+newName:newName;this._uiSourceCodesMap[newPath]=this._uiSourceCodesMap[oldPath];delete this._uiSourceCodesMap[oldPath];callback(true,newName);}},refresh:function(path)
|
| -{this._projectDelegate.refresh(path);},excludeFolder:function(path)
|
| -{this._projectDelegate.excludeFolder(path);var uiSourceCodes=this._uiSourceCodesList.slice();for(var i=0;i<uiSourceCodes.length;++i){var uiSourceCode=uiSourceCodes[i];if(uiSourceCode.path().startsWith(path.substr(1)))
|
| -this._removeFile(uiSourceCode.path());}},createFile:function(path,name,callback)
|
| +{this._projectDelegate.refresh(path);},createFile:function(path,name,callback)
|
| {this._projectDelegate.createFile(path,name,innerCallback);function innerCallback(filePath)
|
| {callback(filePath);}},deleteFile:function(uiSourceCode)
|
| {this._projectDelegate.deleteFile(uiSourceCode.path());},remove:function()
|
| @@ -7422,7 +7913,8 @@
|
| {this._workspace=workspace;WebInspector.resourceTreeModel.addEventListener(WebInspector.ResourceTreeModel.EventTypes.InspectedURLChanged,this._inspectedURLChanged,this);window.addEventListener("focus",this._windowFocused.bind(this),false);}
|
| WebInspector.WorkspaceController.prototype={_inspectedURLChanged:function(event)
|
| {WebInspector.Revision.filterOutStaleRevisions();},_windowFocused:function(event)
|
| -{if(this._fileSystemRefreshTimeout)
|
| +{if(!WebInspector.experimentsSettings.refreshFileSystemsOnFocus.isEnabled())
|
| +return;if(this._fileSystemRefreshTimeout)
|
| return;this._fileSystemRefreshTimeout=setTimeout(refreshFileSystems.bind(this),1000);function refreshFileSystems()
|
| {delete this._fileSystemRefreshTimeout;var projects=this._workspace.projects();for(var i=0;i<projects.length;++i)
|
| projects[i].refresh("/");}}}
|
| @@ -7440,7 +7932,6 @@
|
| {this.performRename(path,newName,innerCallback.bind(this));function innerCallback(success,newName)
|
| {if(success)
|
| this._updateName(path,newName);callback(success,newName);}},refresh:function(path)
|
| -{},excludeFolder:function(path)
|
| {},createFile:function(path,name,callback)
|
| {},deleteFile:function(path)
|
| {},remove:function()
|
| @@ -7686,8 +8177,7 @@
|
| return[];var scriptsForSourceURL=isInlineScript?this._inlineScriptsForSourceURL:this._nonInlineScriptsForSourceURL;return scriptsForSourceURL[uiSourceCode.url]||[];},_bindUISourceCodeToScripts:function(uiSourceCode,scripts)
|
| {console.assert(scripts.length);var scriptFile=new WebInspector.ResourceScriptFile(this,uiSourceCode,scripts);uiSourceCode.setScriptFile(scriptFile);for(var i=0;i<scripts.length;++i)
|
| scripts[i].updateLocations();uiSourceCode.setSourceMapping(this);},_unbindUISourceCodeFromScripts:function(uiSourceCode,scripts)
|
| -{console.assert(scripts.length);var scriptFile=(uiSourceCode.scriptFile());if(scriptFile){scriptFile.dispose();uiSourceCode.setScriptFile(null);}
|
| -uiSourceCode.setSourceMapping(null);},_initialize:function()
|
| +{console.assert(scripts.length);var scriptFile=(uiSourceCode.scriptFile());scriptFile.dispose();uiSourceCode.setScriptFile(null);uiSourceCode.setSourceMapping(null);},_initialize:function()
|
| {this._inlineScriptsForSourceURL={};this._nonInlineScriptsForSourceURL={};},_debuggerReset:function()
|
| {function unbindUISourceCodes(scriptsForSourceURL)
|
| {for(var sourceURL in scriptsForSourceURL){var scripts=scriptsForSourceURL[sourceURL];if(!scripts.length)
|
| @@ -8013,7 +8503,7 @@
|
| WebInspector.DOMDocument=function(domAgent,payload)
|
| {WebInspector.DOMNode.call(this,domAgent,this,false,payload);this.documentURL=payload.documentURL||"";this.baseURL=(payload.baseURL);console.assert(this.baseURL);this.xmlVersion=payload.xmlVersion;this._listeners={};}
|
| WebInspector.DOMDocument.prototype={__proto__:WebInspector.DOMNode.prototype}
|
| -WebInspector.DOMAgent=function(){this._idToDOMNode={};this._document=null;this._attributeLoadNodeIds={};InspectorBackend.registerDOMDispatcher(new WebInspector.DOMDispatcher(this));this._defaultHighlighter=new WebInspector.DefaultDOMNodeHighlighter();this._highlighter=this._defaultHighlighter;}
|
| +WebInspector.DOMAgent=function(){this._idToDOMNode={};this._document=null;this._attributeLoadNodeIds={};InspectorBackend.registerDOMDispatcher(new WebInspector.DOMDispatcher(this));}
|
| WebInspector.DOMAgent.Events={AttrModified:"AttrModified",AttrRemoved:"AttrRemoved",CharacterDataModified:"CharacterDataModified",NodeInserted:"NodeInserted",NodeRemoved:"NodeRemoved",DocumentUpdated:"DocumentUpdated",ChildNodeCountUpdated:"ChildNodeCountUpdated",UndoRedoRequested:"UndoRedoRequested",UndoRedoCompleted:"UndoRedoCompleted",InspectNodeRequested:"InspectNodeRequested"}
|
| WebInspector.DOMAgent.prototype={requestDocument:function(callback)
|
| {if(this._document){if(callback)
|
| @@ -8089,12 +8579,12 @@
|
| {DOMAgent.querySelector(nodeId,selectors,this._wrapClientCallback(callback));},querySelectorAll:function(nodeId,selectors,callback)
|
| {DOMAgent.querySelectorAll(nodeId,selectors,this._wrapClientCallback(callback));},highlightDOMNode:function(nodeId,mode,objectId)
|
| {if(this._hideDOMNodeHighlightTimeout){clearTimeout(this._hideDOMNodeHighlightTimeout);delete this._hideDOMNodeHighlightTimeout;}
|
| -this._highlighter.highlightDOMNode(nodeId||0,this._buildHighlightConfig(mode),objectId);},hideDOMNodeHighlight:function()
|
| +if(objectId||nodeId)
|
| +DOMAgent.highlightNode(this._buildHighlightConfig(mode),objectId?undefined:nodeId,objectId);else
|
| +DOMAgent.hideHighlight();},hideDOMNodeHighlight:function()
|
| {this.highlightDOMNode(0);},highlightDOMNodeForTwoSeconds:function(nodeId)
|
| {this.highlightDOMNode(nodeId);this._hideDOMNodeHighlightTimeout=setTimeout(this.hideDOMNodeHighlight.bind(this),2000);},setInspectModeEnabled:function(enabled,inspectShadowDOM,callback)
|
| -{function onDocumentAvailable()
|
| -{this._highlighter.setInspectModeEnabled(enabled,inspectShadowDOM,this._buildHighlightConfig(),callback);}
|
| -this.requestDocument(onDocumentAvailable.bind(this));},_buildHighlightConfig:function(mode)
|
| +{this._dispatchWhenDocumentAvailable(DOMAgent.setInspectModeEnabled.bind(DOMAgent,enabled,inspectShadowDOM,this._buildHighlightConfig()),callback);},_buildHighlightConfig:function(mode)
|
| {mode=mode||"all";var highlightConfig={showInfo:mode==="all",showRulers:WebInspector.settings.showMetricsRulers.get()};if(mode==="all"||mode==="content")
|
| highlightConfig.contentColor=WebInspector.Color.PageHighlight.Content.toProtocolRGBA();if(mode==="all"||mode==="padding")
|
| highlightConfig.paddingColor=WebInspector.Color.PageHighlight.Padding.toProtocolRGBA();if(mode==="all"||mode==="border")
|
| @@ -8119,8 +8609,7 @@
|
| this.dispatchEventToListeners(WebInspector.DOMAgent.Events.UndoRedoRequested);DOMAgent.undo(callback);},redo:function(callback)
|
| {function mycallback(error)
|
| {this.dispatchEventToListeners(WebInspector.DOMAgent.Events.UndoRedoCompleted);callback(error);}
|
| -this.dispatchEventToListeners(WebInspector.DOMAgent.Events.UndoRedoRequested);DOMAgent.redo(callback);},setHighlighter:function(highlighter)
|
| -{this._highlighter=highlighter||this._defaultHighlighter;},__proto__:WebInspector.Object.prototype}
|
| +this.dispatchEventToListeners(WebInspector.DOMAgent.Events.UndoRedoRequested);DOMAgent.redo(callback);},__proto__:WebInspector.Object.prototype}
|
| WebInspector.DOMDispatcher=function(domAgent)
|
| {this._domAgent=domAgent;}
|
| WebInspector.DOMDispatcher.prototype={documentUpdated:function()
|
| @@ -8136,14 +8625,6 @@
|
| {this._domAgent._childNodeRemoved(parentNodeId,nodeId);},shadowRootPushed:function(hostId,root)
|
| {this._domAgent._shadowRootPushed(hostId,root);},shadowRootPopped:function(hostId,rootId)
|
| {this._domAgent._shadowRootPopped(hostId,rootId);}}
|
| -WebInspector.DOMNodeHighlighter=function(){}
|
| -WebInspector.DOMNodeHighlighter.prototype={highlightDOMNode:function(nodeId,config,objectId){},setInspectModeEnabled:function(enabled,inspectShadowDOM,config,callback){}}
|
| -WebInspector.DefaultDOMNodeHighlighter=function(){}
|
| -WebInspector.DefaultDOMNodeHighlighter.prototype={highlightDOMNode:function(nodeId,config,objectId)
|
| -{if(objectId||nodeId)
|
| -DOMAgent.highlightNode(config,objectId?undefined:nodeId,objectId);else
|
| -DOMAgent.hideHighlight();},setInspectModeEnabled:function(enabled,inspectShadowDOM,config,callback)
|
| -{DOMAgent.setInspectModeEnabled(enabled,inspectShadowDOM,config,callback);}}
|
| WebInspector.domAgent=null;WebInspector.evaluateForTestInFrontend=function(callId,script)
|
| {if(!InspectorFrontendHost.isUnderTest())
|
| return;function invokeMethod()
|
| @@ -8181,7 +8662,8 @@
|
| {var sourceView=viewGetter();if(!sourceView||!sourceView.canHighlightPosition())
|
| return false;WebInspector.Dialog.show(sourceView.element,new WebInspector.GoToLineDialog(sourceView));return true;}
|
| WebInspector.GoToLineDialog.createShortcut=function()
|
| -{var isMac=WebInspector.isMac();var shortcut;return WebInspector.KeyboardShortcut.makeDescriptor("g",WebInspector.KeyboardShortcut.Modifiers.Ctrl);}
|
| +{var isMac=WebInspector.isMac();var shortcut;if(isMac)
|
| +return WebInspector.KeyboardShortcut.makeDescriptor("l",WebInspector.KeyboardShortcut.Modifiers.Meta);return WebInspector.KeyboardShortcut.makeDescriptor("g",WebInspector.KeyboardShortcut.Modifiers.Ctrl);}
|
| WebInspector.GoToLineDialog.prototype={focus:function()
|
| {WebInspector.setCurrentFocusElement(this._input);this._input.select();},_onGoClick:function()
|
| {this._applyLineNumber();WebInspector.Dialog.hide();},_applyLineNumber:function()
|
| @@ -8212,16 +8694,10 @@
|
| {this._resizerWidgetElement=resizerWidgetElement;this._installResizer(resizerWidgetElement);}}
|
| WebInspector.SettingsScreen=function(onHide)
|
| {WebInspector.HelpScreen.call(this);this.element.id="settings-screen";this._onHide=onHide;this._tabbedPane=new WebInspector.TabbedPane();this._tabbedPane.element.addStyleClass("help-window-main");var settingsLabelElement=document.createElement("div");settingsLabelElement.className="help-window-label";settingsLabelElement.createTextChild(WebInspector.UIString("Settings"));this._tabbedPane.element.insertBefore(settingsLabelElement,this._tabbedPane.element.firstChild);this._tabbedPane.element.appendChild(this._createCloseButton());this._tabbedPane.appendTab(WebInspector.SettingsScreen.Tabs.General,WebInspector.UIString("General"),new WebInspector.GenericSettingsTab());if(!WebInspector.experimentsSettings.showOverridesInDrawer.isEnabled())
|
| -this._tabbedPane.appendTab(WebInspector.SettingsScreen.Tabs.Overrides,WebInspector.UIString("Overrides"),new WebInspector.OverridesSettingsTab());this._tabbedPane.appendTab(WebInspector.SettingsScreen.Tabs.Workspace,WebInspector.UIString("Workspace"),new WebInspector.WorkspaceSettingsTab());if(WebInspector.experimentsSettings.experimentsEnabled)
|
| +this._tabbedPane.appendTab(WebInspector.SettingsScreen.Tabs.Overrides,WebInspector.UIString("Overrides"),new WebInspector.OverridesSettingsTab());this._tabbedPane.appendTab(WebInspector.SettingsScreen.Tabs.Workspace,WebInspector.UIString("Workspace"),new WebInspector.WorkspaceSettingsTab());if(WebInspector.experimentsSettings.tethering.isEnabled())
|
| +this._tabbedPane.appendTab(WebInspector.SettingsScreen.Tabs.Tethering,WebInspector.UIString("Port forwarding"),new WebInspector.TetheringSettingsTab());if(WebInspector.experimentsSettings.experimentsEnabled)
|
| this._tabbedPane.appendTab(WebInspector.SettingsScreen.Tabs.Experiments,WebInspector.UIString("Experiments"),new WebInspector.ExperimentsSettingsTab());this._tabbedPane.appendTab(WebInspector.SettingsScreen.Tabs.Shortcuts,WebInspector.UIString("Shortcuts"),WebInspector.shortcutsScreen.createShortcutsTabView());this._tabbedPane.shrinkableTabs=false;this._tabbedPane.verticalTabLayout=true;this._lastSelectedTabSetting=WebInspector.settings.createSetting("lastSelectedSettingsTab",WebInspector.SettingsScreen.Tabs.General);this.selectTab(this._lastSelectedTabSetting.get());this._tabbedPane.addEventListener(WebInspector.TabbedPane.EventTypes.TabSelected,this._tabSelected,this);}
|
| -WebInspector.SettingsScreen.regexValidator=function(text)
|
| -{var regex;try{regex=new RegExp(text);}catch(e){}
|
| -return regex?null:"Invalid pattern";}
|
| -WebInspector.SettingsScreen.integerValidator=function(min,max,text)
|
| -{var value=parseInt(text,10);if(isNaN(value))
|
| -return"Invalid number format";if(value<min||value>max)
|
| -return"Value is out of range ["+min+", "+max+"]";return null;}
|
| -WebInspector.SettingsScreen.Tabs={General:"general",Overrides:"overrides",Workspace:"workspace",Experiments:"experiments",Shortcuts:"shortcuts"}
|
| +WebInspector.SettingsScreen.Tabs={General:"general",Overrides:"overrides",Workspace:"workspace",Tethering:"tethering",Experiments:"experiments",Shortcuts:"shortcuts"}
|
| WebInspector.SettingsScreen.prototype={selectTab:function(tabId)
|
| {this._tabbedPane.selectTab(tabId);},_tabSelected:function(event)
|
| {this._lastSelectedTabSetting.set(this._tabbedPane.selectedTabId);},wasShown:function()
|
| @@ -8231,79 +8707,133 @@
|
| WebInspector.SettingsTab=function(name,id)
|
| {WebInspector.View.call(this);this.element.className="settings-tab-container";if(id)
|
| this.element.id=id;var header=this.element.createChild("header");header.createChild("h3").appendChild(document.createTextNode(name));this.containerElement=this.element.createChild("div","help-container-wrapper").createChild("div","settings-tab help-content help-container");}
|
| -WebInspector.SettingsTab.createCheckbox=function(name,getter,setter,omitParagraphElement,inputElement,tooltip)
|
| -{var input=inputElement||document.createElement("input");input.type="checkbox";input.name=name;input.checked=getter();function listener()
|
| -{setter(input.checked);}
|
| +WebInspector.SettingsTab.prototype={_appendSection:function(name)
|
| +{var block=this.containerElement.createChild("div","help-block");if(name)
|
| +block.createChild("div","help-section-title").textContent=name;return block;},_createCheckboxSetting:function(name,setting,omitParagraphElement,inputElement,tooltip)
|
| +{var input=inputElement||document.createElement("input");input.type="checkbox";input.name=name;input.checked=setting.get();function listener()
|
| +{setting.set(input.checked);}
|
| input.addEventListener("click",listener,false);var label=document.createElement("label");label.appendChild(input);label.appendChild(document.createTextNode(name));if(tooltip)
|
| label.title=tooltip;if(omitParagraphElement)
|
| -return label;var p=document.createElement("p");p.appendChild(label);return p;}
|
| -WebInspector.SettingsTab.createSettingCheckbox=function(name,setting,omitParagraphElement,inputElement,tooltip)
|
| -{return WebInspector.SettingsTab.createCheckbox(name,setting.get.bind(setting),setting.set.bind(setting),omitParagraphElement,inputElement,tooltip);}
|
| -WebInspector.SettingsTab.createSettingFieldset=function(setting)
|
| -{var fieldset=document.createElement("fieldset");fieldset.disabled=!setting.get();setting.addChangeListener(settingChanged);return fieldset;function settingChanged()
|
| -{fieldset.disabled=!setting.get();}}
|
| -WebInspector.SettingsTab.prototype={_appendSection:function(name)
|
| -{var block=this.containerElement.createChild("div","help-block");if(name)
|
| -block.createChild("div","help-section-title").textContent=name;return block;},_createSelectSetting:function(name,options,setting)
|
| -{var p=document.createElement("p");var labelElement=p.createChild("label");labelElement.textContent=name;var select=p.createChild("select");var settingValue=setting.get();for(var i=0;i<options.length;++i){var option=options[i];select.add(new Option(option[0],option[1]));if(settingValue===option[1])
|
| +return label;var p=document.createElement("p");p.appendChild(label);return p;},_createSelectSetting:function(name,options,setting)
|
| +{var fieldsetElement=document.createElement("fieldset");fieldsetElement.createChild("label").textContent=name;var select=document.createElement("select");var settingValue=setting.get();for(var i=0;i<options.length;++i){var option=options[i];select.add(new Option(option[0],option[1]));if(settingValue===option[1])
|
| select.selectedIndex=i;}
|
| function changeListener(e)
|
| -{setting.set(options[select.selectedIndex][1]);}
|
| -select.addEventListener("change",changeListener,false);return p;},_createInputSetting:function(label,setting,numeric,maxLength,width,validatorCallback)
|
| -{var p=document.createElement("p");var labelElement=p.createChild("label");labelElement.textContent=label;var inputElement=p.createChild("input");inputElement.value=setting.get();inputElement.type="text";if(numeric)
|
| +{setting.set(e.target.value);}
|
| +select.addEventListener("change",changeListener,false);fieldsetElement.appendChild(select);var p=document.createElement("p");p.appendChild(fieldsetElement);return p;},_createInputSetting:function(label,setting,numeric,maxLength,width,validatorCallback)
|
| +{var fieldset=document.createElement("fieldset");var p=fieldset.createChild("p");var labelElement=p.createChild("label");labelElement.textContent=label+" ";var inputElement=labelElement.createChild("input");inputElement.value=setting.get();inputElement.type="text";if(numeric)
|
| inputElement.className="numeric";if(maxLength)
|
| inputElement.maxLength=maxLength;if(width)
|
| -inputElement.style.width=width;if(validatorCallback){var errorMessageLabel=p.createChild("div");errorMessageLabel.addStyleClass("field-error-message");errorMessageLabel.style.color="DarkRed";inputElement.oninput=function()
|
| +inputElement.style.width=width;if(validatorCallback){var errorMessageLabel=labelElement.createChild("div");errorMessageLabel.addStyleClass("field-error-message");errorMessageLabel.style.color="DarkRed";inputElement.oninput=function()
|
| {var error=validatorCallback(inputElement.value);if(!error)
|
| error="";errorMessageLabel.textContent=error;};}
|
| function onBlur()
|
| {setting.set(numeric?Number(inputElement.value):inputElement.value);}
|
| -inputElement.addEventListener("blur",onBlur,false);return p;},_createCustomSetting:function(name,element)
|
| +inputElement.addEventListener("blur",onBlur,false);return fieldset;},_createCustomSetting:function(name,element)
|
| {var p=document.createElement("p");var fieldsetElement=document.createElement("fieldset");fieldsetElement.createChild("label").textContent=name;fieldsetElement.appendChild(element);p.appendChild(fieldsetElement);return p;},__proto__:WebInspector.View.prototype}
|
| WebInspector.GenericSettingsTab=function()
|
| -{WebInspector.SettingsTab.call(this,WebInspector.UIString("General"),"general-tab-content");var p=this._appendSection();p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Disable cache (while DevTools is open)"),WebInspector.settings.cacheDisabled));var disableJSElement=WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Disable JavaScript"),WebInspector.settings.javaScriptDisabled);p.appendChild(disableJSElement);WebInspector.settings.javaScriptDisabled.addChangeListener(this._javaScriptDisabledChanged,this);this._disableJSCheckbox=disableJSElement.getElementsByTagName("input")[0];this._updateScriptDisabledCheckbox();p=this._appendSection(WebInspector.UIString("Appearance"));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Split panels vertically when docked to right"),WebInspector.settings.splitVerticallyWhenDockedToRight));p=this._appendSection(WebInspector.UIString("Elements"));var colorFormatElement=this._createSelectSetting(WebInspector.UIString("Color format"),[[WebInspector.UIString("As authored"),WebInspector.Color.Format.Original],["HEX: #DAC0DE",WebInspector.Color.Format.HEX],["RGB: rgb(128, 255, 255)",WebInspector.Color.Format.RGB],["HSL: hsl(300, 80%, 90%)",WebInspector.Color.Format.HSL]],WebInspector.settings.colorFormat);p.appendChild(colorFormatElement);p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show user agent styles"),WebInspector.settings.showUserAgentStyles));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Word wrap"),WebInspector.settings.domWordWrap));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show Shadow DOM"),WebInspector.settings.showShadowDOM));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show rulers"),WebInspector.settings.showMetricsRulers));p=this._appendSection(WebInspector.UIString("Rendering"));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show paint rectangles"),WebInspector.settings.showPaintRects));this._forceCompositingModeCheckbox=document.createElement("input");var checkbox=WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Force accelerated compositing"),WebInspector.settings.forceCompositingMode,false,this._forceCompositingModeCheckbox);p.appendChild(checkbox);WebInspector.settings.forceCompositingMode.addChangeListener(this._forceCompositingModeChanged,this);var fieldset=WebInspector.SettingsTab.createSettingFieldset(WebInspector.settings.forceCompositingMode);this._showCompositedLayersBordersCheckbox=document.createElement("input");fieldset.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show composited layer borders"),WebInspector.settings.showDebugBorders,false,this._showCompositedLayersBordersCheckbox));this._showFPSCheckbox=document.createElement("input");fieldset.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show FPS meter"),WebInspector.settings.showFPSCounter,false,this._showFPSCheckbox));this._continousPaintingCheckbox=document.createElement("input");fieldset.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Enable continuous page repainting"),WebInspector.settings.continuousPainting,false,this._continousPaintingCheckbox));this._showScrollBottleneckRectsCheckbox=document.createElement("input");var tooltip=WebInspector.UIString("Shows areas of the page that slow down scrolling:\nTouch and mousewheel event listeners can delay scrolling.\nSome areas need to repaint their content when scrolled.");fieldset.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show potential scroll bottlenecks"),WebInspector.settings.showScrollBottleneckRects,false,this._showScrollBottleneckRectsCheckbox,tooltip));checkbox.appendChild(fieldset);this._forceCompositingModeChanged();p=this._appendSection(WebInspector.UIString("Sources"));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Search in content scripts"),WebInspector.settings.searchInContentScripts));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Enable JS source maps"),WebInspector.settings.jsSourceMapsEnabled));checkbox=WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Enable CSS source maps"),WebInspector.settings.cssSourceMapsEnabled);p.appendChild(checkbox);fieldset=WebInspector.SettingsTab.createSettingFieldset(WebInspector.settings.cssSourceMapsEnabled);var autoReloadCSSCheckbox=fieldset.createChild("input");fieldset.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Auto-reload generated CSS"),WebInspector.settings.cssReloadEnabled,false,autoReloadCSSCheckbox));checkbox.appendChild(fieldset);var indentationElement=this._createSelectSetting(WebInspector.UIString("Default indentation"),[[WebInspector.UIString("2 spaces"),WebInspector.TextUtils.Indent.TwoSpaces],[WebInspector.UIString("4 spaces"),WebInspector.TextUtils.Indent.FourSpaces],[WebInspector.UIString("8 spaces"),WebInspector.TextUtils.Indent.EightSpaces],[WebInspector.UIString("Tab character"),WebInspector.TextUtils.Indent.TabCharacter]],WebInspector.settings.textEditorIndent);p.appendChild(indentationElement);p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Detect indentation"),WebInspector.settings.textEditorAutoDetectIndent));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show whitespace characters"),WebInspector.settings.showWhitespacesInEditor));if(WebInspector.experimentsSettings.frameworksDebuggingSupport.isEnabled()){checkbox=WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Skip stepping through sources with particular names"),WebInspector.settings.skipStackFramesSwitch);fieldset=WebInspector.SettingsTab.createSettingFieldset(WebInspector.settings.skipStackFramesSwitch);fieldset.appendChild(this._createInputSetting(WebInspector.UIString("Pattern"),WebInspector.settings.skipStackFramesPattern,false,1000,"100px",WebInspector.SettingsScreen.regexValidator));checkbox.appendChild(fieldset);p.appendChild(checkbox);}
|
| -WebInspector.settings.skipStackFramesSwitch.addChangeListener(this._skipStackFramesSwitchOrPatternChanged,this);WebInspector.settings.skipStackFramesPattern.addChangeListener(this._skipStackFramesSwitchOrPatternChanged,this);p=this._appendSection(WebInspector.UIString("Profiler"));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show advanced heap snapshot properties"),WebInspector.settings.showAdvancedHeapSnapshotProperties));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("High resolution CPU profiling"),WebInspector.settings.highResolutionCpuProfiling));p=this._appendSection(WebInspector.UIString("Timeline"));checkbox=WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Limit number of captured JS stack frames"),WebInspector.settings.timelineLimitStackFramesFlag);p.appendChild(checkbox);fieldset=WebInspector.SettingsTab.createSettingFieldset(WebInspector.settings.timelineLimitStackFramesFlag);var frameCountValidator=WebInspector.SettingsScreen.integerValidator.bind(this,0,99);fieldset.appendChild(this._createInputSetting(WebInspector.UIString("Frames to capture"),WebInspector.settings.timelineStackFramesToCapture,true,2,"2em",frameCountValidator));checkbox.appendChild(fieldset);p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Show CPU activity on the ruler"),WebInspector.settings.showCpuOnTimelineRuler));p=this._appendSection(WebInspector.UIString("Console"));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Log XMLHttpRequests"),WebInspector.settings.monitoringXHREnabled));p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Preserve log upon navigation"),WebInspector.settings.preserveConsoleLog));if(WebInspector.extensionServer.hasExtensions()){var handlerSelector=new WebInspector.HandlerSelector(WebInspector.openAnchorLocationRegistry);p=this._appendSection(WebInspector.UIString("Extensions"));p.appendChild(this._createCustomSetting(WebInspector.UIString("Open links in"),handlerSelector.element));}
|
| -p=this._appendSection();var panelShortcutTitle=WebInspector.UIString("Enable %s + 1-9 shortcut to switch panels",WebInspector.isMac()?"Cmd":"Ctrl");p.appendChild(WebInspector.SettingsTab.createSettingCheckbox(panelShortcutTitle,WebInspector.settings.shortcutPanelSwitch));}
|
| +{WebInspector.SettingsTab.call(this,WebInspector.UIString("General"),"general-tab-content");var p=this._appendSection();p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Disable cache (while DevTools is open)"),WebInspector.settings.cacheDisabled));var disableJSElement=this._createCheckboxSetting(WebInspector.UIString("Disable JavaScript"),WebInspector.settings.javaScriptDisabled);p.appendChild(disableJSElement);WebInspector.settings.javaScriptDisabled.addChangeListener(this._javaScriptDisabledChanged,this);this._disableJSCheckbox=disableJSElement.getElementsByTagName("input")[0];this._updateScriptDisabledCheckbox();p=this._appendSection(WebInspector.UIString("Appearance"));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Split panels vertically when docked to right"),WebInspector.settings.splitVerticallyWhenDockedToRight));p=this._appendSection(WebInspector.UIString("Elements"));var colorFormatElement=this._createSelectSetting(WebInspector.UIString("Color format"),[[WebInspector.UIString("As authored"),WebInspector.Color.Format.Original],["HEX: #DAC0DE",WebInspector.Color.Format.HEX],["RGB: rgb(128, 255, 255)",WebInspector.Color.Format.RGB],["HSL: hsl(300, 80%, 90%)",WebInspector.Color.Format.HSL]],WebInspector.settings.colorFormat);p.appendChild(colorFormatElement);colorFormatElement.firstChild.className="toplevel";p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show user agent styles"),WebInspector.settings.showUserAgentStyles));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Word wrap"),WebInspector.settings.domWordWrap));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show Shadow DOM"),WebInspector.settings.showShadowDOM));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show rulers"),WebInspector.settings.showMetricsRulers));p=this._appendSection(WebInspector.UIString("Rendering"));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show paint rectangles"),WebInspector.settings.showPaintRects));this._forceCompositingModeCheckbox=document.createElement("input");p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Force accelerated compositing"),WebInspector.settings.forceCompositingMode,false,this._forceCompositingModeCheckbox));WebInspector.settings.forceCompositingMode.addChangeListener(this._forceCompositingModeChanged,this);this._compositingModeSettings=p.createChild("fieldset");this._showCompositedLayersBordersCheckbox=document.createElement("input");this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show composited layer borders"),WebInspector.settings.showDebugBorders,false,this._showCompositedLayersBordersCheckbox));this._showFPSCheckbox=document.createElement("input");this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show FPS meter"),WebInspector.settings.showFPSCounter,false,this._showFPSCheckbox));this._continousPaintingCheckbox=document.createElement("input");this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebInspector.UIString("Enable continuous page repainting"),WebInspector.settings.continuousPainting,false,this._continousPaintingCheckbox));this._showScrollBottleneckRectsCheckbox=document.createElement("input");var tooltip=WebInspector.UIString("Shows areas of the page that slow down scrolling:\nTouch and mousewheel event listeners can delay scrolling.\nSome areas need to repaint their content when scrolled.");this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show potential scroll bottlenecks"),WebInspector.settings.showScrollBottleneckRects,false,this._showScrollBottleneckRectsCheckbox,tooltip));this._forceCompositingModeChanged();p=this._appendSection(WebInspector.UIString("Sources"));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Search in content scripts"),WebInspector.settings.searchInContentScripts));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Enable JS source maps"),WebInspector.settings.jsSourceMapsEnabled));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Enable CSS source maps"),WebInspector.settings.cssSourceMapsEnabled));WebInspector.settings.cssSourceMapsEnabled.addChangeListener(this._cssSourceMapsEnablementChanged,this);this._cssSourceMapSettings=p.createChild("fieldset");var autoReloadCSSCheckbox=this._cssSourceMapSettings.createChild("input");this._cssSourceMapSettings.appendChild(this._createCheckboxSetting(WebInspector.UIString("Auto-reload generated CSS"),WebInspector.settings.cssReloadEnabled,false,autoReloadCSSCheckbox));this._cssSourceMapsEnablementChanged();var indentationElement=this._createSelectSetting(WebInspector.UIString("Default indentation"),[[WebInspector.UIString("2 spaces"),WebInspector.TextUtils.Indent.TwoSpaces],[WebInspector.UIString("4 spaces"),WebInspector.TextUtils.Indent.FourSpaces],[WebInspector.UIString("8 spaces"),WebInspector.TextUtils.Indent.EightSpaces],[WebInspector.UIString("Tab character"),WebInspector.TextUtils.Indent.TabCharacter]],WebInspector.settings.textEditorIndent);indentationElement.firstChild.className="toplevel";p.appendChild(indentationElement);p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Detect indentation"),WebInspector.settings.textEditorAutoDetectIndent));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show whitespace characters"),WebInspector.settings.showWhitespacesInEditor));if(WebInspector.experimentsSettings.frameworksDebuggingSupport.isEnabled())
|
| +p.appendChild(this._createSkipStackFrameSetting());WebInspector.settings.skipStackFramesSwitch.addChangeListener(this._skipStackFramesSwitchOrPatternChanged,this);WebInspector.settings.skipStackFramesPattern.addChangeListener(this._skipStackFramesSwitchOrPatternChanged,this);p=this._appendSection(WebInspector.UIString("Profiler"));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show advanced heap snapshot properties"),WebInspector.settings.showAdvancedHeapSnapshotProperties));p=this._appendSection(WebInspector.UIString("Timeline"));var checkbox=this._createCheckboxSetting(WebInspector.UIString("Limit number of captured JS stack frames"),WebInspector.settings.timelineLimitStackFramesFlag);p.appendChild(checkbox);var fieldset=this._createInputSetting(WebInspector.UIString("Frames to capture"),WebInspector.settings.timelineStackFramesToCapture,true,2,"2em");fieldset.disabled=!WebInspector.settings.timelineLimitStackFramesFlag.get();WebInspector.settings.timelineLimitStackFramesFlag.addChangeListener(this._timelineLimitStackFramesChanged.bind(this,fieldset));checkbox.appendChild(fieldset);p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show CPU activity on the ruler"),WebInspector.settings.showCpuOnTimelineRuler));p=this._appendSection(WebInspector.UIString("Console"));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Log XMLHttpRequests"),WebInspector.settings.monitoringXHREnabled));p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Preserve log upon navigation"),WebInspector.settings.preserveConsoleLog));if(WebInspector.extensionServer.hasExtensions()){var handlerSelector=new WebInspector.HandlerSelector(WebInspector.openAnchorLocationRegistry);p=this._appendSection(WebInspector.UIString("Extensions"));p.appendChild(this._createCustomSetting(WebInspector.UIString("Open links in"),handlerSelector.element));}
|
| +p=this._appendSection();var panelShortcutTitle=WebInspector.UIString("Enable %s + 1-9 shortcut to switch panels",WebInspector.isMac()?"Cmd":"Ctrl");p.appendChild(this._createCheckboxSetting(panelShortcutTitle,WebInspector.settings.shortcutPanelSwitch));}
|
| WebInspector.GenericSettingsTab.prototype={_forceCompositingModeChanged:function(event)
|
| -{var compositing=event?!!event.data:WebInspector.settings.forceCompositingMode.get();if(!compositing){this._showFPSCheckbox.checked=false;this._continousPaintingCheckbox.checked=false;this._showCompositedLayersBordersCheckbox.checked=false;this._showScrollBottleneckRectsCheckbox.checked=false;WebInspector.settings.showFPSCounter.set(false);WebInspector.settings.continuousPainting.set(false);WebInspector.settings.showDebugBorders.set(false);WebInspector.settings.showScrollBottleneckRects.set(false);}
|
| -this._forceCompositingModeCheckbox.checked=compositing;},_updateScriptDisabledCheckbox:function()
|
| +{var compositing=event?!!event.data:WebInspector.settings.forceCompositingMode.get();this._compositingModeSettings.disabled=!compositing
|
| +if(!compositing){this._showFPSCheckbox.checked=false;this._continousPaintingCheckbox.checked=false;this._showCompositedLayersBordersCheckbox.checked=false;this._showScrollBottleneckRectsCheckbox.checked=false;WebInspector.settings.showFPSCounter.set(false);WebInspector.settings.continuousPainting.set(false);WebInspector.settings.showDebugBorders.set(false);WebInspector.settings.showScrollBottleneckRects.set(false);}
|
| +this._forceCompositingModeCheckbox.checked=compositing;},_cssSourceMapsEnablementChanged:function(event)
|
| +{var cssSourceMapsEnabled=event?(event.data):WebInspector.settings.cssSourceMapsEnabled.get();this._cssSourceMapSettings.disabled=!cssSourceMapsEnabled;},_timelineLimitStackFramesChanged:function(fieldset)
|
| +{fieldset.disabled=!WebInspector.settings.timelineLimitStackFramesFlag.get();},_updateScriptDisabledCheckbox:function()
|
| {function executionStatusCallback(error,status)
|
| {if(error||!status)
|
| return;switch(status){case"forbidden":this._disableJSCheckbox.checked=true;this._disableJSCheckbox.disabled=true;break;case"disabled":this._disableJSCheckbox.checked=true;break;default:this._disableJSCheckbox.checked=false;break;}}
|
| PageAgent.getScriptExecutionStatus(executionStatusCallback.bind(this));},_javaScriptDisabledChanged:function()
|
| {PageAgent.setScriptExecutionDisabled(WebInspector.settings.javaScriptDisabled.get(),this._updateScriptDisabledCheckbox.bind(this));},_skipStackFramesSwitchOrPatternChanged:function()
|
| -{WebInspector.DebuggerModel.applySkipStackFrameSettings();},__proto__:WebInspector.SettingsTab.prototype}
|
| +{WebInspector.DebuggerModel.applySkipStackFrameSettings();},_createSkipStackFrameSetting:function()
|
| +{var fragment=document.createDocumentFragment();var labelElement=fragment.createChild("label");var checkboxElement=labelElement.createChild("input");checkboxElement.type="checkbox";checkboxElement.checked=WebInspector.settings.skipStackFramesSwitch.get();checkboxElement.addEventListener("click",checkboxClicked,false);labelElement.appendChild(document.createTextNode(WebInspector.UIString("Skip stepping through sources with particular names")));var fieldsetElement=this._createInputSetting(WebInspector.UIString("Pattern"),WebInspector.settings.skipStackFramesPattern,false,1000,"100px",regExpValidator);fieldsetElement.disabled=!checkboxElement.checked;fragment.appendChild(fieldsetElement);return fragment;function regExpValidator(text)
|
| +{try{var unused=new RegExp(text);unused.unused=unused;return null;}catch(e){return"Invalid pattern";}}
|
| +function checkboxClicked()
|
| +{var enabled=checkboxElement.checked;fieldsetElement.disabled=!checkboxElement.checked;WebInspector.settings.skipStackFramesSwitch.set(enabled);}},__proto__:WebInspector.SettingsTab.prototype}
|
| WebInspector.OverridesSettingsTab=function()
|
| {WebInspector.SettingsTab.call(this,WebInspector.UIString("Overrides"),"overrides-tab-content");this._view=new WebInspector.OverridesView();this.containerElement.parentElement.appendChild(this._view.containerElement);this.containerElement.remove();this.containerElement=this._view.containerElement;}
|
| WebInspector.OverridesSettingsTab.prototype={__proto__:WebInspector.SettingsTab.prototype}
|
| WebInspector.WorkspaceSettingsTab=function()
|
| -{WebInspector.SettingsTab.call(this,WebInspector.UIString("Workspace"),"workspace-tab-content");WebInspector.isolatedFileSystemManager.addEventListener(WebInspector.IsolatedFileSystemManager.Events.FileSystemAdded,this._fileSystemAdded,this);WebInspector.isolatedFileSystemManager.addEventListener(WebInspector.IsolatedFileSystemManager.Events.FileSystemRemoved,this._fileSystemRemoved,this);this._commonSection=this._appendSection(WebInspector.UIString("Common"));var folderExcludePatternInput=this._createInputSetting(WebInspector.UIString("Folder exclude pattern"),WebInspector.settings.workspaceFolderExcludePattern,false,0,"270px",WebInspector.SettingsScreen.regexValidator);this._commonSection.appendChild(folderExcludePatternInput);this._fileSystemsSection=this._appendSection(WebInspector.UIString("Folders"));this._fileSystemsListContainer=this._fileSystemsSection.createChild("p","settings-list-container");this._addFileSystemRowElement=this._fileSystemsSection.createChild("div");var addFileSystemButton=this._addFileSystemRowElement.createChild("input","text-button");addFileSystemButton.type="button";addFileSystemButton.value=WebInspector.UIString("Add folder\u2026");addFileSystemButton.addEventListener("click",this._addFileSystemClicked.bind(this));this._editFileSystemButton=this._addFileSystemRowElement.createChild("input","text-button");this._editFileSystemButton.type="button";this._editFileSystemButton.value=WebInspector.UIString("Edit\u2026");this._editFileSystemButton.addEventListener("click",this._editFileSystemClicked.bind(this));this._updateEditFileSystemButtonState();this._reset();}
|
| +{WebInspector.SettingsTab.call(this,WebInspector.UIString("Workspace"),"workspace-tab-content");WebInspector.isolatedFileSystemManager.addEventListener(WebInspector.IsolatedFileSystemManager.Events.FileSystemAdded,this._fileSystemAdded,this);WebInspector.isolatedFileSystemManager.addEventListener(WebInspector.IsolatedFileSystemManager.Events.FileSystemRemoved,this._fileSystemRemoved,this);WebInspector.isolatedFileSystemManager.mapping().addEventListener(WebInspector.FileSystemMapping.Events.FileMappingAdded,this._fileMappingAdded,this);WebInspector.isolatedFileSystemManager.mapping().addEventListener(WebInspector.FileSystemMapping.Events.FileMappingRemoved,this._fileMappingRemoved,this);this._fileSystemsSection=this._appendSection(WebInspector.UIString("Folders"));this._fileSystemsListContainer=this._fileSystemsSection.createChild("p","settings-list-container");this._addFileSystemRowElement=this._fileSystemsSection.createChild("div");var addFileSystemButton=this._addFileSystemRowElement.createChild("input","text-button");addFileSystemButton.type="button";addFileSystemButton.value=WebInspector.UIString("Add folder");addFileSystemButton.addEventListener("click",this._addFileSystemClicked.bind(this));this._reset();}
|
| WebInspector.WorkspaceSettingsTab.prototype={wasShown:function()
|
| {WebInspector.SettingsTab.prototype.wasShown.call(this);this._reset();},_reset:function()
|
| -{this._resetFileSystems();},_resetFileSystems:function()
|
| +{this._resetFileSystems();this._resetFileMappings();},_resetFileSystems:function()
|
| {this._fileSystemsListContainer.removeChildren();var fileSystemPaths=WebInspector.isolatedFileSystemManager.mapping().fileSystemPaths();delete this._fileSystemsList;if(!fileSystemPaths.length){var noFileSystemsMessageElement=this._fileSystemsListContainer.createChild("div","no-file-systems-message");noFileSystemsMessageElement.textContent=WebInspector.UIString("You have no file systems added.");return;}
|
| -this._fileSystemsList=new WebInspector.SettingsList(["path"],this._renderFileSystem.bind(this));this._fileSystemsList.element.addStyleClass("file-systems-list");this._fileSystemsList.addEventListener(WebInspector.SettingsList.Events.Selected,this._fileSystemSelected.bind(this));this._fileSystemsList.addEventListener(WebInspector.SettingsList.Events.Removed,this._fileSystemRemovedfromList.bind(this));this._fileSystemsList.addEventListener(WebInspector.SettingsList.Events.DoubleClicked,this._fileSystemDoubleClicked.bind(this));this._fileSystemsListContainer.appendChild(this._fileSystemsList.element);for(var i=0;i<fileSystemPaths.length;++i)
|
| -this._fileSystemsList.addItem(fileSystemPaths[i]);this._updateEditFileSystemButtonState();},_updateEditFileSystemButtonState:function()
|
| -{this._editFileSystemButton.disabled=!this._selectedFileSystemPath();},_fileSystemSelected:function(event)
|
| -{this._updateEditFileSystemButtonState();},_fileSystemDoubleClicked:function(event)
|
| -{var id=(event.data);this._editFileSystem(id);},_editFileSystemClicked:function(event)
|
| -{this._editFileSystem(this._selectedFileSystemPath());},_editFileSystem:function(id)
|
| -{WebInspector.EditFileSystemDialog.show(document.body,id);},_createRemoveButton:function(handler)
|
| +this._fileSystemsList=new WebInspector.SettingsList(["path"],this._renderFileSystem.bind(this),this._removeFileSystem.bind(this),this._fileSystemSelected.bind(this));this._fileSystemsList.onExpandToggle=this._fileSystemExpandToggled.bind(this);this._fileSystemsListContainer.appendChild(this._fileSystemsList.element);for(var i=0;i<fileSystemPaths.length;++i)
|
| +this._fileSystemsList.addItem(fileSystemPaths[i]);},_fileSystemSelected:function(id)
|
| +{this._resetFileMappings();},_fileSystemExpandToggled:function()
|
| +{this._resetFileMappings();},_createEditTextInput:function(className,placeHolder)
|
| +{var inputElement=document.createElement("input");inputElement.addStyleClass(className);inputElement.type="text";inputElement.placeholder=placeHolder;return inputElement;},_createRemoveButton:function(handler)
|
| {var removeButton=document.createElement("button");removeButton.addStyleClass("button");removeButton.addStyleClass("remove-item-button");removeButton.value=WebInspector.UIString("Remove");if(handler)
|
| removeButton.addEventListener("click",handler,false);else
|
| removeButton.disabled=true;return removeButton;},_renderFileSystem:function(columnElement,column,id)
|
| +{var fileSystemPath=id;var textElement=columnElement.createChild("span","list-column-text");var pathElement=textElement.createChild("span","file-system-path");pathElement.title=fileSystemPath;const maxTotalPathLength=60;const maxFolderNameLength=30;var lastIndexOfSlash=fileSystemPath.lastIndexOf(WebInspector.isWin()?"\\":"/");var folderName=fileSystemPath.substr(lastIndexOfSlash+1);var folderPath=fileSystemPath.substr(0,lastIndexOfSlash+1);folderPath=folderPath.trimMiddle(maxTotalPathLength-Math.min(maxFolderNameLength,folderName.length));folderName=folderName.trimMiddle(maxFolderNameLength);var folderPathElement=pathElement.createChild("span");folderPathElement.textContent=folderPath;var nameElement=pathElement.createChild("span","file-system-path-name");nameElement.textContent=folderName;},_removeFileSystem:function(id)
|
| {if(!id)
|
| -return"";var fileSystemPath=id;var textElement=columnElement.createChild("span","list-column-text");var pathElement=textElement.createChild("span","file-system-path");pathElement.title=fileSystemPath;const maxTotalPathLength=55;const maxFolderNameLength=30;var lastIndexOfSlash=fileSystemPath.lastIndexOf(WebInspector.isWin()?"\\":"/");var folderName=fileSystemPath.substr(lastIndexOfSlash+1);var folderPath=fileSystemPath.substr(0,lastIndexOfSlash+1);folderPath=folderPath.trimMiddle(maxTotalPathLength-Math.min(maxFolderNameLength,folderName.length));folderName=folderName.trimMiddle(maxFolderNameLength);var folderPathElement=pathElement.createChild("span");folderPathElement.textContent=folderPath;var nameElement=pathElement.createChild("span","file-system-path-name");nameElement.textContent=folderName;},_fileSystemRemovedfromList:function(event)
|
| -{var id=(event.data);if(!id)
|
| return;WebInspector.isolatedFileSystemManager.removeFileSystem(id);},_addFileSystemClicked:function()
|
| {WebInspector.isolatedFileSystemManager.addFileSystem();},_fileSystemAdded:function(event)
|
| {var fileSystem=(event.data);if(!this._fileSystemsList)
|
| this._reset();else
|
| this._fileSystemsList.addItem(fileSystem.path());},_fileSystemRemoved:function(event)
|
| -{var fileSystem=(event.data);var selectedFileSystemPath=this._selectedFileSystemPath();if(this._fileSystemsList.itemForId(fileSystem.path()))
|
| -this._fileSystemsList.removeItem(fileSystem.path());if(!this._fileSystemsList.itemIds().length)
|
| -this._reset();this._updateEditFileSystemButtonState();},_selectedFileSystemPath:function()
|
| -{return this._fileSystemsList?this._fileSystemsList.selectedId():null;},__proto__:WebInspector.SettingsTab.prototype}
|
| +{var fileSystem=(event.data);var selectedFileSystemPath=this._selectedFileSystemPath();this._fileSystemsList.removeItem(fileSystem.path());if(!this._fileSystemsList.itemIds().length)
|
| +this._reset();else if(fileSystem.path()===selectedFileSystemPath)
|
| +this._resetFileMappings();},_fileMappingAdded:function(event)
|
| +{var entry=(event.data);this._addMappingRow(entry);},_fileMappingRemoved:function(event)
|
| +{var entry=(event.data);if(!this._selectedFileSystemPath()||this._selectedFileSystemPath()!==entry.fileSystemPath)
|
| +return;delete this._entries[entry.urlPrefix];this._fileMappingsList.removeItem(entry.urlPrefix);},_selectedFileSystemPath:function()
|
| +{return this._fileSystemsList?this._fileSystemsList.selectedId():null;},_resetFileMappings:function()
|
| +{if(this._fileMappingsSection){this._fileMappingsSection.remove();delete this._fileMappingsSection;delete this._fileMappingsListContainer;delete this._fileMappingsList;}
|
| +if(!this._selectedFileSystemPath()||!this._fileSystemsList.expanded())
|
| +return;var fileSystemListItem=this._fileSystemsList.selectedItem();this._fileMappingsSection=fileSystemListItem.createChild("div","file-mappings-section");this._fileMappingsListContainer=this._fileMappingsSection.createChild("div","file-mappings-list-container");var entries=WebInspector.isolatedFileSystemManager.mapping().mappingEntries(this._selectedFileSystemPath());if(this._fileMappingsList)
|
| +this._fileMappingsList.element.remove();this._fileMappingsList=new WebInspector.EditableSettingsList(["url","path"],this._fileMappingValuesProvider.bind(this),this._removeFileMapping.bind(this),this._fileMappingValidate.bind(this),this._fileMappingEdit.bind(this));this._fileMappingsList.element.addStyleClass("file-mappings-list");this._fileMappingsListContainer.appendChild(this._fileMappingsList.element);this._entries={};for(var i=0;i<entries.length;++i)
|
| +this._addMappingRow(entries[i]);return this._fileMappingsList;},_fileMappingValuesProvider:function(itemId,columnId)
|
| +{if(!itemId)
|
| +return"";var entry=this._entries[itemId];switch(columnId){case"url":return entry.urlPrefix;case"path":return entry.pathPrefix;default:console.assert("Should not be reached.");}
|
| +return"";},_fileMappingValidate:function(itemId,data)
|
| +{var oldPathPrefix=itemId?this._entries[itemId].pathPrefix:null;return this._validateMapping(data["url"],itemId,data["path"],oldPathPrefix);},_fileMappingEdit:function(itemId,data)
|
| +{if(itemId){var urlPrefix=itemId;var pathPrefix=this._entries[itemId].pathPrefix;var fileSystemPath=this._entries[itemId].fileSystemPath;WebInspector.isolatedFileSystemManager.mapping().removeFileMapping(fileSystemPath,urlPrefix,pathPrefix);}
|
| +this._addFileMapping(data["url"],data["path"]);},_validateMapping:function(urlPrefix,allowedURLPrefix,path,allowedPathPrefix)
|
| +{var columns=[];if(!this._checkURLPrefix(urlPrefix,allowedURLPrefix))
|
| +columns.push("url");if(!this._checkPathPrefix(path,allowedPathPrefix))
|
| +columns.push("path");return columns;},_removeFileMapping:function(urlPrefix)
|
| +{if(!urlPrefix)
|
| +return;var entry=this._entries[urlPrefix];WebInspector.isolatedFileSystemManager.mapping().removeFileMapping(entry.fileSystemPath,entry.urlPrefix,entry.pathPrefix);},_addFileMapping:function(urlPrefix,pathPrefix)
|
| +{var normalizedURLPrefix=this._normalizePrefix(urlPrefix);var normalizedPathPrefix=this._normalizePrefix(pathPrefix);WebInspector.isolatedFileSystemManager.mapping().addFileMapping(this._selectedFileSystemPath(),normalizedURLPrefix,normalizedPathPrefix);this._fileMappingsList.selectItem(normalizedURLPrefix);return true;},_normalizePrefix:function(prefix)
|
| +{if(!prefix)
|
| +return"";return prefix+(prefix[prefix.length-1]==="/"?"":"/");},_addMappingRow:function(entry)
|
| +{var fileSystemPath=entry.fileSystemPath;var urlPrefix=entry.urlPrefix;if(!this._selectedFileSystemPath()||this._selectedFileSystemPath()!==fileSystemPath)
|
| +return;this._entries[urlPrefix]=entry;var fileMappingListItem=this._fileMappingsList.addItem(urlPrefix,null);},_checkURLPrefix:function(value,allowedPrefix)
|
| +{var prefix=this._normalizePrefix(value);return!!prefix&&(prefix===allowedPrefix||!this._entries[prefix]);},_checkPathPrefix:function(value,allowedPrefix)
|
| +{var prefix=this._normalizePrefix(value);if(!prefix)
|
| +return false;if(prefix===allowedPrefix)
|
| +return true;for(var urlPrefix in this._entries){var entry=this._entries[urlPrefix];if(urlPrefix&&entry.pathPrefix===prefix)
|
| +return false;}
|
| +return true;},__proto__:WebInspector.SettingsTab.prototype}
|
| +WebInspector.TetheringSettingsTab=function()
|
| +{WebInspector.SettingsTab.call(this,WebInspector.UIString("Port Forwarding"),"workspace-tab-content");}
|
| +WebInspector.TetheringSettingsTab.prototype={wasShown:function()
|
| +{if(this._paragraphElement)
|
| +return;WebInspector.SettingsTab.prototype.wasShown.call(this);var sectionElement=this._appendSection();var labelElement=sectionElement.createChild("div");labelElement.addStyleClass("tethering-help-info");labelElement.textContent=WebInspector.UIString("Creates a listen TCP port on your device that maps to a particular TCP port accessible from the host machine.");labelElement.createChild("br");labelElement.createChild("div","tethering-help-title-left").textContent=WebInspector.UIString("Device port");labelElement.createChild("div","tethering-help-title-right").textContent=WebInspector.UIString("Target");this._paragraphElement=sectionElement.createChild("div");var mappingEntries=WebInspector.settings.portForwardings.get();for(var i=0;i<mappingEntries.length;++i)
|
| +this._addMappingRow(mappingEntries[i].port,mappingEntries[i].location,false);if(!mappingEntries.length)
|
| +this._addMappingRow("","",true);this._save();},_addMappingRow:function(port,location,focus)
|
| +{var mappingRow=this._paragraphElement.createChild("div","workspace-settings-row");var portElement=mappingRow.createChild("input","tethering-port-input");portElement.type="text";portElement.value=port||"";if(!port)
|
| +portElement.placeholder="8080";portElement.addEventListener("keydown",this._editTextInputKey.bind(this,true),true);portElement.addEventListener("blur",this._save.bind(this),true);portElement.addEventListener("input",this._validatePort.bind(this,portElement),true);var locationElement=mappingRow.createChild("input");locationElement.type="text";locationElement.value=location||"127.0.0.1:";locationElement.addEventListener("keydown",this._editTextInputKey.bind(this,false),true);locationElement.addEventListener("blur",this._save.bind(this),true);locationElement.addEventListener("input",this._validateLocation.bind(this,locationElement),true);var removeButton=mappingRow.createChild("button","button remove-button");removeButton.value=WebInspector.UIString("Remove");removeButton.tabIndex=-1;removeButton.addEventListener("click",removeMappingClicked.bind(this),false);function removeMappingClicked()
|
| +{mappingRow.remove();if(!this._paragraphElement.querySelector(".workspace-settings-row"))
|
| +this._addMappingRow();this._save();}
|
| +if(focus)
|
| +setTimeout(function(){portElement.focus();},0);return mappingRow;},_save:function()
|
| +{var portForwardings=[];for(var rowElement=this._paragraphElement.firstChild;rowElement;rowElement=rowElement.nextSibling){var portElement=rowElement.firstChild;var locationElement=portElement.nextSibling;var port=this._validatePort(portElement);var location=this._validateLocation(locationElement);if(!port||!location)
|
| +continue;portForwardings.push({port:parseInt(port,10),location:location});}
|
| +WebInspector.settings.portForwardings.set(portForwardings);},_editTextInputKey:function(isPort,event)
|
| +{if(!WebInspector.KeyboardShortcut.hasNoModifiers((event)))
|
| +return;if(event.keyCode===WebInspector.KeyboardShortcut.Keys.Enter.code||event.keyCode===WebInspector.KeyboardShortcut.Keys.Tab.code){if(isPort)
|
| +event.target.nextElementSibling.focus();else{if(event.target.parentElement.nextSibling)
|
| +event.target.parentElement.nextSibling.firstChild.focus();else
|
| +this._addMappingRow("","",true);}
|
| +event.consume(true);}},_validatePort:function(element,event)
|
| +{var port=element.value;if(isNaN(port)||port<5000||port>10000){element.addStyleClass("workspace-settings-error");return 0;}
|
| +element.removeStyleClass("workspace-settings-error");return parseInt(port,10);},_validateLocation:function(element,event)
|
| +{var location=element.value;if(!/.*:\d+/.test(location)){element.addStyleClass("workspace-settings-error");return"";}
|
| +element.removeStyleClass("workspace-settings-error");return location;},__proto__:WebInspector.SettingsTab.prototype}
|
| WebInspector.ExperimentsSettingsTab=function()
|
| {WebInspector.SettingsTab.call(this,WebInspector.UIString("Experiments"),"experiments-tab-content");var experiments=WebInspector.experimentsSettings.experiments;if(experiments.length){var experimentsSection=this._appendSection();experimentsSection.appendChild(this._createExperimentsWarningSubsection());for(var i=0;i<experiments.length;++i)
|
| experimentsSection.appendChild(this._createExperimentCheckbox(experiments[i]));}}
|
| @@ -8334,17 +8864,16 @@
|
| this._settingsScreen.hide();},resize:function()
|
| {if(this._settingsScreen&&this._settingsScreen.isShowing())
|
| this._settingsScreen.doResize();}}
|
| -WebInspector.SettingsList=function(columns,itemRenderer)
|
| -{this.element=document.createElement("div");this.element.addStyleClass("settings-list");this.element.tabIndex=-1;this._itemRenderer=itemRenderer;this._listItems={};this._ids=[];this._columns=columns;}
|
| -WebInspector.SettingsList.Events={Selected:"Selected",Removed:"Removed",DoubleClicked:"DoubleClicked",}
|
| +WebInspector.SettingsList=function(columns,itemRenderer,itemRemover,itemSelectedHandler)
|
| +{this.element=document.createElement("div");this.element.addStyleClass("settings-list");this.element.tabIndex=-1;this._itemRenderer=itemRenderer;this._listItems={};this._ids=[];this._itemRemover=itemRemover;this._itemSelectedHandler=itemSelectedHandler;this._columns=columns;}
|
| WebInspector.SettingsList.prototype={addItem:function(itemId,beforeId)
|
| {var listItem=document.createElement("div");listItem._id=itemId;listItem.addStyleClass("settings-list-item");if(typeof beforeId!==undefined)
|
| this.element.insertBefore(listItem,this._listItems[beforeId]);else
|
| this.element.appendChild(listItem);var listItemContents=listItem.createChild("div","settings-list-item-contents");var listItemColumnsElement=listItemContents.createChild("div","settings-list-item-columns");listItem.columnElements={};for(var i=0;i<this._columns.length;++i){var columnElement=listItemColumnsElement.createChild("div","list-column");var columnId=this._columns[i];listItem.columnElements[columnId]=columnElement;this._itemRenderer(columnElement,columnId,itemId);}
|
| -var removeItemButton=this._createRemoveButton(removeItemClicked.bind(this));listItemContents.addEventListener("click",this.selectItem.bind(this,itemId),false);listItemContents.addEventListener("dblclick",this._onDoubleClick.bind(this,itemId),false);listItemContents.appendChild(removeItemButton);this._listItems[itemId]=listItem;if(typeof beforeId!==undefined)
|
| +var removeItemButton=this._createRemoveButton(removeItemClicked.bind(this));listItemContents.addEventListener("click",this.selectItem.bind(this,itemId),false);listItemContents.appendChild(removeItemButton);this._listItems[itemId]=listItem;if(typeof beforeId!==undefined)
|
| this._ids.splice(this._ids.indexOf(beforeId),0,itemId);else
|
| this._ids.push(itemId);function removeItemClicked(event)
|
| -{removeItemButton.disabled=true;this.removeItem(itemId);this.dispatchEventToListeners(WebInspector.SettingsList.Events.Removed,itemId);event.consume();}
|
| +{removeItemButton.disabled=true;this._itemRemover(itemId);event.consume();}
|
| return listItem;},removeItem:function(id)
|
| {this._listItems[id].remove();delete this._listItems[id];this._ids.remove(id);if(id===this._selectedId){delete this._selectedId;if(this._ids.length)
|
| this.selectItem(this._ids[0]);}},itemIds:function()
|
| @@ -8352,18 +8881,23 @@
|
| {return this._columns.slice();},selectedId:function()
|
| {return this._selectedId;},selectedItem:function()
|
| {return this._selectedId?this._listItems[this._selectedId]:null;},itemForId:function(itemId)
|
| -{return this._listItems[itemId];},_onDoubleClick:function(id,event)
|
| -{this.dispatchEventToListeners(WebInspector.SettingsList.Events.DoubleClicked,id);},selectItem:function(id,event)
|
| -{if(typeof this._selectedId!=="undefined"){this._listItems[this._selectedId].removeStyleClass("selected");}
|
| -this._selectedId=id;if(typeof this._selectedId!=="undefined"){this._listItems[this._selectedId].addStyleClass("selected");}
|
| -this.dispatchEventToListeners(WebInspector.SettingsList.Events.Selected,id);if(event)
|
| +{return this._listItems[itemId];},expanded:function()
|
| +{return this._expanded;},toggleExpanded:function()
|
| +{if(this._expanded)
|
| +delete this._expanded;else
|
| +this._expanded=true;if(this.onExpandToggle)
|
| +this.onExpandToggle();},selectItem:function(id,event)
|
| +{if(id===this._selectedId){this.toggleExpanded();return;}
|
| +if(typeof this._selectedId!=="undefined"){delete this._expanded;this._listItems[this._selectedId].removeStyleClass("selected");}
|
| +this._selectedId=id;if(typeof this._selectedId!=="undefined"){this._listItems[this._selectedId].addStyleClass("selected");this.toggleExpanded();}
|
| +this._itemSelectedHandler(id);if(event)
|
| event.consume();},_createRemoveButton:function(handler)
|
| -{var removeButton=document.createElement("button");removeButton.addStyleClass("remove-item-button");removeButton.value=WebInspector.UIString("Remove");removeButton.addEventListener("click",handler,false);return removeButton;},__proto__:WebInspector.Object.prototype}
|
| -WebInspector.EditableSettingsList=function(columns,valuesProvider,validateHandler,editHandler)
|
| -{WebInspector.SettingsList.call(this,columns,this._renderColumn.bind(this));this._validateHandler=validateHandler;this._editHandler=editHandler;this._valuesProvider=valuesProvider;this._addInputElements={};this._editInputElements={};this._textElements={};this._addMappingItem=this.addItem(null);this._addMappingItem.addStyleClass("item-editing");this._addMappingItem.addStyleClass("add-list-item");}
|
| +{var removeButton=document.createElement("button");removeButton.addStyleClass("remove-item-button");removeButton.value=WebInspector.UIString("Remove");removeButton.addEventListener("click",handler,false);return removeButton;}}
|
| +WebInspector.EditableSettingsList=function(columns,valuesProvider,itemRemover,validateHandler,editHandler)
|
| +{WebInspector.SettingsList.call(this,columns,this._renderColumn.bind(this),itemRemover,function(){});this._validateHandler=validateHandler;this._editHandler=editHandler;this._valuesProvider=valuesProvider;this._addInputElements={};this._editInputElements={};this._textElements={};this._addMappingItem=this.addItem(null);this._addMappingItem.addStyleClass("item-editing");this._addMappingItem.addStyleClass("add-list-item");}
|
| WebInspector.EditableSettingsList.prototype={addItem:function(itemId,beforeId)
|
| {var listItem=WebInspector.SettingsList.prototype.addItem.call(this,itemId,beforeId);listItem.addStyleClass("editable");return listItem;},_renderColumn:function(columnElement,columnId,itemId)
|
| -{columnElement.addStyleClass("settings-list-column-"+columnId);var placeholder=(columnId==="url")?WebInspector.UIString("URL prefix"):WebInspector.UIString("Folder path");if(itemId===null){var inputElement=columnElement.createChild("input","list-column-editor");inputElement.placeholder=placeholder;inputElement.addEventListener("blur",this._onAddMappingInputBlur.bind(this));inputElement.addEventListener("input",this._validateEdit.bind(this,itemId));this._addInputElements[columnId]=inputElement;return;}
|
| +{columnElement.addStyleClass("file-mapping-"+columnId);var placeholder=(columnId==="url")?WebInspector.UIString("URL prefix"):WebInspector.UIString("Folder path");if(itemId===null){var inputElement=columnElement.createChild("input","list-column-editor");inputElement.placeholder=placeholder;inputElement.addEventListener("blur",this._onAddMappingInputBlur.bind(this));inputElement.addEventListener("input",this._validateEdit.bind(this,itemId));this._addInputElements[columnId]=inputElement;return;}
|
| if(!this._editInputElements[itemId])
|
| this._editInputElements[itemId]={};if(!this._textElements[itemId])
|
| this._textElements[itemId]={};var value=this._valuesProvider(itemId,columnId);var textElement=columnElement.createChild("span","list-column-text");textElement.textContent=value;textElement.title=value;columnElement.addEventListener("click",rowClicked.bind(this),false);this._textElements[itemId][columnId]=textElement;var inputElement=columnElement.createChild("input","list-column-editor");inputElement.value=value;inputElement.addEventListener("blur",this._editMappingBlur.bind(this,itemId));inputElement.addEventListener("input",this._validateEdit.bind(this,itemId));columnElement.inputElement=inputElement;this._editInputElements[itemId][columnId]=inputElement;function rowClicked(event)
|
| @@ -8388,61 +8922,6 @@
|
| return;if(!this._hasChanges(null))
|
| return;if(!this._validateEdit(null))
|
| return;this._editHandler(null,this._data(null));var columns=this.columns();for(var i=0;i<columns.length;++i){var columnId=columns[i];var inputElement=this._addInputElements[columnId];inputElement.value="";}},__proto__:WebInspector.SettingsList.prototype}
|
| -WebInspector.EditFileSystemDialog=function(fileSystemPath)
|
| -{WebInspector.DialogDelegate.call(this);this._fileSystemPath=fileSystemPath;this.element=document.createElement("div");this.element.className="edit-file-system-dialog";var header=this.element.createChild("div","header");var headerText=header.createChild("span");headerText.textContent="Edit file system";var closeButton=header.createChild("div","close-button-gray done-button");closeButton.addEventListener("click",this._onDoneClick.bind(this),false);var contents=this.element.createChild("div","contents");WebInspector.isolatedFileSystemManager.mapping().addEventListener(WebInspector.FileSystemMapping.Events.FileMappingAdded,this._fileMappingAdded,this);WebInspector.isolatedFileSystemManager.mapping().addEventListener(WebInspector.FileSystemMapping.Events.FileMappingRemoved,this._fileMappingRemoved,this);WebInspector.isolatedFileSystemManager.mapping().addEventListener(WebInspector.FileSystemMapping.Events.ExcludedFolderAdded,this._excludedFolderAdded,this);WebInspector.isolatedFileSystemManager.mapping().addEventListener(WebInspector.FileSystemMapping.Events.ExcludedFolderRemoved,this._excludedFolderRemoved,this);var blockHeader=contents.createChild("div","block-header");blockHeader.textContent="Mappings";this._fileMappingsSection=contents.createChild("div","file-mappings-section");this._fileMappingsListContainer=this._fileMappingsSection.createChild("div","settings-list-container");var entries=WebInspector.isolatedFileSystemManager.mapping().mappingEntries(this._fileSystemPath);this._fileMappingsList=new WebInspector.EditableSettingsList(["url","path"],this._fileMappingValuesProvider.bind(this),this._fileMappingValidate.bind(this),this._fileMappingEdit.bind(this));this._fileMappingsList.addEventListener(WebInspector.SettingsList.Events.Removed,this._fileMappingRemovedfromList.bind(this));this._fileMappingsList.element.addStyleClass("file-mappings-list");this._fileMappingsListContainer.appendChild(this._fileMappingsList.element);this._entries={};for(var i=0;i<entries.length;++i)
|
| -this._addMappingRow(entries[i]);blockHeader=contents.createChild("div","block-header");blockHeader.textContent="Excluded folders";this._excludedFolderListSection=contents.createChild("div","excluded-folders-section");this._excludedFolderListContainer=this._excludedFolderListSection.createChild("div","settings-list-container");var excludedFolderEntries=WebInspector.isolatedFileSystemManager.mapping().excludedFolders(fileSystemPath);this._excludedFolderList=new WebInspector.EditableSettingsList(["path"],this._excludedFolderValueProvider.bind(this),this._excludedFolderValidate.bind(this),this._excludedFolderEdit.bind(this));this._excludedFolderList.addEventListener(WebInspector.SettingsList.Events.Removed,this._excludedFolderRemovedfromList.bind(this));this._excludedFolderList.element.addStyleClass("excluded-folders-list");this._excludedFolderListContainer.appendChild(this._excludedFolderList.element);this._excludedFolderEntries=new StringMap();for(var i=0;i<excludedFolderEntries.length;++i)
|
| -this._addExcludedFolderRow(excludedFolderEntries[i]);this.element.tabIndex=0;}
|
| -WebInspector.EditFileSystemDialog.show=function(element,fileSystemPath)
|
| -{WebInspector.Dialog.show(element,new WebInspector.EditFileSystemDialog(fileSystemPath));var glassPane=document.getElementById("glass-pane");glassPane.addStyleClass("settings-glass-pane");}
|
| -WebInspector.EditFileSystemDialog.prototype={show:function(element)
|
| -{element.appendChild(this.element);this.element.addStyleClass("dialog-contents");element.addStyleClass("settings-dialog");element.addStyleClass("settings-tab");this._dialogElement=element;},_resize:function()
|
| -{if(!this._dialogElement)
|
| -return;const width=540;const minHeight=150;var maxHeight=document.body.offsetHeight-10;maxHeight=Math.max(minHeight,maxHeight);this._dialogElement.style.maxHeight=maxHeight+"px";this._dialogElement.style.width=width+"px";},position:function(element,relativeToElement)
|
| -{this._resize();},willHide:function(event)
|
| -{},_fileMappingAdded:function(event)
|
| -{var entry=(event.data);this._addMappingRow(entry);},_fileMappingRemoved:function(event)
|
| -{var entry=(event.data);if(this._fileSystemPath!==entry.fileSystemPath)
|
| -return;delete this._entries[entry.urlPrefix];if(this._fileMappingsList.itemForId(entry.urlPrefix))
|
| -this._fileMappingsList.removeItem(entry.urlPrefix);this._resize();},_fileMappingValuesProvider:function(itemId,columnId)
|
| -{if(!itemId)
|
| -return"";var entry=this._entries[itemId];switch(columnId){case"url":return entry.urlPrefix;case"path":return entry.pathPrefix;default:console.assert("Should not be reached.");}
|
| -return"";},_fileMappingValidate:function(itemId,data)
|
| -{var oldPathPrefix=itemId?this._entries[itemId].pathPrefix:null;return this._validateMapping(data["url"],itemId,data["path"],oldPathPrefix);},_fileMappingEdit:function(itemId,data)
|
| -{if(itemId){var urlPrefix=itemId;var pathPrefix=this._entries[itemId].pathPrefix;var fileSystemPath=this._entries[itemId].fileSystemPath;WebInspector.isolatedFileSystemManager.mapping().removeFileMapping(fileSystemPath,urlPrefix,pathPrefix);}
|
| -this._addFileMapping(data["url"],data["path"]);},_validateMapping:function(urlPrefix,allowedURLPrefix,path,allowedPathPrefix)
|
| -{var columns=[];if(!this._checkURLPrefix(urlPrefix,allowedURLPrefix))
|
| -columns.push("url");if(!this._checkPathPrefix(path,allowedPathPrefix))
|
| -columns.push("path");return columns;},_fileMappingRemovedfromList:function(event)
|
| -{var urlPrefix=(event.data);if(!urlPrefix)
|
| -return;var entry=this._entries[urlPrefix];WebInspector.isolatedFileSystemManager.mapping().removeFileMapping(entry.fileSystemPath,entry.urlPrefix,entry.pathPrefix);},_addFileMapping:function(urlPrefix,pathPrefix)
|
| -{var normalizedURLPrefix=this._normalizePrefix(urlPrefix);var normalizedPathPrefix=this._normalizePrefix(pathPrefix);WebInspector.isolatedFileSystemManager.mapping().addFileMapping(this._fileSystemPath,normalizedURLPrefix,normalizedPathPrefix);this._fileMappingsList.selectItem(normalizedURLPrefix);return true;},_normalizePrefix:function(prefix)
|
| -{if(!prefix)
|
| -return"";return prefix+(prefix[prefix.length-1]==="/"?"":"/");},_addMappingRow:function(entry)
|
| -{var fileSystemPath=entry.fileSystemPath;var urlPrefix=entry.urlPrefix;if(!this._fileSystemPath||this._fileSystemPath!==fileSystemPath)
|
| -return;this._entries[urlPrefix]=entry;var fileMappingListItem=this._fileMappingsList.addItem(urlPrefix,null);this._resize();},_excludedFolderAdded:function(event)
|
| -{var entry=(event.data);this._addExcludedFolderRow(entry);},_excludedFolderRemoved:function(event)
|
| -{var entry=(event.data);var fileSystemPath=entry.fileSystemPath;if(!fileSystemPath||this._fileSystemPath!==fileSystemPath)
|
| -return;delete this._excludedFolderEntries[entry.path];if(this._excludedFolderList.itemForId(entry.path))
|
| -this._excludedFolderList.removeItem(entry.path);},_excludedFolderValueProvider:function(itemId,columnId)
|
| -{return itemId;},_excludedFolderValidate:function(itemId,data)
|
| -{var fileSystemPath=this._fileSystemPath;var columns=[];if(!this._validateExcludedFolder(data["path"],itemId))
|
| -columns.push("path");return columns;},_validateExcludedFolder:function(path,allowedPath)
|
| -{return!!path&&(path===allowedPath||!this._excludedFolderEntries.contains(path));},_excludedFolderEdit:function(itemId,data)
|
| -{var fileSystemPath=this._fileSystemPath;if(itemId)
|
| -WebInspector.isolatedFileSystemManager.mapping().removeExcludedFolder(fileSystemPath,itemId);var excludedFolderPath=data["path"];WebInspector.isolatedFileSystemManager.mapping().addExcludedFolder(fileSystemPath,excludedFolderPath);},_excludedFolderRemovedfromList:function(event)
|
| -{var itemId=(event.data);if(!itemId)
|
| -return;WebInspector.isolatedFileSystemManager.mapping().removeExcludedFolder(this._fileSystemPath,itemId);},_addExcludedFolderRow:function(entry)
|
| -{var fileSystemPath=entry.fileSystemPath;if(!fileSystemPath||this._fileSystemPath!==fileSystemPath)
|
| -return;var path=entry.path;this._excludedFolderEntries.put(path,entry);this._excludedFolderList.addItem(path,null);},_checkURLPrefix:function(value,allowedPrefix)
|
| -{var prefix=this._normalizePrefix(value);return!!prefix&&(prefix===allowedPrefix||!this._entries[prefix]);},_checkPathPrefix:function(value,allowedPrefix)
|
| -{var prefix=this._normalizePrefix(value);if(!prefix)
|
| -return false;if(prefix===allowedPrefix)
|
| -return true;for(var urlPrefix in this._entries){var entry=this._entries[urlPrefix];if(urlPrefix&&entry.pathPrefix===prefix)
|
| -return false;}
|
| -return true;},focus:function()
|
| -{WebInspector.setCurrentFocusElement(this.element);},_onDoneClick:function()
|
| -{WebInspector.Dialog.hide();},onEnter:function()
|
| -{},__proto__:WebInspector.DialogDelegate.prototype}
|
| WebInspector.ShortcutsScreen=function()
|
| {this._sections=({});}
|
| WebInspector.ShortcutsScreen.prototype={section:function(name)
|
| @@ -8467,21 +8946,27 @@
|
| result.appendChild(delimiter.cloneNode(true));result.appendChild(nodes[i]);}
|
| return result;}}
|
| WebInspector.OverridesView=function()
|
| -{WebInspector.View.call(this);this.registerRequiredCSS("helpScreen.css");this.element.addStyleClass("fill");this.element.addStyleClass("help-window-main");this.element.addStyleClass("settings-tab-container");var paneContent=this.element.createChild("div","tabbed-pane-content");var headerTitle=paneContent.createChild("header").createChild("h3");headerTitle.appendChild(document.createTextNode(WebInspector.UIString("Overrides")));var wrapper=paneContent.createChild("div","help-container-wrapper overrides-view");var topContainer=wrapper.createChild("div","settings-tab help-content");var enableOptionsContainer=topContainer.createChild("div","help-block");var enableOnStartupField=WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Enable on DevTools startup"),WebInspector.settings.enableOverridesOnStartup);enableOnStartupField.id="enable-devtools-on-startup";this._enableOnStartupField=enableOnStartupField;var enableLabel=this._createNonPersistedCheckbox(WebInspector.UIString("Enable"),this._setOverridesActive.bind(this));var enableCheckbox=enableLabel.getElementsByTagName("input")[0];enableCheckbox.checked=WebInspector.settings.enableOverridesOnStartup.get();enableOptionsContainer.appendChild(enableLabel);enableOptionsContainer.appendChild(enableOnStartupField);var mainContainer=topContainer.createChild("fieldset","help-container");this._mainContainer=mainContainer;function appendBlock(contentElements)
|
| +{WebInspector.View.call(this);this.registerRequiredCSS("helpScreen.css");this.element.addStyleClass("fill");this.element.addStyleClass("help-window-main");this.element.addStyleClass("settings-tab-container");var paneContent=this.element.createChild("div","tabbed-pane-content");var headerTitle=paneContent.createChild("header").createChild("h3");headerTitle.appendChild(document.createTextNode(WebInspector.UIString("Overrides")));var wrapper=paneContent.createChild("div","help-container-wrapper overrides-view");var topContainer=wrapper.createChild("div","settings-tab help-content");var enableOptionsContainer=topContainer.createChild("div","help-block");function enableClicked(enabled)
|
| +{WebInspector.overridesSupport.setOverridesActive(enabled);this._mainContainer.disabled=!enabled;}
|
| +var boundEnableClicked=enableClicked.bind(this);var enableLabel=this._createNonPersistedCheckbox(WebInspector.UIString("Enable"),boundEnableClicked);var enableCheckbox=enableLabel.getElementsByTagName("input")[0];enableCheckbox.checked=WebInspector.settings.enableOverridesOnStartup.get();enableOptionsContainer.appendChild(enableLabel);var enableOnStartupPara=this._createCheckboxSetting(WebInspector.UIString("Enable on DevTools startup"),WebInspector.settings.enableOverridesOnStartup);enableOnStartupPara.id="enable-devtools-on-startup";enableOptionsContainer.appendChild(enableOnStartupPara);function enableOnStartupClicked(event)
|
| +{var enableOnStartup=(event.data);if(enableOnStartup){enableCheckbox.checked=true;boundEnableClicked(true);}}
|
| +WebInspector.settings.enableOverridesOnStartup.addChangeListener(enableOnStartupClicked,this);var mainContainer=topContainer.createChild("div","help-container");this._mainContainer=mainContainer;function appendBlock(contentElements)
|
| {var blockElement=mainContainer.createChild("div","help-block");for(var i=0;i<contentElements.length;++i)
|
| blockElement.appendChild(contentElements[i]);}
|
| -this.containerElement=topContainer;appendBlock([this._createUserAgentControl()]);appendBlock([this._createDeviceMetricsControl()]);appendBlock([this._createGeolocationOverrideControl()]);appendBlock([this._createDeviceOrientationOverrideControl()]);appendBlock([WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Emulate touch events"),WebInspector.settings.emulateTouchEvents)]);appendBlock([this._createMediaEmulationElement()]);this._setOverridesActive(enableCheckbox.checked);this._statusElement=document.createElement("span");this._statusElement.textContent=WebInspector.UIString("Overrides");}
|
| +this.containerElement=topContainer;appendBlock([this._createUserAgentControl()]);appendBlock([this._createDeviceMetricsControl()]);appendBlock([this._createGeolocationOverrideControl()]);appendBlock([this._createDeviceOrientationOverrideControl()]);appendBlock([this._createCheckboxSetting(WebInspector.UIString("Emulate touch events"),WebInspector.settings.emulateTouchEvents)]);appendBlock([this._createMediaEmulationElement()]);boundEnableClicked(enableCheckbox.checked);this._statusElement=document.createElement("span");this._statusElement.textContent=WebInspector.UIString("Overrides");}
|
| WebInspector.OverridesView.showInDrawer=function()
|
| {if(!WebInspector.OverridesView._view)
|
| WebInspector.OverridesView._view=new WebInspector.OverridesView();var view=WebInspector.OverridesView._view;WebInspector.showViewInDrawer(view._statusElement,view);}
|
| -WebInspector.OverridesView.prototype={_setOverridesActive:function(active)
|
| -{WebInspector.overridesSupport.setOverridesActive(active);this._mainContainer.disabled=!active;this._enableOnStartupField.disabled=!active;},_createSettingCheckbox:function(name,setting,callback)
|
| -{var checkbox=WebInspector.SettingsTab.createCheckbox(name,setting.get.bind(setting),listener);function listener(value)
|
| -{setting.set(value);if(callback)
|
| -callback(value);}
|
| -return checkbox;},_createUserAgentControl:function()
|
| -{var checkbox=WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("User Agent"),WebInspector.settings.overrideUserAgent);checkbox.appendChild(this._createUserAgentSelectRowElement());return checkbox;},_createUserAgentSelectRowElement:function()
|
| -{var userAgent=WebInspector.settings.userAgent.get();const userAgents=[["Internet Explorer 10","Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; Trident/6.0)"],["Internet Explorer 9","Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)"],["Internet Explorer 8","Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0)"],["Internet Explorer 7","Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0)"],["Firefox 7 \u2014 Windows","Mozilla/5.0 (Windows NT 6.1; Intel Mac OS X 10.6; rv:7.0.1) Gecko/20100101 Firefox/7.0.1"],["Firefox 7 \u2014 Mac","Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:7.0.1) Gecko/20100101 Firefox/7.0.1"],["Firefox 4 \u2014 Windows","Mozilla/5.0 (Windows NT 6.1; rv:2.0.1) Gecko/20100101 Firefox/4.0.1"],["Firefox 4 \u2014 Mac","Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:2.0.1) Gecko/20100101 Firefox/4.0.1"],["Firefox 14 \u2014 Android Mobile","Mozilla/5.0 (Android; Mobile; rv:14.0) Gecko/14.0 Firefox/14.0"],["Firefox 14 \u2014 Android Tablet","Mozilla/5.0 (Android; Tablet; rv:14.0) Gecko/14.0 Firefox/14.0"],["Chrome \u2014 Android Mobile","Mozilla/5.0 (Linux; Android 4.0.4; Galaxy Nexus Build/IMM76B) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.133 Mobile Safari/535.19"],["Chrome \u2014 Android Tablet","Mozilla/5.0 (Linux; Android 4.1.2; Nexus 7 Build/JZ054K) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.166 Safari/535.19"],["iPhone \u2014 iOS 6","Mozilla/5.0 (iPhone; CPU iPhone OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25","640x1136x1"],["iPhone \u2014 iOS 5","Mozilla/5.0 (iPhone; CPU iPhone OS 5_0 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9A334 Safari/7534.48.3","640x960x1"],["iPhone \u2014 iOS 4","Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_2 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8H7 Safari/6533.18.5","640x960x1"],["iPad \u2014 iOS 6","Mozilla/5.0 (iPad; CPU OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25","1024x768x1"],["iPad \u2014 iOS 5","Mozilla/5.0 (iPad; CPU OS 5_0 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9A334 Safari/7534.48.3","1024x768x1"],["iPad \u2014 iOS 4","Mozilla/5.0 (iPad; CPU OS 4_3_2 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8H7 Safari/6533.18.5","1024x768x1"],["Android 2.3 \u2014 Nexus S","Mozilla/5.0 (Linux; U; Android 2.3.6; en-us; Nexus S Build/GRK39F) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1","480x800x1.1"],["Android 4.0.2 \u2014 Galaxy Nexus","Mozilla/5.0 (Linux; U; Android 4.0.2; en-us; Galaxy Nexus Build/ICL53F) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30","720x1280x1.1"],["BlackBerry \u2014 PlayBook 2.1","Mozilla/5.0 (PlayBook; U; RIM Tablet OS 2.1.0; en-US) AppleWebKit/536.2+ (KHTML, like Gecko) Version/7.2.1.0 Safari/536.2+","1024x600x1"],["BlackBerry \u2014 9900","Mozilla/5.0 (BlackBerry; U; BlackBerry 9900; en-US) AppleWebKit/534.11+ (KHTML, like Gecko) Version/7.0.0.187 Mobile Safari/534.11+","640x480x1"],["BlackBerry \u2014 BB10","Mozilla/5.0 (BB10; Touch) AppleWebKit/537.1+ (KHTML, like Gecko) Version/10.0.0.1337 Mobile Safari/537.1+","768x1280x1"],["MeeGo \u2014 Nokia N9","Mozilla/5.0 (MeeGo; NokiaN9) AppleWebKit/534.13 (KHTML, like Gecko) NokiaBrowser/8.5.0 Mobile Safari/534.13","480x854x1"],[WebInspector.UIString("Other..."),"Other"]];var fieldsetElement=WebInspector.SettingsTab.createSettingFieldset(WebInspector.settings.overrideUserAgent);var p=fieldsetElement.createChild("p");this._selectElement=p.createChild("select");this._otherUserAgentElement=p.createChild("input");this._otherUserAgentElement.type="text";this._otherUserAgentElement.value=userAgent;this._otherUserAgentElement.title=userAgent;var selectionRestored=false;for(var i=0;i<userAgents.length;++i){var agent=userAgents[i];var option=new Option(agent[0],agent[1]);option._metrics=agent[2]?agent[2]:"";this._selectElement.add(option);if(userAgent===agent[1]){this._selectElement.selectedIndex=i;selectionRestored=true;}}
|
| +WebInspector.OverridesView.prototype={_createCheckboxSetting:function(name,setting,callback,omitFieldsetElement,inputElement)
|
| +{var input=inputElement||document.createElement("input");input.type="checkbox";input.name=name;input.checked=setting.get();function listener()
|
| +{setting.set(input.checked);if(callback)
|
| +callback(input.checked);}
|
| +input.addEventListener("click",listener,false);var label=document.createElement("label");label.appendChild(input);label.appendChild(document.createTextNode(name));if(omitFieldsetElement)
|
| +return label;var fieldset=document.createElement("fieldset");fieldset.appendChild(label);return fieldset;},_createUserAgentControl:function()
|
| +{var fieldsetElement;function overrideToggled(checked)
|
| +{fieldsetElement.disabled=!checked;}
|
| +var p=this._createCheckboxSetting(WebInspector.UIString("User Agent"),WebInspector.settings.overrideUserAgent,overrideToggled);var checkboxElement=p.getElementsByTagName("input")[0];fieldsetElement=this._createUserAgentSelectRowElement(checkboxElement);p.appendChild(fieldsetElement);overrideToggled(checkboxElement.checked);return p;},_createUserAgentSelectRowElement:function(checkboxElement)
|
| +{var userAgent=WebInspector.settings.userAgent.get();const userAgents=[["Internet Explorer 10","Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; Trident/6.0)"],["Internet Explorer 9","Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)"],["Internet Explorer 8","Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0)"],["Internet Explorer 7","Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0)"],["Firefox 7 \u2014 Windows","Mozilla/5.0 (Windows NT 6.1; Intel Mac OS X 10.6; rv:7.0.1) Gecko/20100101 Firefox/7.0.1"],["Firefox 7 \u2014 Mac","Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:7.0.1) Gecko/20100101 Firefox/7.0.1"],["Firefox 4 \u2014 Windows","Mozilla/5.0 (Windows NT 6.1; rv:2.0.1) Gecko/20100101 Firefox/4.0.1"],["Firefox 4 \u2014 Mac","Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:2.0.1) Gecko/20100101 Firefox/4.0.1"],["Firefox 14 \u2014 Android Mobile","Mozilla/5.0 (Android; Mobile; rv:14.0) Gecko/14.0 Firefox/14.0"],["Firefox 14 \u2014 Android Tablet","Mozilla/5.0 (Android; Tablet; rv:14.0) Gecko/14.0 Firefox/14.0"],["Chrome \u2014 Android Mobile","Mozilla/5.0 (Linux; Android 4.0.4; Galaxy Nexus Build/IMM76B) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.133 Mobile Safari/535.19"],["Chrome \u2014 Android Tablet","Mozilla/5.0 (Linux; Android 4.1.2; Nexus 7 Build/JZ054K) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.166 Safari/535.19"],["iPhone \u2014 iOS 6","Mozilla/5.0 (iPhone; CPU iPhone OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25","640x1136x1"],["iPhone \u2014 iOS 5","Mozilla/5.0 (iPhone; CPU iPhone OS 5_0 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9A334 Safari/7534.48.3","640x960x1"],["iPhone \u2014 iOS 4","Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_2 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8H7 Safari/6533.18.5","640x960x1"],["iPad \u2014 iOS 6","Mozilla/5.0 (iPad; CPU OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25","1024x768x1"],["iPad \u2014 iOS 5","Mozilla/5.0 (iPad; CPU OS 5_0 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9A334 Safari/7534.48.3","1024x768x1"],["iPad \u2014 iOS 4","Mozilla/5.0 (iPad; CPU OS 4_3_2 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8H7 Safari/6533.18.5","1024x768x1"],["Android 2.3 \u2014 Nexus S","Mozilla/5.0 (Linux; U; Android 2.3.6; en-us; Nexus S Build/GRK39F) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1","480x800x1.1"],["Android 4.0.2 \u2014 Galaxy Nexus","Mozilla/5.0 (Linux; U; Android 4.0.2; en-us; Galaxy Nexus Build/ICL53F) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30","720x1280x1.1"],["BlackBerry \u2014 PlayBook 2.1","Mozilla/5.0 (PlayBook; U; RIM Tablet OS 2.1.0; en-US) AppleWebKit/536.2+ (KHTML, like Gecko) Version/7.2.1.0 Safari/536.2+","1024x600x1"],["BlackBerry \u2014 9900","Mozilla/5.0 (BlackBerry; U; BlackBerry 9900; en-US) AppleWebKit/534.11+ (KHTML, like Gecko) Version/7.0.0.187 Mobile Safari/534.11+","640x480x1"],["BlackBerry \u2014 BB10","Mozilla/5.0 (BB10; Touch) AppleWebKit/537.1+ (KHTML, like Gecko) Version/10.0.0.1337 Mobile Safari/537.1+","768x1280x1"],["MeeGo \u2014 Nokia N9","Mozilla/5.0 (MeeGo; NokiaN9) AppleWebKit/534.13 (KHTML, like Gecko) NokiaBrowser/8.5.0 Mobile Safari/534.13","480x854x1"],[WebInspector.UIString("Other..."),"Other"]];var fieldsetElement=document.createElement("fieldset");this._selectElement=fieldsetElement.createChild("select");this._otherUserAgentElement=fieldsetElement.createChild("input");this._otherUserAgentElement.type="text";this._otherUserAgentElement.value=userAgent;this._otherUserAgentElement.title=userAgent;this._userAgentFieldsetElement=fieldsetElement;var selectionRestored=false;for(var i=0;i<userAgents.length;++i){var agent=userAgents[i];var option=new Option(agent[0],agent[1]);option._metrics=agent[2]?agent[2]:"";this._selectElement.add(option);if(userAgent===agent[1]){this._selectElement.selectedIndex=i;selectionRestored=true;}}
|
| if(!selectionRestored){if(!userAgent)
|
| this._selectElement.selectedIndex=0;else
|
| this._selectElement.selectedIndex=userAgents.length-1;}
|
| @@ -8496,8 +8981,8 @@
|
| element.className="numeric";element.addEventListener("blur",eventListener,false);return element;},_createNonPersistedCheckbox:function(title,callback)
|
| {var labelElement=document.createElement("label");var checkboxElement=labelElement.createChild("input");checkboxElement.type="checkbox";checkboxElement.checked=false;checkboxElement.addEventListener("click",onclick,false);labelElement.appendChild(document.createTextNode(title));return labelElement;function onclick()
|
| {callback(checkboxElement.checked);}},_createDeviceMetricsControl:function()
|
| -{const metricsSetting=WebInspector.settings.deviceMetrics.get();var metrics=WebInspector.OverridesSupport.DeviceMetrics.parseSetting(metricsSetting);var checkbox=this._createSettingCheckbox(WebInspector.UIString("Device metrics"),WebInspector.settings.overrideDeviceMetrics,this._onMetricsCheckboxClicked.bind(this));checkbox.appendChild(this._createDeviceMetricsElement(metrics));this._onMetricsCheckboxClicked(WebInspector.settings.overrideDeviceMetrics.get());return checkbox;},_onMetricsCheckboxClicked:function(enabled)
|
| -{if(enabled&&!this._widthOverrideElement.value)
|
| +{const metricsSetting=WebInspector.settings.deviceMetrics.get();var metrics=WebInspector.OverridesSupport.DeviceMetrics.parseSetting(metricsSetting);const p=this._createCheckboxSetting(WebInspector.UIString("Device metrics"),WebInspector.settings.overrideDeviceMetrics,this._onMetricsCheckboxClicked.bind(this));this._metricsCheckboxElement=p.getElementsByTagName("input")[0];const metricsSectionElement=this._createDeviceMetricsElement(metrics);p.appendChild(metricsSectionElement);this._metricsSectionElement=metricsSectionElement;this._onMetricsCheckboxClicked(this._metricsCheckboxElement.checked);return p;},_onMetricsCheckboxClicked:function(enabled)
|
| +{this._deviceMetricsFieldsetElement.disabled=!enabled;if(enabled&&!this._widthOverrideElement.value)
|
| this._widthOverrideElement.focus();},_applyDeviceMetricsUserInput:function()
|
| {this._setDeviceMetricsOverride(WebInspector.OverridesSupport.DeviceMetrics.parseUserInput(this._widthOverrideElement.value.trim(),this._heightOverrideElement.value.trim(),this._fontScaleFactorOverrideElement.value.trim()),true);},_setDeviceMetricsOverride:function(metrics,userInputModified)
|
| {function setValid(condition,element)
|
| @@ -8508,35 +8993,36 @@
|
| return;if(!userInputModified){this._widthOverrideElement.value=metrics.widthToInput();this._heightOverrideElement.value=metrics.heightToInput();this._fontScaleFactorOverrideElement.value=metrics.fontScaleFactorToInput();}
|
| if(metrics.isValid()){var value=metrics.toSetting();if(value!==WebInspector.settings.deviceMetrics.get())
|
| WebInspector.settings.deviceMetrics.set(value);}},_createDeviceMetricsElement:function(metrics)
|
| -{var fieldsetElement=WebInspector.SettingsTab.createSettingFieldset(WebInspector.settings.overrideDeviceMetrics);fieldsetElement.id="metrics-override-section";var p=fieldsetElement.createChild("p");function swapDimensionsClicked(event)
|
| +{var fieldsetElement=document.createElement("fieldset");fieldsetElement.id="metrics-override-section";this._deviceMetricsFieldsetElement=fieldsetElement;function swapDimensionsClicked(event)
|
| {var widthValue=this._widthOverrideElement.value;this._widthOverrideElement.value=this._heightOverrideElement.value;this._heightOverrideElement.value=widthValue;this._applyDeviceMetricsUserInput();}
|
| -var tableElement=p.createChild("table","nowrap");var rowElement=tableElement.createChild("tr");var cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode(WebInspector.UIString("Screen resolution:")));cellElement=rowElement.createChild("td");this._widthOverrideElement=this._createInput(cellElement,"metrics-override-width",String(metrics.width||screen.width),this._applyDeviceMetricsUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" \u00D7 "));this._heightOverrideElement=this._createInput(cellElement,"metrics-override-height",String(metrics.height||screen.height),this._applyDeviceMetricsUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" \u2014 "));this._swapDimensionsElement=cellElement.createChild("button");this._swapDimensionsElement.appendChild(document.createTextNode(" \u21C4 "));this._swapDimensionsElement.title=WebInspector.UIString("Swap dimensions");this._swapDimensionsElement.addEventListener("click",swapDimensionsClicked.bind(this),false);rowElement=tableElement.createChild("tr");cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode(WebInspector.UIString("Font scale factor:")));cellElement=rowElement.createChild("td");this._fontScaleFactorOverrideElement=this._createInput(cellElement,"metrics-override-font-scale",String(metrics.fontScaleFactor||1),this._applyDeviceMetricsUserInput.bind(this),true);rowElement=tableElement.createChild("tr");cellElement=rowElement.createChild("td");cellElement.colSpan=2;var checkbox=WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Fit in window"),WebInspector.settings.deviceFitWindow,true);cellElement.appendChild(checkbox);return fieldsetElement;},_createGeolocationOverrideControl:function()
|
| -{const geolocationSetting=WebInspector.settings.geolocationOverride.get();var geolocation=WebInspector.OverridesSupport.GeolocationPosition.parseSetting(geolocationSetting);var checkbox=this._createSettingCheckbox(WebInspector.UIString("Override Geolocation"),WebInspector.settings.overrideGeolocation,this._geolocationOverrideCheckboxClicked.bind(this));var geolocationSectionElement=this._createGeolocationOverrideElement(geolocation);checkbox.appendChild(geolocationSectionElement);this._geolocationOverrideCheckboxClicked(WebInspector.settings.overrideGeolocation.get());return checkbox;},_geolocationOverrideCheckboxClicked:function(enabled)
|
| -{if(enabled&&!this._latitudeElement.value)
|
| +var tableElement=fieldsetElement.createChild("table","nowrap");var rowElement=tableElement.createChild("tr");var cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode(WebInspector.UIString("Screen resolution:")));cellElement=rowElement.createChild("td");this._widthOverrideElement=this._createInput(cellElement,"metrics-override-width",String(metrics.width||screen.width),this._applyDeviceMetricsUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" \u00D7 "));this._heightOverrideElement=this._createInput(cellElement,"metrics-override-height",String(metrics.height||screen.height),this._applyDeviceMetricsUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" \u2014 "));this._swapDimensionsElement=cellElement.createChild("button");this._swapDimensionsElement.appendChild(document.createTextNode(" \u21C4 "));this._swapDimensionsElement.title=WebInspector.UIString("Swap dimensions");this._swapDimensionsElement.addEventListener("click",swapDimensionsClicked.bind(this),false);rowElement=tableElement.createChild("tr");cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode(WebInspector.UIString("Font scale factor:")));cellElement=rowElement.createChild("td");this._fontScaleFactorOverrideElement=this._createInput(cellElement,"metrics-override-font-scale",String(metrics.fontScaleFactor||1),this._applyDeviceMetricsUserInput.bind(this),true);rowElement=tableElement.createChild("tr");cellElement=rowElement.createChild("td");cellElement.colSpan=2;this._fitWindowCheckboxElement=document.createElement("input");cellElement.appendChild(this._createCheckboxSetting(WebInspector.UIString("Fit in window"),WebInspector.settings.deviceFitWindow,undefined,true,this._fitWindowCheckboxElement));return fieldsetElement;},_createGeolocationOverrideControl:function()
|
| +{const geolocationSetting=WebInspector.settings.geolocationOverride.get();var geolocation=WebInspector.OverridesSupport.GeolocationPosition.parseSetting(geolocationSetting);var p=this._createCheckboxSetting(WebInspector.UIString("Override Geolocation"),WebInspector.settings.overrideGeolocation,this._geolocationOverrideCheckboxClicked.bind(this));this._geolocationOverrideCheckboxElement=p.getElementsByTagName("input")[0];var geolocationSectionElement=this._createGeolocationOverrideElement(geolocation);p.appendChild(geolocationSectionElement);this._geolocationSectionElement=geolocationSectionElement;this._geolocationOverrideCheckboxClicked(this._geolocationOverrideCheckboxElement.checked);return p;},_geolocationOverrideCheckboxClicked:function(enabled)
|
| +{this._geolocationFieldsetElement.disabled=!enabled;if(enabled&&!this._latitudeElement.value)
|
| this._latitudeElement.focus();},_applyGeolocationUserInput:function()
|
| {this._setGeolocationPosition(WebInspector.OverridesSupport.GeolocationPosition.parseUserInput(this._latitudeElement.value.trim(),this._longitudeElement.value.trim(),this._geolocationErrorElement.checked),true);},_setGeolocationPosition:function(geolocation,userInputModified)
|
| {if(!geolocation)
|
| return;if(!userInputModified){this._latitudeElement.value=geolocation.latitude;this._longitudeElement.value=geolocation.longitude;}
|
| var value=geolocation.toSetting();WebInspector.settings.geolocationOverride.set(value);},_createGeolocationOverrideElement:function(geolocation)
|
| -{var fieldsetElement=WebInspector.SettingsTab.createSettingFieldset(WebInspector.settings.overrideGeolocation);fieldsetElement.id="geolocation-override-section";var p=fieldsetElement.createChild("p");var tableElement=p.createChild("table");var rowElement=tableElement.createChild("tr");var cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode(WebInspector.UIString("Geolocation Position")+":"));cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode(WebInspector.UIString("Lat = ")));this._latitudeElement=this._createInput(cellElement,"geolocation-override-latitude",String(geolocation.latitude),this._applyGeolocationUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" , "));cellElement.appendChild(document.createTextNode(WebInspector.UIString("Lon = ")));this._longitudeElement=this._createInput(cellElement,"geolocation-override-longitude",String(geolocation.longitude),this._applyGeolocationUserInput.bind(this),true);rowElement=tableElement.createChild("tr");cellElement=rowElement.createChild("td");cellElement.colSpan=2;var geolocationErrorLabelElement=document.createElement("label");var geolocationErrorCheckboxElement=geolocationErrorLabelElement.createChild("input");geolocationErrorCheckboxElement.id="geolocation-error";geolocationErrorCheckboxElement.type="checkbox";geolocationErrorCheckboxElement.checked=!geolocation||geolocation.error;geolocationErrorCheckboxElement.addEventListener("click",this._applyGeolocationUserInput.bind(this),false);geolocationErrorLabelElement.appendChild(document.createTextNode(WebInspector.UIString("Emulate position unavailable")));this._geolocationErrorElement=geolocationErrorCheckboxElement;cellElement.appendChild(geolocationErrorLabelElement);return fieldsetElement;},_createDeviceOrientationOverrideControl:function()
|
| -{const deviceOrientationSetting=WebInspector.settings.deviceOrientationOverride.get();var deviceOrientation=WebInspector.OverridesSupport.DeviceOrientation.parseSetting(deviceOrientationSetting);var checkbox=this._createSettingCheckbox(WebInspector.UIString("Override Device Orientation"),WebInspector.settings.overrideDeviceOrientation,this._deviceOrientationOverrideCheckboxClicked.bind(this));var deviceOrientationSectionElement=this._createDeviceOrientationOverrideElement(deviceOrientation);checkbox.appendChild(deviceOrientationSectionElement);this._deviceOrientationOverrideCheckboxClicked(WebInspector.settings.overrideDeviceOrientation.get());return checkbox;},_deviceOrientationOverrideCheckboxClicked:function(enabled)
|
| -{if(enabled&&!this._alphaElement.value)
|
| +{var fieldsetElement=document.createElement("fieldset");fieldsetElement.id="geolocation-override-section";this._geolocationFieldsetElement=fieldsetElement;var tableElement=fieldsetElement.createChild("table");var rowElement=tableElement.createChild("tr");var cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode(WebInspector.UIString("Geolocation Position")+":"));cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode(WebInspector.UIString("Lat = ")));this._latitudeElement=this._createInput(cellElement,"geolocation-override-latitude",String(geolocation.latitude),this._applyGeolocationUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" , "));cellElement.appendChild(document.createTextNode(WebInspector.UIString("Lon = ")));this._longitudeElement=this._createInput(cellElement,"geolocation-override-longitude",String(geolocation.longitude),this._applyGeolocationUserInput.bind(this),true);rowElement=tableElement.createChild("tr");cellElement=rowElement.createChild("td");cellElement.colSpan=2;var geolocationErrorLabelElement=document.createElement("label");var geolocationErrorCheckboxElement=geolocationErrorLabelElement.createChild("input");geolocationErrorCheckboxElement.id="geolocation-error";geolocationErrorCheckboxElement.type="checkbox";geolocationErrorCheckboxElement.checked=!geolocation||geolocation.error;geolocationErrorCheckboxElement.addEventListener("click",this._applyGeolocationUserInput.bind(this),false);geolocationErrorLabelElement.appendChild(document.createTextNode(WebInspector.UIString("Emulate position unavailable")));this._geolocationErrorElement=geolocationErrorCheckboxElement;cellElement.appendChild(geolocationErrorLabelElement);return fieldsetElement;},_createDeviceOrientationOverrideControl:function()
|
| +{const deviceOrientationSetting=WebInspector.settings.deviceOrientationOverride.get();var deviceOrientation=WebInspector.OverridesSupport.DeviceOrientation.parseSetting(deviceOrientationSetting);var p=this._createCheckboxSetting(WebInspector.UIString("Override Device Orientation"),WebInspector.settings.overrideDeviceOrientation,this._deviceOrientationOverrideCheckboxClicked.bind(this));this._deviceOrientationOverrideCheckboxElement=p.getElementsByTagName("input")[0];var deviceOrientationSectionElement=this._createDeviceOrientationOverrideElement(deviceOrientation);p.appendChild(deviceOrientationSectionElement);this._deviceOrientationSectionElement=deviceOrientationSectionElement;this._deviceOrientationOverrideCheckboxClicked(this._deviceOrientationOverrideCheckboxElement.checked);return p;},_deviceOrientationOverrideCheckboxClicked:function(enabled)
|
| +{this._deviceOrientationFieldsetElement.disabled=!enabled;if(enabled&&!this._alphaElement.value)
|
| this._alphaElement.focus();},_applyDeviceOrientationUserInput:function()
|
| {this._setDeviceOrientation(WebInspector.OverridesSupport.DeviceOrientation.parseUserInput(this._alphaElement.value.trim(),this._betaElement.value.trim(),this._gammaElement.value.trim()),true);},_setDeviceOrientation:function(deviceOrientation,userInputModified)
|
| {if(!deviceOrientation)
|
| return;if(!userInputModified){this._alphaElement.value=deviceOrientation.alpha;this._betaElement.value=deviceOrientation.beta;this._gammaElement.value=deviceOrientation.gamma;}
|
| var value=deviceOrientation.toSetting();WebInspector.settings.deviceOrientationOverride.set(value);},_createDeviceOrientationOverrideElement:function(deviceOrientation)
|
| -{var fieldsetElement=WebInspector.SettingsTab.createSettingFieldset(WebInspector.settings.overrideDeviceOrientation);fieldsetElement.id="device-orientation-override-section";var p=fieldsetElement.createChild("p");var tableElement=p.createChild("table");var rowElement=tableElement.createChild("tr");var cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode("\u03B1: "));this._alphaElement=this._createInput(cellElement,"device-orientation-override-alpha",String(deviceOrientation.alpha),this._applyDeviceOrientationUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" \u03B2: "));this._betaElement=this._createInput(cellElement,"device-orientation-override-beta",String(deviceOrientation.beta),this._applyDeviceOrientationUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" \u03B3: "));this._gammaElement=this._createInput(cellElement,"device-orientation-override-gamma",String(deviceOrientation.gamma),this._applyDeviceOrientationUserInput.bind(this),true);return fieldsetElement;},_createMediaEmulationElement:function()
|
| -{var checkbox=WebInspector.SettingsTab.createSettingCheckbox(WebInspector.UIString("Emulate CSS media"),WebInspector.settings.overrideCSSMedia);var fieldsetElement=WebInspector.SettingsTab.createSettingFieldset(WebInspector.settings.overrideCSSMedia);checkbox.appendChild(fieldsetElement);var p=fieldsetElement.createChild("p");var mediaSelectElement=p.createChild("select");var mediaTypes=WebInspector.CSSStyleModel.MediaTypes;var defaultMedia=WebInspector.settings.emulatedCSSMedia.get();for(var i=0;i<mediaTypes.length;++i){var mediaType=mediaTypes[i];if(mediaType==="all"){continue;}
|
| +{var fieldsetElement=document.createElement("fieldset");fieldsetElement.id="device-orientation-override-section";this._deviceOrientationFieldsetElement=fieldsetElement;var tableElement=fieldsetElement.createChild("table");var rowElement=tableElement.createChild("tr");var cellElement=rowElement.createChild("td");cellElement.appendChild(document.createTextNode("\u03B1: "));this._alphaElement=this._createInput(cellElement,"device-orientation-override-alpha",String(deviceOrientation.alpha),this._applyDeviceOrientationUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" \u03B2: "));this._betaElement=this._createInput(cellElement,"device-orientation-override-beta",String(deviceOrientation.beta),this._applyDeviceOrientationUserInput.bind(this),true);cellElement.appendChild(document.createTextNode(" \u03B3: "));this._gammaElement=this._createInput(cellElement,"device-orientation-override-gamma",String(deviceOrientation.gamma),this._applyDeviceOrientationUserInput.bind(this),true);return fieldsetElement;},_createMediaEmulationElement:function()
|
| +{const p=this._createCheckboxSetting(WebInspector.UIString("Emulate CSS media"),WebInspector.settings.overrideCSSMedia,checkboxClicked);var checkboxElement=p.getElementsByTagName("input")[0];var mediaSelectElement=p.createChild("select");var mediaTypes=WebInspector.CSSStyleModel.MediaTypes;var defaultMedia=WebInspector.settings.emulatedCSSMedia.get();for(var i=0;i<mediaTypes.length;++i){var mediaType=mediaTypes[i];if(mediaType==="all"){continue;}
|
| var option=document.createElement("option");option.text=mediaType;option.value=mediaType;mediaSelectElement.add(option);if(mediaType===defaultMedia)
|
| mediaSelectElement.selectedIndex=mediaSelectElement.options.length-1;}
|
| -mediaSelectElement.addEventListener("change",this._emulateMediaChanged.bind(this,mediaSelectElement),false);return checkbox;},_emulateMediaChanged:function(select)
|
| +function checkboxClicked(enabled)
|
| +{mediaSelectElement.disabled=!enabled;}
|
| +mediaSelectElement.addEventListener("change",this._emulateMediaChanged.bind(this,mediaSelectElement),false);checkboxClicked(checkboxElement.checked);return p;},_emulateMediaChanged:function(select)
|
| {var media=select.options[select.selectedIndex].value;WebInspector.settings.emulatedCSSMedia.set(media);},__proto__:WebInspector.View.prototype}
|
| WebInspector.HAREntry=function(request)
|
| {this._request=request;}
|
| WebInspector.HAREntry.prototype={build:function()
|
| -{var entry={startedDateTime:new Date(this._request.startTime*1000),time:WebInspector.HAREntry._toMilliseconds(this._request.duration),request:this._buildRequest(),response:this._buildResponse(),cache:{},timings:this._buildTimings()};if(this._request.connectionId)
|
| -entry.connection=String(this._request.connectionId);var page=WebInspector.networkLog.pageLoadForRequest(this._request);if(page)
|
| +{var entry={startedDateTime:new Date(this._request.startTime*1000),time:WebInspector.HAREntry._toMilliseconds(this._request.duration),request:this._buildRequest(),response:this._buildResponse(),cache:{},timings:this._buildTimings()};var page=WebInspector.networkLog.pageLoadForRequest(this._request);if(page)
|
| entry.pageref="page_"+page.id;return entry;},_buildRequest:function()
|
| {var res={method:this._request.requestMethod,url:this._buildRequestURL(this._request.url),httpVersion:this._request.requestHttpVersion,headers:this._request.requestHeaders,queryString:this._buildParameters(this._request.queryParameters||[]),cookies:this._buildCookies(this._request.requestCookies||[]),headersSize:this._request.requestHeadersSize,bodySize:this.requestBodySize};if(this._request.requestFormData)
|
| res.postData=this._buildPostData();return res;},_buildResponse:function()
|
| @@ -8828,7 +9314,7 @@
|
| WebInspector.domAgent.setInspectModeEnabled(enabled,WebInspector.settings.showShadowDOM.get(),callback.bind(this));},handleShortcut:function(event)
|
| {if(WebInspector.KeyboardShortcut.makeKeyFromEvent(event)!==this._shortcut.key)
|
| return false;this.toggleSearch();event.consume(true);return true;}}
|
| -WebInspector.inspectElementModeController=null;WebInspector.WorkerManager=function()
|
| +WebInspector.WorkerManager=function()
|
| {this._workerIdToWindow={};InspectorBackend.registerWorkerDispatcher(new WebInspector.WorkerDispatcher(this));}
|
| WebInspector.WorkerManager.isWorkerFrontend=function()
|
| {return!!WebInspector.queryParamsObject["dedicatedWorkerId"]||!!WebInspector.queryParamsObject["isSharedWorker"];}
|
| @@ -9002,7 +9488,8 @@
|
| {var handler=this._handlers[name];var result=handler&&handler(data);return!!result;},registerHandler:function(name,handler)
|
| {this._handlers[name]=handler;this.dispatchEventToListeners(WebInspector.HandlerRegistry.EventTypes.HandlersUpdated);},unregisterHandler:function(name)
|
| {delete this._handlers[name];this.dispatchEventToListeners(WebInspector.HandlerRegistry.EventTypes.HandlersUpdated);},appendApplicableItems:function(event,contextMenu,target)
|
| -{this._appendContentProviderItems(contextMenu,target);this._appendHrefItems(contextMenu,target);},_appendContentProviderItems:function(contextMenu,target)
|
| +{if(event.hasBeenHandledByHandlerRegistry)
|
| +return;event.hasBeenHandledByHandlerRegistry=true;this._appendContentProviderItems(contextMenu,target);this._appendHrefItems(contextMenu,target);},_appendContentProviderItems:function(contextMenu,target)
|
| {if(!(target instanceof WebInspector.UISourceCode||target instanceof WebInspector.Resource||target instanceof WebInspector.NetworkRequest))
|
| return;var contentProvider=(target);if(!contentProvider.contentURL())
|
| return;contextMenu.appendItem(WebInspector.openLinkExternallyLabel(),WebInspector.openResource.bind(WebInspector,contentProvider.contentURL(),false));for(var i=1;i<this.handlerNames.length;++i){var handler=this.handlerNames[i];contextMenu.appendItem(WebInspector.UIString(WebInspector.useLowerCaseMenuTitles()?"Open using %s":"Open Using %s",handler),this.dispatchToHandler.bind(this,handler,{url:contentProvider.contentURL()}));}
|
| @@ -9208,7 +9695,7 @@
|
| this._initialize();}}
|
| WebInspector.StyleFile=function(uiSourceCode)
|
| {this._uiSourceCode=uiSourceCode;this._uiSourceCode.addEventListener(WebInspector.UISourceCode.Events.WorkingCopyChanged,this._workingCopyChanged,this);this._uiSourceCode.addEventListener(WebInspector.UISourceCode.Events.WorkingCopyCommitted,this._workingCopyCommitted,this);}
|
| -WebInspector.StyleFile.updateTimeout=200;WebInspector.StyleFile.sourceURLRegex=/\n[\040\t]*\/\*#[\040\t]sourceURL=[\040\t]*([^\s]*)[\040\t]*\*\/[\040\t]*$/m;WebInspector.StyleFile.prototype={_workingCopyCommitted:function(event)
|
| +WebInspector.StyleFile.updateTimeout=200;WebInspector.StyleFile.prototype={_workingCopyCommitted:function(event)
|
| {if(this._isAddingRevision)
|
| return;this._commitIncrementalEdit(true);},_workingCopyChanged:function(event)
|
| {if(this._isAddingRevision)
|
| @@ -9219,8 +9706,7 @@
|
| WebInspector.showErrorMessage(error);},_clearIncrementalUpdateTimer:function()
|
| {if(!this._incrementalUpdateTimer)
|
| return;clearTimeout(this._incrementalUpdateTimer);delete this._incrementalUpdateTimer;},addRevision:function(content)
|
| -{this._isAddingRevision=true;if(this._uiSourceCode.project().type()===WebInspector.projectTypes.FileSystem)
|
| -content=content.replace(WebInspector.StyleFile.sourceURLRegex,"");this._uiSourceCode.addRevision(content);delete this._isAddingRevision;},dispose:function()
|
| +{this._isAddingRevision=true;this._uiSourceCode.addRevision(content);delete this._isAddingRevision;},dispose:function()
|
| {this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.WorkingCopyCommitted,this._workingCopyCommitted,this);this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.WorkingCopyChanged,this._workingCopyChanged,this);}}
|
| WebInspector.StyleContentBinding=function(cssModel,workspace)
|
| {this._cssModel=cssModel;this._workspace=workspace;this._cssModel.addEventListener(WebInspector.CSSStyleModel.Events.StyleSheetChanged,this._styleSheetChanged,this);}
|
| @@ -9250,8 +9736,10 @@
|
| this._resourceAdded({data:resources[i]});}
|
| populateFrame.call(this,WebInspector.resourceTreeModel.mainFrame);},_parsedScriptSource:function(event)
|
| {var script=(event.data);if(!script.sourceURL||script.isInlineScript()||script.isSnippet())
|
| -return;if(script.isContentScript&&!script.hasSourceURL){var parsedURL=new WebInspector.ParsedURL(script.sourceURL);if(!parsedURL.host)
|
| +return;if(!script.hasSourceURL&&!script.isContentScript){var requestURL=script.sourceURL.replace(/#.*/,"");if(WebInspector.resourceForURL(requestURL)||WebInspector.networkLog.requestForURL(requestURL))
|
| return;}
|
| +if(script.isContentScript&&!script.hasSourceURL){var parsedURL=new WebInspector.ParsedURL(script.sourceURL);if(!parsedURL.host)
|
| +return;}
|
| this._addFile(script.sourceURL,script,script.isContentScript);},_styleSheetAdded:function(event)
|
| {var header=(event.data);if((!header.hasSourceURL||header.isInline)&&header.origin!=="inspector")
|
| return;this._addFile(header.resourceURL(),header,false);},_resourceAdded:function(event)
|
| @@ -9265,14 +9753,14 @@
|
| WebInspector.networkWorkspaceProvider=null;WebInspector.ElementsPanelDescriptor=function()
|
| {WebInspector.PanelDescriptor.call(this,"elements",WebInspector.UIString("Elements"),"ElementsPanel","ElementsPanel.js");WebInspector.ContextMenu.registerProvider(this);}
|
| WebInspector.ElementsPanelDescriptor.prototype={appendApplicableItems:function(event,contextMenu,target)
|
| -{if(target instanceof WebInspector.RemoteObject){var remoteObject=(target);if(remoteObject.subtype!=="node")
|
| -return;}else if(!(target instanceof WebInspector.DOMNode))
|
| +{if(!(target instanceof WebInspector.RemoteObject))
|
| +return;var remoteObject=(target);if(remoteObject.subtype!=="node")
|
| return;this.panel().appendApplicableItems(event,contextMenu,target);},registerShortcuts:function()
|
| {var elementsSection=WebInspector.shortcutsScreen.section(WebInspector.UIString("Elements Panel"));var navigate=WebInspector.ElementsPanelDescriptor.ShortcutKeys.NavigateUp.concat(WebInspector.ElementsPanelDescriptor.ShortcutKeys.NavigateDown);elementsSection.addRelatedKeys(navigate,WebInspector.UIString("Navigate elements"));var expandCollapse=WebInspector.ElementsPanelDescriptor.ShortcutKeys.Expand.concat(WebInspector.ElementsPanelDescriptor.ShortcutKeys.Collapse);elementsSection.addRelatedKeys(expandCollapse,WebInspector.UIString("Expand/collapse"));elementsSection.addAlternateKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.EditAttribute,WebInspector.UIString("Edit attribute"));elementsSection.addAlternateKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.HideElement,WebInspector.UIString("Hide element"));elementsSection.addAlternateKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.ToggleEditAsHTML,WebInspector.UIString("Toggle edit as HTML"));var stylesPaneSection=WebInspector.shortcutsScreen.section(WebInspector.UIString("Styles Pane"));var nextPreviousProperty=WebInspector.ElementsPanelDescriptor.ShortcutKeys.NextProperty.concat(WebInspector.ElementsPanelDescriptor.ShortcutKeys.PreviousProperty);stylesPaneSection.addRelatedKeys(nextPreviousProperty,WebInspector.UIString("Next/previous property"));stylesPaneSection.addRelatedKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.IncrementValue,WebInspector.UIString("Increment value"));stylesPaneSection.addRelatedKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.DecrementValue,WebInspector.UIString("Decrement value"));stylesPaneSection.addAlternateKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.IncrementBy10,WebInspector.UIString("Increment by %f",10));stylesPaneSection.addAlternateKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.DecrementBy10,WebInspector.UIString("Decrement by %f",10));stylesPaneSection.addAlternateKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.IncrementBy100,WebInspector.UIString("Increment by %f",100));stylesPaneSection.addAlternateKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.DecrementBy100,WebInspector.UIString("Decrement by %f",100));stylesPaneSection.addAlternateKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.IncrementBy01,WebInspector.UIString("Increment by %f",0.1));stylesPaneSection.addAlternateKeys(WebInspector.ElementsPanelDescriptor.ShortcutKeys.DecrementBy01,WebInspector.UIString("Decrement by %f",0.1));},__proto__:WebInspector.PanelDescriptor.prototype}
|
| WebInspector.ElementsPanelDescriptor.ShortcutKeys={NavigateUp:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Up)],NavigateDown:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Down)],Expand:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Right)],Collapse:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Left)],EditAttribute:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Enter)],HideElement:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.H)],ToggleEditAsHTML:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F2)],NextProperty:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Tab)],PreviousProperty:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Tab,WebInspector.KeyboardShortcut.Modifiers.Shift)],IncrementValue:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Up)],DecrementValue:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Down)],IncrementBy10:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.PageUp),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Up,WebInspector.KeyboardShortcut.Modifiers.Shift)],DecrementBy10:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.PageDown),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Down,WebInspector.KeyboardShortcut.Modifiers.Shift)],IncrementBy100:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.PageUp,WebInspector.KeyboardShortcut.Modifiers.Shift)],DecrementBy100:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.PageDown,WebInspector.KeyboardShortcut.Modifiers.Shift)],IncrementBy01:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.PageUp,WebInspector.KeyboardShortcut.Modifiers.Alt)],DecrementBy01:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.PageDown,WebInspector.KeyboardShortcut.Modifiers.Alt)]};WebInspector.NetworkPanelDescriptor=function()
|
| {WebInspector.PanelDescriptor.call(this,"network",WebInspector.UIString("Network"),"NetworkPanel","NetworkPanel.js");WebInspector.ContextMenu.registerProvider(this);}
|
| WebInspector.NetworkPanelDescriptor.prototype={appendApplicableItems:function(event,contextMenu,target)
|
| -{if(!(target instanceof WebInspector.NetworkRequest||target instanceof WebInspector.Resource||target instanceof WebInspector.UISourceCode))
|
| +{if(!(target instanceof WebInspector.NetworkRequest))
|
| return;this.panel().appendApplicableItems(event,contextMenu,target);},__proto__:WebInspector.PanelDescriptor.prototype}
|
| WebInspector.ProfilesPanelDescriptor=function()
|
| {WebInspector.PanelDescriptor.call(this,"profiles",WebInspector.UIString("Profiles"),"ProfilesPanel","ProfilesPanel.js");}
|
| @@ -9300,17 +9788,14 @@
|
| {var hasApplicableItems=target instanceof WebInspector.UISourceCode;if(!hasApplicableItems&&target instanceof WebInspector.RemoteObject){var remoteObject=(target);if(remoteObject.type!=="function")
|
| return;}
|
| this.panel().appendApplicableItems(event,contextMenu,target);},registerShortcuts:function()
|
| -{var section=WebInspector.shortcutsScreen.section(WebInspector.UIString("Sources Panel"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.PauseContinue,WebInspector.UIString("Pause/Continue"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.StepOver,WebInspector.UIString("Step over"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.StepInto,WebInspector.UIString("Step into"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.StepIntoSelection,WebInspector.UIString("Step into selection"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.StepOut,WebInspector.UIString("Step out"));var nextAndPrevFrameKeys=WebInspector.ScriptsPanelDescriptor.ShortcutKeys.NextCallFrame.concat(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.PrevCallFrame);section.addRelatedKeys(nextAndPrevFrameKeys,WebInspector.UIString("Next/previous call frame"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.EvaluateSelectionInConsole,WebInspector.UIString("Evaluate selection in console"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.GoToMember,WebInspector.UIString("Go to member"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.ToggleBreakpoint,WebInspector.UIString("Toggle breakpoint"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.ToggleComment,WebInspector.UIString("Toggle comment"));},__proto__:WebInspector.PanelDescriptor.prototype}
|
| -WebInspector.ScriptsPanelDescriptor.ShortcutKeys={RunSnippet:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Enter,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],PauseContinue:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F8),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Backslash,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],StepOver:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F10),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.SingleQuote,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],StepInto:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F11),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Semicolon,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],StepIntoSelection:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F11,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F11,WebInspector.KeyboardShortcut.Modifiers.Shift|WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],StepOut:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F11,WebInspector.KeyboardShortcut.Modifiers.Shift),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Semicolon,WebInspector.KeyboardShortcut.Modifiers.Shift|WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],EvaluateSelectionInConsole:[WebInspector.KeyboardShortcut.makeDescriptor("e",WebInspector.KeyboardShortcut.Modifiers.Shift|WebInspector.KeyboardShortcut.Modifiers.Ctrl)],GoToMember:[WebInspector.KeyboardShortcut.makeDescriptor("o",WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta|WebInspector.KeyboardShortcut.Modifiers.Shift)],ToggleBreakpoint:[WebInspector.KeyboardShortcut.makeDescriptor("b",WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],NextCallFrame:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Period,WebInspector.KeyboardShortcut.Modifiers.Ctrl)],PrevCallFrame:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Comma,WebInspector.KeyboardShortcut.Modifiers.Ctrl)],ToggleComment:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Slash,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)]};WebInspector.TimelinePanelDescriptor=function()
|
| +{var section=WebInspector.shortcutsScreen.section(WebInspector.UIString("Sources Panel"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.PauseContinue,WebInspector.UIString("Pause/Continue"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.StepOver,WebInspector.UIString("Step over"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.StepInto,WebInspector.UIString("Step into"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.StepOut,WebInspector.UIString("Step out"));var nextAndPrevFrameKeys=WebInspector.ScriptsPanelDescriptor.ShortcutKeys.NextCallFrame.concat(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.PrevCallFrame);section.addRelatedKeys(nextAndPrevFrameKeys,WebInspector.UIString("Next/previous call frame"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.EvaluateSelectionInConsole,WebInspector.UIString("Evaluate selection in console"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.GoToMember,WebInspector.UIString("Go to member"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.ToggleBreakpoint,WebInspector.UIString("Toggle breakpoint"));section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.ToggleComment,WebInspector.UIString("Toggle comment"));},__proto__:WebInspector.PanelDescriptor.prototype}
|
| +WebInspector.ScriptsPanelDescriptor.ShortcutKeys={RunSnippet:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Enter,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],PauseContinue:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F8)],StepOver:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F10),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.SingleQuote,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],StepInto:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F11),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Semicolon,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],StepOut:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.F11,WebInspector.KeyboardShortcut.Modifiers.Shift),WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Semicolon,WebInspector.KeyboardShortcut.Modifiers.Shift|WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],EvaluateSelectionInConsole:[WebInspector.KeyboardShortcut.makeDescriptor("e",WebInspector.KeyboardShortcut.Modifiers.Shift|WebInspector.KeyboardShortcut.Modifiers.Ctrl)],GoToMember:[WebInspector.KeyboardShortcut.makeDescriptor("o",WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta|WebInspector.KeyboardShortcut.Modifiers.Shift)],ToggleBreakpoint:[WebInspector.KeyboardShortcut.makeDescriptor("b",WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],NextCallFrame:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Period,WebInspector.KeyboardShortcut.Modifiers.Ctrl)],PrevCallFrame:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Comma,WebInspector.KeyboardShortcut.Modifiers.Ctrl)],ToggleComment:[WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortcut.Keys.Slash,WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)]};WebInspector.TimelinePanelDescriptor=function()
|
| {WebInspector.PanelDescriptor.call(this,"timeline",WebInspector.UIString("Timeline"),"TimelinePanel","TimelinePanel.js");}
|
| WebInspector.TimelinePanelDescriptor.prototype={registerShortcuts:function()
|
| {var section=WebInspector.shortcutsScreen.section(WebInspector.UIString("Timeline Panel"));section.addAlternateKeys(WebInspector.TimelinePanelDescriptor.ShortcutKeys.StartStopRecording,WebInspector.UIString("Start/stop recording"));section.addAlternateKeys(WebInspector.TimelinePanelDescriptor.ShortcutKeys.SaveToFile,WebInspector.UIString("Save timeline data"));section.addAlternateKeys(WebInspector.TimelinePanelDescriptor.ShortcutKeys.LoadFromFile,WebInspector.UIString("Load timeline data"));},__proto__:WebInspector.PanelDescriptor.prototype}
|
| WebInspector.TimelinePanelDescriptor.ShortcutKeys={StartStopRecording:[WebInspector.KeyboardShortcut.makeDescriptor("e",WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],SaveToFile:[WebInspector.KeyboardShortcut.makeDescriptor("s",WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)],LoadFromFile:[WebInspector.KeyboardShortcut.makeDescriptor("o",WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)]}
|
| -WebInspector.LayersPanelDescriptor=function()
|
| -{WebInspector.PanelDescriptor.call(this,"layers",WebInspector.UIString("Layers"),"LayersPanel","LayersPanel.js");}
|
| -WebInspector.LayersPanelDescriptor.prototype={__proto__:WebInspector.PanelDescriptor.prototype}
|
| WebInspector.DockController=function()
|
| -{this._dockToggleButton=new WebInspector.StatusBarButton("","dock-status-bar-item",3);this._dockToggleButtonOption=new WebInspector.StatusBarButton("","dock-status-bar-item",3);this._dockToggleButton.addEventListener("click",this._toggleDockState,this);this._dockToggleButtonOption.addEventListener("click",this._toggleDockState,this);this._dockToggleButton.setLongClickOptionsEnabled(this._createDockOptions.bind(this));this.setDockSide(WebInspector.queryParamsObject["dockSide"]||"bottom");}
|
| +{this._dockToggleButton=new WebInspector.StatusBarButton("","dock-status-bar-item",3);this._dockToggleButtonOption=new WebInspector.StatusBarButton("","dock-status-bar-item",3);this._dockToggleButton.addEventListener("click",this._toggleDockState,this);this._dockToggleButtonOption.addEventListener("click",this._toggleDockState,this);this._dockToggleButton.makeLongClickOptionsEnabled(this._createDockOptions.bind(this));this.setDockSide(WebInspector.queryParamsObject["dockSide"]||"bottom");}
|
| WebInspector.DockController.State={DockedToBottom:"bottom",DockedToRight:"right",Undocked:"undocked"}
|
| WebInspector.DockController.Events={DockSideChanged:"DockSideChanged"}
|
| WebInspector.DockController.prototype={get element()
|
| @@ -9344,73 +9829,6 @@
|
| WebInspector.TracingDispatcher.prototype={dataCollected:function(data)
|
| {this._tracingAgent._eventsCollected(data);},tracingComplete:function()
|
| {this._tracingAgent._tracingComplete();}}
|
| -WebInspector.ScreencastView=function()
|
| -{WebInspector.View.call(this);this.registerRequiredCSS("screencastView.css");this.element.addStyleClass("fill");this.element.addStyleClass("screencast");this._viewportElement=this.element.createChild("div","screencast-viewport hidden");this._canvasElement=this._viewportElement.createChild("canvas");this._canvasElement.tabIndex=1;this._canvasElement.addEventListener("mousedown",this._handleMouseEvent.bind(this),false);this._canvasElement.addEventListener("mouseup",this._handleMouseEvent.bind(this),false);this._canvasElement.addEventListener("mousemove",this._handleMouseEvent.bind(this),false);this._canvasElement.addEventListener("mousewheel",this._handleMouseEvent.bind(this),false);this._canvasElement.addEventListener("click",this._handleMouseEvent.bind(this),false);this._canvasElement.addEventListener("contextmenu",this._handleContextMenuEvent.bind(this),false);this._canvasElement.addEventListener("keydown",this._handleKeyEvent.bind(this),false);this._canvasElement.addEventListener("keyup",this._handleKeyEvent.bind(this),false);this._canvasElement.addEventListener("keypress",this._handleKeyEvent.bind(this),false);this._titleElement=this._viewportElement.createChild("div","screencast-element-title monospace hidden");this._tagNameElement=this._titleElement.createChild("span","screencast-tag-name");this._nodeIdElement=this._titleElement.createChild("span","screencast-node-id");this._classNameElement=this._titleElement.createChild("span","screencast-class-name");this._titleElement.appendChild(document.createTextNode(" "));this._nodeWidthElement=this._titleElement.createChild("span");this._titleElement.createChild("span","screencast-px").textContent="px";this._titleElement.appendChild(document.createTextNode(" \u00D7 "));this._nodeHeightElement=this._titleElement.createChild("span");this._titleElement.createChild("span","screencast-px").textContent="px";this._imageElement=new Image();this._isCasting=false;this._context=this._canvasElement.getContext("2d");this._checkerboardPattern=this._createCheckerboardPattern(this._context);WebInspector.resourceTreeModel.addEventListener(WebInspector.ResourceTreeModel.EventTypes.ScreencastFrame,this._screencastFrame,this);}
|
| -WebInspector.ScreencastView._bordersSize=40;WebInspector.ScreencastView.prototype={wasShown:function()
|
| -{this._startCasting();},willHide:function()
|
| -{this._stopCasting();},_startCasting:function()
|
| -{if(this._isCasting)
|
| -return;this._isCasting=true;const maxImageDimension=800;var dimensions=this._viewportDimensions();if(dimensions.width<0||dimensions.height<0){this._isCasting=false;return;}
|
| -PageAgent.startScreencast("jpeg",80,Math.min(maxImageDimension,dimensions.width),Math.min(maxImageDimension,dimensions.height));WebInspector.domAgent.setHighlighter(this);},_stopCasting:function()
|
| -{if(!this._isCasting)
|
| -return;this._isCasting=false;PageAgent.stopScreencast();WebInspector.domAgent.setHighlighter(null);},_screencastFrame:function(event)
|
| -{var base64Data=(event.data.data);this._imageElement.src="data:image/jpg;base64,"+base64Data;this._deviceScaleFactor=(event.data.deviceScaleFactor);this._pageScaleFactor=(event.data.pageScaleFactor);this._viewport=(event.data.viewport);if(!this._viewport)
|
| -return;var offsetTop=(event.data.offsetTop)||0;var offsetBottom=(event.data.offsetBottom)||0;var screenWidthDIP=this._viewport.width*this._pageScaleFactor;var screenHeightDIP=this._viewport.height*this._pageScaleFactor+offsetTop+offsetBottom;this._screenOffsetTop=offsetTop;this._resizeViewport(screenWidthDIP,screenHeightDIP);this._imageZoom=this._imageElement.naturalWidth?this._canvasElement.offsetWidth/this._imageElement.naturalWidth:1;this.highlightDOMNode(this._highlightNodeId,this._highlightConfig);},_resizeViewport:function(screenWidthDIP,screenHeightDIP)
|
| -{var dimensions=this._viewportDimensions();this._screenZoom=Math.min(dimensions.width/screenWidthDIP,dimensions.height/screenHeightDIP);var bordersSize=WebInspector.ScreencastView._bordersSize;this._viewportElement.removeStyleClass("hidden");this._viewportElement.style.width=screenWidthDIP*this._screenZoom+bordersSize+"px";this._viewportElement.style.height=screenHeightDIP*this._screenZoom+bordersSize+"px";},_handleMouseEvent:function(event)
|
| -{if(!this._viewport)
|
| -return;if(!this._inspectModeConfig||event.type==="mousewheel"){this._simulateTouchGestureForMouseEvent(event);return;}
|
| -var position=this._convertIntoScreenSpace(event);DOMAgent.getNodeForLocation(position.x/this._pageScaleFactor,position.y/this._pageScaleFactor,callback.bind(this));function callback(error,nodeId)
|
| -{if(error)
|
| -return;if(event.type==="mousemove")
|
| -this.highlightDOMNode(nodeId,this._inspectModeConfig);else if(event.type==="click")
|
| -WebInspector.domAgent.dispatchEventToListeners(WebInspector.DOMAgent.Events.InspectNodeRequested,nodeId);}},_handleKeyEvent:function(event)
|
| -{var type;switch(event.type){case"keydown":type="keyDown";break;case"keyup":type="keyUp";break;case"keypress":type="char";break;default:return;}
|
| -var text=event.type==="keypress"?String.fromCharCode(event.charCode):undefined;InputAgent.dispatchKeyEvent(type,this._modifiersForEvent(event),event.timeStamp/1000,text,text?text.toLowerCase():undefined,event.keyIdentifier,event.keyCode,event.keyCode,undefined,false,false,false);event.consume();this._canvasElement.focus();},_handleContextMenuEvent:function(event)
|
| -{event.consume(true);},_simulateTouchGestureForMouseEvent:function(event)
|
| -{var position=this._convertIntoScreenSpace(event);var timeStamp=event.timeStamp/1000;var x=position.x;var y=position.y;switch(event.which){case 1:if(event.type==="mousedown"){InputAgent.dispatchGestureEvent("scrollBegin",x,y,timeStamp);}else if(event.type==="mousemove"){var dx=this._lastScrollPosition?position.x-this._lastScrollPosition.x:0;var dy=this._lastScrollPosition?position.y-this._lastScrollPosition.y:0;if(dx||dy)
|
| -InputAgent.dispatchGestureEvent("scrollUpdate",x,y,timeStamp,dx,dy);}else if(event.type==="mouseup"){InputAgent.dispatchGestureEvent("scrollEnd",x,y,timeStamp);}else if(event.type==="mousewheel"){InputAgent.dispatchGestureEvent("scrollBegin",x,y,timeStamp);InputAgent.dispatchGestureEvent("scrollUpdate",x,y,timeStamp,event.wheelDeltaX,event.wheelDeltaY);InputAgent.dispatchGestureEvent("scrollEnd",x,y,timeStamp);}else if(event.type==="click"){InputAgent.dispatchGestureEvent("tapDown",x,y,timeStamp);InputAgent.dispatchGestureEvent("tap",x,y,timeStamp);}
|
| -this._lastScrollPosition=position;break;case 2:if(event.type==="mousedown"){InputAgent.dispatchGestureEvent("tapDown",x,y,timeStamp);}else if(event.type==="mouseup"){InputAgent.dispatchGestureEvent("tap",x,y,timeStamp);}
|
| -break;case 3:if(event.type==="mousedown"){this._pinchStart=position;InputAgent.dispatchGestureEvent("pinchBegin",x,y,timeStamp);}else if(event.type==="mousemove"){var dx=this._pinchStart?position.x-this._pinchStart.x:0;var dy=this._pinchStart?position.y-this._pinchStart.y:0;if(dx||dy){var scale=Math.pow(dy<0?0.999:1.001,Math.abs(dy));InputAgent.dispatchGestureEvent("pinchUpdate",this._pinchStart.x,this._pinchStart.y,timeStamp,0,0,scale);}}else if(event.type==="mouseup"){InputAgent.dispatchGestureEvent("pinchEnd",x,y,timeStamp);}
|
| -break;case 0:default:}},_convertIntoScreenSpace:function(event)
|
| -{var zoom=this._canvasElement.offsetWidth/this._viewport.width/this._pageScaleFactor;var position={};position.x=Math.round(event.offsetX/zoom);position.y=Math.round(event.offsetY/zoom-this._screenOffsetTop);return position;},_modifiersForEvent:function(event)
|
| -{var modifiers=0;if(event.altKey)
|
| -modifiers=1;if(event.ctrlKey)
|
| -modifiers+=2;if(event.metaKey)
|
| -modifiers+=4;if(event.shiftKey)
|
| -modifiers+=8;return modifiers;},onResize:function()
|
| -{if(this._deferredCasting){clearTimeout(this._deferredCasting);delete this._deferredCasting;}
|
| -this._stopCasting();this._deferredCasting=setTimeout(this._startCasting.bind(this),100);},highlightDOMNode:function(nodeId,config,objectId)
|
| -{this._highlightNodeId=nodeId;this._highlightConfig=config;if(!nodeId){this._model=null;this._config=null;this._node=null;this._titleElement.addStyleClass("hidden");this._repaint();return;}
|
| -this._node=WebInspector.domAgent.nodeForId(nodeId);DOMAgent.getBoxModel(nodeId,callback.bind(this));function callback(error,model)
|
| -{if(error){this._repaint();return;}
|
| -this._model=this._scaleModel(model);this._config=config;this._repaint();}},_scaleModel:function(model)
|
| -{var scale=this._canvasElement.offsetWidth/this._viewport.width;function scaleQuad(quad)
|
| -{for(var i=0;i<quad.length;i+=2){quad[i]=(quad[i]-this._viewport.x)*scale;quad[i+1]=(quad[i+1]-this._viewport.y)*scale+this._screenOffsetTop*this._screenZoom;}}
|
| -scaleQuad.call(this,model.content);scaleQuad.call(this,model.padding);scaleQuad.call(this,model.border);scaleQuad.call(this,model.margin);return model;},_repaint:function()
|
| -{var model=this._model;var config=this._config;this._canvasElement.width=window.devicePixelRatio*this._canvasElement.offsetWidth;this._canvasElement.height=window.devicePixelRatio*this._canvasElement.offsetHeight;this._context.save();this._context.scale(window.devicePixelRatio,window.devicePixelRatio);this._context.save();this._context.fillStyle=this._checkerboardPattern;this._context.fillRect(0,0,this._canvasElement.offsetWidth,this._screenOffsetTop*this._screenZoom);this._context.fillRect(0,this._screenOffsetTop*this._screenZoom+this._imageElement.naturalHeight*this._imageZoom,this._canvasElement.offsetWidth,this._canvasElement.offsetHeight);this._context.restore();if(model&&config){this._context.save();const transparentColor="rgba(0, 0, 0, 0)";var hasContent=model.content&&config.contentColor!==transparentColor;var hasPadding=model.padding&&config.paddingColor!==transparentColor;var hasBorder=model.border&&config.borderColor!==transparentColor;var hasMargin=model.margin&&config.marginColor!==transparentColor;var clipQuad;if(hasMargin&&(!hasBorder||!this._quadsAreEqual(model.margin,model.border))){this._drawOutlinedQuadWithClip(model.margin,model.border,config.marginColor);clipQuad=model.border;}
|
| -if(hasBorder&&(!hasPadding||!this._quadsAreEqual(model.border,model.padding))){this._drawOutlinedQuadWithClip(model.border,model.padding,config.borderColor);clipQuad=model.padding;}
|
| -if(hasPadding&&(!hasContent||!this._quadsAreEqual(model.padding,model.content))){this._drawOutlinedQuadWithClip(model.padding,model.content,config.paddingColor);clipQuad=model.content;}
|
| -if(hasContent)
|
| -this._drawOutlinedQuad(model.content,config.contentColor);this._context.restore();this._drawElementTitle();this._context.globalCompositeOperation="destination-over";}
|
| -this._context.drawImage(this._imageElement,0,this._screenOffsetTop*this._screenZoom,this._imageElement.naturalWidth*this._imageZoom,this._imageElement.naturalHeight*this._imageZoom);this._context.restore();},_quadsAreEqual:function(quad1,quad2)
|
| -{for(var i=0;i<quad1.length;++i){if(quad1[i]!==quad2[i])
|
| -return false;}
|
| -return true;},_cssColor:function(color)
|
| -{if(!color)
|
| -return"transparent";return WebInspector.Color.fromRGBA([color.r,color.g,color.b,color.a]).toString(WebInspector.Color.Format.RGBA)||"";},_quadToPath:function(quad)
|
| -{this._context.beginPath();this._context.moveTo(quad[0],quad[1]);this._context.lineTo(quad[2],quad[3]);this._context.lineTo(quad[4],quad[5]);this._context.lineTo(quad[6],quad[7]);this._context.closePath();return this._context;},_drawOutlinedQuad:function(quad,fillColor)
|
| -{this._context.save();this._context.lineWidth=2;this._quadToPath(quad).clip();this._context.fillStyle=this._cssColor(fillColor);this._context.fill();this._context.restore();},_drawOutlinedQuadWithClip:function(quad,clipQuad,fillColor)
|
| -{this._context.fillStyle=this._cssColor(fillColor);this._context.save();this._context.lineWidth=0;this._quadToPath(quad).fill();this._context.globalCompositeOperation="destination-out";this._context.fillStyle="red";this._quadToPath(clipQuad).fill();this._context.restore();},_drawElementTitle:function()
|
| -{if(!this._node)
|
| -return;var canvasWidth=this._canvasElement.offsetWidth;var canvasHeight=this._canvasElement.offsetHeight;var lowerCaseName=this._node.localName()||this._node.nodeName().toLowerCase();this._tagNameElement.textContent=lowerCaseName;this._nodeIdElement.textContent=this._node.getAttribute("id")?"#"+this._node.getAttribute("id"):"";this._nodeIdElement.textContent=this._node.getAttribute("id")?"#"+this._node.getAttribute("id"):"";var className=this._node.getAttribute("class");if(className&&className.length>50)
|
| -className=className.substring(0,50)+"\u2026";this._classNameElement.textContent=className||"";this._nodeWidthElement.textContent=this._model.width;this._nodeHeightElement.textContent=this._model.height;var marginQuad=this._model.margin;var titleWidth=this._titleElement.offsetWidth+6;var titleHeight=this._titleElement.offsetHeight+4;var anchorTop=this._model.margin[1];var anchorBottom=this._model.margin[7];const arrowHeight=7;var renderArrowUp=false;var renderArrowDown=false;var boxX=Math.max(2,this._model.margin[0]);if(boxX+titleWidth>canvasWidth)
|
| -boxX=canvasWidth-titleWidth-2;var boxY;if(anchorTop>canvasHeight){boxY=canvasHeight-titleHeight-arrowHeight;renderArrowDown=true;}else if(anchorBottom<0){boxY=arrowHeight;renderArrowUp=true;}else if(anchorBottom+titleHeight+arrowHeight<canvasHeight){boxY=anchorBottom+arrowHeight-4;renderArrowUp=true;}else if(anchorTop-titleHeight-arrowHeight>0){boxY=anchorTop-titleHeight-arrowHeight+3;renderArrowDown=true;}else
|
| -boxY=arrowHeight;this._context.save();this._context.translate(0.5,0.5);this._context.beginPath();this._context.moveTo(boxX,boxY);if(renderArrowUp){this._context.lineTo(boxX+2*arrowHeight,boxY);this._context.lineTo(boxX+3*arrowHeight,boxY-arrowHeight);this._context.lineTo(boxX+4*arrowHeight,boxY);}
|
| -this._context.lineTo(boxX+titleWidth,boxY);this._context.lineTo(boxX+titleWidth,boxY+titleHeight);if(renderArrowDown){this._context.lineTo(boxX+4*arrowHeight,boxY+titleHeight);this._context.lineTo(boxX+3*arrowHeight,boxY+titleHeight+arrowHeight);this._context.lineTo(boxX+2*arrowHeight,boxY+titleHeight);}
|
| -this._context.lineTo(boxX,boxY+titleHeight);this._context.closePath();this._context.fillStyle="rgb(255, 255, 194)";this._context.fill();this._context.strokeStyle="rgb(128, 128, 128)";this._context.stroke();this._context.restore();this._titleElement.removeStyleClass("hidden");this._titleElement.style.top=(boxY+3)+"px";this._titleElement.style.left=(boxX+3)+"px";},_viewportDimensions:function()
|
| -{const gutterSize=30;const bordersSize=WebInspector.ScreencastView._bordersSize;return{width:this.element.offsetWidth-bordersSize-gutterSize,height:this.element.offsetHeight-bordersSize-gutterSize};},setInspectModeEnabled:function(enabled,inspectShadowDOM,config,callback)
|
| -{this._inspectModeConfig=enabled?config:null;callback(null);},_createCheckerboardPattern:function(context)
|
| -{var pattern=(document.createElement("canvas"));const size=32;pattern.width=size*2;pattern.height=size*2;var pctx=pattern.getContext("2d");pctx.fillStyle="rgb(195, 195, 195)";pctx.fillRect(0,0,size*2,size*2);pctx.fillStyle="rgb(225, 225, 225)";pctx.fillRect(0,0,size,size);pctx.fillRect(size,size,size,size);return context.createPattern(pattern,"repeat");},__proto__:WebInspector.View.prototype}
|
| function platformExtensionAPI(coreAPI)
|
| {function getTabId()
|
| {return tabId;}
|
|
|