blob: 6792231e4133126b084f7e80fc6c6f6889286f4d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
// Copyright (c) 2010 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.
#ifndef CHROME_BROWSER_CHROMEOS_NATIVE_DIALOG_WINDOW_H_
#define CHROME_BROWSER_CHROMEOS_NATIVE_DIALOG_WINDOW_H_
#include "gfx/native_widget_types.h"
namespace gfx {
class Rect;
class Size;
} // namespace gfx
namespace chromeos {
// Flags for ShowNativeDialog.
enum NativeDialogFlags {
DIALOG_FLAG_DEFAULT = 0x00, // Default non-resizeable, non-modal dialog.
DIALOG_FLAG_RESIZEABLE = 0x01, // For resizeable dialog.
DIALOG_FLAG_MODAL = 0x02, // For modal dialog.
};
// Shows a |native_dialog| hosted in a views::Window. |flags| are combinations
// of the NativeDialogFlags. |size| is a default size. Zero width/height of
// |size| means let gtk choose a proper size for that dimension. |min_size| is
// the minimum size of the final host Window.
void ShowNativeDialog(gfx::NativeWindow parent,
gfx::NativeView native_dialog,
int flags,
const gfx::Size& size,
const gfx::Size& min_size);
// Gets the container window of the given |native_dialog|.
gfx::NativeWindow GetNativeDialogWindow(gfx::NativeView native_dialog);
// Gets the bounds of the contained dialog content.
gfx::Rect GetNativeDialogContentsBounds(gfx::NativeView native_dialog);
} // namespace chromeos
#endif // CHROME_BROWSER_CHROMEOS_NATIVE_DIALOG_WINDOW_H_
|