projects
/
wxWidgets.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
remove Create{Window,Client,Paint}DC() methods without window parameter -- they don...
[wxWidgets.git]
/
src
/
motif
/
dialog.cpp
diff --git
a/src/motif/dialog.cpp
b/src/motif/dialog.cpp
index b34a7ae8013a91378ac956e024b4b95eb944d9e7..3955a68d4536e6385f011764ffde4e670c3f7e42 100644
(file)
--- a/
src/motif/dialog.cpp
+++ b/
src/motif/dialog.cpp
@@
-12,13
+12,6
@@
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
-#ifdef __VMS
-#define XtDisplay XTDISPLAY
-#define XtWindow XTWINDOW
-#define XtParent XTPARENT
-#define XtScreen XTSCREEN
-#endif
-
#include "wx/dialog.h"
#ifndef WX_PRECOMP
#include "wx/dialog.h"
#ifndef WX_PRECOMP
@@
-155,7
+148,7
@@
bool wxDialog::XmDoCreateTLW(wxWindow* parent,
XtSetArg (args[1], XmNautoUnmanage, False);
Widget dialogShell =
XmCreateBulletinBoardDialog( parentWidget,
XtSetArg (args[1], XmNautoUnmanage, False);
Widget dialogShell =
XmCreateBulletinBoardDialog( parentWidget,
-
wxConstCast(name.mb_str(), char
),
+
name.char_str(
),
args, 2);
m_mainWidget = (WXWidget) dialogShell;
args, 2);
m_mainWidget = (WXWidget) dialogShell;
@@
-190,6
+183,9
@@
wxDialog::~wxDialog()
{
m_isBeingDeleted = true;
{
m_isBeingDeleted = true;
+ // if the dialog is modal, this will end its event loop
+ Show(false);
+
delete m_eventLoop;
if (m_mainWidget)
delete m_eventLoop;
if (m_mainWidget)
@@
-236,9
+232,9
@@
void wxDialog::SetTitle(const wxString& title)
{
wxXmString str( title );
XtVaSetValues( (Widget)m_mainWidget,
{
wxXmString str( title );
XtVaSetValues( (Widget)m_mainWidget,
- XmNtitle, title.mb_str(),
+ XmNtitle,
(const char*)
title.mb_str(),
XmNdialogTitle, str(),
XmNdialogTitle, str(),
- XmNiconName, title.mb_str(),
+ XmNiconName,
(const char*)
title.mb_str(),
NULL );
}
}
NULL );
}
}
@@
-248,10
+244,16
@@
bool wxDialog::Show( bool show )
if( !wxWindowBase::Show( show ) )
return false;
if( !wxWindowBase::Show( show ) )
return false;
+ if ( !show && IsModal() )
+ EndModal(wxID_CANCEL);
+
m_isShown = show;
if (show)
{
m_isShown = show;
if (show)
{
+ if (CanDoLayoutAdaptation())
+ DoLayoutAdaptation();
+
// this usually will result in TransferDataToWindow() being called
// which will change the controls values so do it before showing as
// otherwise we could have some flicker
// this usually will result in TransferDataToWindow() being called
// which will change the controls values so do it before showing as
// otherwise we could have some flicker