UI: Programs: Replace "Options" button with "Menu"

This commit is contained in:
Nodir Temirkhodjaev 2023-05-08 19:06:17 +03:00
parent c23238269c
commit 609b612511
5 changed files with 8 additions and 8 deletions

View File

@ -107,7 +107,7 @@ QLayout *HomeWindow::setupHeader()
{ {
auto layout = new QHBoxLayout(); auto layout = new QHBoxLayout();
m_btMenu = ControlUtil::createButton(":/icons/application_double.png"); m_btMenu = ControlUtil::createButton(":/icons/node-tree.png");
m_btMenu->setMenu(windowManager()->trayIcon()->menu()); m_btMenu->setMenu(windowManager()->trayIcon()->menu());
layout->addWidget(m_btMenu); layout->addWidget(m_btMenu);

View File

@ -12,6 +12,7 @@
#include <form/controls/appinforow.h> #include <form/controls/appinforow.h>
#include <form/controls/controlutil.h> #include <form/controls/controlutil.h>
#include <form/controls/tableview.h> #include <form/controls/tableview.h>
#include <form/tray/trayicon.h>
#include <fortsettings.h> #include <fortsettings.h>
#include <manager/windowmanager.h> #include <manager/windowmanager.h>
#include <model/applistmodel.h> #include <model/applistmodel.h>
@ -134,7 +135,7 @@ void ProgramsWindow::retranslateUi()
m_btRemoveApp->setText(tr("Remove")); m_btRemoveApp->setText(tr("Remove"));
m_btServices->setText(tr("Services")); m_btServices->setText(tr("Services"));
m_btOptions->setText(tr("Options")); m_btMenu->setText(tr("Menu"));
appListModel()->refresh(); appListModel()->refresh();
@ -239,10 +240,8 @@ QLayout *ProgramsWindow::setupHeader()
&WindowManager::showServicesWindow); &WindowManager::showServicesWindow);
// Options button // Options button
m_btOptions = ControlUtil::createLinkButton(":/icons/cog.png"); m_btMenu = ControlUtil::createLinkButton(":/icons/node-tree.png");
m_btMenu->setMenu(windowManager()->trayIcon()->menu());
connect(m_btOptions, &QAbstractButton::clicked, windowManager(),
&WindowManager::showOptionsWindow);
layout->addWidget(m_btEdit); layout->addWidget(m_btEdit);
layout->addWidget(ControlUtil::createSeparator(Qt::Vertical)); layout->addWidget(ControlUtil::createSeparator(Qt::Vertical));
@ -253,7 +252,7 @@ QLayout *ProgramsWindow::setupHeader()
layout->addStretch(); layout->addStretch();
layout->addWidget(m_btServices); layout->addWidget(m_btServices);
layout->addWidget(ControlUtil::createSeparator(Qt::Vertical)); layout->addWidget(ControlUtil::createSeparator(Qt::Vertical));
layout->addWidget(m_btOptions); layout->addWidget(m_btMenu);
return layout; return layout;
} }

View File

@ -90,7 +90,7 @@ private:
QPushButton *m_btRemoveApp = nullptr; QPushButton *m_btRemoveApp = nullptr;
QPushButton *m_btEdit = nullptr; QPushButton *m_btEdit = nullptr;
QPushButton *m_btServices = nullptr; QPushButton *m_btServices = nullptr;
QPushButton *m_btOptions = nullptr; QPushButton *m_btMenu = nullptr;
ProgramEditDialog *m_formAppEdit = nullptr; ProgramEditDialog *m_formAppEdit = nullptr;
TableView *m_appListView = nullptr; TableView *m_appListView = nullptr;
AppInfoRow *m_appInfoRow = nullptr; AppInfoRow *m_appInfoRow = nullptr;

View File

@ -37,6 +37,7 @@
<file>icons/key.png</file> <file>icons/key.png</file>
<file>icons/lightbulb.png</file> <file>icons/lightbulb.png</file>
<file>icons/lock_open.png</file> <file>icons/lock_open.png</file>
<file>icons/node-tree.png</file>
<file>icons/page_copy.png</file> <file>icons/page_copy.png</file>
<file>icons/pencil.png</file> <file>icons/pencil.png</file>
<file>icons/play.png</file> <file>icons/play.png</file>

BIN
src/ui/icons/node-tree.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB