Skip to content

Commit

Permalink
Add icon
Browse files Browse the repository at this point in the history
  • Loading branch information
mhtvsSFrpHdE committed Aug 10, 2022
1 parent 8339224 commit 8207a91
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 0 deletions.
Binary file added qpp/prefetch/Resource/icon/main/prefetch.ico
Binary file not shown.
Binary file added qpp/prefetch/Resource/icon/main/prefetch.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions qpp/prefetch/Source/Interface/tray_icon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,6 @@ void TrayIcon::init()

void TrayIcon::start()
{
TrayIcon::systemTrayIcon->setIcon(QIcon(":/qrc/Resource/icon/main/prefetch.png"));
TrayIcon::systemTrayIcon->show();
}
6 changes: 6 additions & 0 deletions qpp/prefetch/prefetch.pro
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,9 @@ QMAKE_CFLAGS_RELEASE -= -O1
QMAKE_CFLAGS_RELEASE -= -O2
QMAKE_CFLAGS_RELEASE -= -O3
QMAKE_CFLAGS_RELEASE *= -Ofast

# Icon
RC_FILE = prefetch.rc

RESOURCES += \
prefetch.qrc
5 changes: 5 additions & 0 deletions qpp/prefetch/prefetch.qrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<RCC>
<qresource prefix="/qrc">
<file>Resource/icon/main/prefetch.png</file>
</qresource>
</RCC>
1 change: 1 addition & 0 deletions qpp/prefetch/prefetch.rc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
IDI_ICON1 ICON DISCARDABLE "Resource/icon/main/prefetch.ico"

0 comments on commit 8207a91

Please sign in to comment.