VSTGUI  4.10
Graphical User Interface Framework not only for VST plugins
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IApplication Class Referenceabstract

Application interface. More...

+ Inheritance diagram for IApplication:

Public Types

using WindowList = std::vector< WindowPtr >
 
using CommandLineArguments = std::vector< UTF8String >
 

Public Member Functions

virtual Application::IDelegategetDelegate () const =0
 Get the application delegate.
 
virtual IPreferencegetPreferences () const =0
 Get the application preferences.
 
virtual const
CommandLineArguments
getCommandLineArguments () const =0
 Get the command line arguments.
 
virtual const ISharedUIResourcesgetSharedUIResources () const =0
 Get the shared UI resources.
 
virtual const ICommonDirectoriesgetCommonDirectories () const =0
 Get common directories.
 
virtual WindowPtr createWindow (const WindowConfiguration &config, const WindowControllerPtr &controller)=0
 Create a new window.
 
virtual const WindowListgetWindows () const =0
 Get all application windows.
 
virtual AlertResult showAlertBox (const AlertBoxConfig &config)=0
 Show an application wide modal alert box.
 
virtual void showAlertBoxForWindow (const AlertBoxForWindowConfig &config)=0
 Show an alert box modal to a window.
 
virtual void registerCommand (const Command &command, char16_t defaultCommandKey)=0
 Register a command.
 
virtual bool executeCommand (const Command &command)=0
 Execute a command.
 
virtual void enableTooltips (bool state)=0
 Enable or disable tooltips in all windows.
 
virtual void quit ()=0
 Quit the application.
 
- Public Member Functions inherited from Interface
virtual ~Interface () noexcept
 
 Interface ()=default
 
 Interface (const Interface &)=delete
 
 Interface (Interface &&)=delete
 
Interfaceoperator= (const Interface &)=delete
 
Interfaceoperator= (Interface &&)=delete
 
template<typename T >
const auto dynamicCast () const
 
template<typename T >
auto dynamicCast ()
 

Static Public Member Functions

static IApplicationinstance ()
 Get the global instance of the application.
 

Detailed Description

Application interface.

Member Typedef Documentation

using CommandLineArguments = std::vector<UTF8String>
using WindowList = std::vector<WindowPtr>

Member Function Documentation

virtual WindowPtr createWindow ( const WindowConfiguration config,
const WindowControllerPtr controller 
)
pure virtual

Create a new window.

Parameters
configwindow configuration
controllerwindow controller (can be nullptr)
Returns
shared window pointer
virtual void enableTooltips ( bool  state)
pure virtual

Enable or disable tooltips in all windows.

Parameters
statetrue to enable tooltips, false for disabling them
virtual bool executeCommand ( const Command command)
pure virtual

Execute a command.

The command will be first dispatched to the active window (if there is one) and if the window did not handle the command the command is dispatched to the application delegate.

Parameters
commandcommand name and group
Returns
if the command was executed
virtual const CommandLineArguments& getCommandLineArguments ( ) const
pure virtual

Get the command line arguments.

virtual const ICommonDirectories& getCommonDirectories ( ) const
pure virtual

Get common directories.

virtual Application::IDelegate& getDelegate ( ) const
pure virtual

Get the application delegate.

virtual IPreference& getPreferences ( ) const
pure virtual

Get the application preferences.

virtual const ISharedUIResources& getSharedUIResources ( ) const
pure virtual

Get the shared UI resources.

virtual const WindowList& getWindows ( ) const
pure virtual

Get all application windows.

Note
The active window will be the first in the list.
Returns
a list of all windows
static IApplication& instance ( )
static

Get the global instance of the application.

virtual void quit ( )
pure virtual

Quit the application.

virtual void registerCommand ( const Command command,
char16_t  defaultCommandKey 
)
pure virtual

Register a command.

The command will be added to the application menu. When the menu item is selected the command is first dispatched to the active window and then to the application delegate.

Parameters
commandcommand name and group
defaultCommandKeydefault command key
virtual AlertResult showAlertBox ( const AlertBoxConfig config)
pure virtual

Show an application wide modal alert box.

Parameters
configalert box configuration
Returns
alert result
virtual void showAlertBoxForWindow ( const AlertBoxForWindowConfig config)
pure virtual

Show an alert box modal to a window.

Parameters
configalert box configuration

The documentation for this class was generated from the following file: