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

Side by Side Diff: chrome/browser/ui/browser.cc

Issue 9203001: Implement input type=color UI (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: fixed Created 8 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "chrome/browser/ui/browser.h" 5 #include "chrome/browser/ui/browser.h"
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <windows.h> 8 #include <windows.h>
9 #include <shellapi.h> 9 #include <shellapi.h>
10 #endif // OS_WIN 10 #endif // OS_WIN
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
143 #include "chrome/common/chrome_switches.h" 143 #include "chrome/common/chrome_switches.h"
144 #include "chrome/common/custom_handlers/protocol_handler.h" 144 #include "chrome/common/custom_handlers/protocol_handler.h"
145 #include "chrome/common/extensions/extension.h" 145 #include "chrome/common/extensions/extension.h"
146 #include "chrome/common/extensions/extension_constants.h" 146 #include "chrome/common/extensions/extension_constants.h"
147 #include "chrome/common/pref_names.h" 147 #include "chrome/common/pref_names.h"
148 #include "chrome/common/profiling.h" 148 #include "chrome/common/profiling.h"
149 #include "chrome/common/url_constants.h" 149 #include "chrome/common/url_constants.h"
150 #include "chrome/common/web_apps.h" 150 #include "chrome/common/web_apps.h"
151 #include "content/browser/browser_url_handler.h" 151 #include "content/browser/browser_url_handler.h"
152 #include "content/browser/renderer_host/render_view_host.h" 152 #include "content/browser/renderer_host/render_view_host.h"
153 #include "content/public/browser/color_chooser.h"
153 #include "content/public/browser/devtools_manager.h" 154 #include "content/public/browser/devtools_manager.h"
154 #include "content/public/browser/download_item.h" 155 #include "content/public/browser/download_item.h"
155 #include "content/public/browser/download_manager.h" 156 #include "content/public/browser/download_manager.h"
156 #include "content/public/browser/interstitial_page.h" 157 #include "content/public/browser/interstitial_page.h"
157 #include "content/public/browser/invalidate_type.h" 158 #include "content/public/browser/invalidate_type.h"
158 #include "content/public/browser/navigation_controller.h" 159 #include "content/public/browser/navigation_controller.h"
159 #include "content/public/browser/navigation_entry.h" 160 #include "content/public/browser/navigation_entry.h"
160 #include "content/public/browser/notification_details.h" 161 #include "content/public/browser/notification_details.h"
161 #include "content/public/browser/notification_service.h" 162 #include "content/public/browser/notification_service.h"
162 #include "content/public/browser/plugin_service.h" 163 #include "content/public/browser/plugin_service.h"
(...skipping 3948 matching lines...) Expand 10 before | Expand all | Expand 10 after
4111 4112
4112 void Browser::DidNavigateToPendingEntry(WebContents* tab) { 4113 void Browser::DidNavigateToPendingEntry(WebContents* tab) {
4113 if (tab == GetSelectedWebContents()) 4114 if (tab == GetSelectedWebContents())
4114 UpdateBookmarkBarState(BOOKMARK_BAR_STATE_CHANGE_TAB_STATE); 4115 UpdateBookmarkBarState(BOOKMARK_BAR_STATE_CHANGE_TAB_STATE);
4115 } 4116 }
4116 4117
4117 content::JavaScriptDialogCreator* Browser::GetJavaScriptDialogCreator() { 4118 content::JavaScriptDialogCreator* Browser::GetJavaScriptDialogCreator() {
4118 return GetJavaScriptDialogCreatorInstance(); 4119 return GetJavaScriptDialogCreatorInstance();
4119 } 4120 }
4120 4121
4122 content::ColorChooser* Browser::OpenColorChooser(WebContents* tab,
4123 int color_chooser_id,
4124 const SkColor& color) {
4125 if (color_chooser_.get())
4126 color_chooser_->End();
4127 color_chooser_.reset(content::ColorChooser::Create(color_chooser_id, tab,
4128 color));
4129 return color_chooser_.get();
4130 }
4131
4132 void Browser::DidEndColorChooser() {
4133 color_chooser_.reset();
4134 }
4135
4121 void Browser::RunFileChooser(WebContents* tab, 4136 void Browser::RunFileChooser(WebContents* tab,
4122 const content::FileChooserParams& params) { 4137 const content::FileChooserParams& params) {
4123 RunFileChooserHelper(tab, params); 4138 RunFileChooserHelper(tab, params);
4124 } 4139 }
4125 4140
4126 void Browser::EnumerateDirectory(WebContents* tab, int request_id, 4141 void Browser::EnumerateDirectory(WebContents* tab, int request_id,
4127 const FilePath& path) { 4142 const FilePath& path) {
4128 EnumerateDirectoryHelper(tab, request_id, path); 4143 EnumerateDirectoryHelper(tab, request_id, path);
4129 } 4144 }
4130 4145
(...skipping 1453 matching lines...) Expand 10 before | Expand all | Expand 10 after
5584 ShowSingletonTabOverwritingNTP(params); 5599 ShowSingletonTabOverwritingNTP(params);
5585 } else { 5600 } else {
5586 LoginUIServiceFactory::GetForProfile( 5601 LoginUIServiceFactory::GetForProfile(
5587 profile()->GetOriginalProfile())->ShowLoginUI(); 5602 profile()->GetOriginalProfile())->ShowLoginUI();
5588 } 5603 }
5589 } 5604 }
5590 5605
5591 void Browser::ToggleSpeechInput() { 5606 void Browser::ToggleSpeechInput() {
5592 GetSelectedWebContents()->GetRenderViewHost()->ToggleSpeechInput(); 5607 GetSelectedWebContents()->GetRenderViewHost()->ToggleSpeechInput();
5593 } 5608 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698