mirror of
https://github.com/gnif/LookingGlass.git
synced 2025-10-10 09:28:08 +00:00
28 lines
565 B
C++
28 lines
565 B
C++
#pragma once
|
|
|
|
#define WIN32_LEAN_AND_MEAN
|
|
#include <windows.h>
|
|
#include <shellapi.h>
|
|
|
|
#define WM_NOTIFY_ICON (WM_USER)
|
|
|
|
class CWindow {
|
|
static ATOM s_atom;
|
|
static UINT s_taskbarCreated;
|
|
static LRESULT CALLBACK wndProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
|
|
|
HWND m_hwnd = NULL;
|
|
NOTIFYICONDATA m_iconData;
|
|
LRESULT handleMessage(UINT uMsg, WPARAM wParam, LPARAM lParam);
|
|
LRESULT onCreate();
|
|
void registerIcon();
|
|
|
|
public:
|
|
static bool registerClass();
|
|
CWindow();
|
|
~CWindow();
|
|
void destroy();
|
|
|
|
HWND hwnd() { return m_hwnd; }
|
|
};
|