Creating Your Own Dialog Box
To create your own dialog box, follow the steps below:
-
Design the visual representation of the panel.
This step includes several aspects such as choosing which gadgets to use, how the focus is managed, or how gadgets will behave when the dialog is resized. This phase can be achieved by using Views Studio.
-
Display your panel in a dialog box.
You can either use the generated code of Views Studio (For details, see Using the Generated Code), or directly use the IlvDialog class. The constructors of IlvDialog provide a facility to pass a file name as a parameter.
The class IlvDialog has already two registered callbacks:
-
apply: This callback invokes the virtual apply method.
-
cancel: This callback invokes the virtual cancel method.
You can, for example, have two buttons in your dialog box, one with the callback set to “apply” and the other set to “cancel”.