Fix compilation warnings due to API changes
This commit is contained in:
parent
289d3b54f3
commit
2c81fb4719
6 changed files with 20 additions and 47 deletions
|
@ -45,18 +45,6 @@ class BrowserContext::ResourceContext : public content::ResourceContext {
|
|||
return getter_->GetURLRequestContext();
|
||||
}
|
||||
|
||||
// FIXME: We should probably allow clients to override this to implement more
|
||||
// restrictive policies.
|
||||
virtual bool AllowMicAccess(const GURL& origin) override {
|
||||
return true;
|
||||
}
|
||||
|
||||
// FIXME: We should probably allow clients to override this to implement more
|
||||
// restrictive policies.
|
||||
virtual bool AllowCameraAccess(const GURL& origin) override {
|
||||
return true;
|
||||
}
|
||||
|
||||
URLRequestContextGetter* getter_;
|
||||
};
|
||||
|
||||
|
@ -80,13 +68,13 @@ void BrowserContext::Initialize() {
|
|||
base::PrefServiceFactory prefs_factory;
|
||||
prefs_factory.SetUserPrefsFile(prefs_path,
|
||||
JsonPrefStore::GetTaskRunnerForFile(
|
||||
prefs_path, BrowserThread::GetBlockingPool()));
|
||||
prefs_path, BrowserThread::GetBlockingPool()).get());
|
||||
|
||||
auto registry = make_scoped_refptr(new PrefRegistrySimple);
|
||||
RegisterInternalPrefs(registry);
|
||||
RegisterPrefs(registry);
|
||||
RegisterInternalPrefs(registry.get());
|
||||
RegisterPrefs(registry.get());
|
||||
|
||||
prefs_ = prefs_factory.Create(registry);
|
||||
prefs_ = prefs_factory.Create(registry.get());
|
||||
}
|
||||
|
||||
BrowserContext::~BrowserContext() {
|
||||
|
@ -102,7 +90,7 @@ void BrowserContext::RegisterInternalPrefs(PrefRegistrySimple* registry) {
|
|||
net::URLRequestContextGetter* BrowserContext::CreateRequestContext(
|
||||
content::ProtocolHandlerMap* protocol_handlers,
|
||||
content::URLRequestInterceptorScopedVector protocol_interceptors) {
|
||||
DCHECK(!url_request_getter_);
|
||||
DCHECK(!url_request_getter_.get());
|
||||
url_request_getter_ = new URLRequestContextGetter(
|
||||
this,
|
||||
GetPath(),
|
||||
|
|
|
@ -68,13 +68,14 @@ class BundledDataSource : public content::URLDataSource {
|
|||
int resource_id =
|
||||
content::DevToolsHttpHandler::GetFrontendResourceId(filename);
|
||||
|
||||
DLOG_IF(WARNING, -1 == resource_id) << "Unable to find dev tool resource: "
|
||||
<< filename << ". If you compiled with debug_devtools=1, try running"
|
||||
" with --debug-devtools.";
|
||||
DLOG_IF(WARNING, resource_id == -1)
|
||||
<< "Unable to find dev tool resource: " << filename
|
||||
<< ". If you compiled with debug_devtools=1, try running with "
|
||||
"--debug-devtools.";
|
||||
const ResourceBundle& rb = ResourceBundle::GetSharedInstance();
|
||||
scoped_refptr<base::RefCountedStaticMemory> bytes(rb.LoadDataResourceBytes(
|
||||
resource_id));
|
||||
callback.Run(bytes);
|
||||
callback.Run(bytes.get());
|
||||
}
|
||||
|
||||
virtual std::string GetMimeType(const std::string& path) const override {
|
||||
|
|
|
@ -21,8 +21,6 @@ using namespace brightray;
|
|||
devtools_docked_ = NO;
|
||||
|
||||
auto contents = inspectableWebContentsView_->inspectable_web_contents()->GetWebContents();
|
||||
contents->SetAllowOverlappingViews(true);
|
||||
|
||||
auto contentsView = contents->GetNativeView();
|
||||
[contentsView setAutoresizingMask:NSViewWidthSizable | NSViewHeightSizable];
|
||||
[self addSubview:contentsView];
|
||||
|
@ -45,9 +43,17 @@ using namespace brightray;
|
|||
if (visible == devtools_visible_)
|
||||
return;
|
||||
|
||||
auto webContents = inspectableWebContentsView_->inspectable_web_contents()->GetWebContents();
|
||||
auto devToolsWebContents = inspectableWebContentsView_->inspectable_web_contents()->devtools_web_contents();
|
||||
auto devToolsView = devToolsWebContents->GetNativeView();
|
||||
|
||||
if (visible && devtools_docked_) {
|
||||
webContents->SetAllowOtherViews(true);
|
||||
devToolsWebContents->SetAllowOtherViews(true);
|
||||
} else {
|
||||
webContents->SetAllowOtherViews(false);
|
||||
}
|
||||
|
||||
devtools_visible_ = visible;
|
||||
if (devtools_docked_) {
|
||||
if (visible) {
|
||||
|
|
|
@ -142,19 +142,6 @@ void MediaCaptureDevicesDispatcher::OnMediaRequestStateChanged(
|
|||
content::MediaRequestState state) {
|
||||
}
|
||||
|
||||
void MediaCaptureDevicesDispatcher::OnAudioStreamPlaying(
|
||||
int render_process_id,
|
||||
int render_frame_id,
|
||||
int stream_id,
|
||||
const ReadPowerAndClipCallback& power_read_callback) {
|
||||
}
|
||||
|
||||
void MediaCaptureDevicesDispatcher::OnAudioStreamStopped(
|
||||
int render_process_id,
|
||||
int render_frame_id,
|
||||
int stream_id) {
|
||||
}
|
||||
|
||||
void MediaCaptureDevicesDispatcher::OnCreatingAudioStream(
|
||||
int render_process_id,
|
||||
int render_view_id) {
|
||||
|
|
|
@ -60,15 +60,6 @@ class MediaCaptureDevicesDispatcher : public content::MediaObserver {
|
|||
const GURL& security_origin,
|
||||
content::MediaStreamType stream_type,
|
||||
content::MediaRequestState state) override;
|
||||
virtual void OnAudioStreamPlaying(
|
||||
int render_process_id,
|
||||
int render_frame_id,
|
||||
int stream_id,
|
||||
const ReadPowerAndClipCallback& power_read_callback) override;
|
||||
virtual void OnAudioStreamStopped(
|
||||
int render_process_id,
|
||||
int render_frame_id,
|
||||
int stream_id) override;
|
||||
virtual void OnCreatingAudioStream(int render_process_id,
|
||||
int render_view_id) override;
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@
|
|||
#include "net/url_request/url_request_intercepting_job_factory.h"
|
||||
#include "net/url_request/url_request_job_factory_impl.h"
|
||||
#include "url/url_constants.h"
|
||||
#include "webkit/browser/quota/special_storage_policy.h"
|
||||
#include "storage/browser/quota/special_storage_policy.h"
|
||||
|
||||
using content::BrowserThread;
|
||||
|
||||
|
@ -120,7 +120,7 @@ URLRequestContextGetter::URLRequestContextGetter(
|
|||
// must synchronously run on the glib message loop. This will be passed to
|
||||
// the URLRequestContextStorage on the IO thread in GetURLRequestContext().
|
||||
proxy_config_service_.reset(net::ProxyService::CreateSystemProxyConfigService(
|
||||
io_loop_->message_loop_proxy(), file_loop_));
|
||||
io_loop_->message_loop_proxy(), file_loop_->message_loop_proxy()));
|
||||
}
|
||||
|
||||
URLRequestContextGetter::~URLRequestContextGetter() {
|
||||
|
|
Loading…
Reference in a new issue