Fixes to remove compile warnings.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@29420 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -67,7 +67,7 @@ public:
|
|||||||
bool CanGetPageSource();
|
bool CanGetPageSource();
|
||||||
wxString GetPageSource();
|
wxString GetPageSource();
|
||||||
void SetPageSource(wxString& source, const wxString& baseUrl = wxEmptyString);
|
void SetPageSource(wxString& source, const wxString& baseUrl = wxEmptyString);
|
||||||
|
|
||||||
//we need to resize the webview when the control size changes
|
//we need to resize the webview when the control size changes
|
||||||
void OnSize(wxSizeEvent &event);
|
void OnSize(wxSizeEvent &event);
|
||||||
protected:
|
protected:
|
||||||
@@ -79,7 +79,7 @@ private:
|
|||||||
wxWindowID m_windowID;
|
wxWindowID m_windowID;
|
||||||
wxString m_currentURL;
|
wxString m_currentURL;
|
||||||
wxString m_pageTitle;
|
wxString m_pageTitle;
|
||||||
void* m_webView;
|
objc_object* m_webView;
|
||||||
//It should be WebView, but WebView is Cocoa only, so any class which included
|
//It should be WebView, but WebView is Cocoa only, so any class which included
|
||||||
//this header would have to link to Cocoa, so for now use void* instead.
|
//this header would have to link to Cocoa, so for now use void* instead.
|
||||||
};
|
};
|
||||||
|
@@ -200,17 +200,17 @@ bool wxWebKitCtrl::CanGoForward(){
|
|||||||
bool wxWebKitCtrl::GoBack(){
|
bool wxWebKitCtrl::GoBack(){
|
||||||
if ( !m_webView )
|
if ( !m_webView )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
[m_webView goBack];
|
bool result = [(WebView*)m_webView goBack];
|
||||||
return true;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool wxWebKitCtrl::GoForward(){
|
bool wxWebKitCtrl::GoForward(){
|
||||||
if ( !m_webView )
|
if ( !m_webView )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
[m_webView goForward];
|
bool result = [(WebView*)m_webView goForward];
|
||||||
return true;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxWebKitCtrl::Reload(){
|
void wxWebKitCtrl::Reload(){
|
||||||
@@ -236,14 +236,13 @@ bool wxWebKitCtrl::CanGetPageSource(){
|
|||||||
}
|
}
|
||||||
|
|
||||||
wxString wxWebKitCtrl::GetPageSource(){
|
wxString wxWebKitCtrl::GetPageSource(){
|
||||||
if ( !m_webView )
|
|
||||||
return wxT("");
|
|
||||||
|
|
||||||
if (CanGetPageSource()){
|
if (CanGetPageSource()){
|
||||||
WebDataSource* dataSource = [[m_webView mainFrame] dataSource];
|
WebDataSource* dataSource = [[m_webView mainFrame] dataSource];
|
||||||
return wxStringWithNSString( [[dataSource representation] documentSource] );
|
return wxStringWithNSString( [[dataSource representation] documentSource] );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return wxT("");
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxWebKitCtrl::SetPageSource(wxString& source, const wxString& baseUrl){
|
void wxWebKitCtrl::SetPageSource(wxString& source, const wxString& baseUrl){
|
||||||
@@ -263,7 +262,7 @@ void wxWebKitCtrl::OnSize(wxSizeEvent &event){
|
|||||||
wxWindow* parent = GetParent();
|
wxWindow* parent = GetParent();
|
||||||
bool inNotebook = false;
|
bool inNotebook = false;
|
||||||
int x = 0;
|
int x = 0;
|
||||||
int y = 18;
|
int y = 18;
|
||||||
while(parent != NULL)
|
while(parent != NULL)
|
||||||
{
|
{
|
||||||
// keep adding the position until we hit the notebook
|
// keep adding the position until we hit the notebook
|
||||||
|
Reference in New Issue
Block a user