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

Side by Side Diff: chrome/browser/ui/extensions/shell_window.cc

Issue 10896032: HTML titlebars for v2 apps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: move function call logic into ModuleSystem Created 8 years, 3 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 #include "chrome/browser/ui/extensions/shell_window.h" 5 #include "chrome/browser/ui/extensions/shell_window.h"
6 6
7 #include "base/utf_string_conversions.h" 7 #include "base/utf_string_conversions.h"
8 #include "chrome/browser/extensions/extension_process_manager.h" 8 #include "chrome/browser/extensions/extension_process_manager.h"
9 #include "chrome/browser/extensions/shell_window_registry.h" 9 #include "chrome/browser/extensions/shell_window_registry.h"
10 #include "chrome/browser/file_select_helper.h" 10 #include "chrome/browser/file_select_helper.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 DCHECK(rvh); 55 DCHECK(rvh);
56 BrowserThread::PostTask(BrowserThread::IO, FROM_HERE, 56 BrowserThread::PostTask(BrowserThread::IO, FROM_HERE,
57 base::Bind(&ResourceDispatcherHost::BlockRequestsForRoute, 57 base::Bind(&ResourceDispatcherHost::BlockRequestsForRoute,
58 base::Unretained(ResourceDispatcherHost::Get()), 58 base::Unretained(ResourceDispatcherHost::Get()),
59 rvh->GetProcess()->GetID(), rvh->GetRoutingID())); 59 rvh->GetProcess()->GetID(), rvh->GetRoutingID()));
60 } 60 }
61 61
62 } // namespace 62 } // namespace
63 63
64 ShellWindow::CreateParams::CreateParams() 64 ShellWindow::CreateParams::CreateParams()
65 : frame(ShellWindow::CreateParams::FRAME_CHROME), 65 : frame(ShellWindow::CreateParams::FRAME_NONE),
66 bounds(10, 10, kDefaultWidth, kDefaultHeight) { 66 bounds(10, 10, kDefaultWidth, kDefaultHeight) {
67 } 67 }
68 68
69 ShellWindow* ShellWindow::Create(Profile* profile, 69 ShellWindow* ShellWindow::Create(Profile* profile,
70 const extensions::Extension* extension, 70 const extensions::Extension* extension,
71 const GURL& url, 71 const GURL& url,
72 const ShellWindow::CreateParams& params) { 72 const ShellWindow::CreateParams& params) {
73 // This object will delete itself when the window is closed. 73 // This object will delete itself when the window is closed.
74 ShellWindow* window = new ShellWindow(profile, extension); 74 ShellWindow* window = new ShellWindow(profile, extension);
75 window->Init(url, params); 75 window->Init(url, params);
(...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 extension_function_dispatcher_.Dispatch(params, 369 extension_function_dispatcher_.Dispatch(params,
370 web_contents_->GetRenderViewHost()); 370 web_contents_->GetRenderViewHost());
371 } 371 }
372 372
373 void ShellWindow::AddMessageToDevToolsConsole(ConsoleMessageLevel level, 373 void ShellWindow::AddMessageToDevToolsConsole(ConsoleMessageLevel level,
374 const std::string& message) { 374 const std::string& message) {
375 content::RenderViewHost* rvh = web_contents_->GetRenderViewHost(); 375 content::RenderViewHost* rvh = web_contents_->GetRenderViewHost();
376 rvh->Send(new ExtensionMsg_AddMessageToConsole( 376 rvh->Send(new ExtensionMsg_AddMessageToConsole(
377 rvh->GetRoutingID(), level, message)); 377 rvh->GetRoutingID(), level, message));
378 } 378 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698