+ if ( x )
+ *x = gs_rectDialog.x;
+ if ( y )
+ *y = gs_rectDialog.y;
+}
+
+void wxColourDialog::DoCentre(int dir)
+{
+ m_centreDir = dir;
+
+ // it's unnecessary to do anything else at this stage as we'll redo it in
+ // MSWOnInitDone() anyhow
+}
+
+void wxColourDialog::DoMoveWindow(int x, int y, int WXUNUSED(w), int WXUNUSED(h))
+{
+ gs_rectDialog.x = x;
+ gs_rectDialog.y = y;
+
+ // our HWND is only set when we're called from MSWOnInitDone(), test if
+ // this is the case
+ HWND hwnd = GetHwnd();
+ if ( hwnd )
+ {
+ // size of the dialog can't be changed because the controls are not
+ // laid out correctly then
+ ::SetWindowPos(hwnd, HWND_TOP, x, y, 0, 0, SWP_NOZORDER | SWP_NOSIZE);
+ }
+ else // just remember that we were requested to move the window
+ {
+ m_movedWindow = true;
+
+ // if Centre() had been called before, it shouldn't be taken into
+ // account now
+ m_centreDir = 0;
+ }