26 #ifndef __TERRALIB_QT_AF_INTERNAL_APPLICATIONCONTROLLER_H 
   27 #define __TERRALIB_QT_AF_INTERNAL_APPLICATIONCONTROLLER_H 
   30 #include "../../common/Singleton.h" 
   43 #include <QStringList> 
Template support for singleton pattern.
 
static void prepareQtEnvironment(const QString &configFileName, const QString &splashFileName)
 
The base API for TerraLib applications.
 
virtual void setMsgBoxParentWidget(QWidget *w)
Tells the widget to be used as the parent of messages showned in a QMessageBox.
 
QMenuBar * findMenuBar(const QString &id) const
Returns the menu bar registered with key id.
 
QString m_appTitle
Application title.
 
QWidget * m_msgBoxParentWidget
Parent used to show message boxes.
 
QString m_appHelpFile
Name of the help file.
 
QString m_appDefaultIconTheme
Name of the icon theme to be used.
 
std::vector< QMenu * > m_menus
Menus registered.
 
QString m_appOrganization
Organization name.
 
QColor getSelectionColor() const
Returns the application selection color.
 
virtual void setConfigFile(const std::string &configFileName)
Tells wich configuration file to be used by the controller during its initialization.
 
QString m_appName
Application name.
 
QMenu * findMenu(const QString &id) const
Returns the menu registered with key id.
 
void registerToolBar(const QString &id, QToolBar *bar)
Register the toolbar in the list of the known toolbars.
 
QColor m_selectionColor
Default selection color.
 
std::string m_appUserSettingsFile
Name of the user settings file.
 
const QString & getAboutLogo() const
Returns the application project extension.
 
QActionGroup * findActionGroup(const QString &id) const
Returns the action group identified by id or NULL if there's not an action group identified by id.
 
QString m_appIconName
Icon used in the application.
 
std::vector< QMenuBar * > m_menuBars
Menu bars registered.
 
virtual ~ApplicationController()
Destructor.
 
QString m_appPluginsPath
Name of the plugins path.
 
void addToolBar(const QString &id, QToolBar *bar)
Register the toolbar in the list of the known toolbars and dispatch an event.
 
const QString & getAppIconName() const
Returns the application icon.
 
std::map< QString, QToolBar * > m_toolbars
Toolbars registered.
 
const QString & getAppTitle() const
Returns the application title.
 
std::string m_appDatasourcesFile
Name of the file containing datasources used.
 
const QString & getAppVersion() const
Returns the application version.
 
void registerMenu(QMenu *mnu)
Register the mnu.
 
void removeToolBar(const QString &id)
Removes the toolbar identified by id.
 
const QString & getUserDataDir() const
 
virtual void finalize()
Finalize the application framework.
 
QString m_appVersion
The application version.
 
const QString & getAppPluginsPath() const
Returns the plugins file path of application.
 
QWidget * getMainWindow() const
Returns main window.
 
bool m_initialized
A flag indicating if the controller is initialized.
 
QString m_appIconThemeDir
Directory of the application icon theme.
 
QString m_appToolBarDefaultIconSize
Size of the tool buttons.
 
const QString & getTlibLogo() const
 
virtual void initialize()
Initializes the application framework.
 
QToolBar * getToolBar(const QString &id) const
Return the toolbar identified by id or NULL if none is found.
 
ApplicationController()
Constructor.
 
void setSelectionColor(const QColor &c)
Sets the application selection color.
 
QAction * findAction(const QString &id) const
Returns the action identified by id or NULL if there's not an action identified by id.
 
QString m_userDataDir
The data dir used to store data files.
 
void setResetTerraLibFlag(const bool &status)
 
void registerMenuBar(QMenuBar *bar)
Register the bar.
 
QSettings & getSettings()
Return the QSettings of the application. This can be used to add settings from external sources.
 
std::vector< QToolBar * > getToolBars() const
Return the list of registered toolbars.
 
virtual void finalizePlugins()
 
void addListener(QObject *obj, const ListenerType &type=BOTH)
Insert an application item that will listen to framework events.
 
void trigger(te::qt::af::evt::Event *)
 
int getDefaultSRID() const
Returns the most recent project.
 
std::set< QObject * > m_applicationItems
The list of registered application items.
 
virtual void initializePlugins()
Load the plugin list and initialize the plugins enabled by the user.
 
int m_defaultSRID
Default SRID value.
 
void safeReadServersList(const std::string &fileName)
 
QMenu * getMenu(const QString &id)
Returns a menu registered with key id.
 
QMenuBar * getMenuBar(const QString &id) const
Returns a menu bar registered with key id.
 
const QString & getAppName() const
Returns the application name.
 
std::string m_appConfigFile
The application framework configuration file.
 
void triggered(te::qt::af::evt::Event *)
Send events in broadcast for all registered components.
 
void removeListener(QObject *obj)
Remove the obj from the list of event listeners.
 
A base class for application events.
 
#define TEQTAFEXPORT
You can use this macro in order to export/import classes and functions from this module.
 
Proxy configuration file for TerraView (see terraview_config.h).