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

Side by Side Diff: Source/devtools/front_end/InspectElementModeController.js

Issue 197283031: DevTools: fix author shadow dom inspection mode, speacial-case ua. Fix crash from the bug. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: For landing Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 10 *
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 62
63 /** 63 /**
64 * @param {?Protocol.Error} error 64 * @param {?Protocol.Error} error
65 * @this {WebInspector.InspectElementModeController} 65 * @this {WebInspector.InspectElementModeController}
66 */ 66 */
67 function callback(error) 67 function callback(error)
68 { 68 {
69 if (!error) 69 if (!error)
70 this.toggleSearchButton.toggled = enabled; 70 this.toggleSearchButton.toggled = enabled;
71 } 71 }
72 WebInspector.domAgent.setInspectModeEnabled(enabled, WebInspector.settin gs.showShadowDOM.get(), callback.bind(this)); 72 WebInspector.domAgent.setInspectModeEnabled(enabled, WebInspector.settin gs.showUAShadowDOM.get(), callback.bind(this));
73 }, 73 },
74 74
75 /** 75 /**
76 * @param {!KeyboardEvent} event 76 * @param {!KeyboardEvent} event
77 * @return {boolean} 77 * @return {boolean}
78 */ 78 */
79 handleShortcut: function(event) 79 handleShortcut: function(event)
80 { 80 {
81 if (WebInspector.KeyboardShortcut.makeKeyFromEvent(event) !== this._shor tcut.key) 81 if (WebInspector.KeyboardShortcut.makeKeyFromEvent(event) !== this._shor tcut.key)
82 return false; 82 return false;
83 this.toggleSearch(); 83 this.toggleSearch();
84 event.consume(true); 84 event.consume(true);
85 return true; 85 return true;
86 } 86 }
87 } 87 }
88 88
89 /** @type {!WebInspector.InspectElementModeController} */ 89 /** @type {!WebInspector.InspectElementModeController} */
90 WebInspector.inspectElementModeController; 90 WebInspector.inspectElementModeController;
OLDNEW
« no previous file with comments | « Source/devtools/front_end/ElementsTreeOutline.js ('k') | Source/devtools/front_end/ScreencastView.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698