A class which encapsulates an MFC CDialog object. Derived from a PyCWnd object.
-
Creates a modless window for the dialog.
-
Creates a modal window for the dialog.
-
Closes a modal dialog.
-
Sets focus to a specific control.
-
Converts the dialog-box units of a rectangle to screen units.
-
Calls the default MFC OnCancel handler.
-
Calls the default MFC OnOK handler.
-
Calls the default MFC OnInitDialog handler.
sentinel
PyCDialog.CreateWindow
CreateWindow(obParent) Create a modeless window for the dialog box.
-
obParent=None : PyCWnd
The parent window for the new window
- CDialog::CreateIndirect
PyCDialog.DoModal
int = DoModal() Create a modal window for the dialog box.
- CDialog::DoModal
The return value from the dialog. This is the value passed to PyCDialog::EndDialog.
PyCDialog.EndDialog
EndDialog(result) Ends a modal dialog box.
-
result : int
The value to be returned by the PyCDialog::DoModal method.
- CDialog::EndDialog
PyCDialog.GotoDlgCtrl
GotoDlgCtrl(control) Moves the focus to the specified control in the dialog box.
-
control : PyCWnd
The control to get the focus.
PyCDialog.MapDialogRect
(left, top, right, bottom) = MapDialogRect(rect) Converts the dialog-box units of a rectangle to screen units.
-
rect : (left, top, right, bottom)
The rect to be converted
PyCDialog.OnCancel
OnCancel() Calls the default MFC OnCancel handler.
- PyCDialog.OnCancel virtual method
PyCDialog.OnCancel Virtual
OnCancel() Called by the MFC architecture when the user selects the Cancel button.
The procedure is expected to dismiss the window with the PyCDialog::EndDialog method.
The base implementation (which dismisses the dialog) is not called if a handler exists. This can be
done via PyCDialog::OnCancel.
PyCDialog.OnInitDialog
int = OnInitDialog() Calls the default MFC OnInitDialog handler.
- PyCDialog.OnInitDialog virtual method
PyCDialog.OnInitDialog Virtual
OnInitDialog() Override to augment dialog-box initialization.
The base implementation is not called if a handler exists. This can be
done via PyCDialog::OnInitDialog.
Specifies whether the application has set the input focus to
one of the controls in the dialog box. If OnInitDialog returns
nonzero, Windows sets the input focus to the first control
in the dialog box. The application can return 0/None only if
it has explicitly set the input focus to one of the controls in the
dialog box.
PyCDialog.OnOK
OnOK() Calls the default MFC OnOK handler.
- PyCDialog.OnOK virtual method
PyCDialog.OnOK Virtual
OnOK() Called by the MFC architecture when the user selects the OK button.
The procedure is expected to dismiss the window with the PyCDialog::EndDialog method.
The base implementation (which dismisses the dialog) is not called if a handler exists. This can be
done via PyCDialog::OnOK.