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

Side by Side Diff: ppapi/proxy/host_dispatcher.cc

Issue 7053022: Use the WebKit default fonts when specifying generic font families. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 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) 2011 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 "ppapi/proxy/host_dispatcher.h" 5 #include "ppapi/proxy/host_dispatcher.h"
6 6
7 #include <map> 7 #include <map>
8 8
9 #include "base/debug/trace_event.h" 9 #include "base/debug/trace_event.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 ppb_proxy_->SetReserveInstanceIDCallback(pp_module_, &ReserveInstanceID); 85 ppb_proxy_->SetReserveInstanceIDCallback(pp_module_, &ReserveInstanceID);
86 } 86 }
87 87
88 HostDispatcher::~HostDispatcher() { 88 HostDispatcher::~HostDispatcher() {
89 g_module_to_dispatcher->erase(pp_module_); 89 g_module_to_dispatcher->erase(pp_module_);
90 } 90 }
91 91
92 bool HostDispatcher::InitHostWithChannel( 92 bool HostDispatcher::InitHostWithChannel(
93 Delegate* delegate, 93 Delegate* delegate,
94 const IPC::ChannelHandle& channel_handle, 94 const IPC::ChannelHandle& channel_handle,
95 bool is_client) { 95 bool is_client,
96 const ppapi::Preferences& preferences) {
96 if (!Dispatcher::InitWithChannel(delegate, channel_handle, is_client)) 97 if (!Dispatcher::InitWithChannel(delegate, channel_handle, is_client))
97 return false; 98 return false;
99 Send(new PpapiMsg_SetPreferences(preferences));
98 return true; 100 return true;
99 } 101 }
100 102
101 // static 103 // static
102 HostDispatcher* HostDispatcher::GetForInstance(PP_Instance instance) { 104 HostDispatcher* HostDispatcher::GetForInstance(PP_Instance instance) {
103 if (!g_instance_to_dispatcher) 105 if (!g_instance_to_dispatcher)
104 return NULL; 106 return NULL;
105 InstanceToDispatcherMap::iterator found = g_instance_to_dispatcher->find( 107 InstanceToDispatcherMap::iterator found = g_instance_to_dispatcher->find(
106 instance); 108 instance);
107 if (found == g_instance_to_dispatcher->end()) 109 if (found == g_instance_to_dispatcher->end())
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
268 dispatcher_->ppb_proxy()->AddRefModule(dispatcher_->pp_module()); 270 dispatcher_->ppb_proxy()->AddRefModule(dispatcher_->pp_module());
269 } 271 }
270 272
271 ScopedModuleReference::~ScopedModuleReference() { 273 ScopedModuleReference::~ScopedModuleReference() {
272 dispatcher_->ppb_proxy()->ReleaseModule(dispatcher_->pp_module()); 274 dispatcher_->ppb_proxy()->ReleaseModule(dispatcher_->pp_module());
273 } 275 }
274 276
275 } // namespace proxy 277 } // namespace proxy
276 } // namespace pp 278 } // namespace pp
277 279
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698