webview: adding page-title-set event

This commit is contained in:
Robo 2015-04-05 14:50:42 +05:30
parent 5ff9588b48
commit 87af6f9c80
7 changed files with 26 additions and 0 deletions

View file

@ -240,6 +240,11 @@ void WebContents::DidNavigateMainFrame(
Emit("did-navigate-to-different-page");
}
void WebContents::TitleWasSet(content::NavigationEntry* entry,
bool explicit_set) {
Emit("page-title-set", entry->GetTitle(), explicit_set);
}
bool WebContents::OnMessageReceived(const IPC::Message& message) {
bool handled = true;
IPC_BEGIN_MESSAGE_MAP(WebContents, message)

View file

@ -172,6 +172,7 @@ class WebContents : public mate::EventEmitter,
void WebContentsDestroyed() override;
void NavigationEntryCommitted(
const content::LoadCommittedDetails& load_details) override;
void TitleWasSet(content::NavigationEntry* entry, bool explicit_set) override;
// content::BrowserPluginGuestDelegate:
void DidAttach(int guest_proxy_routing_id) final;