X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9d9cbcdd28830f7b8af7e5125bd922e14345b3c8..6f67d53729164f54dd65540d4622eee47d47c6fe:/wxPython/src/webkit.i diff --git a/wxPython/src/webkit.i b/wxPython/src/webkit.i index 88cc4ce9b1..4e0f84f9ef 100644 --- a/wxPython/src/webkit.i +++ b/wxPython/src/webkit.i @@ -38,8 +38,6 @@ %pythoncode { __docfilter__ = wx.__DocFilter(globals()) } -%include _webkit_rename.i - //--------------------------------------------------------------------------- // Put some wx default wxChar* values into wxStrings. @@ -86,6 +84,8 @@ public: bool CanGetPageSource() { return false; } wxString GetPageSource() { return wxEmptyString; } void SetPageSource(wxString& source, const wxString& baseUrl = wxEmptyString) {} + wxString GetPageURL() { return wxEmptyString; } + wxString GetPageTitle() { return wxEmptyString; } }; @@ -96,6 +96,8 @@ enum { wxWEBKIT_STATE_TRANSFERRING = 0, wxWEBKIT_STATE_STOP = 0, wxWEBKIT_STATE_FAILED = 0, + + wxEVT_WEBKIT_STATE_CHANGED = 0 }; class wxWebKitStateChangedEvent : public wxCommandEvent @@ -104,7 +106,7 @@ public: wxWebKitStateChangedEvent( wxWindow* win = NULL ) { wxPyRaiseNotImplemented(); } - int GetState() { return 0 } + int GetState() { return 0; } void SetState(const int state) {} wxString GetURL() { return wxEmptyString; } void SetURL(const wxString& url) {} @@ -114,7 +116,7 @@ public: #endif %} -// Now define it for SWIG, usign either the real class or the dummy above. +// Now define it for SWIG, using either the real class or the dummy above. MustHaveApp(wxWebKitCtrl); @@ -132,7 +134,7 @@ public: const wxValidator& validator = wxDefaultValidator, const wxString& name = wxPyWebKitNameStr); - %name(PreWebKitCtrl)wxWebKitCtrl(); + %RenameCtor(PreWebKitCtrl, wxWebKitCtrl()); bool Create(wxWindow *parent, @@ -154,6 +156,12 @@ public: bool CanGetPageSource(); wxString GetPageSource(); void SetPageSource(wxString& source, const wxString& baseUrl = wxPyEmptyString); + wxString GetPageURL(); + wxString GetPageTitle(); + + %property(PageSource, GetPageSource, SetPageSource, doc="See `GetPageSource` and `SetPageSource`"); + %property(PageTitle, GetPageTitle, doc="See `GetPageTitle`"); + %property(PageURL, GetPageURL, doc="See `GetPageURL`"); }; @@ -182,6 +190,9 @@ public: void SetState(const int state); wxString GetURL(); void SetURL(const wxString& url); + + %property(State, GetState, SetState, doc="See `GetState` and `SetState`"); + %property(URL, GetURL, SetURL, doc="See `GetURL` and `SetURL`"); };