\membersection{wxDateTime::wxDateTime}\label{wxdatetimewxdatetimedate}
-\func{wxDateTime\&}{wxDateTime}{\param{wxDateTime\_t }{day}, \param{Month }{month = Inv\_Month}, \param{wxDateTime\_t }{hour = 0}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}}
+\func{wxDateTime\&}{wxDateTime}{\param{wxDateTime\_t }{day}, \param{Month }{month = Inv\_Month}, \param{int}{ Inv_Year},
+\param{wxDateTime\_t }{hour = 0}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}}
Same as \helpref{Set}{wxdatetimesetdate}
\membersection{::wxGetLocalTimeMillis}\label{wxgetlocaltimemillis}
-\func{wxLongLone}{wxGetLocalTimeMillis}{\void}
+\func{wxLongLong}{wxGetLocalTimeMillis}{\void}
Returns the number of milliseconds since local time 00:00:00 Jan 1st 1970.
\wxheading{See also}
\helpref{wxDateTime::Now}{wxdatetimenow},\\
-\helpref{wxLongLone}{wxlonglong}
+\helpref{wxLongLong}{wxlonglong}
\wxheading{Include files}
\perlnote{In wxPerl this method takes no parameters and returns a
2-element list {\tt ( xUnit, yUnit )}.}
+\membersection{wxScrolledWindow::GetViewStart}\label{wxscrolledwindowgetviewstart}
+
+\constfunc{void}{GetViewStart}{\param{int* }{x}, \param{int* }{ y}}
+
+Get the position at which the visible portion of the window starts.
+
+\wxheading{Parameters}
+
+\docparam{x}{Receives the first visible x position in scroll units.}
+
+\docparam{y}{Receives the first visible y position in scroll units.}
+
+\wxheading{Remarks}
+
+If either of the scrollbars is not at the home position, {\it x} and/or
+\rtfsp{\it y} will be greater than zero. Combined with \helpref{wxWindow::GetClientSize}{wxwindowgetclientsize},
+the application can use this function to efficiently redraw only the
+visible portion of the window. The positions are in logical scroll
+units, not pixels, so to convert to pixels you will have to multiply
+by the number of pixels per scroll increment.
+
+\wxheading{See also}
+
+\helpref{wxScrolledWindow::SetScrollbars}{wxscrolledwindowsetscrollbars}
+
+\pythonnote{The wxPython version of this methods accepts no
+parameters and returns a tuple of values for x and y.}
+
+\perlnote{In wxPerl this method takes no parameters and returns a
+2-element list {\tt ( x, y )}.}
+
\membersection{wxScrolledWindow::GetVirtualSize}\label{wxscrolledwindowgetvirtualsize}
\constfunc{void}{GetVirtualSize}{\param{int* }{x}, \param{int* }{y}}
Call this function to tell wxScrolledWindow to perform the actual scrolling on
a different window (not on itself).
-\membersection{wxScrolledWindow::GetViewStart}\label{wxscrolledwindowgetviewstart}
-
-\constfunc{void}{GetViewStart}{\param{int* }{x}, \param{int* }{ y}}
-
-Get the position at which the visible portion of the window starts.
-
-\wxheading{Parameters}
-
-\docparam{x}{Receives the first visible x position in scroll units.}
-
-\docparam{y}{Receives the first visible y position in scroll units.}
-
-\wxheading{Remarks}
-
-If either of the scrollbars is not at the home position, {\it x} and/or
-\rtfsp{\it y} will be greater than zero. Combined with \helpref{wxWindow::GetClientSize}{wxwindowgetclientsize},
-the application can use this function to efficiently redraw only the
-visible portion of the window. The positions are in logical scroll
-units, not pixels, so to convert to pixels you will have to multiply
-by the number of pixels per scroll increment.
-
-\wxheading{See also}
-
-\helpref{wxScrolledWindow::SetScrollbars}{wxscrolledwindowsetscrollbars}
-
-\pythonnote{The wxPython version of this methods accepts no
-parameters and returns a tuple of values for x and y.}
-
-\perlnote{In wxPerl this method takes no parameters and returns a
-2-element list {\tt ( x, y )}.}
-
virtual void DoSetSize(int x, int y, int w, int h,
int sizeFlags = wxSIZE_AUTO);
virtual wxSize DoGetBestSize() const;
+ virtual long MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam);
DECLARE_DYNAMIC_CLASS(wxStaticText)
};
StaticVAlign_Max
};
+class DerivedStaticText: public wxStaticText
+{
+public:
+ DerivedStaticText(wxWindow* parent, wxWindowID id, const wxString& label,
+ const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize,
+ long style = 0):
+ wxStaticText(parent, id, label, pos, size, style)
+ {
+ }
+ void OnMouseEvent(wxMouseEvent& event)
+ {
+ if (event.LeftDown())
+ wxMessageBox(wxT("Clicked on static text"));
+ }
+DECLARE_EVENT_TABLE()
+};
+
+BEGIN_EVENT_TABLE(DerivedStaticText, wxStaticText)
+ EVT_MOUSE_EVENTS(DerivedStaticText::OnMouseEvent)
+END_EVENT_TABLE()
+
// ----------------------------------------------------------------------------
// StaticWidgetsPage
// ----------------------------------------------------------------------------
m_sizerStatBox = new wxStaticBoxSizer(box, isVert ? wxHORIZONTAL
: wxVERTICAL);
- m_statText = new wxStaticText(this, -1, m_textLabel->GetValue(),
+ m_statText = new DerivedStaticText(this, -1, m_textLabel->GetValue(),
wxDefaultPosition, wxDefaultSize,
flagsText);
return ret;
}
+long wxStaticText::MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam)
+{
+ // Ensure that static items get messages. Some controls don't like this
+ // message to be intercepted (e.g. RichEdit), hence the tests.
+ if (nMsg == WM_NCHITTEST)
+ return (long)HTCLIENT;
+
+ return wxWindow::MSWWindowProc(nMsg, wParam, lParam);
+}
#endif // wxUSE_STATTEXT