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

Side by Side Diff: chrome/browser/ui/libgtk2ui/select_file_dialog_impl.h

Issue 19052005: Move PathIsWritable, DirectoryExists, ContentsEqual, and TextContentsEqual to the base namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 5 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 // 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 // This file implements common select dialog functionality between GTK and KDE. 5 // This file implements common select dialog functionality between GTK and KDE.
6 6
7 #ifndef CHROME_BROWSER_UI_LIBGTK2UI_SELECT_FILE_DIALOG_IMPL_H_ 7 #ifndef CHROME_BROWSER_UI_LIBGTK2UI_SELECT_FILE_DIALOG_IMPL_H_
8 #define CHROME_BROWSER_UI_LIBGTK2UI_SELECT_FILE_DIALOG_IMPL_H_ 8 #define CHROME_BROWSER_UI_LIBGTK2UI_SELECT_FILE_DIALOG_IMPL_H_
9 9
10 #include <set> 10 #include <set>
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 virtual void SelectFileImpl( 52 virtual void SelectFileImpl(
53 Type type, 53 Type type,
54 const string16& title, 54 const string16& title,
55 const base::FilePath& default_path, 55 const base::FilePath& default_path,
56 const FileTypeInfo* file_types, 56 const FileTypeInfo* file_types,
57 int file_type_index, 57 int file_type_index,
58 const base::FilePath::StringType& default_extension, 58 const base::FilePath::StringType& default_extension,
59 gfx::NativeWindow owning_window, 59 gfx::NativeWindow owning_window,
60 void* params) = 0; 60 void* params) = 0;
61 61
62 // Wrapper for file_util::DirectoryExists() that allow access on the UI 62 // Wrapper for base::DirectoryExists() that allow access on the UI
63 // thread. Use this only in the file dialog functions, where it's ok 63 // thread. Use this only in the file dialog functions, where it's ok
64 // because the file dialog has to do many stats anyway. One more won't 64 // because the file dialog has to do many stats anyway. One more won't
65 // hurt too badly and it's likely already cached. 65 // hurt too badly and it's likely already cached.
66 bool CallDirectoryExistsOnUIThread(const base::FilePath& path); 66 bool CallDirectoryExistsOnUIThread(const base::FilePath& path);
67 67
68 // The file filters. 68 // The file filters.
69 FileTypeInfo file_types_; 69 FileTypeInfo file_types_;
70 70
71 // The index of the default selected file filter. 71 // The index of the default selected file filter.
72 // Note: This starts from 1, not 0. 72 // Note: This starts from 1, not 0.
73 size_t file_type_index_; 73 size_t file_type_index_;
74 74
75 // The set of all parent windows for which we are currently running dialogs. 75 // The set of all parent windows for which we are currently running dialogs.
76 std::set<aura::Window*> parents_; 76 std::set<aura::Window*> parents_;
77 77
78 // The type of dialog we are showing the user. 78 // The type of dialog we are showing the user.
79 Type type_; 79 Type type_;
80 80
81 // These two variables track where the user last saved a file or opened a 81 // These two variables track where the user last saved a file or opened a
82 // file so that we can display future dialogs with the same starting path. 82 // file so that we can display future dialogs with the same starting path.
83 static base::FilePath* last_saved_path_; 83 static base::FilePath* last_saved_path_;
84 static base::FilePath* last_opened_path_; 84 static base::FilePath* last_opened_path_;
85 85
86 DISALLOW_COPY_AND_ASSIGN(SelectFileDialogImpl); 86 DISALLOW_COPY_AND_ASSIGN(SelectFileDialogImpl);
87 }; 87 };
88 88
89 } // namespace libgtk2ui 89 } // namespace libgtk2ui
90 90
91 #endif // CHROME_BROWSER_UI_LIBGTK2UI_SELECT_FILE_DIALOG_IMPL_H_ 91 #endif // CHROME_BROWSER_UI_LIBGTK2UI_SELECT_FILE_DIALOG_IMPL_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/glue/sync_backend_host.cc ('k') | chrome/browser/ui/libgtk2ui/select_file_dialog_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698