Update to Chromium revision 181864.

- Adds support for chrome://view-http-cache/*, chrome://appcache-internals/, chrome://blob-internals/, chrome://tcmalloc/ and chrome://histograms/

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1106 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt 2013-02-23 00:43:28 +00:00
parent fd97bbf292
commit 6f922731b4
64 changed files with 574 additions and 387 deletions

View File

@ -17,5 +17,5 @@
{
'chromium_url': 'http://src.chromium.org/svn/trunk/src',
'chromium_revision': '176706',
'chromium_revision': '181864',
}

49
cef.gyp
View File

@ -7,6 +7,7 @@
'pkg-config': 'pkg-config',
'chromium_code': 1,
'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/cef',
'about_credits_file': '<(SHARED_INTERMEDIATE_DIR)/about_credits.html',
'revision': '<!(python tools/revision.py)',
# Need to be creative to match dylib version formatting requirements.
'version_mac_dylib':
@ -632,15 +633,47 @@
}],
],
},
{
'target_name': 'about_credits',
'type': 'none',
'actions': [
{
'variables': {
'generator_path': '../tools/licenses.py',
},
'action_name': 'generate_about_credits',
'inputs': [
# TODO(phajdan.jr): make licenses.py print inputs too.
'<(generator_path)',
],
'outputs': [
'<(about_credits_file)',
],
'hard_dependency': 1,
'action': ['python',
'<(generator_path)',
'credits',
'<(about_credits_file)',
],
'message': 'Generating about:credits.',
},
],
},
{
# Create the pack file for CEF resources.
'target_name': 'cef_resources',
'type': 'none',
'dependencies': [
'about_credits',
],
'actions': [
{
'action_name': 'cef_resources',
'variables': {
'grit_grd_file': 'libcef/resources/cef_resources.grd',
'grit_additional_defines': [
'-E', 'about_credits_file=<(about_credits_file)',
],
},
'includes': [ '../build/grit_action.gypi' ],
},
@ -838,8 +871,8 @@
'libcef/browser/internal_scheme_handler.cc',
'libcef/browser/internal_scheme_handler.h',
'libcef/browser/javascript_dialog.h',
'libcef/browser/javascript_dialog_creator.cc',
'libcef/browser/javascript_dialog_creator.h',
'libcef/browser/javascript_dialog_manager.cc',
'libcef/browser/javascript_dialog_manager.h',
'libcef/browser/menu_creator.cc',
'libcef/browser/menu_creator.h',
'libcef/browser/menu_model_impl.cc',
@ -851,8 +884,6 @@
'libcef/browser/path_util_impl.cc',
'libcef/browser/process_util_impl.cc',
'libcef/browser/proxy_stubs.cc',
'libcef/browser/resource_context.cc',
'libcef/browser/resource_context.h',
'libcef/browser/resource_dispatcher_host_delegate.cc',
'libcef/browser/resource_dispatcher_host_delegate.h',
'libcef/browser/resource_request_job.cc',
@ -965,16 +996,6 @@
'<(DEPTH)/chrome/browser/net/proxy_service_factory.h',
'<(DEPTH)/chrome/browser/prefs/command_line_pref_store.cc',
'<(DEPTH)/chrome/browser/prefs/command_line_pref_store.h',
'<(DEPTH)/chrome/browser/prefs/pref_notifier_impl.cc',
'<(DEPTH)/chrome/browser/prefs/pref_notifier_impl.h',
'<(DEPTH)/chrome/browser/prefs/pref_service.cc',
'<(DEPTH)/chrome/browser/prefs/pref_service.h',
'<(DEPTH)/chrome/browser/prefs/pref_service_builder.cc',
'<(DEPTH)/chrome/browser/prefs/pref_service_builder.h',
'<(DEPTH)/chrome/browser/prefs/pref_service_simple.cc',
'<(DEPTH)/chrome/browser/prefs/pref_service_simple.h',
'<(DEPTH)/chrome/browser/prefs/pref_value_store.cc',
'<(DEPTH)/chrome/browser/prefs/pref_value_store.h',
'<(DEPTH)/chrome/browser/prefs/proxy_config_dictionary.cc',
'<(DEPTH)/chrome/browser/prefs/proxy_config_dictionary.h',
'<(DEPTH)/chrome/browser/prefs/proxy_prefs.cc',

View File

@ -9,7 +9,6 @@
#include "libcef/browser/browser_host_impl.h"
#include "libcef/browser/context.h"
#include "libcef/browser/download_manager_delegate.h"
#include "libcef/browser/resource_context.h"
#include "libcef/browser/thread_util.h"
#include "libcef/browser/url_request_context_getter.h"
@ -19,7 +18,9 @@
#include "content/public/browser/download_manager.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/browser/geolocation_permission_context.h"
#include "content/public/browser/resource_context.h"
#include "content/public/browser/speech_recognition_preferences.h"
#include "content/public/browser/storage_partition.h"
using content::BrowserThread;
@ -172,12 +173,34 @@ class CefSpeechRecognitionPreferences
} // namespace
class CefBrowserContext::CefResourceContext : public content::ResourceContext {
public:
CefResourceContext() : getter_(NULL) {}
virtual ~CefResourceContext() {}
// ResourceContext implementation:
virtual net::HostResolver* GetHostResolver() OVERRIDE {
CHECK(getter_);
return getter_->host_resolver();
}
virtual net::URLRequestContext* GetRequestContext() OVERRIDE {
CHECK(getter_);
return getter_->GetURLRequestContext();
}
void set_url_request_context_getter(CefURLRequestContextGetter* getter) {
getter_ = getter;
}
private:
CefURLRequestContextGetter* getter_;
DISALLOW_COPY_AND_ASSIGN(CefResourceContext);
};
CefBrowserContext::CefBrowserContext()
: use_osr_next_contents_view_(false) {
// Initialize the request context getter.
url_request_getter_ = new CefURLRequestContextGetter(
BrowserThread::UnsafeGetMessageLoopForThread(BrowserThread::IO),
BrowserThread::UnsafeGetMessageLoopForThread(BrowserThread::FILE));
: use_osr_next_contents_view_(false),
resource_context_(new CefResourceContext) {
}
CefBrowserContext::~CefBrowserContext() {
@ -192,7 +215,7 @@ CefBrowserContext::~CefBrowserContext() {
}
}
FilePath CefBrowserContext::GetPath() {
base::FilePath CefBrowserContext::GetPath() {
return _Context->cache_path();
}
@ -210,7 +233,8 @@ content::DownloadManagerDelegate*
}
net::URLRequestContextGetter* CefBrowserContext::GetRequestContext() {
return url_request_getter_;
CEF_REQUIRE_UIT();
return GetDefaultStoragePartition(this)->GetURLRequestContext();
}
net::URLRequestContextGetter*
@ -236,23 +260,12 @@ net::URLRequestContextGetter*
net::URLRequestContextGetter*
CefBrowserContext::GetMediaRequestContextForStoragePartition(
const FilePath& partition_path,
const base::FilePath& partition_path,
bool in_memory) {
return GetRequestContext();
}
net::URLRequestContextGetter*
CefBrowserContext::GetRequestContextForStoragePartition(
const FilePath& partition_path,
bool in_memory) {
return NULL;
}
content::ResourceContext* CefBrowserContext::GetResourceContext() {
if (!resource_context_.get()) {
resource_context_.reset(new CefResourceContext(
static_cast<CefURLRequestContextGetter*>(GetRequestContext())));
}
return resource_context_.get();
}
@ -276,6 +289,48 @@ quota::SpecialStoragePolicy* CefBrowserContext::GetSpecialStoragePolicy() {
return NULL;
}
net::URLRequestContextGetter* CefBrowserContext::CreateRequestContext(
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_devtools_protocol_handler) {
DCHECK(!url_request_getter_);
// CEF doesn't use URLDataManager for serving chrome internal protocols.
// |chrome_protocol_handler| and |chrome_devtools_protocol_handler| are
// ignored so as not to conflict with CEF's protocol implementation.
url_request_getter_ = new CefURLRequestContextGetter(
BrowserThread::UnsafeGetMessageLoopForThread(BrowserThread::IO),
BrowserThread::UnsafeGetMessageLoopForThread(BrowserThread::FILE),
blob_protocol_handler.Pass(),
file_system_protocol_handler.Pass(),
developer_protocol_handler.Pass());
resource_context_->set_url_request_context_getter(url_request_getter_.get());
return url_request_getter_.get();
}
net::URLRequestContextGetter*
CefBrowserContext::CreateRequestContextForStoragePartition(
const base::FilePath& partition_path,
bool in_memory,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_devtools_protocol_handler) {
return NULL;
}
bool CefBrowserContext::use_osr_next_contents_view() const {
return use_osr_next_contents_view_;
}

View File

@ -11,6 +11,7 @@
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "content/public/browser/browser_context.h"
#include "net/url_request/url_request_job_factory.h"
namespace content {
class DownloadManagerDelegate;
@ -18,7 +19,7 @@ class SpeechRecognitionPreferences;
}
class CefDownloadManagerDelegate;
class CefResourceContext;
class CefURLRequestContextGetter;
class CefBrowserContext : public content::BrowserContext {
public:
@ -26,7 +27,7 @@ class CefBrowserContext : public content::BrowserContext {
virtual ~CefBrowserContext();
// BrowserContext methods.
virtual FilePath GetPath() OVERRIDE;
virtual base::FilePath GetPath() OVERRIDE;
virtual bool IsOffTheRecord() const OVERRIDE;
virtual content::DownloadManagerDelegate* GetDownloadManagerDelegate() OVERRIDE;
virtual net::URLRequestContextGetter* GetRequestContext() OVERRIDE;
@ -37,11 +38,8 @@ class CefBrowserContext : public content::BrowserContext {
int renderer_child_id) OVERRIDE;
virtual net::URLRequestContextGetter*
GetMediaRequestContextForStoragePartition(
const FilePath& partition_path,
const base::FilePath& partition_path,
bool in_memory) OVERRIDE;
virtual net::URLRequestContextGetter* GetRequestContextForStoragePartition(
const FilePath& partition_path,
bool in_memory) OVERRIDE;
virtual content::ResourceContext* GetResourceContext() OVERRIDE;
virtual content::GeolocationPermissionContext*
GetGeolocationPermissionContext() OVERRIDE;
@ -49,6 +47,31 @@ class CefBrowserContext : public content::BrowserContext {
GetSpeechRecognitionPreferences() OVERRIDE;
virtual quota::SpecialStoragePolicy* GetSpecialStoragePolicy() OVERRIDE;
net::URLRequestContextGetter* CreateRequestContext(
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_devtools_protocol_handler);
net::URLRequestContextGetter* CreateRequestContextForStoragePartition(
const FilePath& partition_path,
bool in_memory,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_devtools_protocol_handler);
// To disable window rendering call this function with |override|=true
// just before calling WebContents::Create. This will cause
// CefContentBrowserClient::OverrideCreateWebContentsView to create
@ -57,10 +80,11 @@ class CefBrowserContext : public content::BrowserContext {
bool use_osr_next_contents_view() const;
private:
class CefResourceContext;
scoped_ptr<CefResourceContext> resource_context_;
scoped_ptr<CefDownloadManagerDelegate> download_manager_delegate_;
scoped_refptr<net::URLRequestContextGetter> url_request_getter_;
scoped_refptr<CefURLRequestContextGetter> url_request_getter_;
scoped_refptr<content::GeolocationPermissionContext>
geolocation_permission_context_;
scoped_refptr<content::SpeechRecognitionPreferences>

View File

@ -39,7 +39,7 @@
#include "content/public/browser/notification_types.h"
#include "content/public/browser/resource_request_info.h"
#include "content/public/common/file_chooser_params.h"
#include "ui/base/dialogs/selected_file_info.h"
#include "ui/shell_dialogs/selected_file_info.h"
#if defined(OS_WIN)
#include "libcef/browser/render_widget_host_view_osr.h"
@ -133,11 +133,11 @@ class CefFileDialogCallbackImpl : public CefFileDialogCallback {
virtual void Continue(const std::vector<CefString>& file_paths) OVERRIDE {
if (CEF_CURRENTLY_ON_UIT()) {
if (!callback_.is_null()) {
std::vector<FilePath> vec;
std::vector<base::FilePath> vec;
if (!file_paths.empty()) {
std::vector<CefString>::const_iterator it = file_paths.begin();
for (; it != file_paths.end(); ++it)
vec.push_back(FilePath(*it));
vec.push_back(base::FilePath(*it));
}
callback_.Run(vec);
callback_.Reset();
@ -172,7 +172,7 @@ class CefFileDialogCallbackImpl : public CefFileDialogCallback {
static void CancelNow(
const CefBrowserHostImpl::RunFileChooserCallback& callback) {
CEF_REQUIRE_UIT();
std::vector<FilePath> file_paths;
std::vector<base::FilePath> file_paths;
callback.Run(file_paths);
}
@ -190,7 +190,7 @@ class CefRunFileDialogCallbackWrapper
callback_(callback) {
}
void Callback(const std::vector<FilePath>& file_paths) {
void Callback(const std::vector<base::FilePath>& file_paths) {
std::vector<CefString> paths;
if (file_paths.size() > 0) {
for (size_t i = 0; i < file_paths.size(); ++i)
@ -544,7 +544,7 @@ void CefBrowserHostImpl::RunFileDialog(
}
params.title = title;
if (!default_file_name.empty())
params.default_file_name = FilePath(default_file_name);
params.default_file_name = base::FilePath(default_file_name);
if (!accept_types.empty()) {
std::vector<CefString>::const_iterator it = accept_types.begin();
for (; it != accept_types.end(); ++it)
@ -1079,7 +1079,7 @@ net::URLRequestContextGetter* CefBrowserHostImpl::GetRequestContext() {
request_context_proxy_ =
new CefURLRequestContextGetterProxy(this,
static_cast<CefURLRequestContextGetter*>(
_Context->browser_context()->GetRequestContext()));
_Context->request_context().get()));
}
return request_context_proxy_.get();
}
@ -1569,11 +1569,11 @@ void CefBrowserHostImpl::DidNavigateMainFramePostCommit(
has_document_ = false;
}
content::JavaScriptDialogCreator*
CefBrowserHostImpl::GetJavaScriptDialogCreator() {
if (!dialog_creator_.get())
dialog_creator_.reset(new CefJavaScriptDialogCreator(this));
return dialog_creator_.get();
content::JavaScriptDialogManager*
CefBrowserHostImpl::GetJavaScriptDialogManager() {
if (!dialog_manager_.get())
dialog_manager_.reset(new CefJavaScriptDialogManager(this));
return dialog_manager_.get();
}
void CefBrowserHostImpl::RunFileChooser(
@ -1730,7 +1730,7 @@ void CefBrowserHostImpl::DidFailLoad(
OnLoadEnd(frame, validated_url, error_code);
}
void CefBrowserHostImpl::PluginCrashed(const FilePath& plugin_path,
void CefBrowserHostImpl::PluginCrashed(const base::FilePath& plugin_path,
base::ProcessId plugin_pid) {
if (client_.get()) {
CefRefPtr<CefLoadHandler> handler = client_->GetLoadHandler();
@ -2092,13 +2092,13 @@ void CefBrowserHostImpl::RunFileChooserOnUIThread(
if (file_chooser_pending_) {
// Dismiss the new dialog immediately.
callback.Run(std::vector<FilePath>());
callback.Run(std::vector<base::FilePath>());
return;
}
if (params.mode == content::FileChooserParams::OpenFolder) {
NOTIMPLEMENTED();
callback.Run(std::vector<FilePath>());
callback.Run(std::vector<base::FilePath>());
return;
}
@ -2157,7 +2157,7 @@ void CefBrowserHostImpl::RunFileChooserOnUIThread(
void CefBrowserHostImpl::OnRunFileChooserCallback(
const RunFileChooserCallback& callback,
const std::vector<FilePath>& file_paths) {
const std::vector<base::FilePath>& file_paths) {
CEF_REQUIRE_UIT();
file_chooser_pending_ = false;
@ -2168,7 +2168,7 @@ void CefBrowserHostImpl::OnRunFileChooserCallback(
void CefBrowserHostImpl::OnRunFileChooserDelegateCallback(
content::WebContents* tab,
const std::vector<FilePath>& file_paths) {
const std::vector<base::FilePath>& file_paths) {
CEF_REQUIRE_UIT();
content::RenderViewHost* render_view_host = tab->GetRenderViewHost();
@ -2183,8 +2183,10 @@ void CefBrowserHostImpl::OnRunFileChooserDelegateCallback(
// Convert FilePath list to SelectedFileInfo list.
std::vector<ui::SelectedFileInfo> selected_files;
for (size_t i = 0; i < file_paths.size(); ++i)
selected_files.push_back(ui::SelectedFileInfo(file_paths[i], FilePath()));
for (size_t i = 0; i < file_paths.size(); ++i) {
selected_files.push_back(
ui::SelectedFileInfo(file_paths[i], base::FilePath()));
}
// Notify our RenderViewHost in all cases.
render_view_host->FilesSelectedInChooser(selected_files,

View File

@ -16,7 +16,7 @@
#include "include/cef_client.h"
#include "include/cef_frame.h"
#include "libcef/browser/frame_host_impl.h"
#include "libcef/browser/javascript_dialog_creator.h"
#include "libcef/browser/javascript_dialog_manager.h"
#include "libcef/browser/menu_creator.h"
#include "libcef/common/response_manager.h"
@ -235,7 +235,7 @@ class CefBrowserHostImpl : public CefBrowserHost,
void OnSetFocus(cef_focus_source_t source);
// The argument vector will be empty if the dialog was cancelled.
typedef base::Callback<void(const std::vector<FilePath>&)>
typedef base::Callback<void(const std::vector<base::FilePath>&)>
RunFileChooserCallback;
// Run the file chooser dialog specified by |params|. Only a single dialog may
@ -292,7 +292,7 @@ class CefBrowserHostImpl : public CefBrowserHost,
content::WebContents* new_contents) OVERRIDE;
virtual void DidNavigateMainFramePostCommit(
content::WebContents* tab) OVERRIDE;
virtual content::JavaScriptDialogCreator* GetJavaScriptDialogCreator()
virtual content::JavaScriptDialogManager* GetJavaScriptDialogManager()
OVERRIDE;
virtual void RunFileChooser(
content::WebContents* tab,
@ -331,7 +331,7 @@ class CefBrowserHostImpl : public CefBrowserHost,
int error_code,
const string16& error_description,
content::RenderViewHost* render_view_host) OVERRIDE;
virtual void PluginCrashed(const FilePath& plugin_path,
virtual void PluginCrashed(const base::FilePath& plugin_path,
base::ProcessId plugin_pid) OVERRIDE;
virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
// Override to provide a thread safe implementation.
@ -438,12 +438,12 @@ class CefBrowserHostImpl : public CefBrowserHost,
// Used with RunFileChooser to clear the |file_chooser_pending_| flag.
void OnRunFileChooserCallback(const RunFileChooserCallback& callback,
const std::vector<FilePath>& file_paths);
const std::vector<base::FilePath>& file_paths);
// Used with WebContentsDelegate::RunFileChooser to notify the WebContents.
void OnRunFileChooserDelegateCallback(
content::WebContents* tab,
const std::vector<FilePath>& file_paths);
const std::vector<base::FilePath>& file_paths);
CefWindowInfo window_info_;
CefBrowserSettings settings_;
@ -501,7 +501,7 @@ class CefBrowserHostImpl : public CefBrowserHost,
scoped_ptr<CefResponseManager> response_manager_;
// Used for creating and managing JavaScript dialogs.
scoped_ptr<CefJavaScriptDialogCreator> dialog_creator_;
scoped_ptr<CefJavaScriptDialogManager> dialog_manager_;
// Used for creating and managing context menus.
scoped_ptr<CefMenuCreator> menu_creator_;

View File

@ -75,7 +75,7 @@ void AddFiltersForAcceptTypes(GtkFileChooser* chooser,
std::string description = GetDescriptionFromMimeType(ascii_type);
bool description_from_ext = description.empty();
std::vector<FilePath::StringType> ext;
std::vector<base::FilePath::StringType> ext;
net::GetExtensionsForMimeType(ascii_type, &ext);
for (size_t x = 0; x < ext.size(); ++x) {
if (!filter)
@ -113,7 +113,7 @@ void AddFiltersForAcceptTypes(GtkFileChooser* chooser,
bool RunFileDialog(const content::FileChooserParams& params,
CefWindowHandle widget,
std::vector<FilePath>* files) {
std::vector<base::FilePath>* files) {
GtkFileChooserAction action;
const gchar* accept_button;
if (params.mode == content::FileChooserParams::Open ||
@ -129,7 +129,7 @@ bool RunFileDialog(const content::FileChooserParams& params,
}
// Consider default file name if any.
FilePath default_file_name(params.default_file_name);
base::FilePath default_file_name(params.default_file_name);
std::string base_name;
if (!default_file_name.empty())
@ -185,7 +185,7 @@ bool RunFileDialog(const content::FileChooserParams& params,
if (params.mode == content::FileChooserParams::Open ||
params.mode == content::FileChooserParams::Save) {
char* filename = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(dialog));
files->push_back(FilePath(filename));
files->push_back(base::FilePath(filename));
success = true;
} else if (params.mode == content::FileChooserParams::OpenMultiple) {
GSList* filenames =
@ -193,7 +193,7 @@ bool RunFileDialog(const content::FileChooserParams& params,
if (filenames) {
for (GSList* iter = filenames; iter != NULL;
iter = g_slist_next(iter)) {
FilePath path(static_cast<char*>(iter->data));
base::FilePath path(static_cast<char*>(iter->data));
g_free(iter->data);
files->push_back(path);
}
@ -318,7 +318,7 @@ void CefBrowserHostImpl::PlatformHandleKeyboardEvent(
void CefBrowserHostImpl::PlatformRunFileChooser(
const content::FileChooserParams& params,
RunFileChooserCallback callback) {
std::vector<FilePath> files;
std::vector<base::FilePath> files;
if (params.mode == content::FileChooserParams::Open ||
params.mode == content::FileChooserParams::OpenMultiple ||

View File

@ -82,7 +82,7 @@ NSMutableArray* GetFileTypesFromAcceptTypes(
[acceptArray addObject:base::SysUTF8ToNSString(ascii_type.substr(1))];
} else {
// Otherwise convert mime type to one or more extensions.
std::vector<FilePath::StringType> ext;
std::vector<base::FilePath::StringType> ext;
net::GetExtensionsForMimeType(ascii_type, &ext);
for (size_t x = 0; x < ext.size(); ++x)
[acceptArray addObject:base::SysUTF8ToNSString(ext[x])];
@ -94,7 +94,7 @@ NSMutableArray* GetFileTypesFromAcceptTypes(
void RunOpenFileDialog(const content::FileChooserParams& params,
NSView* view,
std::vector<FilePath>* files) {
std::vector<base::FilePath>* files) {
NSOpenPanel* openPanel = [NSOpenPanel openPanel];
string16 title;
@ -108,7 +108,7 @@ void RunOpenFileDialog(const content::FileChooserParams& params,
[openPanel setTitle:base::SysUTF16ToNSString(title)];
// Consider default file name if any.
FilePath default_file_name(params.default_file_name);
base::FilePath default_file_name(params.default_file_name);
if (!default_file_name.empty()) {
if (!default_file_name.BaseName().empty()) {
@ -145,7 +145,7 @@ void RunOpenFileDialog(const content::FileChooserParams& params,
for (i=0; i<count; i++) {
NSURL* url = [urls objectAtIndex:i];
if ([url isFileURL])
files->push_back(FilePath(base::SysNSStringToUTF8([url path])));
files->push_back(base::FilePath(base::SysNSStringToUTF8([url path])));
}
}
[NSApp endSheet:openPanel];
@ -153,7 +153,7 @@ void RunOpenFileDialog(const content::FileChooserParams& params,
bool RunSaveFileDialog(const content::FileChooserParams& params,
NSView* view,
FilePath* file) {
base::FilePath* file) {
NSSavePanel* savePanel = [NSSavePanel savePanel];
string16 title;
@ -164,7 +164,7 @@ bool RunSaveFileDialog(const content::FileChooserParams& params,
[savePanel setTitle:base::SysUTF16ToNSString(title)];
// Consider default file name if any.
FilePath default_file_name(params.default_file_name);
base::FilePath default_file_name(params.default_file_name);
if (!default_file_name.empty()) {
if (!default_file_name.BaseName().empty()) {
@ -194,7 +194,7 @@ bool RunSaveFileDialog(const content::FileChooserParams& params,
if ([savePanel runModal] == NSFileHandlingPanelOKButton) {
NSURL * url = [savePanel URL];
NSString* path = [url path];
*file = FilePath([path UTF8String]);
*file = base::FilePath([path UTF8String]);
success = true;
}
[NSApp endSheet:savePanel];
@ -300,13 +300,13 @@ void CefBrowserHostImpl::PlatformHandleKeyboardEvent(
void CefBrowserHostImpl::PlatformRunFileChooser(
const content::FileChooserParams& params,
RunFileChooserCallback callback) {
std::vector<FilePath> files;
std::vector<base::FilePath> files;
if (params.mode == content::FileChooserParams::Open ||
params.mode == content::FileChooserParams::OpenMultiple) {
RunOpenFileDialog(params, PlatformGetWindowHandle(), &files);
} else if (params.mode == content::FileChooserParams::Save) {
FilePath file;
base::FilePath file;
if (RunSaveFileDialog(params, PlatformGetWindowHandle(), &file))
files.push_back(file);
} else {

View File

@ -200,7 +200,7 @@ std::wstring GetFilterStringFromAcceptTypes(
descriptions.push_back(std::wstring());
} else {
// Otherwise convert mime type to one or more extensions.
std::vector<FilePath::StringType> ext;
std::vector<base::FilePath::StringType> ext;
std::wstring ext_str;
net::GetExtensionsForMimeType(ascii_type, &ext);
if (ext.size() > 0) {
@ -223,7 +223,7 @@ std::wstring GetFilterStringFromAcceptTypes(
bool RunOpenFileDialog(const content::FileChooserParams& params,
HWND owner,
FilePath* path) {
base::FilePath* path) {
OPENFILENAME ofn;
// We must do this otherwise the ofn's FlagsEx may be initialized to random
@ -233,7 +233,7 @@ bool RunOpenFileDialog(const content::FileChooserParams& params,
ofn.hwndOwner = owner;
// Consider default file name if any.
FilePath default_file_name(params.default_file_name);
base::FilePath default_file_name(params.default_file_name);
wchar_t filename[MAX_PATH] = {0};
@ -268,13 +268,13 @@ bool RunOpenFileDialog(const content::FileChooserParams& params,
bool success = !!GetOpenFileName(&ofn);
if (success)
*path = FilePath(filename);
*path = base::FilePath(filename);
return success;
}
bool RunOpenMultiFileDialog(const content::FileChooserParams& params,
HWND owner,
std::vector<FilePath>* paths) {
std::vector<base::FilePath>* paths) {
OPENFILENAME ofn;
// We must do this otherwise the ofn's FlagsEx may be initialized to random
@ -309,10 +309,10 @@ bool RunOpenMultiFileDialog(const content::FileChooserParams& params,
bool success = !!GetOpenFileName(&ofn);
if (success) {
std::vector<FilePath> files;
std::vector<base::FilePath> files;
const wchar_t* selection = ofn.lpstrFile;
while (*selection) { // Empty string indicates end of list.
files.push_back(FilePath(selection));
files.push_back(base::FilePath(selection));
// Skip over filename and null-terminator.
selection += files.back().value().length() + 1;
}
@ -324,8 +324,8 @@ bool RunOpenMultiFileDialog(const content::FileChooserParams& params,
} else {
// Otherwise, the first string is the path, and the remainder are
// filenames.
std::vector<FilePath>::iterator path = files.begin();
for (std::vector<FilePath>::iterator file = path + 1;
std::vector<base::FilePath>::iterator path = files.begin();
for (std::vector<base::FilePath>::iterator file = path + 1;
file != files.end(); ++file) {
paths->push_back(path->Append(*file));
}
@ -336,7 +336,7 @@ bool RunOpenMultiFileDialog(const content::FileChooserParams& params,
bool RunSaveFileDialog(const content::FileChooserParams& params,
HWND owner,
FilePath* path) {
base::FilePath* path) {
OPENFILENAME ofn;
// We must do this otherwise the ofn's FlagsEx may be initialized to random
@ -346,7 +346,7 @@ bool RunSaveFileDialog(const content::FileChooserParams& params,
ofn.hwndOwner = owner;
// Consider default file name if any.
FilePath default_file_name(params.default_file_name);
base::FilePath default_file_name(params.default_file_name);
wchar_t filename[MAX_PATH] = {0};
@ -381,7 +381,7 @@ bool RunSaveFileDialog(const content::FileChooserParams& params,
bool success = !!GetSaveFileName(&ofn);
if (success)
*path = FilePath(filename);
*path = base::FilePath(filename);
return success;
}
@ -645,16 +645,16 @@ void CefBrowserHostImpl::PlatformHandleKeyboardEvent(
void CefBrowserHostImpl::PlatformRunFileChooser(
const content::FileChooserParams& params,
RunFileChooserCallback callback) {
std::vector<FilePath> files;
std::vector<base::FilePath> files;
if (params.mode == content::FileChooserParams::Open) {
FilePath file;
base::FilePath file;
if (RunOpenFileDialog(params, PlatformGetWindowHandle(), &file))
files.push_back(file);
} else if (params.mode == content::FileChooserParams::OpenMultiple) {
RunOpenMultiFileDialog(params, PlatformGetWindowHandle(), &files);
} else if (params.mode == content::FileChooserParams::Save) {
FilePath file;
base::FilePath file;
if (RunSaveFileDialog(params, PlatformGetWindowHandle(), &file))
files.push_back(file);
} else {

View File

@ -8,6 +8,7 @@
#include "libcef/browser/browser_context.h"
#include "libcef/browser/browser_message_loop.h"
#include "libcef/browser/context.h"
#include "libcef/browser/devtools_delegate.h"
#include "base/bind.h"
@ -70,9 +71,12 @@ int CefBrowserMainParts::PreCreateThreads() {
void CefBrowserMainParts::PreMainMessageLoopRun() {
browser_context_.reset(new CefBrowserContext());
// Initialize the request context getter.
_Context->set_request_context(browser_context_->GetRequestContext());
// Initialize proxy configuration service.
ChromeProxyConfigService* chrome_proxy_config_service =
ProxyServiceFactory::CreateProxyConfigService(true);
ProxyServiceFactory::CreateProxyConfigService();
proxy_config_service_.reset(chrome_proxy_config_service);
pref_proxy_config_tracker_->SetChromeProxyConfigService(
chrome_proxy_config_service);
@ -94,6 +98,7 @@ void CefBrowserMainParts::PostMainMessageLoopRun() {
if (devtools_delegate_)
devtools_delegate_->Stop();
pref_proxy_config_tracker_->DetachFromPrefService();
_Context->set_request_context(NULL);
browser_context_.reset();
}

View File

@ -3,9 +3,9 @@
// be found in the LICENSE file.
#include "libcef/browser/browser_message_loop.h"
#include "base/run_loop.h"
CefBrowserMessageLoop::CefBrowserMessageLoop()
: is_iterating_(true) {
CefBrowserMessageLoop::CefBrowserMessageLoop() {
}
CefBrowserMessageLoop::~CefBrowserMessageLoop() {
@ -23,20 +23,11 @@ CefBrowserMessageLoop* CefBrowserMessageLoop::current() {
return static_cast<CefBrowserMessageLoop*>(loop);
}
bool CefBrowserMessageLoop::DoIdleWork() {
bool valueToRet = inherited::DoIdleWork();
if (is_iterating_)
pump_->Quit();
return valueToRet;
void CefBrowserMessageLoop::DoMessageLoopIteration() {
base::RunLoop run_loop;
run_loop.RunUntilIdle();
}
// Do a single interation of the UI message loop.
void CefBrowserMessageLoop::DoMessageLoopIteration() {
void CefBrowserMessageLoop::RunMessageLoop() {
Run();
}
// Run the UI message loop.
void CefBrowserMessageLoop::RunMessageLoop() {
is_iterating_ = false;
DoMessageLoopIteration();
}

View File

@ -20,20 +20,13 @@ class CefBrowserMessageLoop : public MessageLoopForUI {
// Returns the MessageLoopForUI of the current thread.
static CefBrowserMessageLoop* current();
virtual bool DoIdleWork();
// Do a single interation of the UI message loop.
void DoMessageLoopIteration();
// Run the UI message loop.
void RunMessageLoop();
bool is_iterating() { return is_iterating_; }
private:
// True if the message loop is doing one iteration at a time.
bool is_iterating_;
DISALLOW_COPY_AND_ASSIGN(CefBrowserMessageLoop);
};

View File

@ -5,10 +5,10 @@
#include "libcef/browser/browser_pref_store.h"
#include "base/command_line.h"
#include "base/prefs/pref_service_builder.h"
#include "base/prefs/pref_registry_simple.h"
#include "base/values.h"
#include "chrome/browser/prefs/command_line_pref_store.h"
#include "chrome/browser/prefs/pref_service_builder.h"
#include "chrome/browser/prefs/pref_service_simple.h"
#include "chrome/browser/prefs/proxy_config_dictionary.h"
#include "chrome/common/pref_names.h"
@ -21,13 +21,13 @@ PrefService* BrowserPrefStore::CreateService() {
new CommandLinePrefStore(CommandLine::ForCurrentProcess()));
builder.WithUserPrefs(this);
PrefServiceSimple* service = builder.CreateSimple();
scoped_refptr<PrefRegistrySimple> registry(new PrefRegistrySimple());
// Default settings.
service->RegisterDictionaryPref(prefs::kProxy,
ProxyConfigDictionary::CreateDirect());
registry->RegisterDictionaryPref(prefs::kProxy,
ProxyConfigDictionary::CreateDirect());
return service;
return builder.Create(registry);
}
BrowserPrefStore::~BrowserPrefStore() {

View File

@ -113,8 +113,7 @@ class CefBrowserURLRequest::Context
fetcher_.reset(net::URLFetcher::Create(url, request_type,
fetcher_delegate_.get()));
fetcher_->SetRequestContext(
_Context->browser_context()->GetRequestContext());
fetcher_->SetRequestContext(_Context->request_context());
CefRequest::HeaderMap headerMap;
request_->GetHeaderMap(headerMap);

View File

@ -108,7 +108,7 @@ std::string GetCommandLine() {
}
std::string GetModulePath() {
FilePath path;
base::FilePath path;
if (PathService::Get(base::FILE_MODULE, &path))
return CefString(path.value());
return std::string();
@ -353,7 +353,8 @@ bool IsTraceFrameValid(CefRefPtr<CefFrameHostImpl> frame) {
return true;
}
void LoadTraceFile(CefRefPtr<CefFrameHostImpl> frame, const FilePath& path) {
void LoadTraceFile(CefRefPtr<CefFrameHostImpl> frame,
const base::FilePath& path) {
CEF_REQUIRE_FILET();
if (!IsTraceFrameValid(frame))
@ -416,7 +417,7 @@ void LoadTraceFile(CefRefPtr<CefFrameHostImpl> frame, const FilePath& path) {
}
void SaveTraceFile(CefRefPtr<CefFrameHostImpl> frame,
const FilePath& path,
const base::FilePath& path,
scoped_ptr<std::string> contents) {
CEF_REQUIRE_FILET();
@ -527,7 +528,7 @@ void OnChromeTracingProcessMessage(CefRefPtr<CefBrowser> browser,
if (!file_paths.empty()) {
CEF_POST_TASK(CEF_FILET,
base::Bind(LoadTraceFile, frame_,
FilePath(file_paths.front())));
base::FilePath(file_paths.front())));
} else {
frame_->SendJavaScript(
"tracingController.onLoadTraceFileCanceled();",
@ -565,7 +566,7 @@ void OnChromeTracingProcessMessage(CefRefPtr<CefBrowser> browser,
if (!file_paths.empty()) {
CEF_POST_TASK(CEF_FILET,
base::Bind(SaveTraceFile, frame_,
FilePath(file_paths.front()),
base::FilePath(file_paths.front()),
base::Passed(contents_.Pass())));
} else {
frame_->SendJavaScript(

View File

@ -49,8 +49,7 @@ class CefAccessTokenStore : public content::AccessTokenStore {
virtual void LoadAccessTokens(
const LoadAccessTokensCallbackType& callback) OVERRIDE {
callback.Run(access_token_set_,
_Context->browser_context()->GetRequestContext());
callback.Run(access_token_set_, _Context->request_context());
}
virtual void SaveAccessToken(
@ -178,12 +177,12 @@ class CefPluginServiceFilter : public content::PluginServiceFilter {
CefPluginServiceFilter() {}
virtual ~CefPluginServiceFilter() {}
virtual bool ShouldUsePlugin(int render_process_id,
int render_view_id,
const void* context,
const GURL& url,
const GURL& policy_url,
webkit::WebPluginInfo* plugin) OVERRIDE {
virtual bool IsPluginAvailable(int render_process_id,
int render_view_id,
const void* context,
const GURL& url,
const GURL& policy_url,
webkit::WebPluginInfo* plugin) OVERRIDE {
bool allowed = true;
CefRefPtr<CefBrowserHostImpl> browser =
@ -207,6 +206,11 @@ class CefPluginServiceFilter : public content::PluginServiceFilter {
return allowed;
}
virtual bool CanLoadPlugin(int render_process_id,
const FilePath& path) OVERRIDE {
return true;
}
};
} // namespace
@ -217,16 +221,6 @@ class CefMediaObserver : public content::MediaObserver {
CefMediaObserver() {}
virtual ~CefMediaObserver() {}
virtual void OnDeleteAudioStream(void* host, int stream_id) OVERRIDE {}
virtual void OnSetAudioStreamPlaying(void* host, int stream_id,
bool playing) OVERRIDE {}
virtual void OnSetAudioStreamStatus(void* host, int stream_id,
const std::string& status) OVERRIDE {}
virtual void OnSetAudioStreamVolume(void* host, int stream_id,
double volume) OVERRIDE {}
virtual void OnMediaEvent(int render_process_id,
const media::MediaLogEvent& event) OVERRIDE {}
virtual void OnCaptureDevicesOpened(
int render_process_id,
int render_view_id,
@ -394,6 +388,50 @@ void CefContentBrowserClient::RenderProcessHostCreated(
host->GetChannel()->AddFilter(new CefBrowserMessageFilter(host));
}
net::URLRequestContextGetter* CefContentBrowserClient::CreateRequestContext(
content::BrowserContext* content_browser_context,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_devtools_protocol_handler) {
CefBrowserContext* cef_browser_context =
CefBrowserContextForBrowserContext(content_browser_context);
return cef_browser_context->CreateRequestContext(
blob_protocol_handler.Pass(), file_system_protocol_handler.Pass(),
developer_protocol_handler.Pass(), chrome_protocol_handler.Pass(),
chrome_devtools_protocol_handler.Pass());
}
net::URLRequestContextGetter*
CefContentBrowserClient::CreateRequestContextForStoragePartition(
content::BrowserContext* content_browser_context,
const base::FilePath& partition_path,
bool in_memory,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_devtools_protocol_handler) {
CefBrowserContext* cef_browser_context =
CefBrowserContextForBrowserContext(content_browser_context);
return cef_browser_context->CreateRequestContextForStoragePartition(
partition_path, in_memory, blob_protocol_handler.Pass(),
file_system_protocol_handler.Pass(),
developer_protocol_handler.Pass(), chrome_protocol_handler.Pass(),
chrome_devtools_protocol_handler.Pass());
}
void CefContentBrowserClient::AppendExtraCommandLineSwitches(
CommandLine* command_line, int child_process_id) {
const CommandLine& browser_cmd = *CommandLine::ForCurrentProcess();
@ -593,7 +631,7 @@ const wchar_t* CefContentBrowserClient::GetResourceDllName() {
if (file_path[0] == 0) {
// Retrieve the module path (usually libcef.dll).
FilePath module;
base::FilePath module;
PathService::Get(base::FILE_MODULE, &module);
const std::wstring wstr = module.value();
size_t count = std::min(static_cast<size_t>(MAX_PATH), wstr.size());
@ -610,3 +648,10 @@ void CefContentBrowserClient::set_last_create_window_params(
CEF_REQUIRE_IOT();
last_create_window_params_ = params;
}
CefBrowserContext*
CefContentBrowserClient::CefBrowserContextForBrowserContext(
content::BrowserContext* content_browser_context) {
DCHECK_EQ(content_browser_context, browser_main_parts_->browser_context());
return browser_main_parts_->browser_context();
}

View File

@ -18,6 +18,7 @@
#include "content/public/browser/content_browser_client.h"
#include "googleurl/src/gurl.h"
class CefBrowserContext;
class CefBrowserInfo;
class CefBrowserMainParts;
class CefMediaObserver;
@ -61,11 +62,37 @@ class CefContentBrowserClient : public content::ContentBrowserClient {
virtual content::BrowserMainParts* CreateBrowserMainParts(
const content::MainFunctionParams& parameters) OVERRIDE;
virtual void RenderProcessHostCreated(
content::RenderProcessHost* host) OVERRIDE;
virtual content::WebContentsView* OverrideCreateWebContentsView(
content::WebContents* web_contents,
content::RenderViewHostDelegateView** rvhdv) OVERRIDE;
virtual void RenderProcessHostCreated(
content::RenderProcessHost* host) OVERRIDE;
virtual net::URLRequestContextGetter* CreateRequestContext(
content::BrowserContext* browser_context,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_devtools_protocol_handler) OVERRIDE;
virtual net::URLRequestContextGetter* CreateRequestContextForStoragePartition(
content::BrowserContext* browser_context,
const base::FilePath& partition_path,
bool in_memory,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
chrome_devtools_protocol_handler) OVERRIDE;
virtual void AppendExtraCommandLineSwitches(CommandLine* command_line,
int child_process_id) OVERRIDE;
virtual content::QuotaPermissionContext*
@ -102,6 +129,9 @@ class CefContentBrowserClient : public content::ContentBrowserClient {
void set_last_create_window_params(const LastCreateWindowParams& params);
private:
CefBrowserContext* CefBrowserContextForBrowserContext(
content::BrowserContext* content_browser_context);
CefBrowserMainParts* browser_main_parts_;
scoped_ptr<CefMediaObserver> media_observer_;

View File

@ -184,12 +184,12 @@ bool CefContext::Initialize(const CefMainArgs& args,
init_thread_id_ = base::PlatformThread::CurrentId();
settings_ = settings;
cache_path_ = FilePath(CefString(&settings.cache_path));
cache_path_ = base::FilePath(CefString(&settings.cache_path));
if (!cache_path_.empty() &&
!file_util::DirectoryExists(cache_path_) &&
!file_util::CreateDirectory(cache_path_)) {
NOTREACHED() << "The cache_path directory could not be created";
cache_path_ = FilePath();
cache_path_ = base::FilePath();
}
if (cache_path_.empty()) {
// Create and use a temporary directory.

View File

@ -18,6 +18,7 @@
#include "base/memory/scoped_ptr.h"
#include "base/threading/platform_thread.h"
#include "net/proxy/proxy_config_service.h"
#include "net/url_request/url_request_context_getter.h"
namespace base {
class WaitableEvent;
@ -60,13 +61,20 @@ class CefContext : public CefBase {
// Retrieve the path at which cache data will be stored on disk. If empty,
// cache data will be stored in-memory.
const FilePath& cache_path() const { return cache_path_; }
const base::FilePath& cache_path() const { return cache_path_; }
const CefSettings& settings() const { return settings_; }
CefRefPtr<CefApp> application() const;
CefBrowserContext* browser_context() const;
CefDevToolsDelegate* devtools_delegate() const;
scoped_refptr<net::URLRequestContextGetter> request_context() const {
return request_context_;
}
void set_request_context(scoped_refptr<net::URLRequestContextGetter> context) {
request_context_ = context;
}
// Passes ownership.
scoped_ptr<net::ProxyConfigService> proxy_config_service() const;
@ -90,13 +98,15 @@ class CefContext : public CefBase {
base::PlatformThreadId init_thread_id_;
CefSettings settings_;
FilePath cache_path_;
base::FilePath cache_path_;
base::ScopedTempDir cache_temp_dir_;
scoped_ptr<CefMainDelegate> main_delegate_;
scoped_ptr<content::ContentMainRunner> main_runner_;
scoped_ptr<CefTraceSubscriber> trace_subscriber_;
scoped_refptr<net::URLRequestContextGetter> request_context_;
IMPLEMENT_REFCOUNTING(CefContext);
IMPLEMENT_LOCKING(CefContext);
};

View File

@ -109,9 +109,9 @@ void CefCookieManagerImpl::SetSupportedSchemes(
if (is_global_) {
// Global changes are handled by the request context.
CefURLRequestContextGetter* getter =
scoped_refptr<CefURLRequestContextGetter> getter =
static_cast<CefURLRequestContextGetter*>(
_Context->browser_context()->GetRequestContext());
_Context->request_context().get());
std::vector<std::string> scheme_vec;
std::vector<CefString>::const_iterator it = schemes.begin();
@ -256,15 +256,15 @@ bool CefCookieManagerImpl::SetStoragePath(
const CefString& path,
bool persist_session_cookies) {
if (CEF_CURRENTLY_ON_IOT()) {
FilePath new_path;
base::FilePath new_path;
if (!path.empty())
new_path = FilePath(path);
new_path = base::FilePath(path);
if (is_global_) {
// Global path changes are handled by the request context.
CefURLRequestContextGetter* getter =
scoped_refptr<CefURLRequestContextGetter> getter =
static_cast<CefURLRequestContextGetter*>(
_Context->browser_context()->GetRequestContext());
_Context->request_context().get());
getter->SetCookieStoragePath(new_path, persist_session_cookies);
cookie_monster_ = getter->GetURLRequestContext()->cookie_store()->
GetCookieMonster();
@ -284,7 +284,7 @@ bool CefCookieManagerImpl::SetStoragePath(
base::ThreadRestrictions::ScopedAllowIO allow_io;
if (file_util::DirectoryExists(new_path) ||
file_util::CreateDirectory(new_path)) {
const FilePath& cookie_path = new_path.AppendASCII("Cookies");
const base::FilePath& cookie_path = new_path.AppendASCII("Cookies");
persistent_store =
new SQLitePersistentCookieStore(cookie_path,
persist_session_cookies,
@ -343,8 +343,8 @@ bool CefCookieManagerImpl::FlushStore(CefRefPtr<CefCompletionHandler> handler) {
void CefCookieManagerImpl::SetGlobal() {
if (CEF_CURRENTLY_ON_IOT()) {
if (_Context->browser_context()) {
cookie_monster_ = _Context->browser_context()->GetRequestContext()->
GetURLRequestContext()->cookie_store()->GetCookieMonster();
cookie_monster_ = _Context->request_context()->GetURLRequestContext()->
cookie_store()->GetCookieMonster();
DCHECK(cookie_monster_);
}
} else {

View File

@ -44,7 +44,7 @@ class CefCookieManagerImpl : public CefCookieManager {
scoped_refptr<net::CookieMonster> cookie_monster_;
bool is_global_;
FilePath storage_path_;
base::FilePath storage_path_;
std::vector<CefString> supported_schemes_;
IMPLEMENT_REFCOUNTING(CefCookieManagerImpl);

View File

@ -145,8 +145,8 @@ bool CefDevToolsDelegate::BundlesFrontendResources() {
return true;
}
FilePath CefDevToolsDelegate::GetDebugFrontendDir() {
return FilePath();
base::FilePath CefDevToolsDelegate::GetDebugFrontendDir() {
return base::FilePath();
}
std::string CefDevToolsDelegate::GetPageThumbnailData(const GURL& url) {
@ -157,6 +157,11 @@ content::RenderViewHost* CefDevToolsDelegate::CreateNewTarget() {
return NULL;
}
content::DevToolsHttpHandlerDelegate::TargetType
CefDevToolsDelegate::GetTargetType(content::RenderViewHost*) {
return kTargetTypeTab;
}
std::string CefDevToolsDelegate::GetDevToolsURL(content::RenderViewHost* rvh,
bool http_scheme) {
const CommandLine& command_line = *CommandLine::ForCurrentProcess();

View File

@ -58,9 +58,10 @@ class CefDevToolsDelegate : public content::DevToolsHttpHandlerDelegate {
// DevToolsHttpProtocolHandler::Delegate overrides.
virtual std::string GetDiscoveryPageHTML() OVERRIDE;
virtual bool BundlesFrontendResources() OVERRIDE;
virtual FilePath GetDebugFrontendDir() OVERRIDE;
virtual base::FilePath GetDebugFrontendDir() OVERRIDE;
virtual std::string GetPageThumbnailData(const GURL& url) OVERRIDE;
virtual content::RenderViewHost* CreateNewTarget() OVERRIDE;
virtual TargetType GetTargetType(content::RenderViewHost*) OVERRIDE;
// Returns the DevTools URL for the specified RenderViewHost.
std::string GetDevToolsURL(content::RenderViewHost* rvh, bool http_scheme);

View File

@ -54,7 +54,7 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
CefBeforeDownloadCallbackImpl(
const base::WeakPtr<DownloadManager>& manager,
int32 download_id,
const FilePath& suggested_name,
const base::FilePath& suggested_name,
const content::DownloadTargetCallback& callback)
: manager_(manager),
download_id_(download_id),
@ -69,7 +69,7 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
return;
if (manager_) {
FilePath path = FilePath(download_path);
base::FilePath path = base::FilePath(download_path);
CEF_POST_TASK(CEF_FILET,
base::Bind(&CefBeforeDownloadCallbackImpl::GenerateFilename,
manager_, download_id_, suggested_name_, path,
@ -89,14 +89,14 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
static void GenerateFilename(
base::WeakPtr<DownloadManager> manager,
int32 download_id,
const FilePath& suggested_name,
const FilePath& download_path,
const base::FilePath& suggested_name,
const base::FilePath& download_path,
bool show_dialog,
const content::DownloadTargetCallback& callback) {
FilePath suggested_path = download_path;
base::FilePath suggested_path = download_path;
if (!suggested_path.empty()) {
// Create the directory if necessary.
FilePath dir_path = suggested_path.DirName();
base::FilePath dir_path = suggested_path.DirName();
if (!file_util::DirectoryExists(dir_path) &&
!file_util::CreateDirectory(dir_path)) {
NOTREACHED() << "failed to create the download directory";
@ -123,7 +123,7 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
static void ChooseDownloadPath(
base::WeakPtr<DownloadManager> manager,
int32 download_id,
const FilePath& suggested_path,
const base::FilePath& suggested_path,
bool show_dialog,
const content::DownloadTargetCallback& callback) {
if (!manager)
@ -169,10 +169,10 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
static void ChooseDownloadPathCallback(
const content::DownloadTargetCallback& callback,
const std::vector<FilePath>& file_paths) {
const std::vector<base::FilePath>& file_paths) {
DCHECK_LE(file_paths.size(), (size_t) 1);
FilePath path;
base::FilePath path;
if (file_paths.size() > 0)
path = file_paths.front();
@ -185,7 +185,7 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
base::WeakPtr<DownloadManager> manager_;
int32 download_id_;
FilePath suggested_name_;
base::FilePath suggested_name_;
content::DownloadTargetCallback callback_;
IMPLEMENT_REFCOUNTING(CefBeforeDownloadCallbackImpl);
@ -319,7 +319,7 @@ bool CefDownloadManagerDelegate::DetermineDownloadTarget(
handler = GetDownloadHandler(browser);
if (handler.get()) {
FilePath suggested_name = net::GenerateFileName(
base::FilePath suggested_name = net::GenerateFileName(
item->GetURL(),
item->GetContentDisposition(),
EmptyString(),

View File

@ -7,7 +7,7 @@
#define CEF_LIBCEF_BROWSER_JAVASCRIPT_DIALOG_H_
#pragma once
#include "content/public/browser/javascript_dialogs.h"
#include "content/public/browser/javascript_dialog_manager.h"
#if defined(TOOLKIT_GTK)
#include "ui/base/gtk/gtk_signal.h"
@ -21,17 +21,17 @@ class CefJavaScriptDialogHelper;
#endif // __OBJC__
#endif // defined(OS_MACOSX)
class CefJavaScriptDialogCreator;
class CefJavaScriptDialogManager;
class CefJavaScriptDialog {
public:
CefJavaScriptDialog(
CefJavaScriptDialogCreator* creator,
CefJavaScriptDialogManager* creator,
content::JavaScriptMessageType message_type,
const string16& display_url,
const string16& message_text,
const string16& default_prompt_text,
const content::JavaScriptDialogCreator::DialogClosedCallback& callback);
const content::JavaScriptDialogManager::DialogClosedCallback& callback);
~CefJavaScriptDialog();
// Called to cancel a dialog mid-flight.
@ -41,8 +41,8 @@ class CefJavaScriptDialog {
void Activate();
private:
CefJavaScriptDialogCreator* creator_;
content::JavaScriptDialogCreator::DialogClosedCallback callback_;
CefJavaScriptDialogManager* creator_;
content::JavaScriptDialogManager::DialogClosedCallback callback_;
#if defined(OS_MACOSX)
CefJavaScriptDialogHelper* helper_; // owned

View File

@ -5,7 +5,7 @@
#include "libcef/browser/javascript_dialog.h"
#include "libcef/browser/browser_host_impl.h"
#include "libcef/browser/javascript_dialog_creator.h"
#include "libcef/browser/javascript_dialog_manager.h"
#include <gtk/gtk.h>
@ -30,12 +30,12 @@ string16 GetPromptText(GtkDialog* dialog) {
} // namespace
CefJavaScriptDialog::CefJavaScriptDialog(
CefJavaScriptDialogCreator* creator,
CefJavaScriptDialogManager* creator,
content::JavaScriptMessageType message_type,
const string16& display_url,
const string16& message_text,
const string16& default_prompt_text,
const content::JavaScriptDialogCreator::DialogClosedCallback& callback)
const content::JavaScriptDialogManager::DialogClosedCallback& callback)
: creator_(creator),
callback_(callback) {
GtkButtonsType buttons = GTK_BUTTONS_NONE;

View File

@ -4,7 +4,7 @@
// found in the LICENSE file.
#include "libcef/browser/javascript_dialog.h"
#include "libcef/browser/javascript_dialog_creator.h"
#include "libcef/browser/javascript_dialog_manager.h"
#import <Cocoa/Cocoa.h>
@ -20,12 +20,12 @@
NSTextField* textField_; // WEAK; owned by alert_
// Copies of the fields in CefJavaScriptDialog because they're private.
CefJavaScriptDialogCreator* creator_;
content::JavaScriptDialogCreator::DialogClosedCallback callback_;
CefJavaScriptDialogManager* creator_;
content::JavaScriptDialogManager::DialogClosedCallback callback_;
}
- (id)initHelperWithCreator:(CefJavaScriptDialogCreator*)creator
andCallback:(content::JavaScriptDialogCreator::DialogClosedCallback)callback;
- (id)initHelperWithCreator:(CefJavaScriptDialogManager*)creator
andCallback:(content::JavaScriptDialogManager::DialogClosedCallback)callback;
- (NSAlert*)alert;
- (NSTextField*)textField;
- (void)alertDidEnd:(NSAlert*)alert
@ -37,8 +37,8 @@
@implementation CefJavaScriptDialogHelper
- (id)initHelperWithCreator:(CefJavaScriptDialogCreator*)creator
andCallback:(content::JavaScriptDialogCreator::DialogClosedCallback)callback {
- (id)initHelperWithCreator:(CefJavaScriptDialogManager*)creator
andCallback:(content::JavaScriptDialogManager::DialogClosedCallback)callback {
if (self = [super init]) {
creator_ = creator;
callback_ = callback;
@ -86,12 +86,12 @@
@end
CefJavaScriptDialog::CefJavaScriptDialog(
CefJavaScriptDialogCreator* creator,
CefJavaScriptDialogManager* creator,
content::JavaScriptMessageType message_type,
const string16& display_url,
const string16& message_text,
const string16& default_prompt_text,
const content::JavaScriptDialogCreator::DialogClosedCallback& callback)
const content::JavaScriptDialogManager::DialogClosedCallback& callback)
: creator_(creator),
callback_(callback) {
bool text_field =

View File

@ -3,7 +3,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "libcef/browser/javascript_dialog_creator.h"
#include "libcef/browser/javascript_dialog_manager.h"
#include "libcef/browser/browser_host_impl.h"
#include "libcef/browser/javascript_dialog.h"
#include "libcef/browser/thread_util.h"
@ -18,7 +18,7 @@ namespace {
class CefJSDialogCallbackImpl : public CefJSDialogCallback {
public:
CefJSDialogCallbackImpl(
const content::JavaScriptDialogCreator::DialogClosedCallback& callback)
const content::JavaScriptDialogManager::DialogClosedCallback& callback)
: callback_(callback) {
}
~CefJSDialogCallbackImpl() {
@ -53,12 +53,12 @@ class CefJSDialogCallbackImpl : public CefJSDialogCallback {
private:
static void CancelNow(
const content::JavaScriptDialogCreator::DialogClosedCallback& callback) {
const content::JavaScriptDialogManager::DialogClosedCallback& callback) {
CEF_REQUIRE_UIT();
callback.Run(false, string16());
}
content::JavaScriptDialogCreator::DialogClosedCallback callback_;
content::JavaScriptDialogManager::DialogClosedCallback callback_;
IMPLEMENT_REFCOUNTING(CefJSDialogCallbackImpl);
};
@ -66,15 +66,15 @@ class CefJSDialogCallbackImpl : public CefJSDialogCallback {
} // namespace
CefJavaScriptDialogCreator::CefJavaScriptDialogCreator(
CefJavaScriptDialogManager::CefJavaScriptDialogManager(
CefBrowserHostImpl* browser)
: browser_(browser) {
}
CefJavaScriptDialogCreator::~CefJavaScriptDialogCreator() {
CefJavaScriptDialogManager::~CefJavaScriptDialogManager() {
}
void CefJavaScriptDialogCreator::RunJavaScriptDialog(
void CefJavaScriptDialogManager::RunJavaScriptDialog(
content::WebContents* web_contents,
const GURL& origin_url,
const std::string& accept_lang,
@ -131,7 +131,7 @@ void CefJavaScriptDialogCreator::RunJavaScriptDialog(
#endif
}
void CefJavaScriptDialogCreator::RunBeforeUnloadDialog(
void CefJavaScriptDialogManager::RunBeforeUnloadDialog(
content::WebContents* web_contents,
const string16& message_text,
bool is_reload,
@ -178,7 +178,7 @@ void CefJavaScriptDialogCreator::RunBeforeUnloadDialog(
#endif
}
void CefJavaScriptDialogCreator::ResetJavaScriptState(
void CefJavaScriptDialogManager::ResetJavaScriptState(
content::WebContents* web_contents) {
CefRefPtr<CefClient> client = browser_->GetClient();
if (client.get()) {
@ -197,7 +197,7 @@ void CefJavaScriptDialogCreator::ResetJavaScriptState(
#endif
}
void CefJavaScriptDialogCreator::DialogClosed(CefJavaScriptDialog* dialog) {
void CefJavaScriptDialogManager::DialogClosed(CefJavaScriptDialog* dialog) {
#if defined(OS_MACOSX) || defined(OS_WIN) || defined(TOOLKIT_GTK)
DCHECK_EQ(dialog, dialog_.get());
dialog_.reset();

View File

@ -3,25 +3,25 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CEF_LIBCEF_BROWSER_JAVASCRIPT_DIALOG_CREATOR_H_
#define CEF_LIBCEF_BROWSER_JAVASCRIPT_DIALOG_CREATOR_H_
#ifndef CEF_LIBCEF_BROWSER_JAVASCRIPT_DIALOG_MANAGER_H_
#define CEF_LIBCEF_BROWSER_JAVASCRIPT_DIALOG_MANAGER_H_
#pragma once
#include <string>
#include "base/compiler_specific.h"
#include "base/memory/scoped_ptr.h"
#include "content/public/browser/javascript_dialogs.h"
#include "content/public/browser/javascript_dialog_manager.h"
class CefBrowserHostImpl;
class CefJavaScriptDialog;
class CefJavaScriptDialogCreator : public content::JavaScriptDialogCreator {
class CefJavaScriptDialogManager : public content::JavaScriptDialogManager {
public:
explicit CefJavaScriptDialogCreator(CefBrowserHostImpl* browser);
virtual ~CefJavaScriptDialogCreator();
explicit CefJavaScriptDialogManager(CefBrowserHostImpl* browser);
virtual ~CefJavaScriptDialogManager();
// JavaScriptDialogCreator methods.
// JavaScriptDialogManager methods.
virtual void RunJavaScriptDialog(
content::WebContents* web_contents,
const GURL& origin_url,
@ -47,7 +47,7 @@ class CefJavaScriptDialogCreator : public content::JavaScriptDialogCreator {
CefBrowserHostImpl* browser() const { return browser_; }
private:
// This pointer is guaranteed to outlive the CefJavaScriptDialogCreator.
// This pointer is guaranteed to outlive the CefJavaScriptDialogManager.
CefBrowserHostImpl* browser_;
#if defined(OS_MACOSX) || defined(OS_WIN) || defined(TOOLKIT_GTK)
@ -55,7 +55,7 @@ class CefJavaScriptDialogCreator : public content::JavaScriptDialogCreator {
scoped_ptr<CefJavaScriptDialog> dialog_;
#endif
DISALLOW_COPY_AND_ASSIGN(CefJavaScriptDialogCreator);
DISALLOW_COPY_AND_ASSIGN(CefJavaScriptDialogManager);
};
#endif // CEF_LIBCEF_BROWSER_JAVASCRIPT_DIALOG_CREATOR_H_
#endif // CEF_LIBCEF_BROWSER_JAVASCRIPT_DIALOG_MANAGER_H_

View File

@ -4,7 +4,7 @@
// found in the LICENSE file.
#include "libcef/browser/javascript_dialog.h"
#include "libcef/browser/javascript_dialog_creator.h"
#include "libcef/browser/javascript_dialog_manager.h"
#include "libcef/browser/browser_host_impl.h"
#include "libcef_dll/resource.h"
@ -86,12 +86,12 @@ INT_PTR CALLBACK CefJavaScriptDialog::DialogProc(HWND dialog,
}
CefJavaScriptDialog::CefJavaScriptDialog(
CefJavaScriptDialogCreator* creator,
CefJavaScriptDialogManager* creator,
content::JavaScriptMessageType message_type,
const string16& display_url,
const string16& message_text,
const string16& default_prompt_text,
const content::JavaScriptDialogCreator::DialogClosedCallback& callback)
const content::JavaScriptDialogManager::DialogClosedCallback& callback)
: creator_(creator),
callback_(callback),
message_text_(message_text),
@ -107,7 +107,7 @@ CefJavaScriptDialog::CefJavaScriptDialog(
else // JAVASCRIPT_MESSAGE_TYPE_PROMPT
dialog_type = IDD_PROMPT;
FilePath file_path;
base::FilePath file_path;
HMODULE hModule = NULL;
// Try to load the dialog from the DLL.

View File

@ -16,7 +16,7 @@ CefMenuCreatorRunnerWin::CefMenuCreatorRunnerWin() {
bool CefMenuCreatorRunnerWin::RunContextMenu(CefMenuCreator* manager) {
// Create a menu based on the model.
menu_.reset(new views::NativeMenuWin(manager->model(), NULL));
menu_->Rebuild();
menu_->Rebuild(NULL);
// Make sure events can be pumped while the menu is up.
MessageLoop::ScopedNestableTaskAllower allow(MessageLoop::current());

View File

@ -14,7 +14,7 @@
#include "content/public/common/referrer.h"
#include "googleurl/src/gurl.h"
#include "net/base/upload_data.h"
#include "webkit/glue/window_open_disposition.h"
#include "ui/base/window_open_disposition.h"
// Parameters that tell CefBrowserHostImpl::Navigate() what to do.
struct CefNavigateParams {

View File

@ -34,7 +34,7 @@ bool CefGetPath(PathKey key, CefString& path) {
return false;
}
FilePath file_path;
base::FilePath file_path;
if (PathService::Get(pref_key, &file_path)) {
path = file_path.value();
return true;

View File

@ -2,11 +2,13 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chrome/browser/prefs/pref_service_syncable.h"
#include "base/logging.h"
#include "chrome/browser/prefs/pref_registry_syncable.h"
// Required by PrefProxyConfigTrackerImpl::RegisterUserPrefs.
void PrefServiceSyncable::RegisterDictionaryPref(const char* path,
DictionaryValue* default_value,
PrefSyncStatus sync_status) {
void PrefRegistrySyncable::RegisterDictionaryPref(
const char* path,
base::DictionaryValue* default_value,
PrefSyncStatus sync_status) {
NOTREACHED();
}

View File

@ -12,6 +12,11 @@
#include "content/public/browser/content_browser_client.h"
#include "content/public/browser/render_view_host.h"
#include "content/public/common/content_client.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebScreenInfo.h"
#if defined(OS_WIN)
#include "third_party/WebKit/Source/WebKit/chromium/public/win/WebScreenInfoFactory.h"
#endif
#include "webkit/glue/webcursor.h"
@ -205,6 +210,13 @@ void CefRenderWidgetHostViewOSR::WillWmDestroy() {
}
#endif
void CefRenderWidgetHostViewOSR::GetScreenInfo(
WebKit::WebScreenInfo* results) {
#if defined(OS_WIN)
*results = WebKit::WebScreenInfoFactory::screenInfo(GetNativeView());
#endif
}
gfx::Rect CefRenderWidgetHostViewOSR::GetBoundsInRootWindow() {
if (!browser_impl_.get())
return gfx::Rect();
@ -249,8 +261,17 @@ content::BackingStore* CefRenderWidgetHostViewOSR::AllocBackingStore(
void CefRenderWidgetHostViewOSR::CopyFromCompositingSurface(
const gfx::Rect& src_subrect,
const gfx::Size& dst_size,
const base::Callback<void(bool b)>& callback,
skia::PlatformBitmap* output) {
const base::Callback<void(bool, const SkBitmap&)>& callback) {
}
void CefRenderWidgetHostViewOSR::CopyFromCompositingSurfaceToVideoFrame(
const gfx::Rect& src_subrect,
const scoped_refptr<media::VideoFrame>& target,
const base::Callback<void(bool)>& callback) {
}
bool CefRenderWidgetHostViewOSR::CanCopyToVideoFrame() const {
return false;
}
void CefRenderWidgetHostViewOSR::OnAcceleratedCompositingStateChange() {

View File

@ -84,6 +84,7 @@ class CefRenderWidgetHostViewOSR : public content::RenderWidgetHostViewBase {
#if defined(OS_WIN) && !defined(USE_AURA)
virtual void WillWmDestroy() OVERRIDE;
#endif
virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE;
virtual gfx::Rect GetBoundsInRootWindow() OVERRIDE;
virtual void Destroy() OVERRIDE;
virtual void SetTooltipText(const string16& tooltip_text) OVERRIDE;
@ -92,8 +93,12 @@ class CefRenderWidgetHostViewOSR : public content::RenderWidgetHostViewBase {
virtual void CopyFromCompositingSurface(
const gfx::Rect& src_subrect,
const gfx::Size& dst_size,
const base::Callback<void(bool b)>& callback,
skia::PlatformBitmap* output) OVERRIDE;
const base::Callback<void(bool, const SkBitmap&)>& callback) OVERRIDE;
virtual void CopyFromCompositingSurfaceToVideoFrame(
const gfx::Rect& src_subrect,
const scoped_refptr<media::VideoFrame>& target,
const base::Callback<void(bool)>& callback) OVERRIDE;
virtual bool CanCopyToVideoFrame() const OVERRIDE;
virtual void OnAcceleratedCompositingStateChange() OVERRIDE;
virtual void SetHasHorizontalScrollbar(
bool has_horizontal_scrollbar) OVERRIDE;

View File

@ -1,31 +0,0 @@
// Copyright (c) 2012 The Chromium 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 "libcef/browser/resource_context.h"
#include "libcef/browser/thread_util.h"
#include "libcef/browser/url_request_context_getter.h"
CefResourceContext::CefResourceContext(
CefURLRequestContextGetter* getter)
: getter_(getter) {
}
CefResourceContext::~CefResourceContext() {
// Destroy the getter after content::ResourceContext has finished destructing.
// Otherwise, the URLRequestContext objects will be deleted before
// ResourceDispatcherHost has canceled any pending URLRequests.
getter_->AddRef();
content::BrowserThread::ReleaseSoon(
content::BrowserThread::IO, FROM_HERE, getter_.get());
}
net::HostResolver* CefResourceContext::GetHostResolver() {
CEF_REQUIRE_IOT();
return getter_->host_resolver();
}
net::URLRequestContext* CefResourceContext::GetRequestContext() {
CEF_REQUIRE_IOT();
return getter_->GetURLRequestContext();
}

View File

@ -1,31 +0,0 @@
// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CEF_LIBCEF_BROWSER_RESOURCE_CONTEXT_H_
#define CEF_LIBCEF_BROWSER_RESOURCE_CONTEXT_H_
#pragma once
#include "base/compiler_specific.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "content/public/browser/resource_context.h"
class CefURLRequestContextGetter;
class CefResourceContext : public content::ResourceContext {
public:
explicit CefResourceContext(CefURLRequestContextGetter* getter);
virtual ~CefResourceContext();
private:
// ResourceContext methods.
virtual net::HostResolver* GetHostResolver() OVERRIDE;
virtual net::URLRequestContext* GetRequestContext() OVERRIDE;
scoped_refptr<CefURLRequestContextGetter> getter_;
DISALLOW_COPY_AND_ASSIGN(CefResourceContext);
};
#endif // CEF_LIBCEF_BROWSER_RESOURCE_CONTEXT_H_

View File

@ -127,7 +127,7 @@ class CefUrlRequestManager {
net::URLRequestJobFactory* GetJobFactory() {
return const_cast<net::URLRequestJobFactory*>(
static_cast<CefURLRequestContextGetter*>(
_Context->browser_context()->GetRequestContext())->
_Context->request_context().get())->
GetURLRequestContext()->job_factory());
}

View File

@ -208,7 +208,7 @@ bool CefNetworkDelegate::OnCanSetCookie(const net::URLRequest& request,
}
bool CefNetworkDelegate::OnCanAccessFile(const net::URLRequest& request,
const FilePath& path) const {
const base::FilePath& path) const {
return true;
}

View File

@ -51,7 +51,7 @@ class CefNetworkDelegate : public net::NetworkDelegate {
const std::string& cookie_line,
net::CookieOptions* options) OVERRIDE;
virtual bool OnCanAccessFile(const net::URLRequest& request,
const FilePath& path) const OVERRIDE;
const base::FilePath& path) const OVERRIDE;
virtual bool OnCanThrottleRequest(
const net::URLRequest& request) const OVERRIDE;
virtual int OnBeforeSocketStreamConnect(

View File

@ -29,6 +29,7 @@
#include "chrome/browser/net/sqlite_persistent_cookie_store.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/common/content_switches.h"
#include "content/public/common/url_constants.h"
#include "net/base/cert_verifier.h"
#include "net/base/default_server_bound_cert_store.h"
#include "net/base/host_resolver.h"
@ -40,6 +41,7 @@
#include "net/http/http_cache.h"
#include "net/http/http_server_properties_impl.h"
#include "net/proxy/proxy_service.h"
#include "net/url_request/protocol_intercept_job_factory.h"
#include "net/url_request/static_http_user_agent_settings.h"
#include "net/url_request/url_request.h"
#include "net/url_request/url_request_context.h"
@ -55,9 +57,18 @@ using content::BrowserThread;
CefURLRequestContextGetter::CefURLRequestContextGetter(
MessageLoop* io_loop,
MessageLoop* file_loop)
MessageLoop* file_loop,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler)
: io_loop_(io_loop),
file_loop_(file_loop) {
file_loop_(file_loop),
blob_protocol_handler_(blob_protocol_handler.Pass()),
file_system_protocol_handler_(file_system_protocol_handler.Pass()),
developer_protocol_handler_(developer_protocol_handler.Pass()) {
// Must first be created on the UI thread.
CEF_REQUIRE_UIT();
}
@ -71,7 +82,7 @@ net::URLRequestContext* CefURLRequestContextGetter::GetURLRequestContext() {
CEF_REQUIRE_IOT();
if (!url_request_context_.get()) {
const FilePath& cache_path = _Context->cache_path();
const base::FilePath& cache_path = _Context->cache_path();
const CommandLine& command_line = *CommandLine::ForCurrentProcess();
const CefSettings& settings = _Context->settings();
@ -162,7 +173,17 @@ net::URLRequestContext* CefURLRequestContextGetter::GetURLRequestContext() {
storage_->set_ftp_transaction_factory(
new net::FtpNetworkLayer(url_request_context_->host_resolver()));
storage_->set_job_factory(new net::URLRequestJobFactoryImpl);
scoped_ptr<net::URLRequestJobFactoryImpl> job_factory(
new net::URLRequestJobFactoryImpl());
bool set_protocol = job_factory->SetProtocolHandler(
chrome::kBlobScheme, blob_protocol_handler_.release());
DCHECK(set_protocol);
set_protocol = job_factory->SetProtocolHandler(
chrome::kFileSystemScheme, file_system_protocol_handler_.release());
DCHECK(set_protocol);
storage_->set_job_factory(new net::ProtocolInterceptJobFactory(
job_factory.PassAs<net::URLRequestJobFactory>(),
developer_protocol_handler_.Pass()));
request_interceptor_.reset(new CefRequestInterceptor);
}
@ -180,7 +201,7 @@ net::HostResolver* CefURLRequestContextGetter::host_resolver() {
}
void CefURLRequestContextGetter::SetCookieStoragePath(
const FilePath& path,
const base::FilePath& path,
bool persist_session_cookies) {
CEF_REQUIRE_IOT();
@ -198,7 +219,7 @@ void CefURLRequestContextGetter::SetCookieStoragePath(
base::ThreadRestrictions::ScopedAllowIO allow_io;
if (file_util::DirectoryExists(path) ||
file_util::CreateDirectory(path)) {
const FilePath& cookie_path = path.AppendASCII("Cookies");
const base::FilePath& cookie_path = path.AppendASCII("Cookies");
persistent_store =
new SQLitePersistentCookieStore(cookie_path,
persist_session_cookies,

View File

@ -15,6 +15,7 @@
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "net/url_request/url_request_context_getter.h"
#include "net/url_request/url_request_job_factory.h"
class CefRequestInterceptor;
class CefURLRequestContextProxy;
@ -73,7 +74,13 @@ class CefURLRequestContextGetter : public net::URLRequestContextGetter {
public:
CefURLRequestContextGetter(
MessageLoop* io_loop,
MessageLoop* file_loop);
MessageLoop* file_loop,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler,
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler);
virtual ~CefURLRequestContextGetter();
// net::URLRequestContextGetter implementation.
@ -83,7 +90,7 @@ class CefURLRequestContextGetter : public net::URLRequestContextGetter {
net::HostResolver* host_resolver();
void SetCookieStoragePath(const FilePath& path,
void SetCookieStoragePath(const base::FilePath& path,
bool persist_session_cookies);
void SetCookieSupportedSchemes(const std::vector<std::string>& schemes);
@ -104,11 +111,17 @@ class CefURLRequestContextGetter : public net::URLRequestContextGetter {
scoped_ptr<net::URLRequestContextStorage> storage_;
scoped_ptr<net::URLRequestContext> url_request_context_;
scoped_ptr<net::URLSecurityManager> url_security_manager_;
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
blob_protocol_handler_;
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
file_system_protocol_handler_;
scoped_ptr<net::URLRequestJobFactory::ProtocolHandler>
developer_protocol_handler_;
typedef std::set<CefURLRequestContextProxy*> RequestContextProxySet;
RequestContextProxySet url_request_context_proxies_;
FilePath cookie_store_path_;
base::FilePath cookie_store_path_;
std::vector<std::string> cookie_supported_schemes_;
DISALLOW_COPY_AND_ASSIGN(CefURLRequestContextGetter);

View File

@ -102,7 +102,8 @@ void CefAddWebPluginPath(const CefString& path) {
}
// No thread affinity.
content::PluginServiceImpl::GetInstance()->AddExtraPluginPath(FilePath(path));
content::PluginServiceImpl::GetInstance()->AddExtraPluginPath(
base::FilePath(path));
}
void CefAddWebPluginDirectory(const CefString& dir) {
@ -118,7 +119,8 @@ void CefAddWebPluginDirectory(const CefString& dir) {
}
// No thread affinity.
content::PluginServiceImpl::GetInstance()->AddExtraPluginDir(FilePath(dir));
content::PluginServiceImpl::GetInstance()->AddExtraPluginDir(
base::FilePath(dir));
}
void CefRemoveWebPluginPath(const CefString& path) {
@ -135,7 +137,7 @@ void CefRemoveWebPluginPath(const CefString& path) {
// No thread affinity.
content::PluginServiceImpl::GetInstance()->RemoveExtraPluginPath(
FilePath(path));
base::FilePath(path));
}
void CefUnregisterInternalWebPlugin(const CefString& path) {
@ -152,7 +154,7 @@ void CefUnregisterInternalWebPlugin(const CefString& path) {
// No thread affinity.
content::PluginServiceImpl::GetInstance()->UnregisterInternalPlugin(
FilePath(path));
base::FilePath(path));
}
void CefForceWebPluginShutdown(const CefString& path) {
@ -169,7 +171,7 @@ void CefForceWebPluginShutdown(const CefString& path) {
if (CEF_CURRENTLY_ON_IOT()) {
content::PluginServiceImpl::GetInstance()->ForcePluginShutdown(
FilePath(path));
base::FilePath(path));
} else {
// Execute on the IO thread.
CEF_POST_TASK(CEF_IOT, base::Bind(CefForceWebPluginShutdown, path));
@ -190,7 +192,7 @@ void CefRegisterWebPluginCrash(const CefString& path) {
if (CEF_CURRENTLY_ON_IOT()) {
content::PluginServiceImpl::GetInstance()->RegisterPluginCrash(
FilePath(path));
base::FilePath(path));
} else {
// Execute on the IO thread.
CEF_POST_TASK(CEF_IOT, base::Bind(CefRegisterWebPluginCrash, path));
@ -214,7 +216,7 @@ void CefIsWebPluginUnstable(
if (CEF_CURRENTLY_ON_IOT()) {
callback->IsUnstable(path,
content::PluginServiceImpl::GetInstance()->IsPluginUnstable(
FilePath(path)));
base::FilePath(path)));
} else {
// Execute on the IO thread.
CEF_POST_TASK(CEF_IOT, base::Bind(CefIsWebPluginUnstable, path, callback));

View File

@ -46,7 +46,7 @@ struct ParamTraits<net::UploadElement> {
}
default: {
DCHECK(type == net::UploadElement::TYPE_FILE);
FilePath file_path;
base::FilePath file_path;
uint64 offset, length;
base::Time expected_modification_time;
if (!ReadParam(m, iter, &file_path))

View File

@ -77,7 +77,7 @@ CefString CefCommandLineImpl::GetProgram() {
void CefCommandLineImpl::SetProgram(const CefString& program) {
CEF_VALUE_VERIFY_RETURN_VOID(true);
mutable_value()->SetProgram(FilePath(program));
mutable_value()->SetProgram(base::FilePath(program));
}
bool CefCommandLineImpl::HasSwitches() {

View File

@ -108,20 +108,21 @@ std::string CefContentClient::GetCarbonInterposePath() const {
}
#endif
FilePath CefContentClient::GetPathForResourcePack(
const FilePath& pack_path,
base::FilePath CefContentClient::GetPathForResourcePack(
const base::FilePath& pack_path,
ui::ScaleFactor scale_factor) {
// Only allow the cef pack file to load.
if (!pack_loading_disabled_ && allow_pack_file_load_)
return pack_path;
return FilePath();
return base::FilePath();
}
FilePath CefContentClient::GetPathForLocalePack(const FilePath& pack_path,
const std::string& locale) {
base::FilePath CefContentClient::GetPathForLocalePack(
const base::FilePath& pack_path,
const std::string& locale) {
if (!pack_loading_disabled_)
return pack_path;
return FilePath();
return base::FilePath();
}
gfx::Image CefContentClient::GetImageNamed(int resource_id) {

View File

@ -47,11 +47,12 @@ class CefContentClient : public content::ContentClient,
private:
// ui::ResourceBundle::Delegate methods.
virtual FilePath GetPathForResourcePack(
const FilePath& pack_path,
virtual base::FilePath GetPathForResourcePack(
const base::FilePath& pack_path,
ui::ScaleFactor scale_factor) OVERRIDE;
virtual FilePath GetPathForLocalePack(const FilePath& pack_path,
const std::string& locale) OVERRIDE;
virtual base::FilePath GetPathForLocalePack(
const base::FilePath& pack_path,
const std::string& locale) OVERRIDE;
virtual gfx::Image GetImageNamed(int resource_id) OVERRIDE;
virtual gfx::Image GetNativeImageNamed(
int resource_id,

View File

@ -40,13 +40,13 @@ namespace {
#if defined(OS_MACOSX)
FilePath GetFrameworksPath() {
base::FilePath GetFrameworksPath() {
// Start out with the path to the running executable.
FilePath execPath;
base::FilePath execPath;
PathService::Get(base::FILE_EXE, &execPath);
// Get the main bundle path.
FilePath bundlePath = base::mac::GetAppBundlePath(execPath);
base::FilePath bundlePath = base::mac::GetAppBundlePath(execPath);
// Go into the Contents/Frameworks directory.
return bundlePath.Append(FILE_PATH_LITERAL("Contents"))
@ -54,12 +54,12 @@ FilePath GetFrameworksPath() {
}
// The framework bundle path is used for loading resources, libraries, etc.
FilePath GetFrameworkBundlePath() {
base::FilePath GetFrameworkBundlePath() {
return GetFrameworksPath().Append(
FILE_PATH_LITERAL("Chromium Embedded Framework.framework"));
}
FilePath GetResourcesFilePath() {
base::FilePath GetResourcesFilePath() {
return GetFrameworkBundlePath().Append(FILE_PATH_LITERAL("Resources"));
}
@ -69,12 +69,12 @@ void OverrideFrameworkBundlePath() {
void OverrideChildProcessPath() {
// Retrieve the name of the running executable.
FilePath path;
base::FilePath path;
PathService::Get(base::FILE_EXE, &path);
std::string name = path.BaseName().value();
FilePath helper_path = GetFrameworksPath()
base::FilePath helper_path = GetFrameworksPath()
.Append(FILE_PATH_LITERAL(name+" Helper.app"))
.Append(FILE_PATH_LITERAL("Contents"))
.Append(FILE_PATH_LITERAL("MacOS"))
@ -85,8 +85,8 @@ void OverrideChildProcessPath() {
#else // !defined(OS_MACOSX)
FilePath GetResourcesFilePath() {
FilePath pak_dir;
base::FilePath GetResourcesFilePath() {
base::FilePath pak_dir;
PathService::Get(base::DIR_MODULE, &pak_dir);
return pak_dir;
}
@ -167,8 +167,8 @@ bool CefMainDelegate::BasicStartupComplete(int* exit_code) {
command_line->AppendSwitch(switches::kSingleProcess);
if (settings.browser_subprocess_path.length > 0) {
FilePath file_path =
FilePath(CefString(&settings.browser_subprocess_path));
base::FilePath file_path =
base::FilePath(CefString(&settings.browser_subprocess_path));
if (!file_path.empty()) {
command_line->AppendSwitchPath(switches::kBrowserSubprocessPath,
file_path);
@ -191,7 +191,7 @@ bool CefMainDelegate::BasicStartupComplete(int* exit_code) {
}
if (settings.log_file.length > 0) {
FilePath file_path = FilePath(CefString(&settings.log_file));
base::FilePath file_path = FilePath(CefString(&settings.log_file));
if (!file_path.empty())
command_line->AppendSwitchPath(switches::kLogFile, file_path);
}
@ -236,7 +236,8 @@ bool CefMainDelegate::BasicStartupComplete(int* exit_code) {
command_line->AppendSwitch(switches::kDisablePackLoading);
} else {
if (settings.resources_dir_path.length > 0) {
FilePath file_path = FilePath(CefString(&settings.resources_dir_path));
base::FilePath file_path =
base::FilePath(CefString(&settings.resources_dir_path));
if (!file_path.empty()) {
command_line->AppendSwitchPath(switches::kResourcesDirPath,
file_path);
@ -244,7 +245,8 @@ bool CefMainDelegate::BasicStartupComplete(int* exit_code) {
}
if (settings.locales_dir_path.length > 0) {
FilePath file_path = FilePath(CefString(&settings.locales_dir_path));
base::FilePath file_path =
base::FilePath(CefString(&settings.locales_dir_path));
if (!file_path.empty())
command_line->AppendSwitchPath(switches::kLocalesDirPath, file_path);
}
@ -281,7 +283,8 @@ bool CefMainDelegate::BasicStartupComplete(int* exit_code) {
}
// Initialize logging.
FilePath log_file = command_line->GetSwitchValuePath(switches::kLogFile);
base::FilePath log_file =
command_line->GetSwitchValuePath(switches::kLogFile);
std::string log_severity_str =
command_line->GetSwitchValueASCII(switches::kLogSeverity);
@ -403,10 +406,10 @@ void CefMainDelegate::ShutdownBrowser() {
void CefMainDelegate::InitializeResourceBundle() {
const CommandLine& command_line = *CommandLine::ForCurrentProcess();
FilePath cef_pak_file, devtools_pak_file, locales_dir;
base::FilePath cef_pak_file, devtools_pak_file, locales_dir;
if (!content_client_.pack_loading_disabled()) {
FilePath resources_dir;
base::FilePath resources_dir;
if (command_line.HasSwitch(switches::kResourcesDirPath)) {
resources_dir =
command_line.GetSwitchValuePath(switches::kResourcesDirPath);

View File

@ -17,11 +17,11 @@
#include "net/base/upload_file_element_reader.h"
#include "net/http/http_request_headers.h"
#include "net/url_request/url_request.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebHTTPHeaderVisitor.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLRequest.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLError.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebHTTPHeaderVisitor.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURL.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURLError.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURLRequest.h"
namespace {
@ -703,7 +703,7 @@ void CefPostDataElementImpl::Get(net::UploadElement& element) {
if (type_ == PDE_TYPE_BYTES) {
element.SetToBytes(static_cast<char*>(data_.bytes.bytes), data_.bytes.size);
} else if (type_ == PDE_TYPE_FILE) {
FilePath path = FilePath(CefString(&data_.filename));
base::FilePath path = base::FilePath(CefString(&data_.filename));
element.SetToFilePath(path);
} else {
NOTREACHED();
@ -720,7 +720,7 @@ net::UploadElementReader* CefPostDataElementImpl::Get() {
return new BytesElementReader(make_scoped_ptr(element));
} else if (type_ == PDE_TYPE_FILE) {
net::UploadElement* element = new net::UploadElement();
FilePath path = FilePath(CefString(&data_.filename));
base::FilePath path = base::FilePath(CefString(&data_.filename));
element->SetToFilePath(path);
return new FileElementReader(make_scoped_ptr(element));
} else {

View File

@ -7,7 +7,7 @@
#pragma once
#include "include/cef_request.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebHTTPBody.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebHTTPBody.h"
namespace net {
class HttpRequestHeaders;

View File

@ -10,9 +10,9 @@
#include "base/stringprintf.h"
#include "net/http/http_request_headers.h"
#include "net/http/http_response_headers.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebHTTPHeaderVisitor.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLResponse.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebHTTPHeaderVisitor.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURLResponse.h"
#define CHECK_READONLY_RETURN_VOID() \

View File

@ -24,9 +24,9 @@
#include "content/public/renderer/navigation_state.h"
#include "content/public/renderer/render_view.h"
#include "net/http/http_util.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURL.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURLResponse.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebDataSource.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h"

View File

@ -38,12 +38,12 @@ MSVC_POP_WARNING();
#include "ipc/ipc_sync_channel.h"
#include "media/base/media.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebPrerenderingSupport.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebPrerendererClient.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebRuntimeFeatures.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebSecurityPolicy.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebWorkerInfo.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebWorkerRunLoop.h"
@ -460,7 +460,7 @@ void CefContentRendererClient::RenderThreadStarted() {
// Note that under Linux, the media library will normally already have
// been initialized by the Zygote before this instance became a Renderer.
FilePath media_path;
base::FilePath media_path;
PathService::Get(base::DIR_MODULE, &media_path);
if (!media_path.empty())
media::InitializeMediaLibrary(media_path);

View File

@ -7,13 +7,13 @@
#include "libcef/renderer/thread_util.h"
#include "base/logging.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebElement.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebNode.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebRange.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURL.h"
using WebKit::WebDocument;
using WebKit::WebElement;

View File

@ -7,8 +7,8 @@
#include "libcef/renderer/thread_util.h"
#include "base/logging.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebDOMEvent.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
using WebKit::WebDOMEvent;
using WebKit::WebString;

View File

@ -12,6 +12,7 @@
#include "base/logging.h"
#include "base/string_util.h"
#include "base/utf_string_conversions.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebDOMEvent.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebDOMEventListener.h"
@ -21,7 +22,6 @@
#include "third_party/WebKit/Source/WebKit/chromium/public/WebInputElement.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebNode.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebSelectElement.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
using WebKit::WebDocument;
using WebKit::WebDOMEvent;

View File

@ -13,11 +13,11 @@
#include "libcef/renderer/v8_impl.h"
#include "libcef/renderer/webkit_glue.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebData.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebData.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebScriptSource.h"
#include "webkit/glue/webkit_glue.h"

View File

@ -12,8 +12,8 @@
#include "content/common/devtools_messages.h"
#include "googleurl/src/gurl.h"
#include "googleurl/src/url_util.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebSecurityPolicy.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
CefRenderMessageFilter::CefRenderMessageFilter()
: channel_(NULL) {

View File

@ -7,9 +7,9 @@
#include "libcef/common/cef_messages.h"
#include "libcef/renderer/content_renderer_client.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebSecurityPolicy.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURL.h"
CefRenderProcessObserver::CefRenderProcessObserver() {
}

View File

@ -8,14 +8,14 @@
#include "base/logging.h"
#include "base/message_loop.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURL.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURLError.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURLLoader.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURLLoaderClient.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURLRequest.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURLResponse.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebKitPlatformSupport.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLError.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLLoader.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLLoaderClient.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLRequest.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLResponse.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebKit.h"
using WebKit::WebString;

View File

@ -10,7 +10,7 @@
<release seq="1">
<includes>
<include name="IDR_CEF_DEVTOOLS_DISCOVERY_PAGE" file="devtools_discovery_page.html" type="BINDATA" />
<include name="IDR_CEF_CREDITS_HTML" file="..\..\..\chrome\browser\resources\about_credits.html" type="BINDATA" />
<include name="IDR_CEF_CREDITS_HTML" file="${about_credits_file}" use_base_dir="false" type="BINDATA" />
<include name="IDR_CEF_CREDITS_JS" file="..\..\..\chrome\browser\resources\about_credits.js" type="BINDATA" />
<include name="IDR_CEF_CREDITS_SWIFTSHADER_JPG" file="..\..\..\chrome\browser\resources\swiftshader.jpg" type="BINDATA" />
<include name="IDR_CEF_LICENSE_TXT" file="..\..\LICENSE.txt" type="BINDATA" />

View File

@ -61,7 +61,7 @@ Added: svn:eol-style
Index: WebCore/bindings/v8/WorkerScriptController.cpp
===================================================================
--- WebCore/bindings/v8/WorkerScriptController.cpp (revision 136040)
--- WebCore/bindings/v8/WorkerScriptController.cpp (revision 142426)
+++ WebCore/bindings/v8/WorkerScriptController.cpp (working copy)
@@ -50,11 +50,23 @@
@ -105,7 +105,7 @@ Index: WebCore/bindings/v8/WorkerScriptController.cpp
return true;
}
@@ -256,6 +272,39 @@
@@ -257,6 +273,39 @@
return workerContext->script();
}
@ -147,7 +147,7 @@ Index: WebCore/bindings/v8/WorkerScriptController.cpp
#endif // ENABLE(WORKERS)
Index: WebCore/bindings/v8/WorkerScriptController.h
===================================================================
--- WebCore/bindings/v8/WorkerScriptController.h (revision 136040)
--- WebCore/bindings/v8/WorkerScriptController.h (revision 142426)
+++ WebCore/bindings/v8/WorkerScriptController.h (working copy)
@@ -40,6 +40,10 @@
#include <wtf/Threading.h>
@ -180,7 +180,7 @@ Index: WebCore/bindings/v8/WorkerScriptController.h
ScopedPersistent<v8::Context> m_context;
Index: WebKit/chromium/public/WebWorkerInfo.h
===================================================================
--- WebKit/chromium/public/WebWorkerInfo.h (revision 136040)
--- WebKit/chromium/public/WebWorkerInfo.h (revision 142426)
+++ WebKit/chromium/public/WebWorkerInfo.h (working copy)
@@ -35,9 +35,15 @@
@ -236,7 +236,7 @@ Added: svn:eol-style
Index: WebKit/chromium/src/WebWorkerInfo.cpp
===================================================================
--- WebKit/chromium/src/WebWorkerInfo.cpp (revision 136040)
--- WebKit/chromium/src/WebWorkerInfo.cpp (revision 142426)
+++ WebKit/chromium/src/WebWorkerInfo.cpp (working copy)
@@ -31,6 +31,7 @@
#include "config.h"

View File

@ -24,8 +24,6 @@
<string>10.5.0</string>
<key>LSUIElement</key>
<string>1</string>
<key>NSPrincipalClass</key>
<string>ClientApplication</string>
<key>NSSupportsAutomaticGraphicsSwitching</key>
<true/>
</dict>