mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 01:05:34 +08:00
Ref T310, removed "m_separator" from IMenuDelegate as it is not used
This commit is contained in:
@@ -71,8 +71,8 @@ namespace BlackGui
|
||||
return mv->selectedObjects();
|
||||
}
|
||||
|
||||
CShowSimulatorFileMenu::CShowSimulatorFileMenu(CAircraftModelView *modelView, COverlayMessagesFrame *messageFrame, bool separator) :
|
||||
IAircraftModelViewMenu(modelView, separator), m_messageFrame(messageFrame)
|
||||
CShowSimulatorFileMenu::CShowSimulatorFileMenu(CAircraftModelView *modelView, COverlayMessagesFrame *messageFrame) :
|
||||
IAircraftModelViewMenu(modelView), m_messageFrame(messageFrame)
|
||||
{ }
|
||||
|
||||
const CLogCategoryList &CShowSimulatorFileMenu::getLogCategories()
|
||||
@@ -158,8 +158,8 @@ namespace BlackGui
|
||||
|
||||
// --------------------------------- with DB data ---------------------------------
|
||||
|
||||
CConsolidateWithDbDataMenu::CConsolidateWithDbDataMenu(CAircraftModelView *modelView, QObject *modelsTarget, bool separator) :
|
||||
IAircraftModelViewMenu(modelView, separator), m_modelsTarget(modelsTarget)
|
||||
CConsolidateWithDbDataMenu::CConsolidateWithDbDataMenu(CAircraftModelView *modelView, QObject *modelsTarget) :
|
||||
IAircraftModelViewMenu(modelView), m_modelsTarget(modelsTarget)
|
||||
{
|
||||
// it can be the target is not yet known
|
||||
if (modelsTarget)
|
||||
@@ -265,8 +265,8 @@ namespace BlackGui
|
||||
|
||||
// --------------------------------- with simulator models ---------------------------------
|
||||
|
||||
CConsolidateWithSimulatorModels::CConsolidateWithSimulatorModels(CAircraftModelView *modelView, QObject *modelsTarget, bool separator) :
|
||||
IAircraftModelViewMenu(modelView, separator), m_modelsTarget(modelsTarget)
|
||||
CConsolidateWithSimulatorModels::CConsolidateWithSimulatorModels(CAircraftModelView *modelView, QObject *modelsTarget) :
|
||||
IAircraftModelViewMenu(modelView), m_modelsTarget(modelsTarget)
|
||||
{
|
||||
// it can be the target is not yet known
|
||||
if (modelsTarget)
|
||||
|
||||
@@ -32,8 +32,8 @@ namespace BlackGui
|
||||
|
||||
public:
|
||||
//! Constructor
|
||||
IAircraftModelViewMenu(BlackGui::Views::CAircraftModelView *modelView, bool separator = true) :
|
||||
IMenuDelegate(modelView, separator)
|
||||
IAircraftModelViewMenu(BlackGui::Views::CAircraftModelView *modelView) :
|
||||
IMenuDelegate(modelView)
|
||||
{}
|
||||
|
||||
//! Log.categories
|
||||
@@ -60,7 +60,7 @@ namespace BlackGui
|
||||
|
||||
public:
|
||||
//! Constructor
|
||||
CShowSimulatorFileMenu(BlackGui::Views::CAircraftModelView *modelView, BlackGui::COverlayMessagesFrame *messageFrame, bool separator = true);
|
||||
CShowSimulatorFileMenu(Views::CAircraftModelView *modelView, COverlayMessagesFrame *messageFrame);
|
||||
|
||||
//! Log.categories
|
||||
static const BlackMisc::CLogCategoryList &getLogCategories();
|
||||
@@ -89,7 +89,7 @@ namespace BlackGui
|
||||
using IAircraftModelViewMenu::IAircraftModelViewMenu;
|
||||
|
||||
//! Constructor
|
||||
CConsolidateWithDbDataMenu(BlackGui::Views::CAircraftModelView *modelView, QObject *modelsTarget, bool separator = true);
|
||||
CConsolidateWithDbDataMenu(BlackGui::Views::CAircraftModelView *modelView, QObject *modelsTarget);
|
||||
|
||||
//! Log.categories
|
||||
static const BlackMisc::CLogCategoryList &getLogCategories();
|
||||
@@ -121,7 +121,7 @@ namespace BlackGui
|
||||
using IAircraftModelViewMenu::IAircraftModelViewMenu;
|
||||
|
||||
//! Constructor
|
||||
CConsolidateWithSimulatorModels(BlackGui::Views::CAircraftModelView *modelView, QObject *modelsTarget, bool separator = true);
|
||||
CConsolidateWithSimulatorModels(Views::CAircraftModelView *modelView, QObject *modelsTarget);
|
||||
|
||||
//! Log.categories
|
||||
static const BlackMisc::CLogCategoryList &getLogCategories();
|
||||
|
||||
@@ -26,8 +26,8 @@ namespace BlackGui
|
||||
return cats;
|
||||
}
|
||||
|
||||
CFontMenu::CFontMenu(QWidget *widget, bool separator, Qt::ShortcutContext shortcutContext) :
|
||||
IMenuDelegate(widget, separator), m_widget(widget)
|
||||
CFontMenu::CFontMenu(QWidget *widget, Qt::ShortcutContext shortcutContext) :
|
||||
IMenuDelegate(widget), m_widget(widget)
|
||||
{
|
||||
this->m_fontDialogAction.reset(new QAction(CIcons::font16(), "Font", this));
|
||||
QObject::connect(this->m_fontDialogAction.data(), &QAction::triggered, this, &CFontMenu::changeFontDialog);
|
||||
|
||||
@@ -33,7 +33,7 @@ namespace BlackGui
|
||||
|
||||
public:
|
||||
//! Constructor
|
||||
CFontMenu(QWidget *widget, bool separator = true, Qt::ShortcutContext shortcutContext = Qt::WidgetShortcut);
|
||||
CFontMenu(QWidget *widget, Qt::ShortcutContext shortcutContext = Qt::WidgetShortcut);
|
||||
|
||||
//! Log.categories
|
||||
static const BlackMisc::CLogCategoryList &getLogCategories();
|
||||
|
||||
@@ -81,7 +81,7 @@ namespace BlackGui
|
||||
//! Is menu?
|
||||
bool isSubMenu() const { return m_isMenu; }
|
||||
|
||||
//! Is separator
|
||||
//! Is separator?
|
||||
bool isSeparator() const { return m_title == "_SEP_"; }
|
||||
|
||||
//! Is menu?
|
||||
@@ -118,20 +118,24 @@ namespace BlackGui
|
||||
//! Path converter into separator
|
||||
static const QString &pathSeparator() { static const QString p("_SEPARATOR"); return p; }
|
||||
|
||||
//! Model set
|
||||
static const QString &pathModelSet() { static const QString p("Custom.10.Model/Model set"); return p; }
|
||||
|
||||
//! Model set, new set
|
||||
static const QString &pathModelSetNew() { static const QString p("Custom.10.Model/Model set/New set"); return p; }
|
||||
|
||||
//! Simulator sub menu
|
||||
static const QString &pathSimulator() { static const QString p("Custom.11.Simulator/Simulator"); return p; }
|
||||
static const QString &pathSimulator() { static const QString p("Custom.10.Simulator/Simulator"); return p; }
|
||||
|
||||
//! Simulator sub menu reload models
|
||||
static const QString &pathSimulatorModelsReload() { static const QString p("Custom.11.Simulator/Simulator/Reload models"); return p; }
|
||||
static const QString &pathSimulatorModelsReload() { static const QString p("Custom.10.Simulator/Simulator/Reload models"); return p; }
|
||||
|
||||
//! Simulator sub menu reload models
|
||||
static const QString &pathSimulatorModelsClearCache() { static const QString p("Custom.11.Simulator/Simulator/Clear model caches"); return p; }
|
||||
static const QString &pathSimulatorModelsClearCache() { static const QString p("Custom.10.Simulator/Simulator/Clear model caches"); return p; }
|
||||
|
||||
//! Model
|
||||
static const QString &pathModel() { static const QString p("Custom.11.Model"); return p; }
|
||||
|
||||
//! Model set
|
||||
static const QString &pathModelSet() { static const QString p("Custom.11.Model/Model set"); return p; }
|
||||
|
||||
//! Model set, new set
|
||||
static const QString &pathModelSetNew() { static const QString p("Custom.11.Model/Model set/New set"); return p; }
|
||||
|
||||
//! Stash sub menu
|
||||
static const QString &pathStash() { static const QString p("Custom.12.Stash/Stash"); return p; }
|
||||
|
||||
@@ -51,8 +51,7 @@ namespace BlackGui
|
||||
|
||||
protected:
|
||||
//! Constructor
|
||||
IMenuDelegate(QWidget *parent = nullptr, bool separator = false) :
|
||||
QObject(parent), m_separator(separator) {}
|
||||
IMenuDelegate(QWidget *parent = nullptr) : QObject(parent) {}
|
||||
|
||||
//! Delegate down one level
|
||||
void nestedCustomMenu(CMenuActions &menuActions) const
|
||||
@@ -70,7 +69,6 @@ namespace BlackGui
|
||||
}
|
||||
|
||||
IMenuDelegate *m_nestedDelegate = nullptr; //!< nested delegate if any
|
||||
bool m_separator = false; //!< at end, terminate with separator
|
||||
};
|
||||
} // ns
|
||||
} // ns
|
||||
|
||||
Reference in New Issue
Block a user