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

Side by Side Diff: chrome/browser/extensions/app_window_contents.cc

Issue 15855010: Make ExtensionMsg_MessageInvoke run a module system function rather than a (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix test compile Created 7 years, 6 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 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 4
5 #include "chrome/browser/extensions/app_window_contents.h" 5 #include "chrome/browser/extensions/app_window_contents.h"
6 6
7 #include "chrome/browser/profiles/profile.h" 7 #include "chrome/browser/profiles/profile.h"
8 #include "chrome/browser/ui/extensions/native_app_window.h" 8 #include "chrome/browser/ui/extensions/native_app_window.h"
9 #include "chrome/common/chrome_notification_types.h" 9 #include "chrome/common/chrome_notification_types.h"
10 #include "chrome/common/extensions/api/app_window.h" 10 #include "chrome/common/extensions/api/app_window.h"
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 update.height.reset(new int(bounds.height())); 88 update.height.reset(new int(bounds.height()));
89 dictionary->Set("bounds", update.ToValue().release()); 89 dictionary->Set("bounds", update.ToValue().release());
90 dictionary->SetBoolean("fullscreen", 90 dictionary->SetBoolean("fullscreen",
91 native_app_window->IsFullscreenOrPending()); 91 native_app_window->IsFullscreenOrPending());
92 dictionary->SetBoolean("minimized", native_app_window->IsMinimized()); 92 dictionary->SetBoolean("minimized", native_app_window->IsMinimized());
93 dictionary->SetBoolean("maximized", native_app_window->IsMaximized()); 93 dictionary->SetBoolean("maximized", native_app_window->IsMaximized());
94 94
95 content::RenderViewHost* rvh = web_contents_->GetRenderViewHost(); 95 content::RenderViewHost* rvh = web_contents_->GetRenderViewHost();
96 rvh->Send(new ExtensionMsg_MessageInvoke(rvh->GetRoutingID(), 96 rvh->Send(new ExtensionMsg_MessageInvoke(rvh->GetRoutingID(),
97 host_->extension()->id(), 97 host_->extension()->id(),
98 "app.window",
98 "updateAppWindowProperties", 99 "updateAppWindowProperties",
99 args, 100 args,
100 false)); 101 false));
101 } 102 }
102 103
103 void AppWindowContents::NativeWindowClosed() { 104 void AppWindowContents::NativeWindowClosed() {
104 content::RenderViewHost* rvh = web_contents_->GetRenderViewHost(); 105 content::RenderViewHost* rvh = web_contents_->GetRenderViewHost();
105 rvh->Send(new ExtensionMsg_AppWindowClosed(rvh->GetRoutingID())); 106 rvh->Send(new ExtensionMsg_AppWindowClosed(rvh->GetRoutingID()));
106 } 107 }
107 108
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 164
164 void AppWindowContents::SuspendRenderViewHost( 165 void AppWindowContents::SuspendRenderViewHost(
165 content::RenderViewHost* rvh) { 166 content::RenderViewHost* rvh) {
166 DCHECK(rvh); 167 DCHECK(rvh);
167 content::BrowserThread::PostTask( 168 content::BrowserThread::PostTask(
168 content::BrowserThread::IO, FROM_HERE, 169 content::BrowserThread::IO, FROM_HERE,
169 base::Bind(&content::ResourceDispatcherHost::BlockRequestsForRoute, 170 base::Bind(&content::ResourceDispatcherHost::BlockRequestsForRoute,
170 base::Unretained(content::ResourceDispatcherHost::Get()), 171 base::Unretained(content::ResourceDispatcherHost::Get()),
171 rvh->GetProcess()->GetID(), rvh->GetRoutingID())); 172 rvh->GetProcess()->GetID(), rvh->GetRoutingID()));
172 } 173 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/api/web_request/web_request_api_unittest.cc ('k') | chrome/browser/extensions/event_router.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698