Diff
Modified: trunk/LayoutTests/ChangeLog (114891 => 114892)
--- trunk/LayoutTests/ChangeLog 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/LayoutTests/ChangeLog 2012-04-23 13:26:20 UTC (rev 114892)
@@ -1,3 +1,13 @@
+2012-04-23 Pavel Feldman <pfeld...@chromium.org>
+
+ Web Inspector: Rename and extract UISourceCodeImpl into _javascript_Source
+ https://bugs.webkit.org/show_bug.cgi?id=84587
+
+ Reviewed by Yury Semikhatsky.
+
+ * inspector/debugger/breakpoint-manager.html:
+ * inspector/debugger/scripts-panel.html:
+
2012-04-23 Mikhail Naganov <mnaga...@chromium.org>
[Chromium] Unreviewed test expectations update.
Modified: trunk/LayoutTests/inspector/debugger/breakpoint-manager.html (114891 => 114892)
--- trunk/LayoutTests/inspector/debugger/breakpoint-manager.html 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/LayoutTests/inspector/debugger/breakpoint-manager.html 2012-04-23 13:26:20 UTC (rev 114892)
@@ -60,7 +60,7 @@
serializedBreakpoints.push(createBreakpoint("a.js", 20, "", false));
serializedBreakpoints.push(createBreakpoint("b.js", 3, "", true));
- function createUISourceCode(id, url) { return new WebInspector.UISourceCodeImpl(id, url, null); }
+ function createUISourceCode(id, url) { return new WebInspector._javascript_Source(id, url, null); }
var scriptMapping = {};
scriptMapping.rawLocationToUILocation = function(rawLocation) { return rawLocation; };
Modified: trunk/LayoutTests/inspector/debugger/scripts-panel.html (114891 => 114892)
--- trunk/LayoutTests/inspector/debugger/scripts-panel.html 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/LayoutTests/inspector/debugger/scripts-panel.html 2012-04-23 13:26:20 UTC (rev 114892)
@@ -43,7 +43,7 @@
}
function createUISouceCode(url)
{
- var uiSourceCode = new WebInspector.UISourceCodeImpl(0, url, null, null);
+ var uiSourceCode = new WebInspector._javascript_Source(0, url, null, null);
uiSourceCode.requestContent = function(callback)
{
InspectorTest.addResult("Source requested for " + url);
Modified: trunk/Source/WebCore/ChangeLog (114891 => 114892)
--- trunk/Source/WebCore/ChangeLog 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/ChangeLog 2012-04-23 13:26:20 UTC (rev 114892)
@@ -1,3 +1,35 @@
+2012-04-23 Pavel Feldman <pfeld...@chromium.org>
+
+ Web Inspector: Rename and extract UISourceCodeImpl into _javascript_Source
+ https://bugs.webkit.org/show_bug.cgi?id=84587
+
+ Reviewed by Yury Semikhatsky.
+
+ No changes other than extraction here. This is the first step in the Resource
+ hierarchy refactoring described in bug 84586.
+
+ * WebCore.gypi:
+ * WebCore.vcproj/WebCore.vcproj:
+ * inspector/compile-front-end.py:
+ * inspector/front-end/CompilerScriptMapping.js:
+ (WebInspector.CompilerScriptMapping.prototype.addScript):
+ * inspector/front-end/DebuggerPresentationModel.js:
+ * inspector/front-end/_javascript_Source.js: Added.
+ (WebInspector._javascript_Source):
+ (WebInspector._javascript_Source.prototype.breakpoints):
+ (WebInspector._javascript_Source.prototype.breakpointAdded):
+ (WebInspector._javascript_Source.prototype.breakpointRemoved):
+ (WebInspector._javascript_Source.prototype.consoleMessages):
+ (WebInspector._javascript_Source.prototype.consoleMessageAdded):
+ (WebInspector._javascript_Source.prototype.consoleMessagesCleared):
+ * inspector/front-end/RawSourceCode.js:
+ (WebInspector.RawSourceCode.prototype._createUISourceCode):
+ * inspector/front-end/SnippetsModel.js:
+ (WebInspector.SnippetsScriptMapping.prototype._snippetAdded):
+ (WebInspector.SnippetsScriptMapping.prototype._createUISourceCodeForScript):
+ * inspector/front-end/WebKit.qrc:
+ * inspector/front-end/inspector.html:
+
2012-04-23 Gavin Peters <gav...@chromium.org>
Move ReferrerPolicy out of SecurityPolicy class into its own header in platform.
Modified: trunk/Source/WebCore/WebCore.gypi (114891 => 114892)
--- trunk/Source/WebCore/WebCore.gypi 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/WebCore.gypi 2012-04-23 13:26:20 UTC (rev 114892)
@@ -6360,6 +6360,7 @@
'inspector/front-end/inspector.js',
'inspector/front-end/_javascript_ContextManager.js',
'inspector/front-end/_javascript_Formatter.js',
+ 'inspector/front-end/_javascript_Source.js',
'inspector/front-end/_javascript_SourceFrame.js',
'inspector/front-end/KeyboardShortcut.js',
'inspector/front-end/MemoryStatistics.js',
Modified: trunk/Source/WebCore/WebCore.vcproj/WebCore.vcproj (114891 => 114892)
--- trunk/Source/WebCore/WebCore.vcproj/WebCore.vcproj 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/WebCore.vcproj/WebCore.vcproj 2012-04-23 13:26:20 UTC (rev 114892)
@@ -74109,6 +74109,10 @@
>
</File>
<File
+ RelativePath="..\inspector\front-end\_javascript_Source.js"
+ >
+ </File>
+ <File
RelativePath="..\inspector\front-end\_javascript_SourceFrame.js"
>
</File>
Modified: trunk/Source/WebCore/inspector/compile-front-end.py (114891 => 114892)
--- trunk/Source/WebCore/inspector/compile-front-end.py 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/inspector/compile-front-end.py 2012-04-23 13:26:20 UTC (rev 114892)
@@ -154,6 +154,7 @@
"NavigatorOverlayController.js",
"NavigatorView.js",
"_javascript_ContextManager.js",
+ "_javascript_Source.js",
"ObjectPopoverHelper.js",
"ObjectPropertiesSection.js",
"PropertiesSidebarPane.js",
Modified: trunk/Source/WebCore/inspector/front-end/CompilerScriptMapping.js (114891 => 114892)
--- trunk/Source/WebCore/inspector/front-end/CompilerScriptMapping.js 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/inspector/front-end/CompilerScriptMapping.js 2012-04-23 13:26:20 UTC (rev 114892)
@@ -117,7 +117,7 @@
contentProvider = new WebInspector.StaticContentProvider("text/_javascript_", sourceContent);
else
contentProvider = new WebInspector.CompilerSourceMappingContentProvider(sourceURL);
- var uiSourceCode = new WebInspector.UISourceCodeImpl(sourceURL, sourceURL, contentProvider);
+ var uiSourceCode = new WebInspector._javascript_Source(sourceURL, sourceURL, contentProvider);
uiSourceCode.isContentScript = script.isContentScript;
uiSourceCode.isEditable = false;
this._uiSourceCodeByURL[sourceURL] = uiSourceCode;
Modified: trunk/Source/WebCore/inspector/front-end/DebuggerPresentationModel.js (114891 => 114892)
--- trunk/Source/WebCore/inspector/front-end/DebuggerPresentationModel.js 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/inspector/front-end/DebuggerPresentationModel.js 2012-04-23 13:26:20 UTC (rev 114892)
@@ -552,85 +552,8 @@
WebInspector.DebuggerPresentationModel.prototype.__proto__ = WebInspector.Object.prototype;
-
/**
* @constructor
- * @extends {WebInspector.UISourceCode}
- * @param {string} id
- * @param {string} url
- * @param {WebInspector.ContentProvider} contentProvider
- */
-WebInspector.UISourceCodeImpl = function(id, url, contentProvider)
-{
- WebInspector.UISourceCode.call(this, id, url, contentProvider);
- /**
- * @type {Object.<string,WebInspector.UIBreakpoint>}
- */
- this._breakpoints = {};
- /**
- * @type {Array.<WebInspector.PresentationConsoleMessage>}
- */
- this._consoleMessages = [];
-}
-
-WebInspector.UISourceCodeImpl.prototype = {
- /**
- * @return {Object.<string,WebInspector.UIBreakpoint>}
- */
- breakpoints: function()
- {
- return this._breakpoints;
- },
-
- /**
- * @param {number} lineNumber
- * @param {WebInspector.UIBreakpoint} breakpoint
- */
- breakpointAdded: function(lineNumber, breakpoint)
- {
- console.assert(!this._breakpoints[String(lineNumber)]);
- this._breakpoints[String(lineNumber)] = breakpoint;
- this.dispatchEventToListeners(WebInspector.UISourceCode.Events.BreakpointAdded, breakpoint);
- },
-
- /**
- * @param {number} lineNumber
- */
- breakpointRemoved: function(lineNumber)
- {
- var breakpoint = this._breakpoints[String(lineNumber)];
- delete this._breakpoints[String(lineNumber)];
- this.dispatchEventToListeners(WebInspector.UISourceCode.Events.BreakpointRemoved, breakpoint);
- },
-
- /**
- * @return {Array.<WebInspector.PresentationConsoleMessage>}
- */
- consoleMessages: function()
- {
- return this._consoleMessages;
- },
-
- /**
- * @param {WebInspector.PresentationConsoleMessage} message
- */
- consoleMessageAdded: function(message)
- {
- this._consoleMessages.push(message);
- this.dispatchEventToListeners(WebInspector.UISourceCode.Events.ConsoleMessageAdded, message);
- },
-
- consoleMessagesCleared: function()
- {
- this._consoleMessages = [];
- this.dispatchEventToListeners(WebInspector.UISourceCode.Events.ConsoleMessagesCleared);
- }
-}
-
-WebInspector.UISourceCodeImpl.prototype.__proto__ = WebInspector.UISourceCode.prototype;
-
-/**
- * @constructor
* @param {WebInspector.UISourceCode} uiSourceCode
* @param {number} lineNumber
* @param {WebInspector.ConsoleMessage} originalMessage
Added: trunk/Source/WebCore/inspector/front-end/_javascript_Source.js (0 => 114892)
--- trunk/Source/WebCore/inspector/front-end/_javascript_Source.js (rev 0)
+++ trunk/Source/WebCore/inspector/front-end/_javascript_Source.js 2012-04-23 13:26:20 UTC (rev 114892)
@@ -0,0 +1,105 @@
+/*
+ * Copyright (C) 2012 Google Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/**
+ * @constructor
+ * @extends {WebInspector.UISourceCode}
+ * @param {string} id
+ * @param {string} url
+ * @param {WebInspector.ContentProvider} contentProvider
+ */
+WebInspector._javascript_Source = function(id, url, contentProvider)
+{
+ WebInspector.UISourceCode.call(this, id, url, contentProvider);
+ /**
+ * @type {Object.<string,WebInspector.UIBreakpoint>}
+ */
+ this._breakpoints = {};
+ /**
+ * @type {Array.<WebInspector.PresentationConsoleMessage>}
+ */
+ this._consoleMessages = [];
+}
+
+WebInspector._javascript_Source.prototype = {
+ /**
+ * @return {Object.<string,WebInspector.UIBreakpoint>}
+ */
+ breakpoints: function()
+ {
+ return this._breakpoints;
+ },
+
+ /**
+ * @param {number} lineNumber
+ * @param {WebInspector.UIBreakpoint} breakpoint
+ */
+ breakpointAdded: function(lineNumber, breakpoint)
+ {
+ console.assert(!this._breakpoints[String(lineNumber)]);
+ this._breakpoints[String(lineNumber)] = breakpoint;
+ this.dispatchEventToListeners(WebInspector.UISourceCode.Events.BreakpointAdded, breakpoint);
+ },
+
+ /**
+ * @param {number} lineNumber
+ */
+ breakpointRemoved: function(lineNumber)
+ {
+ var breakpoint = this._breakpoints[String(lineNumber)];
+ delete this._breakpoints[String(lineNumber)];
+ this.dispatchEventToListeners(WebInspector.UISourceCode.Events.BreakpointRemoved, breakpoint);
+ },
+
+ /**
+ * @return {Array.<WebInspector.PresentationConsoleMessage>}
+ */
+ consoleMessages: function()
+ {
+ return this._consoleMessages;
+ },
+
+ /**
+ * @param {WebInspector.PresentationConsoleMessage} message
+ */
+ consoleMessageAdded: function(message)
+ {
+ this._consoleMessages.push(message);
+ this.dispatchEventToListeners(WebInspector.UISourceCode.Events.ConsoleMessageAdded, message);
+ },
+
+ consoleMessagesCleared: function()
+ {
+ this._consoleMessages = [];
+ this.dispatchEventToListeners(WebInspector.UISourceCode.Events.ConsoleMessagesCleared);
+ }
+}
+
+WebInspector._javascript_Source.prototype.__proto__ = WebInspector.UISourceCode.prototype;
Property changes on: trunk/Source/WebCore/inspector/front-end/_javascript_Source.js
___________________________________________________________________
Added: svn:eol-style
Modified: trunk/Source/WebCore/inspector/front-end/RawSourceCode.js (114891 => 114892)
--- trunk/Source/WebCore/inspector/front-end/RawSourceCode.js 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/inspector/front-end/RawSourceCode.js 2012-04-23 13:26:20 UTC (rev 114892)
@@ -216,7 +216,7 @@
*/
_createUISourceCode: function(id, url, contentProvider)
{
- var uiSourceCode = new WebInspector.UISourceCodeImpl(id, url, contentProvider);
+ var uiSourceCode = new WebInspector._javascript_Source(id, url, contentProvider);
uiSourceCode.isContentScript = this.isContentScript;
uiSourceCode.isEditable = this._scripts.length === 1 && !this._scripts[0].lineOffset && !this._scripts[0].columnOffset && !this._formatted;
return uiSourceCode;
Modified: trunk/Source/WebCore/inspector/front-end/SnippetsModel.js (114891 => 114892)
--- trunk/Source/WebCore/inspector/front-end/SnippetsModel.js 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/inspector/front-end/SnippetsModel.js 2012-04-23 13:26:20 UTC (rev 114892)
@@ -394,7 +394,7 @@
{
var uiSourceCodeId = ""; // FIXME: to be implemented.
var uiSourceCodeURL = ""; // FIXME: to be implemented.
- var uiSourceCode = new WebInspector.UISourceCodeImpl(uiSourceCodeId, uiSourceCodeURL, new WebInspector.SnippetContentProvider(snippet));
+ var uiSourceCode = new WebInspector._javascript_Source(uiSourceCodeId, uiSourceCodeURL, new WebInspector.SnippetContentProvider(snippet));
uiSourceCode.isSnippet = true;
uiSourceCode.isEditable = true;
this._uiSourceCodeForSnippet.put(snippet, uiSourceCode);
@@ -417,7 +417,7 @@
*/
_createUISourceCodeForScript: function(script)
{
- var uiSourceCode = new WebInspector.UISourceCodeImpl(script.sourceURL, script.sourceURL, new WebInspector.ScriptContentProvider(script));
+ var uiSourceCode = new WebInspector._javascript_Source(script.sourceURL, script.sourceURL, new WebInspector.ScriptContentProvider(script));
uiSourceCode.isSnippetEvaluation = true;
var oldUISourceCode = this._uiSourceCodeForScriptId[script.scriptId];
this._uiSourceCodeForScriptId[script.scriptId] = uiSourceCode;
Modified: trunk/Source/WebCore/inspector/front-end/WebKit.qrc (114891 => 114892)
--- trunk/Source/WebCore/inspector/front-end/WebKit.qrc 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/inspector/front-end/WebKit.qrc 2012-04-23 13:26:20 UTC (rev 114892)
@@ -79,6 +79,7 @@
<file>InspectorView.js</file>
<file>_javascript_ContextManager.js</file>
<file>_javascript_Formatter.js</file>
+ <file>_javascript_Source.js</file>
<file>_javascript_SourceFrame.js</file>
<file>KeyboardShortcut.js</file>
<file>MemoryStatistics.js</file>
Modified: trunk/Source/WebCore/inspector/front-end/inspector.html (114891 => 114892)
--- trunk/Source/WebCore/inspector/front-end/inspector.html 2012-04-23 13:15:09 UTC (rev 114891)
+++ trunk/Source/WebCore/inspector/front-end/inspector.html 2012-04-23 13:26:20 UTC (rev 114892)
@@ -176,6 +176,7 @@
<script type="text/_javascript_" src=""
<script type="text/_javascript_" src=""
<script type="text/_javascript_" src=""
+ <script type="text/_javascript_" src=""
<script type="text/_javascript_" src=""
<script type="text/_javascript_" src=""
<script type="text/_javascript_" src=""