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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/sdk/DOMModel.js

Issue 2560043005: DevTools: Remove unused variables. Disallow unused variables with eslint (Closed)
Patch Set: A new unused variable was born Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009, 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2009, 2010 Google Inc. All rights reserved.
3 * Copyright (C) 2009 Joseph Pecoraro 3 * Copyright (C) 2009 Joseph Pecoraro
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 1789 matching lines...) Expand 10 before | Expand all | Expand 10 after
1800 } 1800 }
1801 1801
1802 markUndoableState() { 1802 markUndoableState() {
1803 this._agent.markUndoableState(); 1803 this._agent.markUndoableState();
1804 } 1804 }
1805 1805
1806 /** 1806 /**
1807 * @param {function(?Protocol.Error)=} callback 1807 * @param {function(?Protocol.Error)=} callback
1808 */ 1808 */
1809 undo(callback) { 1809 undo(callback) {
1810 /**
1811 * @param {?Protocol.Error} error
1812 * @this {SDK.DOMModel}
1813 */
1814 function mycallback(error) {
1815 this.dispatchEventToListeners(SDK.DOMModel.Events.UndoRedoCompleted);
1816 callback(error);
1817 }
1818
1819 this.dispatchEventToListeners(SDK.DOMModel.Events.UndoRedoRequested);
1820 this._agent.undo(callback); 1810 this._agent.undo(callback);
1821 } 1811 }
1822 1812
1823 /** 1813 /**
1824 * @param {function(?Protocol.Error)=} callback 1814 * @param {function(?Protocol.Error)=} callback
1825 */ 1815 */
1826 redo(callback) { 1816 redo(callback) {
1827 /**
1828 * @param {?Protocol.Error} error
1829 * @this {SDK.DOMModel}
1830 */
1831 function mycallback(error) {
1832 this.dispatchEventToListeners(SDK.DOMModel.Events.UndoRedoCompleted);
1833 callback(error);
1834 }
1835
1836 this.dispatchEventToListeners(SDK.DOMModel.Events.UndoRedoRequested);
1837 this._agent.redo(callback); 1817 this._agent.redo(callback);
1838 } 1818 }
1839 1819
1840 /** 1820 /**
1841 * @param {?SDK.DOMNodeHighlighter} highlighter 1821 * @param {?SDK.DOMNodeHighlighter} highlighter
1842 */ 1822 */
1843 setHighlighter(highlighter) { 1823 setHighlighter(highlighter) {
1844 this._highlighter = highlighter || this._defaultHighlighter; 1824 this._highlighter = highlighter || this._defaultHighlighter;
1845 } 1825 }
1846 1826
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
1934 AttrModified: Symbol('AttrModified'), 1914 AttrModified: Symbol('AttrModified'),
1935 AttrRemoved: Symbol('AttrRemoved'), 1915 AttrRemoved: Symbol('AttrRemoved'),
1936 CharacterDataModified: Symbol('CharacterDataModified'), 1916 CharacterDataModified: Symbol('CharacterDataModified'),
1937 DOMMutated: Symbol('DOMMutated'), 1917 DOMMutated: Symbol('DOMMutated'),
1938 NodeInserted: Symbol('NodeInserted'), 1918 NodeInserted: Symbol('NodeInserted'),
1939 NodeInspected: Symbol('NodeInspected'), 1919 NodeInspected: Symbol('NodeInspected'),
1940 NodeHighlightedInOverlay: Symbol('NodeHighlightedInOverlay'), 1920 NodeHighlightedInOverlay: Symbol('NodeHighlightedInOverlay'),
1941 NodeRemoved: Symbol('NodeRemoved'), 1921 NodeRemoved: Symbol('NodeRemoved'),
1942 DocumentUpdated: Symbol('DocumentUpdated'), 1922 DocumentUpdated: Symbol('DocumentUpdated'),
1943 ChildNodeCountUpdated: Symbol('ChildNodeCountUpdated'), 1923 ChildNodeCountUpdated: Symbol('ChildNodeCountUpdated'),
1944 UndoRedoRequested: Symbol('UndoRedoRequested'),
1945 UndoRedoCompleted: Symbol('UndoRedoCompleted'),
1946 DistributedNodesChanged: Symbol('DistributedNodesChanged'), 1924 DistributedNodesChanged: Symbol('DistributedNodesChanged'),
1947 ModelSuspended: Symbol('ModelSuspended'),
1948 InspectModeWillBeToggled: Symbol('InspectModeWillBeToggled'), 1925 InspectModeWillBeToggled: Symbol('InspectModeWillBeToggled'),
1949 MarkersChanged: Symbol('MarkersChanged') 1926 MarkersChanged: Symbol('MarkersChanged')
1950 }; 1927 };
1951 1928
1952 1929
1953 /** 1930 /**
1954 * @implements {Protocol.DOMDispatcher} 1931 * @implements {Protocol.DOMDispatcher}
1955 * @unrestricted 1932 * @unrestricted
1956 */ 1933 */
1957 SDK.DOMDispatcher = class { 1934 SDK.DOMDispatcher = class {
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after
2170 /** 2147 /**
2171 * @override 2148 * @override
2172 * @param {!Protocol.Page.FrameId} frameId 2149 * @param {!Protocol.Page.FrameId} frameId
2173 */ 2150 */
2174 highlightFrame(frameId) { 2151 highlightFrame(frameId) {
2175 this._agent.highlightFrame( 2152 this._agent.highlightFrame(
2176 frameId, Common.Color.PageHighlight.Content.toProtocolRGBA(), 2153 frameId, Common.Color.PageHighlight.Content.toProtocolRGBA(),
2177 Common.Color.PageHighlight.ContentOutline.toProtocolRGBA()); 2154 Common.Color.PageHighlight.ContentOutline.toProtocolRGBA());
2178 } 2155 }
2179 }; 2156 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698