OnIdle -> OnInternalIdle

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@21798 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2003-07-09 17:15:09 +00:00
parent 74039d33c7
commit 5180055b69
11 changed files with 24 additions and 23 deletions

View File

@@ -164,7 +164,7 @@ public:
// implementation only from now on // implementation only from now on
// ------------------------------- // -------------------------------
void OnIdle( wxIdleEvent &event ); void OnInternalIdle( );
void OnSize( wxSizeEvent &event ); void OnSize( wxSizeEvent &event );
// We have to hand down a few functions // We have to hand down a few functions

View File

@@ -113,7 +113,7 @@ public:
// callbacks // callbacks
// --------- // ---------
void OnSize(wxSizeEvent& event); void OnSize(wxSizeEvent& event);
void OnIdle(wxIdleEvent& event); void OnInternalIdle();
void OnSelChange(wxNotebookEvent& event); void OnSelChange(wxNotebookEvent& event);
void OnSetFocus(wxFocusEvent& event); void OnSetFocus(wxFocusEvent& event);
void OnNavigationKey(wxNavigationKeyEvent& event); void OnNavigationKey(wxNavigationKeyEvent& event);

View File

@@ -190,7 +190,7 @@ public:
void OnSize(wxSizeEvent& event); void OnSize(wxSizeEvent& event);
// In live mode, resize child windows in idle time // In live mode, resize child windows in idle time
void OnIdle(wxIdleEvent& event); void OnInternalIdle();
// Draws borders // Draws borders
virtual void DrawBorders(wxDC& dc); virtual void DrawBorders(wxDC& dc);

View File

@@ -362,7 +362,7 @@ public:
void OnKillFocus( wxFocusEvent &event ); void OnKillFocus( wxFocusEvent &event );
void OnChar( wxKeyEvent &event ); void OnChar( wxKeyEvent &event );
void OnMouse( wxMouseEvent &event ); void OnMouse( wxMouseEvent &event );
void OnIdle( wxIdleEvent &event ); void OnInternalIdle( );
// implementation helpers // implementation helpers
protected: protected:

View File

@@ -214,7 +214,6 @@ protected:
void OnMouseMove(wxMouseEvent& event); void OnMouseMove(wxMouseEvent& event);
void OnMouseDown(wxMouseEvent& event); void OnMouseDown(wxMouseEvent& event);
void OnMouseUp(wxMouseEvent& event); void OnMouseUp(wxMouseEvent& event);
void OnIdle(wxIdleEvent& event);
#if wxUSE_CLIPBOARD #if wxUSE_CLIPBOARD
void OnKeyUp(wxKeyEvent& event); void OnKeyUp(wxKeyEvent& event);
void OnDoubleClick(wxMouseEvent& event); void OnDoubleClick(wxMouseEvent& event);
@@ -223,6 +222,8 @@ protected:
void OnMouseLeave(wxMouseEvent& event); void OnMouseLeave(wxMouseEvent& event);
#endif // wxUSE_CLIPBOARD #endif // wxUSE_CLIPBOARD
virtual void OnInternalIdle();
// Returns new filter (will be stored into m_DefaultFilter variable) // Returns new filter (will be stored into m_DefaultFilter variable)
virtual wxHtmlFilter *GetDefaultFilter() {return new wxHtmlFilterPlainText;} virtual wxHtmlFilter *GetDefaultFilter() {return new wxHtmlFilterPlainText;}

View File

