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

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

Issue 1176343002: DevTools: make toolbar button click targets square (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: review comments addressed Created 5 years, 6 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) 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2007 Matt Lilek (pewtermoose@gmail.com). 3 * Copyright (C) 2007 Matt Lilek (pewtermoose@gmail.com).
4 * Copyright (C) 2009 Joseph Pecoraro 4 * Copyright (C) 2009 Joseph Pecoraro
5 * Copyright (C) 2011 Google Inc. All rights reserved. 5 * Copyright (C) 2011 Google Inc. All rights reserved.
6 * 6 *
7 * Redistribution and use in source and binary forms, with or without 7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions 8 * modification, are permitted provided that the following conditions
9 * are met: 9 * are met:
10 * 10 *
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 this._searchProvider = searchable; 43 this._searchProvider = searchable;
44 this._setting = settingName ? WebInspector.settings.createSetting(settingNam e, {}) : null; 44 this._setting = settingName ? WebInspector.settings.createSetting(settingNam e, {}) : null;
45 45
46 this.element.addEventListener("keydown", this._onKeyDown.bind(this), false); 46 this.element.addEventListener("keydown", this._onKeyDown.bind(this), false);
47 47
48 this.contentElement.createChild("content"); 48 this.contentElement.createChild("content");
49 this._footerElementContainer = this.contentElement.createChild("div", "searc h-bar hidden"); 49 this._footerElementContainer = this.contentElement.createChild("div", "searc h-bar hidden");
50 this._footerElementContainer.style.order = 100; 50 this._footerElementContainer.style.order = 100;
51 51
52 var toolbar = new WebInspector.Toolbar(this._footerElementContainer); 52 var toolbar = new WebInspector.Toolbar(this._footerElementContainer);
53 if (!Runtime.experiments.isEnabled("materialDesign"))
54 toolbar.makeNarrow();
55 53
56 if (this._searchProvider.supportsCaseSensitiveSearch()) { 54 if (this._searchProvider.supportsCaseSensitiveSearch()) {
57 this._caseSensitiveButton = new WebInspector.ToolbarTextButton(WebInspec tor.UIString("Case sensitive"), "case-sensitive-search-toolbar-item", "Aa", 2); 55 this._caseSensitiveButton = new WebInspector.ToolbarTextButton(WebInspec tor.UIString("Case sensitive"), "case-sensitive-search-toolbar-item", "Aa", 2);
58 this._caseSensitiveButton.addEventListener("click", this._toggleCaseSens itiveSearch, this); 56 this._caseSensitiveButton.addEventListener("click", this._toggleCaseSens itiveSearch, this);
59 toolbar.appendToolbarItem(this._caseSensitiveButton); 57 toolbar.appendToolbarItem(this._caseSensitiveButton);
60 } 58 }
61 59
62 if (this._searchProvider.supportsRegexSearch()) { 60 if (this._searchProvider.supportsRegexSearch()) {
63 this._regexButton = new WebInspector.ToolbarTextButton(WebInspector.UISt ring("Regex"), "regex-search-toolbar-item", ".*", 2); 61 this._regexButton = new WebInspector.ToolbarTextButton(WebInspector.UISt ring("Regex"), "regex-search-toolbar-item", ".*", 2);
64 this._regexButton.addEventListener("click", this._toggleRegexSearch, thi s); 62 this._regexButton.addEventListener("click", this._toggleRegexSearch, thi s);
(...skipping 668 matching lines...) Expand 10 before | Expand all | Expand 10 after
733 // Silent catch. 731 // Silent catch.
734 } 732 }
735 733
736 // Otherwise just do a plain text search. 734 // Otherwise just do a plain text search.
737 if (!regex) 735 if (!regex)
738 regex = createPlainTextSearchRegex(query, modifiers); 736 regex = createPlainTextSearchRegex(query, modifiers);
739 737
740 return regex; 738 return regex;
741 } 739 }
742 } 740 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/timeline/timelinePanel.css ('k') | Source/devtools/front_end/ui/SidebarPane.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698