Application class.
More...
#include <ilviews/gadgets/appli.h>
Application class.
Library: ilvgadgt
Base class for applications generated with Rogue Wave Views Studio.
- See also
- IlvContainer.
Accessors\nAccessors provide a scriptable and uniform way to inspect and modify an object by using its base class methods <tt>IlvValueInterface::queryValue()</tt>, <tt>IlvValueInterface::queryValues()</tt>, <tt>IlvValueInterface::changeValue()</tt>, <tt>IlvValueInterface::changeValues()</tt>.\n\n\nThis class inherits the accessors of its superclass \c IlvValueInterface and adds the following ones:
Data accessors
Method accessors
◆ IlvApplication() [1/2]
IlvApplication::IlvApplication |
( |
const char * |
name, |
|
|
const char * |
displayName, |
|
|
int |
argc = 0 , |
|
|
char ** |
argv = 0 |
|
) |
| |
Constructor.
This constructor creates an instance of IlvApplication
, whose name is provided by the parameter name and whose display (IlvDisplay
class) is created using the parameters displayName, argc, and argv.
◆ IlvApplication() [2/2]
Constructor.
This constructor initializes a new IlvApplication
using the display provided in the parameter display. The name of this new application is initialized to a copy of the string name. If the owner parameter is IlTrue
, the display is deleted by the application destructor.
◆ addPanel()
Adds a panel to the list of panels.
Adds a panel to the internal list of panels. For classes generated by Rogue Wave Views Studio, each panel is added to the application immediately after its creation. Consequently, use this function only when adding a panel to an application that has not been created with Rogue Wave Views Studio.
- Parameters
-
◆ beforeRunning()
virtual void IlvApplication::beforeRunning |
( |
| ) |
|
|
virtual |
Called before launching the event loop.
Can be redefined by deriving the class generated by Rogue Wave Views Studio. This method is called using the member function run()
just before launching the event loop. The definition of this method within the IlvApplication
class defaults to nothing.
◆ GetApplication()
Returns the application object connected to the specified container.
- Parameters
-
- Returns
- The application object connected to container, or
0
if container is not connected to an application.
- See also
IlvApplication::addPanel
.
◆ getDisplay()
Gets the display instance used to create the object.
- Returns
- A pointer to the display instance that was used to create this object.
◆ getName()
const char* IlvApplication::getName |
( |
| ) |
const |
|
virtual |
Gets the application name.
- Returns
- The application name.
Reimplemented from IlvValueInterface.
◆ getPanel()
IlvContainer* IlvApplication::getPanel |
( |
const char * |
name | ) |
const |
Gets an application panel giving its name.
- Returns
- The application panel whose name is name, or
0
if there's no panel with this name in the application.
◆ hidePanel()
void IlvApplication::hidePanel |
( |
const char * |
name | ) |
|
Closes a panel.
Closes a panel by using its name.
- Parameters
-
name | The name of the panel. |
◆ mainLoop()
virtual void IlvApplication::mainLoop |
( |
| ) |
|
|
virtual |
The main loop of the application.
The default implementation calls the function IlvMainLoop
.
◆ makePanels()
virtual void IlvApplication::makePanels |
( |
| ) |
|
|
virtual |
Creates the application panels.
This function is called when the application is initialized and creates the application panels. As defined in the IlvApplication
class, this method does nothing directly, but may be redefined in subclasses. For example, this method is redefined by the classes generated by Rogue Wave Views Studio.
◆ raisePanel()
void IlvApplication::raisePanel |
( |
const char * |
name | ) |
|
Raises a panel.
Brings a panel to the foreground by using its name.
- Parameters
-
name | The name of the panel. |
◆ realize()
void IlvApplication::realize |
( |
| ) |
|
Initializes the application.
Initializes the application by creating its panels if the application is not yet initialized. This function has no effect if it is called more than once. It is called by the run
member function. However, if you want to initialize your application before running it, you can call this function.
◆ removePanel()
Removes a panel.
Removes a panel from the application and optionally delete it. A panel which is part of an application must not be deleted without being removed from the application.
- Parameters
-
panel | The panel to remove from the application. |
destroyIt | If set to IlTrue , the panel is destroyed through a call to its destructor. |
◆ run()
virtual void IlvApplication::run |
( |
| ) |
|
|
virtual |
Initializes the application.
Initializes the application and launches the event loop through a call to IlvMainLoop
. The application is initialized only once. run
is the entry point for the application.
◆ setState()
virtual IlBoolean IlvApplication::setState |
( |
const char * |
stateName | ) |
|
|
virtual |
Set the application to the state specified by its name.
- Parameters
-
stateName | The name of the state. |
◆ showPanel()
void IlvApplication::showPanel |
( |
const char * |
name | ) |
|
Opens a panel.
Opens a panel by using its name.
- Parameters
-
name | The name of the panel. |