Skip to content
This repository has been archived by the owner on Feb 13, 2024. It is now read-only.

Commit

Permalink
Revert "Add support for tray icon (linux)"
Browse files Browse the repository at this point in the history
This reverts commit e696350.
  • Loading branch information
IndrekV committed Apr 6, 2015
1 parent df96f52 commit c15250c
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 23 deletions.
1 change: 0 additions & 1 deletion src/ui/linux/TogglDesktop/Resources.qrc
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,5 @@
<file>fonts/RobotoTTF/Roboto-Regular.ttf</file>
<file>fonts/RobotoTTF/Roboto-Thin.ttf</file>
<file>fonts/RobotoTTF/Roboto-ThinItalic.ttf</file>
<file>icons/16x16/toggldesktop_gray.png</file>
</qresource>
</RCC>
Binary file not shown.
17 changes: 0 additions & 17 deletions src/ui/linux/TogglDesktop/mainwindowcontroller.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,20 +89,8 @@ MainWindowController::MainWindowController(
icon.addFile(QString::fromUtf8(":/icons/1024x1024/toggldesktop.png"));
setWindowIcon(icon);

trayIcon = new QSystemTrayIcon(this);
normalTrayIcon = QIcon(":/icons/16x16/toggldesktop.png");
disabledTrayIcon = QIcon(":/icons/16x16/toggldesktop_gray.png");

connectMenuActions();
enableMenuActions();

trayMenu = new QMenu(this);
trayMenu->addAction(actionStop);
trayMenu->addAction(actionContinue);
trayMenu->addAction(actionLogout);

trayIcon->setContextMenu(trayMenu);
trayIcon->show();
}

MainWindowController::~MainWindowController() {
Expand Down Expand Up @@ -177,11 +165,6 @@ void MainWindowController::enableMenuActions() {
actionClear_Cache->setEnabled(loggedIn);
actionSend_Feedback->setEnabled(loggedIn);
actionReports->setEnabled(loggedIn);
if (tracking) {
trayIcon->setIcon(normalTrayIcon);
} else {
trayIcon->setIcon(disabledTrayIcon);
}
}

void MainWindowController::connectMenuActions() {
Expand Down
5 changes: 0 additions & 5 deletions src/ui/linux/TogglDesktop/mainwindowcontroller.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,11 +92,6 @@ class MainWindowController : public QMainWindow {
QAction *actionSend_Feedback;
QAction *actionReports;

QMenu *trayMenu;
QIcon normalTrayIcon;
QIcon disabledTrayIcon;
QSystemTrayIcon *trayIcon;

PreferencesDialog *preferencesDialog;
AboutDialog *aboutDialog;
FeedbackDialog *feedbackDialog;
Expand Down

0 comments on commit c15250c

Please sign in to comment.