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

Side by Side Diff: webkit/glue/plugins/plugin_lib.cc

Issue 4291001: Convert implicit scoped_refptr constructor calls to explicit ones, part 2 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/build
Patch Set: comments Created 10 years, 1 month 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
« no previous file with comments | « webkit/glue/plugins/plugin_instance.cc ('k') | webkit/glue/webmediaplayer_impl.cc » ('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 (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "webkit/glue/plugins/plugin_lib.h" 5 #include "webkit/glue/plugins/plugin_lib.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/message_loop.h" 8 #include "base/message_loop.h"
9 #include "base/metrics/stats_counters.h" 9 #include "base/metrics/stats_counters.h"
10 #include "base/string_util.h" 10 #include "base/string_util.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 PluginLib::PluginLib(const WebPluginInfo& info, 67 PluginLib::PluginLib(const WebPluginInfo& info,
68 const PluginEntryPoints* entry_points) 68 const PluginEntryPoints* entry_points)
69 : web_plugin_info_(info), 69 : web_plugin_info_(info),
70 library_(NULL), 70 library_(NULL),
71 initialized_(false), 71 initialized_(false),
72 saved_data_(0), 72 saved_data_(0),
73 instance_count_(0), 73 instance_count_(0),
74 skip_unload_(false) { 74 skip_unload_(false) {
75 base::StatsCounter(kPluginLibrariesLoadedCounter).Increment(); 75 base::StatsCounter(kPluginLibrariesLoadedCounter).Increment();
76 memset(static_cast<void*>(&plugin_funcs_), 0, sizeof(plugin_funcs_)); 76 memset(static_cast<void*>(&plugin_funcs_), 0, sizeof(plugin_funcs_));
77 g_loaded_libs->push_back(this); 77 g_loaded_libs->push_back(make_scoped_refptr(this));
78 78
79 if (entry_points) { 79 if (entry_points) {
80 internal_ = true; 80 internal_ = true;
81 entry_points_ = *entry_points; 81 entry_points_ = *entry_points;
82 } else { 82 } else {
83 internal_ = false; 83 internal_ = false;
84 // We will read the entry points from the plugin directly. 84 // We will read the entry points from the plugin directly.
85 memset(&entry_points_, 0, sizeof(entry_points_)); 85 memset(&entry_points_, 0, sizeof(entry_points_));
86 } 86 }
87 } 87 }
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 } 308 }
309 309
310 void PluginLib::Shutdown() { 310 void PluginLib::Shutdown() {
311 if (initialized_ && !internal_) { 311 if (initialized_ && !internal_) {
312 NP_Shutdown(); 312 NP_Shutdown();
313 initialized_ = false; 313 initialized_ = false;
314 } 314 }
315 } 315 }
316 316
317 } // namespace NPAPI 317 } // namespace NPAPI
OLDNEW
« no previous file with comments | « webkit/glue/plugins/plugin_instance.cc ('k') | webkit/glue/webmediaplayer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698