Work around http://crbug.com/279472 for devtools views

This commit is contained in:
Adam Roben 2013-10-10 14:07:20 -04:00
parent c0e744db78
commit 8ae459e9fa

View file

@ -58,6 +58,12 @@ content::WebContents* InspectableWebContentsImpl::GetWebContents() const {
void InspectableWebContentsImpl::ShowDevTools() { void InspectableWebContentsImpl::ShowDevTools() {
if (!devtools_web_contents_) { if (!devtools_web_contents_) {
devtools_web_contents_.reset(content::WebContents::Create(content::WebContents::CreateParams(web_contents_->GetBrowserContext()))); devtools_web_contents_.reset(content::WebContents::Create(content::WebContents::CreateParams(web_contents_->GetBrowserContext())));
#if defined(OS_MACOSX)
// Work around http://crbug.com/279472.
devtools_web_contents_->GetView()->SetAllowOverlappingViews(true);
#endif
Observe(devtools_web_contents_.get()); Observe(devtools_web_contents_.get());
devtools_web_contents_->SetDelegate(this); devtools_web_contents_->SetDelegate(this);