summaryrefslogtreecommitdiff
path: root/plugins/W7UI/clistproxywindow.h
diff options
context:
space:
mode:
authorVadim Dashevskiy <watcherhd@gmail.com>2012-05-23 07:44:30 +0000
committerVadim Dashevskiy <watcherhd@gmail.com>2012-05-23 07:44:30 +0000
commitf3d44bc057201407373012b7f682881bda7b3d98 (patch)
treeddf031a82529c84e13222131cf184ecf176d3954 /plugins/W7UI/clistproxywindow.h
parentc2d827972a16f1710406d15e58304aecc4e1c9b5 (diff)
some includes restored, mir_full.sln updated, some renaming of folders and projects
git-svn-id: http://svn.miranda-ng.org/main/trunk@140 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/W7UI/clistproxywindow.h')
-rw-r--r--plugins/W7UI/clistproxywindow.h64
1 files changed, 64 insertions, 0 deletions
diff --git a/plugins/W7UI/clistproxywindow.h b/plugins/W7UI/clistproxywindow.h
new file mode 100644
index 0000000000..153c59089b
--- /dev/null
+++ b/plugins/W7UI/clistproxywindow.h
@@ -0,0 +1,64 @@
+#ifndef clistproxywindow_h__
+#define clistproxywindow_h__
+
+class CClistProxyWindow: public CDwmWindow
+{
+public:
+ CClistProxyWindow();
+ ~CClistProxyWindow();
+
+ void Flash();
+ void SetOverlayIcon(HICON hIcon);
+ void SetOverlayIconHandle(HANDLE hIcolibIcon);
+ void AddOverlayEvent(int idx);
+ void RemoveOverlayEvent(int idx);
+ int AllocateOverlayEvent(HANDLE hIcolibIcon);
+
+private:
+ class COverlayEventSlot
+ {
+ private:
+ HANDLE m_hIcolibItem;
+ TCHAR *m_overlayText;
+ int m_level;
+
+ public:
+ COverlayEventSlot(HANDLE hIcolibItem, TCHAR *overlayText)
+ {
+ m_hIcolibItem = hIcolibItem;
+ m_overlayText = mir_tstrdup(overlayText);
+ m_level = 0;
+ }
+ ~COverlayEventSlot() { mir_free(m_overlayText); }
+ void Push() { m_level++; }
+ void Pop() { if (m_level > 0) m_level--; }
+ operator bool() { return m_level > 0; }
+ HANDLE GetIcon() { return m_hIcolibItem; }
+ };
+
+ int m_activeOverlay;
+ HICON m_overlayIcon;
+ HANDLE m_overlayIconHandle;
+ TCHAR *m_overlayText;
+ OBJLIST<COverlayEventSlot> m_overlayEvents;
+
+ int __cdecl OnStatusModeChanged(WPARAM wParam, LPARAM lParam);
+ int __cdecl OnAvatarChanged(WPARAM wParam, LPARAM lParam);
+ int __cdecl OnModulesLoaded(WPARAM wParam, LPARAM lParam);
+ int __cdecl OnAccListChanged(WPARAM wParam, LPARAM lParam);
+
+ HANDLE SetEventHook(char *evt, int (__cdecl CClistProxyWindow::*fn)(WPARAM, LPARAM));
+
+ void Update();
+
+protected:
+ void OnActivate(HWND hwndFrom);
+ void OnToolbar(int id, INT_PTR data);
+ void OnRenderThumbnail(int width, int height);
+ void OnClose();
+ void OnTimer(int id);
+};
+
+extern CClistProxyWindow *g_clistProxyWnd;
+
+#endif // clistproxywindow_h__