2 ******************************************************************************
5 * @author The OpenPilot Team, http://www.openpilot.org Copyright (C) 2010.
6 * Parts by Nokia Corporation (qt-info@nokia.com) Copyright (C) 2009.
7 * @addtogroup GCSPlugins GCS Plugins
9 * @addtogroup CorePlugin Core Plugin
11 * @brief The Core GCS plugin
12 *****************************************************************************/
14 * This program is free software; you can redistribute it and/or modify
15 * it under the terms of the GNU General Public License as published by
16 * the Free Software Foundation; either version 3 of the License, or
17 * (at your option) any later version.
19 * This program is distributed in the hope that it will be useful, but
20 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
21 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
24 * You should have received a copy of the GNU General Public License along
25 * with this program; if not, write to the Free Software Foundation, Inc.,
26 * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
33 #include "mainwindow.h"
37 class CoreImpl
: public ICore
{
41 CoreImpl(MainWindow
*mainwindow
);
44 bool showOptionsDialog(const QString
&group
= QString(),
45 const QString
&page
= QString(),
47 bool showWarningWithOptions(const QString
&title
, const QString
&text
,
48 const QString
&details
= QString(),
49 const QString
&settingsCategory
= QString(),
50 const QString
&settingsId
= QString(),
53 ActionManager
*actionManager() const;
54 UniqueIDManager
*uniqueIDManager() const;
55 MessageManager
*messageManager() const;
56 ConnectionManager
*connectionManager() const;
57 UAVGadgetInstanceManager
*uavGadgetInstanceManager() const;
58 VariableManager
*variableManager() const;
59 ThreadManager
*threadManager() const;
60 ModeManager
*modeManager() const;
61 MimeDatabase
*mimeDatabase() const;
63 QSettings
*settings(QSettings::Scope scope
= QSettings::UserScope
) const;
64 SettingsDatabase
*settingsDatabase() const;
65 void readMainSettings(QSettings
*qs
, bool workspaceDiffOnly
);
66 void saveMainSettings(QSettings
*qs
);
67 void readSettings(IConfigurablePlugin
*plugin
, QSettings
*qs
= 0);
68 void saveSettings(IConfigurablePlugin
*plugin
, QSettings
*qs
= 0);
69 void deleteSettings();
71 QString
resourcePath() const;
73 IContext
*currentContextObject() const;
75 QMainWindow
*mainWindow() const;
77 // adds and removes additional active contexts, this context is appended to the
78 // currently active contexts. call updateContext after changing
79 void addAdditionalContext(int context
);
80 void removeAdditionalContext(int context
);
81 bool hasContext(int context
) const;
82 void addContextObject(IContext
*contex
);
83 void removeContextObject(IContext
*contex
);
87 void openFiles(const QStringList
&fileNames
);
90 MainWindow
*m_mainwindow
;
91 friend class MainWindow
;
93 } // namespace Internal