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

Side by Side Diff: extensions/renderer/messaging_bindings.cc

Issue 664933004: Standardize usage of virtual/override/final in extensions/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 | « extensions/renderer/logging_native_handler.h ('k') | extensions/renderer/module_system.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "extensions/renderer/messaging_bindings.h" 5 #include "extensions/renderer/messaging_bindings.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 "PortRelease", 94 "PortRelease",
95 base::Bind(&ExtensionImpl::PortRelease, base::Unretained(this))); 95 base::Bind(&ExtensionImpl::PortRelease, base::Unretained(this)));
96 RouteFunction( 96 RouteFunction(
97 "PostMessage", 97 "PostMessage",
98 base::Bind(&ExtensionImpl::PostMessage, base::Unretained(this))); 98 base::Bind(&ExtensionImpl::PostMessage, base::Unretained(this)));
99 // TODO(fsamuel, kalman): Move BindToGC out of messaging natives. 99 // TODO(fsamuel, kalman): Move BindToGC out of messaging natives.
100 RouteFunction("BindToGC", 100 RouteFunction("BindToGC",
101 base::Bind(&ExtensionImpl::BindToGC, base::Unretained(this))); 101 base::Bind(&ExtensionImpl::BindToGC, base::Unretained(this)));
102 } 102 }
103 103
104 virtual ~ExtensionImpl() {} 104 ~ExtensionImpl() override {}
105 105
106 private: 106 private:
107 void ClearPortDataAndNotifyDispatcher(int port_id) { 107 void ClearPortDataAndNotifyDispatcher(int port_id) {
108 ClearPortData(port_id); 108 ClearPortData(port_id);
109 dispatcher_->ClearPortData(port_id); 109 dispatcher_->ClearPortData(port_id);
110 } 110 }
111 111
112 // Sends a message along the given channel. 112 // Sends a message along the given channel.
113 void PostMessage(const v8::FunctionCallbackInfo<v8::Value>& args) { 113 void PostMessage(const v8::FunctionCallbackInfo<v8::Value>& args) {
114 content::RenderView* renderview = context()->GetRenderView(); 114 content::RenderView* renderview = context()->GetRenderView();
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after
425 const ScriptContextSet& context_set, 425 const ScriptContextSet& context_set,
426 int port_id, 426 int port_id,
427 const std::string& error_message, 427 const std::string& error_message,
428 content::RenderView* restrict_to_render_view) { 428 content::RenderView* restrict_to_render_view) {
429 context_set.ForEach( 429 context_set.ForEach(
430 restrict_to_render_view, 430 restrict_to_render_view,
431 base::Bind(&DispatchOnDisconnectToScriptContext, port_id, error_message)); 431 base::Bind(&DispatchOnDisconnectToScriptContext, port_id, error_message));
432 } 432 }
433 433
434 } // namespace extensions 434 } // namespace extensions
OLDNEW
« no previous file with comments | « extensions/renderer/logging_native_handler.h ('k') | extensions/renderer/module_system.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698