mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
- Add developer tools support (issue #127).
- Send title change notifications generated after page content is done loading. - Restore windows and bring to the front in BrowserWebViewDelegate::show(). git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@168 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
@@ -40,7 +40,10 @@ void CefBrowserImpl::UIT_CreateBrowser(const CefString& url)
|
||||
|
||||
// Add the new browser to the list maintained by the context
|
||||
_Context->AddBrowser(this);
|
||||
|
||||
|
||||
if (!settings_.developer_tools_disabled)
|
||||
dev_tools_agent_.reset(new BrowserDevToolsAgent());
|
||||
|
||||
NSView* parentView = (NSView*)window_info_.m_ParentView;
|
||||
gfx::Rect contentRect(window_info_.m_x, window_info_.m_y,
|
||||
window_info_.m_nWidth, window_info_.m_nHeight);
|
||||
@@ -51,9 +54,12 @@ void CefBrowserImpl::UIT_CreateBrowser(const CefString& url)
|
||||
// Create the webview host object
|
||||
webviewhost_.reset(
|
||||
WebViewHost::Create(parentView, contentRect, delegate_.get(),
|
||||
NULL, prefs));
|
||||
dev_tools_agent_.get(), prefs));
|
||||
delegate_->RegisterDragDrop();
|
||||
|
||||
|
||||
if (!settings_.developer_tools_disabled)
|
||||
dev_tools_agent_->SetWebView(webviewhost_->webview());
|
||||
|
||||
BrowserWebView* browserView = (BrowserWebView*)webviewhost_->view_handle();
|
||||
browserView.browser = this;
|
||||
window_info_.m_View = (void*)browserView;
|
||||
@@ -137,3 +143,14 @@ int CefBrowserImpl::UIT_GetPagesCount(WebKit::WebFrame* frame)
|
||||
NOTIMPLEMENTED();
|
||||
return 0;
|
||||
}
|
||||
|
||||
void CefBrowserImpl::UIT_CloseDevTools()
|
||||
{
|
||||
REQUIRE_UIT();
|
||||
|
||||
if(!dev_tools_agent_.get())
|
||||
return;
|
||||
|
||||
// TODO(port): Add implementation.
|
||||
NOTIMPLEMENTED();
|
||||
}
|
||||
|
Reference in New Issue
Block a user