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

Side by Side Diff: ui/shell_dialogs/select_file_dialog.cc

Issue 232773008: More removal of GTK code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove base/ so I don't need another stamp. Created 6 years, 8 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 | « ui/gl/gl_surface_glx.cc ('k') | ui/surface/transport_dib.h » ('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 (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 "ui/shell_dialogs/select_file_dialog.h" 5 #include "ui/shell_dialogs/select_file_dialog.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
11 #include "ui/base/l10n/l10n_util.h" 11 #include "ui/base/l10n/l10n_util.h"
12 #include "ui/shell_dialogs/select_file_dialog_factory.h" 12 #include "ui/shell_dialogs/select_file_dialog_factory.h"
13 #include "ui/shell_dialogs/select_file_policy.h" 13 #include "ui/shell_dialogs/select_file_policy.h"
14 #include "ui/shell_dialogs/selected_file_info.h" 14 #include "ui/shell_dialogs/selected_file_info.h"
15 #include "ui/shell_dialogs/shell_dialogs_delegate.h" 15 #include "ui/shell_dialogs/shell_dialogs_delegate.h"
16 16
17 #if defined(OS_WIN) 17 #if defined(OS_WIN)
18 #include "ui/shell_dialogs/select_file_dialog_win.h" 18 #include "ui/shell_dialogs/select_file_dialog_win.h"
19 #elif defined(OS_MACOSX) 19 #elif defined(OS_MACOSX)
20 #include "ui/shell_dialogs/select_file_dialog_mac.h" 20 #include "ui/shell_dialogs/select_file_dialog_mac.h"
21 #elif defined(TOOLKIT_GTK)
22 #include "ui/shell_dialogs/gtk/select_file_dialog_impl.h"
23 #elif defined(OS_ANDROID) 21 #elif defined(OS_ANDROID)
24 #include "ui/shell_dialogs/select_file_dialog_android.h" 22 #include "ui/shell_dialogs/select_file_dialog_android.h"
25 #elif defined(USE_AURA) && !defined(USE_ASH) && defined(OS_LINUX) 23 #elif defined(USE_AURA) && !defined(USE_ASH) && defined(OS_LINUX)
26 #include "ui/shell_dialogs/linux_shell_dialog.h" 24 #include "ui/shell_dialogs/linux_shell_dialog.h"
27 #endif 25 #endif
28 26
29 namespace { 27 namespace {
30 28
31 // Optional dialog factory. Leaked. 29 // Optional dialog factory. Leaked.
32 ui::SelectFileDialogFactory* dialog_factory_ = NULL; 30 ui::SelectFileDialogFactory* dialog_factory_ = NULL;
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 if (shell_dialogs) 81 if (shell_dialogs)
84 return shell_dialogs->CreateSelectFileDialog(listener, policy); 82 return shell_dialogs->CreateSelectFileDialog(listener, policy);
85 #endif 83 #endif
86 84
87 #if defined(OS_WIN) 85 #if defined(OS_WIN)
88 // TODO(ananta) 86 // TODO(ananta)
89 // Fix this for Chrome ASH on Windows. 87 // Fix this for Chrome ASH on Windows.
90 return CreateWinSelectFileDialog(listener, policy); 88 return CreateWinSelectFileDialog(listener, policy);
91 #elif defined(OS_MACOSX) && !defined(USE_AURA) 89 #elif defined(OS_MACOSX) && !defined(USE_AURA)
92 return CreateMacSelectFileDialog(listener, policy); 90 return CreateMacSelectFileDialog(listener, policy);
93 #elif defined(TOOLKIT_GTK)
94 return CreateLinuxSelectFileDialog(listener, policy);
95 #elif defined(OS_ANDROID) 91 #elif defined(OS_ANDROID)
96 return CreateAndroidSelectFileDialog(listener, policy); 92 return CreateAndroidSelectFileDialog(listener, policy);
97 #else 93 #else
98 NOTIMPLEMENTED(); 94 NOTIMPLEMENTED();
99 return NULL; 95 return NULL;
100 #endif 96 #endif
101 } 97 }
102 98
103 void SelectFileDialog::SelectFile( 99 void SelectFileDialog::SelectFile(
104 Type type, 100 Type type,
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 void SelectFileDialog::CancelFileSelection(void* params) { 146 void SelectFileDialog::CancelFileSelection(void* params) {
151 if (listener_) 147 if (listener_)
152 listener_->FileSelectionCanceled(params); 148 listener_->FileSelectionCanceled(params);
153 } 149 }
154 150
155 ShellDialogsDelegate* SelectFileDialog::GetShellDialogsDelegate() { 151 ShellDialogsDelegate* SelectFileDialog::GetShellDialogsDelegate() {
156 return g_shell_dialogs_delegate_; 152 return g_shell_dialogs_delegate_;
157 } 153 }
158 154
159 } // namespace ui 155 } // namespace ui
OLDNEW
« no previous file with comments | « ui/gl/gl_surface_glx.cc ('k') | ui/surface/transport_dib.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698