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

Side by Side Diff: Source/devtools/front_end/ui/DropDownMenu.js

Issue 662793002: [DevTools] Replace usages of document with custom functions. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 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
« no previous file with comments | « Source/devtools/front_end/ui/DataGrid.js ('k') | Source/devtools/front_end/ui/PieChart.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * @constructor 6 * @constructor
7 * @extends {WebInspector.Object} 7 * @extends {WebInspector.Object}
8 */ 8 */
9 WebInspector.DropDownMenu = function() 9 WebInspector.DropDownMenu = function()
10 { 10 {
11 this.element = document.createElementWithClass("select", "drop-down-menu"); 11 this.element = createElementWithClass("select", "drop-down-menu");
12 this.element.addEventListener("mousedown", this._onBeforeMouseDown.bind(this ), true); 12 this.element.addEventListener("mousedown", this._onBeforeMouseDown.bind(this ), true);
13 this.element.addEventListener("mousedown", consumeEvent, false); 13 this.element.addEventListener("mousedown", consumeEvent, false);
14 this.element.addEventListener("change", this._onChange.bind(this), false); 14 this.element.addEventListener("change", this._onChange.bind(this), false);
15 } 15 }
16 16
17 WebInspector.DropDownMenu.Events = { 17 WebInspector.DropDownMenu.Events = {
18 BeforeShow: "BeforeShow", 18 BeforeShow: "BeforeShow",
19 ItemSelected: "ItemSelected" 19 ItemSelected: "ItemSelected"
20 } 20 }
21 21
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 this.element.selectedIndex = -1; 59 this.element.selectedIndex = -1;
60 }, 60 },
61 61
62 clear: function() 62 clear: function()
63 { 63 {
64 this.element.removeChildren(); 64 this.element.removeChildren();
65 }, 65 },
66 66
67 __proto__: WebInspector.Object.prototype 67 __proto__: WebInspector.Object.prototype
68 } 68 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/ui/DataGrid.js ('k') | Source/devtools/front_end/ui/PieChart.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698