OLD | NEW |
---|---|
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 #ifndef CONTENT_SHELL_SHELL_H_ | 5 #ifndef CONTENT_SHELL_SHELL_H_ |
6 #define CONTENT_SHELL_SHELL_H_ | 6 #define CONTENT_SHELL_SHELL_H_ |
7 | 7 |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 14 matching lines...) Expand all Loading... | |
25 | 25 |
26 typedef struct _GtkToolItem GtkToolItem; | 26 typedef struct _GtkToolItem GtkToolItem; |
27 #elif defined(OS_ANDROID) | 27 #elif defined(OS_ANDROID) |
28 #include "base/android/scoped_java_ref.h" | 28 #include "base/android/scoped_java_ref.h" |
29 #elif defined(USE_AURA) | 29 #elif defined(USE_AURA) |
30 namespace views { | 30 namespace views { |
31 class Widget; | 31 class Widget; |
32 class ViewsDelegate; | 32 class ViewsDelegate; |
33 } | 33 } |
34 namespace aura { | 34 namespace aura { |
35 class RootWindow; | |
35 namespace client { | 36 namespace client { |
36 class StackingClient; | 37 class StackingClient; |
37 } | 38 } |
38 } | 39 } |
39 #endif | 40 #endif |
40 | 41 |
41 class GURL; | 42 class GURL; |
42 namespace content { | 43 namespace content { |
43 | 44 |
45 // Content area size for newly created windows. | |
46 static const int kTestWindowWidth = 800; | |
47 static const int kTestWindowHeight = 600; | |
oshima
2013/01/17 08:57:56
no static in header. just const int is enough.
jochen (gone - plz use gerrit)
2013/01/17 20:02:09
Can you instead add a gfx::Size default_window_siz
Nayan
2013/01/18 18:59:56
Done.
| |
48 | |
44 class BrowserContext; | 49 class BrowserContext; |
45 class ShellJavaScriptDialogCreator; | 50 class ShellJavaScriptDialogCreator; |
46 class SiteInstance; | 51 class SiteInstance; |
47 class WebContents; | 52 class WebContents; |
48 | 53 |
49 // This represents one window of the Content Shell, i.e. all the UI including | 54 // This represents one window of the Content Shell, i.e. all the UI including |
50 // buttons and url bar, as well as the web content area. | 55 // buttons and url bar, as well as the web content area. |
51 class Shell : public WebContentsDelegate, | 56 class Shell : public WebContentsDelegate, |
52 public NotificationObserver { | 57 public NotificationObserver { |
53 public: | 58 public: |
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
196 CHROMEGTK_CALLBACK_0(Shell, void, OnURLEntryActivate); | 201 CHROMEGTK_CALLBACK_0(Shell, void, OnURLEntryActivate); |
197 CHROMEGTK_CALLBACK_0(Shell, gboolean, OnWindowDestroyed); | 202 CHROMEGTK_CALLBACK_0(Shell, gboolean, OnWindowDestroyed); |
198 | 203 |
199 CHROMEG_CALLBACK_3(Shell, gboolean, OnCloseWindowKeyPressed, GtkAccelGroup*, | 204 CHROMEG_CALLBACK_3(Shell, gboolean, OnCloseWindowKeyPressed, GtkAccelGroup*, |
200 GObject*, guint, GdkModifierType); | 205 GObject*, guint, GdkModifierType); |
201 CHROMEG_CALLBACK_3(Shell, gboolean, OnNewWindowKeyPressed, GtkAccelGroup*, | 206 CHROMEG_CALLBACK_3(Shell, gboolean, OnNewWindowKeyPressed, GtkAccelGroup*, |
202 GObject*, guint, GdkModifierType); | 207 GObject*, guint, GdkModifierType); |
203 CHROMEG_CALLBACK_3(Shell, gboolean, OnHighlightURLView, GtkAccelGroup*, | 208 CHROMEG_CALLBACK_3(Shell, gboolean, OnHighlightURLView, GtkAccelGroup*, |
204 GObject*, guint, GdkModifierType); | 209 GObject*, guint, GdkModifierType); |
205 #endif | 210 #endif |
211 #if defined(USE_AURA) | |
212 static scoped_ptr<aura::RootWindow> CreateRootWindow(int width, | |
213 int height); | |
214 #endif | |
206 | 215 |
207 scoped_ptr<ShellJavaScriptDialogCreator> dialog_creator_; | 216 scoped_ptr<ShellJavaScriptDialogCreator> dialog_creator_; |
208 | 217 |
209 scoped_ptr<WebContents> web_contents_; | 218 scoped_ptr<WebContents> web_contents_; |
210 | 219 |
211 Shell* dev_tools_; | 220 Shell* dev_tools_; |
212 | 221 |
213 bool is_fullscreen_; | 222 bool is_fullscreen_; |
214 | 223 |
215 gfx::NativeWindow window_; | 224 gfx::NativeWindow window_; |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
252 static base::Callback<void(Shell*)> shell_created_callback_; | 261 static base::Callback<void(Shell*)> shell_created_callback_; |
253 | 262 |
254 // True if the destructur of Shell should post a quit closure on the current | 263 // True if the destructur of Shell should post a quit closure on the current |
255 // message loop if the destructed Shell object was the last one. | 264 // message loop if the destructed Shell object was the last one. |
256 static bool quit_message_loop_; | 265 static bool quit_message_loop_; |
257 }; | 266 }; |
258 | 267 |
259 } // namespace content | 268 } // namespace content |
260 | 269 |
261 #endif // CONTENT_SHELL_SHELL_H_ | 270 #endif // CONTENT_SHELL_SHELL_H_ |
OLD | NEW |