mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
cefclient: Split ClientApp into process-specific types (issue #1500).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2015 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
43
tests/cefclient/browser/client_app_browser.cc
Normal file
43
tests/cefclient/browser/client_app_browser.cc
Normal file
@@ -0,0 +1,43 @@
|
||||
// Copyright (c) 2013 The Chromium Embedded Framework Authors. All rights
|
||||
// reserved. Use of this source code is governed by a BSD-style license that
|
||||
// can be found in the LICENSE file.
|
||||
|
||||
#include "cefclient/browser/client_app_browser.h"
|
||||
|
||||
#include "include/cef_cookie.h"
|
||||
|
||||
namespace client {
|
||||
|
||||
ClientAppBrowser::ClientAppBrowser() {
|
||||
}
|
||||
|
||||
void ClientAppBrowser::OnContextInitialized() {
|
||||
CreateDelegates(delegates_);
|
||||
|
||||
// Register cookieable schemes with the global cookie manager.
|
||||
CefRefPtr<CefCookieManager> manager = CefCookieManager::GetGlobalManager();
|
||||
DCHECK(manager.get());
|
||||
manager->SetSupportedSchemes(cookieable_schemes_);
|
||||
|
||||
print_handler_ = CreatePrintHandler();
|
||||
|
||||
DelegateSet::iterator it = delegates_.begin();
|
||||
for (; it != delegates_.end(); ++it)
|
||||
(*it)->OnContextInitialized(this);
|
||||
}
|
||||
|
||||
void ClientAppBrowser::OnBeforeChildProcessLaunch(
|
||||
CefRefPtr<CefCommandLine> command_line) {
|
||||
DelegateSet::iterator it = delegates_.begin();
|
||||
for (; it != delegates_.end(); ++it)
|
||||
(*it)->OnBeforeChildProcessLaunch(this, command_line);
|
||||
}
|
||||
|
||||
void ClientAppBrowser::OnRenderProcessThreadCreated(
|
||||
CefRefPtr<CefListValue> extra_info) {
|
||||
DelegateSet::iterator it = delegates_.begin();
|
||||
for (; it != delegates_.end(); ++it)
|
||||
(*it)->OnRenderProcessThreadCreated(this, extra_info);
|
||||
}
|
||||
|
||||
} // namespace client
|
Reference in New Issue
Block a user