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

Side by Side Diff: content/shell/browser/shell.h

Issue 2417983002: Form submissions opening in a new window don't need special treatment anymore. (Closed)
Patch Set: Using params.source_site_instance for consistency with //chrome layer. Created 4 years, 2 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
« no previous file with comments | « no previous file | content/shell/browser/shell.cc » ('j') | content/shell/browser/shell.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef CONTENT_SHELL_BROWSER_SHELL_H_ 4 #ifndef CONTENT_SHELL_BROWSER_SHELL_H_
5 #define CONTENT_SHELL_BROWSER_SHELL_H_ 5 #define CONTENT_SHELL_BROWSER_SHELL_H_
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <memory> 9 #include <memory>
10 #include <vector> 10 #include <vector>
11 11
12 #include "base/callback_forward.h" 12 #include "base/callback_forward.h"
13 #include "base/memory/ref_counted.h"
13 #include "base/strings/string_piece.h" 14 #include "base/strings/string_piece.h"
14 #include "build/build_config.h" 15 #include "build/build_config.h"
15 #include "content/public/browser/web_contents_delegate.h" 16 #include "content/public/browser/web_contents_delegate.h"
16 #include "content/public/browser/web_contents_observer.h" 17 #include "content/public/browser/web_contents_observer.h"
17 #include "ipc/ipc_channel.h" 18 #include "ipc/ipc_channel.h"
18 #include "ui/gfx/geometry/size.h" 19 #include "ui/gfx/geometry/size.h"
19 #include "ui/gfx/native_widget_types.h" 20 #include "ui/gfx/native_widget_types.h"
20 21
21 #if defined(OS_ANDROID) 22 #if defined(OS_ANDROID)
22 #include "base/android/scoped_java_ref.h" 23 #include "base/android/scoped_java_ref.h"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 void ShowDevTools(); 79 void ShowDevTools();
79 void CloseDevTools(); 80 void CloseDevTools();
80 #if defined(OS_MACOSX) 81 #if defined(OS_MACOSX)
81 // Resizes the web content view to the given dimensions. 82 // Resizes the web content view to the given dimensions.
82 void SizeTo(const gfx::Size& content_size); 83 void SizeTo(const gfx::Size& content_size);
83 #endif 84 #endif
84 85
85 // Do one time initialization at application startup. 86 // Do one time initialization at application startup.
86 static void Initialize(); 87 static void Initialize();
87 88
88 static Shell* CreateNewWindow(BrowserContext* browser_context, 89 static Shell* CreateNewWindow(
89 const GURL& url, 90 BrowserContext* browser_context,
90 SiteInstance* site_instance, 91 const GURL& url,
91 const gfx::Size& initial_size); 92 const scoped_refptr<SiteInstance>& site_instance,
Łukasz Anforowicz 2016/10/20 22:56:42 scoped_refptr is better than a raw pointer, right?
93 const gfx::Size& initial_size);
92 94
93 // Returns the Shell object corresponding to the given RenderViewHost. 95 // Returns the Shell object corresponding to the given RenderViewHost.
94 static Shell* FromRenderViewHost(RenderViewHost* rvh); 96 static Shell* FromRenderViewHost(RenderViewHost* rvh);
95 97
96 // Returns the currently open windows. 98 // Returns the currently open windows.
97 static std::vector<Shell*>& windows() { return windows_; } 99 static std::vector<Shell*>& windows() { return windows_; }
98 100
99 // Closes all windows and returns. This runs a message loop. 101 // Closes all windows and returns. This runs a message loop.
100 static void CloseAllWindows(); 102 static void CloseAllWindows();
101 103
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
267 static base::Callback<void(Shell*)> shell_created_callback_; 269 static base::Callback<void(Shell*)> shell_created_callback_;
268 270
269 // True if the destructur of Shell should post a quit closure on the current 271 // True if the destructur of Shell should post a quit closure on the current
270 // message loop if the destructed Shell object was the last one. 272 // message loop if the destructed Shell object was the last one.
271 static bool quit_message_loop_; 273 static bool quit_message_loop_;
272 }; 274 };
273 275
274 } // namespace content 276 } // namespace content
275 277
276 #endif // CONTENT_SHELL_BROWSER_SHELL_H_ 278 #endif // CONTENT_SHELL_BROWSER_SHELL_H_
OLDNEW
« no previous file with comments | « no previous file | content/shell/browser/shell.cc » ('j') | content/shell/browser/shell.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698