@@ -4432,7 +4432,6 @@ IMPLEMENT_DYNAMIC_CLASS(wxGenericListCtrl, wxControl)
BEGIN_EVENT_TABLE(wxGenericListCtrl,wxControl) BEGIN_EVENT_TABLE(wxGenericListCtrl,wxControl)
EVT_SIZE(wxGenericListCtrl::OnSize) EVT_SIZE(wxGenericListCtrl::OnSize)
EVT_IDLE(wxGenericListCtrl::OnIdle)
END_EVENT_TABLE() END_EVENT_TABLE()
wxGenericListCtrl::wxGenericListCtrl() wxGenericListCtrl::wxGenericListCtrl()
@@ -5035,9 +5034,9 @@ void wxGenericListCtrl::ResizeReportView(bool showHeader)
} }
} }
void wxGenericListCtrl::OnIdle( wxIdleEvent & event ) void wxGenericListCtrl::OnInternalIdle()
{ {
event.Skip(); wxWindow::OnInternalIdle();
// do it only if needed // do it only if needed
if ( !m_mainWin->m_dirty ) if ( !m_mainWin->m_dirty )

View File

@@ -432,8 +432,6 @@ public:
#endif // wxUSE_FILE #endif // wxUSE_FILE
void OnClear(wxCommandEvent& event); void OnClear(wxCommandEvent& event);
void OnIdle(wxIdleEvent&);
// accessors // accessors
wxTextCtrl *TextCtrl() const { return m_pTextCtrl; } wxTextCtrl *TextCtrl() const { return m_pTextCtrl; }

View File

@@ -56,7 +56,6 @@ BEGIN_EVENT_TABLE(wxNotebook, wxControl)
EVT_MOUSE_EVENTS(wxNotebook::OnMouseEvent) EVT_MOUSE_EVENTS(wxNotebook::OnMouseEvent)
EVT_SET_FOCUS(wxNotebook::OnSetFocus) EVT_SET_FOCUS(wxNotebook::OnSetFocus)
EVT_NAVIGATION_KEY(wxNotebook::OnNavigationKey) EVT_NAVIGATION_KEY(wxNotebook::OnNavigationKey)
// EVT_IDLE(wxNotebook::OnIdle)
END_EVENT_TABLE() END_EVENT_TABLE()
IMPLEMENT_DYNAMIC_CLASS(wxNotebook, wxControl) IMPLEMENT_DYNAMIC_CLASS(wxNotebook, wxControl)
@@ -457,8 +456,11 @@ void wxNotebook::OnSize(wxSizeEvent& event)
// This was supposed to cure the non-display of the notebook // This was supposed to cure the non-display of the notebook
// until the user resizes the window. // until the user resizes the window.
// What's going on? // What's going on?
void wxNotebook::OnIdle(wxIdleEvent& event) void wxNotebook::OnInternalIdle()
{ {
wxWindow::OnInternalIdle();
#if 0
static bool s_bFirstTime = TRUE; static bool s_bFirstTime = TRUE;
if ( s_bFirstTime ) { if ( s_bFirstTime ) {
/* /*
@@ -478,7 +480,7 @@ void wxNotebook::OnIdle(wxIdleEvent& event)
*/ */
s_bFirstTime = FALSE; s_bFirstTime = FALSE;
} }
event.Skip(); #endif
} }
// Implementation: calculate the layout of the view rect // Implementation: calculate the layout of the view rect

View File

@@ -50,7 +50,6 @@ IMPLEMENT_DYNAMIC_CLASS(wxSplitterEvent, wxNotifyEvent)
BEGIN_EVENT_TABLE(wxSplitterWindow, wxWindow) BEGIN_EVENT_TABLE(wxSplitterWindow, wxWindow)
EVT_PAINT(wxSplitterWindow::OnPaint) EVT_PAINT(wxSplitterWindow::OnPaint)
EVT_SIZE(wxSplitterWindow::OnSize) EVT_SIZE(wxSplitterWindow::OnSize)
EVT_IDLE(wxSplitterWindow::OnIdle)
EVT_MOUSE_EVENTS(wxSplitterWindow::OnMouseEvent) EVT_MOUSE_EVENTS(wxSplitterWindow::OnMouseEvent)
#if defined( __WXMSW__ ) || defined( __WXMAC__) #if defined( __WXMSW__ ) || defined( __WXMAC__)
@@ -156,12 +155,12 @@ void wxSplitterWindow::OnPaint(wxPaintEvent& WXUNUSED(event))
DrawSash(dc); DrawSash(dc);
} }
void wxSplitterWindow::OnIdle(wxIdleEvent& event) void wxSplitterWindow::OnInternalIdle()
{ {
wxWindow::OnInternalIdle();
if (m_needUpdating) if (m_needUpdating)
SizeWindows(); SizeWindows();
event.Skip();
} }
void wxSplitterWindow::OnMouseEvent(wxMouseEvent& event) void wxSplitterWindow::OnMouseEvent(wxMouseEvent& event)

View File

@@ -716,7 +716,6 @@ BEGIN_EVENT_TABLE(wxGenericTreeCtrl,wxScrolledWindow)
EVT_CHAR (wxGenericTreeCtrl::OnChar) EVT_CHAR (wxGenericTreeCtrl::OnChar)
EVT_SET_FOCUS (wxGenericTreeCtrl::OnSetFocus) EVT_SET_FOCUS (wxGenericTreeCtrl::OnSetFocus)
EVT_KILL_FOCUS (wxGenericTreeCtrl::OnKillFocus) EVT_KILL_FOCUS (wxGenericTreeCtrl::OnKillFocus)
EVT_IDLE (wxGenericTreeCtrl::OnIdle)
END_EVENT_TABLE() END_EVENT_TABLE()
#if !defined(__WXMSW__) || defined(__WIN16__) || defined(__WXUNIVERSAL__) #if !defined(__WXMSW__) || defined(__WIN16__) || defined(__WXUNIVERSAL__)
@@ -3158,8 +3157,10 @@ void wxGenericTreeCtrl::OnMouse( wxMouseEvent &event )
} }
} }
void wxGenericTreeCtrl::OnIdle( wxIdleEvent &WXUNUSED(event) ) void wxGenericTreeCtrl::OnInternalIdle()
{ {
wxWindow::OnInternalIdle();
// Check if we need to select the root item // Check if we need to select the root item
// because nothing else has been selected. // because nothing else has been selected.
// Delaying it means that we can invoke event handlers // Delaying it means that we can invoke event handlers

View File

@@ -964,8 +964,10 @@ void wxHtmlWindow::OnMouseUp(wxMouseEvent& event)
void wxHtmlWindow::OnIdle(wxIdleEvent& WXUNUSED(event)) void wxHtmlWindow::OnInternalIdle()
{ {
wxWindow::OnInternalIdle();
if (m_tmpMouseMoved && (m_Cell != NULL)) if (m_tmpMouseMoved && (m_Cell != NULL))
{ {
#ifdef DEBUG_HTML_SELECTION #ifdef DEBUG_HTML_SELECTION
@@ -1312,7 +1314,6 @@ BEGIN_EVENT_TABLE(wxHtmlWindow, wxScrolledWindow)
EVT_LEFT_UP(wxHtmlWindow::OnMouseUp) EVT_LEFT_UP(wxHtmlWindow::OnMouseUp)
EVT_RIGHT_UP(wxHtmlWindow::OnMouseUp) EVT_RIGHT_UP(wxHtmlWindow::OnMouseUp)
EVT_MOTION(wxHtmlWindow::OnMouseMove) EVT_MOTION(wxHtmlWindow::OnMouseMove)
EVT_IDLE(wxHtmlWindow::OnIdle)
EVT_ERASE_BACKGROUND(wxHtmlWindow::OnEraseBackground) EVT_ERASE_BACKGROUND(wxHtmlWindow::OnEraseBackground)
EVT_PAINT(wxHtmlWindow::OnPaint) EVT_PAINT(wxHtmlWindow::OnPaint)
#if wxUSE_CLIPBOARD #if wxUSE_CLIPBOARD