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

Side by Side Diff: chrome/renderer/external_host_bindings.cc

Issue 10382059: Quote CppBoundClass/CppVariant in namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix a long line Created 8 years, 7 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) 2011 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/renderer/external_host_bindings.h" 5 #include "chrome/renderer/external_host_bindings.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/values.h" 9 #include "base/values.h"
10 #include "chrome/common/render_messages.h" 10 #include "chrome/common/render_messages.h"
11 #include "third_party/WebKit/Source/WebKit/chromium/public/WebBindings.h" 11 #include "third_party/WebKit/Source/WebKit/chromium/public/WebBindings.h"
12 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h" 12 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h"
13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" 13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h"
14 14
15 using WebKit::WebBindings; 15 using WebKit::WebBindings;
16 using webkit_glue::CppArgumentList;
17 using webkit_glue::CppVariant;
16 18
17 ExternalHostBindings::ExternalHostBindings(IPC::Message::Sender* sender, 19 ExternalHostBindings::ExternalHostBindings(IPC::Message::Sender* sender,
18 int routing_id) 20 int routing_id)
19 : frame_(NULL), sender_(sender), routing_id_(routing_id) { 21 : frame_(NULL), sender_(sender), routing_id_(routing_id) {
20 BindCallback("postMessage", base::Bind(&ExternalHostBindings::PostMessage, 22 BindCallback("postMessage", base::Bind(&ExternalHostBindings::PostMessage,
21 base::Unretained(this))); 23 base::Unretained(this)));
22 BindProperty("onmessage", &on_message_handler_); 24 BindProperty("onmessage", &on_message_handler_);
23 } 25 }
24 26
25 ExternalHostBindings::~ExternalHostBindings() { 27 ExternalHostBindings::~ExternalHostBindings() {
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 DCHECK(success == false); 185 DCHECK(success == false);
184 } else { 186 } else {
185 DCHECK(success != false); 187 DCHECK(success != false);
186 // Pass the ownership to the caller (don't call ReleaseVariantValue). 188 // Pass the ownership to the caller (don't call ReleaseVariantValue).
187 *message_event = result.value.objectValue; 189 *message_event = result.value.objectValue;
188 } 190 }
189 } 191 }
190 192
191 return success; 193 return success;
192 } 194 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698