diff options
| author | fffw | 2015-01-20 19:58:48 +0800 |
|---|---|---|
| committer | fffw | 2015-01-20 19:58:48 +0800 |
| commit | 94ea832f6a261570cada495d49e01e97321663a8 (patch) | |
| tree | a46834a30f26652fe662c3af0bc80add9213015a | |
| parent | 9be7e1dfa77b85bc57e7737c43fcecf23257ace1 (diff) | |
| download | systray-94ea832f6a261570cada495d49e01e97321663a8.tar.bz2 | |
use MinGW-W64 for up to date headers
| -rw-r--r-- | README.md | 14 | ||||
| -rw-r--r-- | platform/windows.c | 21 |
2 files changed, 10 insertions, 25 deletions
@@ -3,15 +3,21 @@ Supports Windows and Mac OSX, Linux coming soon. ## Install -```sh -go get github.com/getlantern/systray -``` +### Linux ```sh sudo apt-get install libgtk-3-dev ``` -if you don't have this package on Linux. +### Windows + +Install [MinGW-W64](http://sourceforge.net/projects/mingw-w64) as it has up to date SDK headers we require. + +Then, simply + +```sh +go get github.com/getlantern/systray +``` ## Try diff --git a/platform/windows.c b/platform/windows.c index a267f44..7a57270 100644 --- a/platform/windows.c +++ b/platform/windows.c @@ -3,28 +3,7 @@ #include <windows.h> #include <shellapi.h> -// Below are windows macros but not found in current header file, -// so we define it manually -#ifndef WM_MENUCOMMAND -#define WM_MENUCOMMAND 0x0126 -#endif - -#ifndef MIM_APPLYTOSUBMENUS -#define MIM_APPLYTOSUBMENUS 0x80000000 -#endif - -#ifndef MIM_STYLE -#define MIM_STYLE 0x00000010 -#endif - -#ifndef MNS_NOTIFYBYPOS -#define MNS_NOTIFYBYPOS 0x08000000 -#endif - - -// Our own macros #define WM_SYSTRAY_MESSAGE (WM_USER + 1) - #define MAX_LOADSTRING 100 NOTIFYICONDATA nid; |
