// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
-#ifdef __VMS
-#define XtDisplay XTDISPLAY
-#define XtWindow XTWINDOW
-#define XtScreen XTSCREEN
-#endif
-
#ifndef WX_PRECOMP
#include "wx/hash.h"
#include "wx/log.h"
// Destructor
wxWindow::~wxWindow()
{
+ SendDestroyEvent();
+
if (g_captureWindow == this)
g_captureWindow = NULL;
- m_isBeingDeleted = true;
-
// Motif-specific actions first
WXWidget wMain = GetMainWidget();
if ( wMain )
// currently active.
// (2) The widget with the focus may not be in the widget table
// depending on which widgets I put in the table
- wxWindow *winFocus = (wxWindow *)NULL;
+ wxWindow *winFocus = NULL;
for ( wxWindowList::compatibility_iterator node = wxTopLevelWindows.GetFirst();
node;
node = node->GetNext() )
return width;
}
-void wxWindow::GetTextExtent(const wxString& string,
- int *x, int *y,
- int *descent, int *externalLeading,
- const wxFont *theFont) const
+void wxWindow::DoGetTextExtent(const wxString& string,
+ int *x, int *y,
+ int *descent,
+ int *externalLeading,
+ const wxFont *theFont) const
{
const wxFont *fontToUse = theFont ? theFont : &m_font;
{
// This calls the UI-update mechanism (querying windows for
// menu/toolbar/control state information)
- if (wxUpdateUIEvent::CanUpdate(this) && IsShown())
+ if (wxUpdateUIEvent::CanUpdate(this) && IsShownOnScreen())
UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
}
if ( wMain )
return (WXDisplay*) XtDisplay(wMain);
else
- return (WXDisplay*) NULL;
+ return NULL;
}
WXWidget wxWindow::GetMainWidget() const
XmScrollBarCallbackStruct *cbs)
{
wxWindow *win = wxGetWindowFromTable(scrollbar);
- wxCHECK_RET( win, _T("invalid widget in scrollbar callback") );
+ wxCHECK_RET( win, wxT("invalid widget in scrollbar callback") );
wxOrientation orientation = (wxOrientation)wxPtrToUInt(clientData);