| Index: chrome/browser/shell_dialogs.h
|
| diff --git a/chrome/browser/shell_dialogs.h b/chrome/browser/shell_dialogs.h
|
| index f9a3baae413c656ac0544b500d132a93561422cf..b89c1b0d65bb852ad2f4e145baaa0164b9026cc3 100644
|
| --- a/chrome/browser/shell_dialogs.h
|
| +++ b/chrome/browser/shell_dialogs.h
|
| @@ -1,4 +1,4 @@
|
| -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
|
| +// Copyright (c) 2006-2009 The Chromium Authors. All rights reserved.
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| @@ -13,6 +13,8 @@
|
| #include "base/ref_counted.h"
|
| #include "base/string16.h"
|
|
|
| +class TabContents;
|
| +
|
| namespace gfx {
|
| class Font;
|
| }
|
| @@ -21,8 +23,12 @@ class Font;
|
| class BaseShellDialog {
|
| public:
|
| // Returns true if a shell dialog box is currently being shown modally
|
| - // to the specified owner.
|
| + // to the specified owner. (For tab-modals, one should provide a default
|
| + // implementations which just produces a window-modal; hence our default
|
| + // implementation just returns false.)
|
| virtual bool IsRunning(gfx::NativeWindow owning_window) const = 0;
|
| + virtual bool IsRunningInTab(const TabContents* parent_tab) const
|
| + { return false; }
|
|
|
| // Notifies the dialog box that the listener has been destroyed and it should
|
| // no longer be sent notifications.
|
| @@ -117,6 +123,19 @@ class SelectFileDialog
|
| const FilePath::StringType& default_extension,
|
| gfx::NativeWindow owning_window,
|
| void* params) = 0;
|
| +
|
| + // Same as SelectFile(), with nearly identical arguments, except that -- on
|
| + // platforms where this is supported -- it will display a tab-modal dialog box
|
| + // for the tab specified by |owning_tab| (if it is NULL, this will yield a
|
| + // modeless dialog). More than one instance can be shown per window.
|
| + virtual void SelectFileInTab(Type type,
|
| + const string16& title,
|
| + const FilePath& default_path,
|
| + const FileTypeInfo* file_types,
|
| + int file_type_index,
|
| + const FilePath::StringType& default_extension,
|
| + TabContents* owning_tab,
|
| + void* params) = 0;
|
| };
|
|
|
| // Shows a dialog box for selecting a font.
|
|
|