Small cursor improvements
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2579 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -196,6 +196,11 @@ public:
|
|||||||
bool m_delayedBackgroundColour:1;
|
bool m_delayedBackgroundColour:1;
|
||||||
bool m_delayedCursor:1;
|
bool m_delayedCursor:1;
|
||||||
|
|
||||||
|
// the cursor is set in OnInternalIdle(). this fields holds
|
||||||
|
// a reference to the cursor currently set in theGdk window
|
||||||
|
// so that we don't have to set it more than once
|
||||||
|
wxCursor m_currentGdkCursor;
|
||||||
|
|
||||||
// contains GTK's widgets internal information about non-default widget
|
// contains GTK's widgets internal information about non-default widget
|
||||||
// font and colours. we create one for each widget that gets any
|
// font and colours. we create one for each widget that gets any
|
||||||
// non-default attribute set via SetFont() or SetForegroundColour() /
|
// non-default attribute set via SetFont() or SetForegroundColour() /
|
||||||
|
@@ -196,6 +196,11 @@ public:
|
|||||||
bool m_delayedBackgroundColour:1;
|
bool m_delayedBackgroundColour:1;
|
||||||
bool m_delayedCursor:1;
|
bool m_delayedCursor:1;
|
||||||
|
|
||||||
|
// the cursor is set in OnInternalIdle(). this fields holds
|
||||||
|
// a reference to the cursor currently set in theGdk window
|
||||||
|
// so that we don't have to set it more than once
|
||||||
|
wxCursor m_currentGdkCursor;
|
||||||
|
|
||||||
// contains GTK's widgets internal information about non-default widget
|
// contains GTK's widgets internal information about non-default widget
|
||||||
// font and colours. we create one for each widget that gets any
|
// font and colours. we create one for each widget that gets any
|
||||||
// non-default attribute set via SetFont() or SetForegroundColour() /
|
// non-default attribute set via SetFont() or SetForegroundColour() /
|
||||||
|
@@ -749,6 +749,10 @@ void wxFrame::OnInternalIdle()
|
|||||||
GtkOnSize( m_x, m_y, m_width, m_height );
|
GtkOnSize( m_x, m_y, m_width, m_height );
|
||||||
|
|
||||||
DoMenuUpdates();
|
DoMenuUpdates();
|
||||||
|
|
||||||
|
if (m_frameMenuBar) m_frameMenuBar->OnInternalIdle();
|
||||||
|
if (m_frameToolBar) m_frameToolBar->OnInternalIdle();
|
||||||
|
if (m_frameStatusBar) m_frameStatusBar->OnInternalIdle();
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxFrame::OnCloseWindow( wxCloseEvent& WXUNUSED(event) )
|
void wxFrame::OnCloseWindow( wxCloseEvent& WXUNUSED(event) )
|
||||||
|
@@ -2030,10 +2030,14 @@ void wxWindow::OnInternalIdle()
|
|||||||
GdkWindow *window = GetConnectWidget()->window;
|
GdkWindow *window = GetConnectWidget()->window;
|
||||||
if (window)
|
if (window)
|
||||||
{
|
{
|
||||||
if (g_globalCursor.Ok())
|
wxCursor cursor = m_cursor;
|
||||||
gdk_window_set_cursor( window, g_globalCursor.GetCursor() );
|
if (g_globalCursor.Ok()) cursor = g_globalCursor;
|
||||||
else
|
|
||||||
gdk_window_set_cursor( window, m_cursor.GetCursor() );
|
if (m_currentGdkCursor != cursor)
|
||||||
|
{
|
||||||
|
gdk_window_set_cursor( window, cursor.GetCursor() );
|
||||||
|
m_currentGdkCursor = cursor;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
UpdateWindowUI();
|
UpdateWindowUI();
|
||||||
|
@@ -749,6 +749,10 @@ void wxFrame::OnInternalIdle()
|
|||||||
GtkOnSize( m_x, m_y, m_width, m_height );
|
GtkOnSize( m_x, m_y, m_width, m_height );
|
||||||
|
|
||||||
DoMenuUpdates();
|
DoMenuUpdates();
|
||||||
|
|
||||||
|
if (m_frameMenuBar) m_frameMenuBar->OnInternalIdle();
|
||||||
|
if (m_frameToolBar) m_frameToolBar->OnInternalIdle();
|
||||||
|
if (m_frameStatusBar) m_frameStatusBar->OnInternalIdle();
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxFrame::OnCloseWindow( wxCloseEvent& WXUNUSED(event) )
|
void wxFrame::OnCloseWindow( wxCloseEvent& WXUNUSED(event) )
|
||||||
|
@@ -2030,10 +2030,14 @@ void wxWindow::OnInternalIdle()
|
|||||||
GdkWindow *window = GetConnectWidget()->window;
|
GdkWindow *window = GetConnectWidget()->window;
|
||||||
if (window)
|
if (window)
|
||||||
{
|
{
|
||||||
if (g_globalCursor.Ok())
|
wxCursor cursor = m_cursor;
|
||||||
gdk_window_set_cursor( window, g_globalCursor.GetCursor() );
|
if (g_globalCursor.Ok()) cursor = g_globalCursor;
|
||||||
else
|
|
||||||
gdk_window_set_cursor( window, m_cursor.GetCursor() );
|
if (m_currentGdkCursor != cursor)
|
||||||
|
{
|
||||||
|
gdk_window_set_cursor( window, cursor.GetCursor() );
|
||||||
|
m_currentGdkCursor = cursor;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
UpdateWindowUI();
|
UpdateWindowUI();
|
||||||
|
Reference in New Issue
Block a user