Added the managed widget to make it work.
git-svn-id: svn://10.0.0.236/trunk@8973 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -63,7 +63,7 @@ void nsDialog::Create(nsIWidget *aParent,
|
||||
if (DBG) fprintf(stderr, "Parent 0x%x\n", parentWidget);
|
||||
|
||||
|
||||
mWidget = ::XtVaCreateManagedWidget("Dialog",
|
||||
mShell = ::XtVaCreateManagedWidget("Dialog",
|
||||
xmDialogShellWidgetClass,
|
||||
parentWidget,
|
||||
XmNwidth, aRect.width,
|
||||
@@ -74,6 +74,21 @@ void nsDialog::Create(nsIWidget *aParent,
|
||||
XmNy, aRect.y,
|
||||
nsnull);
|
||||
|
||||
// Initially used xmDrawingAreaWidgetClass instead of
|
||||
// newManageClass. Drawing area will spontaneously resize
|
||||
// to fit it's contents.
|
||||
|
||||
mWidget = ::XtVaCreateManagedWidget("drawingArea",
|
||||
newManageClass,
|
||||
mShell,
|
||||
XmNwidth, aRect.width,
|
||||
XmNheight, aRect.height,
|
||||
XmNmarginHeight, 0,
|
||||
XmNmarginWidth, 0,
|
||||
XmNrecomputeSize, False,
|
||||
XmNuserData, this,
|
||||
nsnull);
|
||||
|
||||
if (DBG) fprintf(stderr, "Dialog 0x%x this 0x%x\n", mWidget, this);
|
||||
|
||||
// save the event callback function
|
||||
|
||||
@@ -61,6 +61,7 @@ public:
|
||||
//virtual void PreCreateWidget(nsWidgetInitData *aInitData);
|
||||
|
||||
private:
|
||||
Widget mShell;
|
||||
|
||||
// this should not be public
|
||||
static PRInt32 GetOuterOffset() {
|
||||
|
||||
Reference in New Issue
Block a user