tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

Static.h (779B)


      1 // Windows/Control/Static.h
      2 
      3 #ifndef __WINDOWS_CONTROL_STATIC_H
      4 #define __WINDOWS_CONTROL_STATIC_H
      5 
      6 #include "../Window.h"
      7 
      8 namespace NWindows {
      9 namespace NControl {
     10 
     11 class CStatic: public CWindow
     12 {
     13 public:
     14  HANDLE SetImage(WPARAM imageType, HANDLE handle) { return (HANDLE)SendMsg(STM_SETIMAGE, imageType, (LPARAM)handle); }
     15  HANDLE GetImage(WPARAM imageType) { return (HANDLE)SendMsg(STM_GETIMAGE, imageType, 0); }
     16 
     17  #ifdef UNDER_CE
     18  HICON SetIcon(HICON icon) { return (HICON)SetImage(IMAGE_ICON, icon); }
     19  HICON GetIcon() { return (HICON)GetImage(IMAGE_ICON); }
     20  #else
     21  HICON SetIcon(HICON icon) { return (HICON)SendMsg(STM_SETICON, (WPARAM)icon, 0); }
     22  HICON GetIcon() { return (HICON)SendMsg(STM_GETICON, 0, 0); }
     23  #endif
     24 };
     25 
     26 }}
     27 
     28 #endif