X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8907154c1a8a6882c6797d1f16393ddfb23e7f3a..31e57091f20015ec946b8d3f691d3b26748f9783:/include/wx/html/htmlwin.h diff --git a/include/wx/html/htmlwin.h b/include/wx/html/htmlwin.h index 9d961b27d8..719173bedb 100644 --- a/include/wx/html/htmlwin.h +++ b/include/wx/html/htmlwin.h @@ -16,6 +16,7 @@ #include "wx/window.h" #include "wx/scrolwin.h" #include "wx/config.h" +#include "wx/stopwatch.h" #include "wx/html/winpars.h" #include "wx/html/htmlcell.h" #include "wx/filesys.h" @@ -85,7 +86,7 @@ public: // it is NOT address/filename of HTML document. If you want to // specify document location, use LoadPage() istead // Return value : false if an error occurred, true otherwise - bool SetPage(const wxString& source); + virtual bool SetPage(const wxString& source); // Append to current page bool AppendToPage(const wxString& source); @@ -123,7 +124,7 @@ public: #endif // wxUSE_STATUSBAR // Sets fonts to be used when displaying HTML page. - void SetFonts(wxString normal_face, wxString fixed_face, + void SetFonts(const wxString& normal_face, const wxString& fixed_face, const int *sizes = NULL); // Sets font sizes to be relative to the given size or the system @@ -213,6 +214,8 @@ public: wxString ToText(); #endif // wxUSE_CLIPBOARD + virtual void OnInternalIdle(); + protected: void Init(); @@ -240,8 +243,6 @@ protected: void OnMouseLeave(wxMouseEvent& event); #endif // wxUSE_CLIPBOARD - virtual void OnInternalIdle(); - // Returns new filter (will be stored into m_DefaultFilter variable) virtual wxHtmlFilter *GetDefaultFilter() {return new wxHtmlFilterPlainText;} @@ -268,9 +269,13 @@ protected: void StopAutoScrolling(); #endif // wxUSE_CLIPBOARD -protected: wxString DoSelectionToText(wxHtmlSelection *sel); +private: + // implementation of SetPage() + bool DoSetPage(const wxString& source); + +protected: // This is pointer to the first cell in parsed data. (Note: the first cell // is usually top one = all other cells are sub-cells of this one) wxHtmlContainerCell *m_Cell; @@ -310,7 +315,7 @@ protected: #if wxUSE_CLIPBOARD // time of the last doubleclick event, used to detect tripleclicks // (tripleclicks are used to select whole line): - wxLongLong m_lastDoubleClick; + wxMilliClock_t m_lastDoubleClick; // helper class to automatically scroll the window if the user is selecting // text and the mouse leaves wxHtmlWindow: