avoid duplicate move events
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74665 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -327,11 +327,14 @@ void wxTopLevelWindowGTK::GTKConfigureEvent(int x, int y)
|
|||||||
gtk_window_get_position(GTK_WINDOW(m_widget), &point.x, &point.y);
|
gtk_window_get_position(GTK_WINDOW(m_widget), &point.x, &point.y);
|
||||||
}
|
}
|
||||||
|
|
||||||
m_x = point.x;
|
if (m_x != point.x || m_y != point.y)
|
||||||
m_y = point.y;
|
{
|
||||||
wxMoveEvent event(point, GetId());
|
m_x = point.x;
|
||||||
event.SetEventObject(this);
|
m_y = point.y;
|
||||||
HandleWindowEvent(event);
|
wxMoveEvent event(point, GetId());
|
||||||
|
event.SetEventObject(this);
|
||||||
|
HandleWindowEvent(event);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
@@ -1102,6 +1105,9 @@ void wxTopLevelWindowGTK::DoSetSize( int x, int y, int width, int height, int si
|
|||||||
if ( m_x != old_x || m_y != old_y )
|
if ( m_x != old_x || m_y != old_y )
|
||||||
{
|
{
|
||||||
gtk_window_move( GTK_WINDOW(m_widget), m_x, m_y );
|
gtk_window_move( GTK_WINDOW(m_widget), m_x, m_y );
|
||||||
|
wxMoveEvent event(wxPoint(m_x, m_y), GetId());
|
||||||
|
event.SetEventObject(this);
|
||||||
|
HandleWindowEvent(event);
|
||||||
}
|
}
|
||||||
|
|
||||||
const wxSize oldSize(m_width, m_height);
|
const wxSize oldSize(m_width, m_height);
|
||||||
|
Reference in New Issue
Block a user