Remove SetPageTitle and GetPageTitle and make GetCurrentTitle actually return the page title.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68560 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Steve Lamerton 2011-08-05 18:23:08 +00:00
parent 515fd027c5
commit 1f0acb4355
2 changed files with 1 additions and 7 deletions

View File

@ -61,8 +61,6 @@ public:
virtual void Stop();
virtual wxString GetPageSource();
virtual wxString GetPageText() { return ""; }
virtual void SetPageTitle(const wxString& title) { m_pageTitle = title; }
virtual wxString GetPageTitle(){ return m_pageTitle; }
//We do not want to hide the other overloads
using wxWebView::SetPage;

View File

@ -814,7 +814,7 @@ wxString wxWebViewWebKit::GetCurrentURL()
wxString wxWebViewWebKit::GetCurrentTitle()
{
return GetPageTitle();
return wxStringWithNSString([m_webView mainFrameTitle]);
}
float wxWebViewWebKit::GetWebkitZoom()
@ -1208,10 +1208,6 @@ wxString nsErrorToWxHtmlError(NSError* error, wxWebNavigationError* out)
- (void)webView:(WebView *)sender didReceiveTitle:(NSString *)title
forFrame:(WebFrame *)frame
{
if (webKitWindow && frame == [sender mainFrame])
{
webKitWindow->SetPageTitle(wxStringWithNSString( title ));
}
wxString target = wxStringWithNSString([frame name]);
wxWebNavigationEvent thisEvent(wxEVT_COMMAND_WEB_VIEW_TITLE_CHANGED,
wx_webviewctrls[sender]->GetId(),