ff_ipc.h 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. /*
  2. LICENSE
  3. -------
  4. Copyright 2005 Nullsoft, Inc.
  5. All rights reserved.
  6. Redistribution and use in source and binary forms, with or without modification,
  7. are permitted provided that the following conditions are met:
  8. * Redistributions of source code must retain the above copyright notice,
  9. this list of conditions and the following disclaimer.
  10. * Redistributions in binary form must reproduce the above copyright notice,
  11. this list of conditions and the following disclaimer in the documentation
  12. and/or other materials provided with the distribution.
  13. * Neither the name of Nullsoft nor the names of its contributors may be used to
  14. endorse or promote products derived from this software without specific prior written permission.
  15. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
  16. IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
  17. FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
  18. CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  19. DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  20. DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
  21. IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  22. OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  23. */
  24. #ifndef _FF_IPC_H
  25. #define _FF_IPC_H
  26. // -----------------------------------------------------------------------------------------------------
  27. // ----- IPC_FF_GETSKINCOLOR : Ask for a skin color -- the color is filtered for the current theme -----
  28. // -----------------------------------------------------------------------------------------------------
  29. #define IPC_FF_GETSKINCOLOR IPC_FF_FIRST + 1 // data = ff_skincolor struct with .colorname, fills in .color
  30. typedef struct {
  31. char colorname[256];
  32. COLORREF color;
  33. } ff_skincolor;
  34. // List of default colors as of june 30, 2003. see freeform/xml/wasabi/xml/system-colors.xml for latest/complete list
  35. // Trees
  36. #define SKINCOLOR_TREE_ITEMTEXT "wasabi.tree.text"
  37. #define SKINCOLOR_TREE_SELITEMBKG "wasabi.tree.selected"
  38. #define SKINCOLOR_TREE_HILITEDROP "wasabi.tree.hiliteddrop"
  39. // Lists
  40. #define SKINCOLOR_LIST_ITEMTEXT "wasabi.list.text"
  41. #define SKINCOLOR_LIST_SELITEMBKG "wasabi.list.item.selected"
  42. #define SKINCOLOR_LIST_FOCUSITEMBKG "wasabi.list.item.focused"
  43. #define SKINCOLOR_LIST_COLUMNBKG "wasabi.list.column.background"
  44. #define SKINCOLOR_LIST_COLUMNTEXT "wasabi.list.column.text"
  45. #define SKINCOLOR_LIST_SELITEMTEXT "wasabi.list.item.selected.fg"
  46. #define SKINCOLOR_LIST_COLUMNSEPARATOR "wasabi.list.column.separator"
  47. // Buttons
  48. #define SKINCOLOR_BUTTON_TEXT "wasabi.button.text"
  49. #define SKINCOLOR_BUTTON_HILITETEXT "wasabi.button.hiliteText"
  50. #define SKINCOLOR_BUTTON_DIMMEDTEXT "wasabi.button.dimmedText"
  51. // ----------------------------------------------------------------------------------------
  52. // ----- IPC_FF_GENSKINBITMAP: Ask gen_ff to create a bitmap of various skin elements -----
  53. // ----------------------------------------------------------------------------------------
  54. // NOTE: You should free the hbitmap eventually using DeleteObject
  55. #define IPC_FF_GENSKINBITMAP IPC_FF_FIRST + 2 // data = ff_skinbitmap with bitmap .id .w .h and .state, fills in .bitmap
  56. typedef struct {
  57. int id; // see below
  58. int w, h;
  59. int state; // id specific, see below
  60. HBITMAP bitmap;
  61. } ff_skinbitmap;
  62. // Bitmap IDs :
  63. #define SKINBITMAP_BUTTON 0 // Generate a button bitmap. states are as follows :
  64. #define BUTTONSTATE_NORMAL 0
  65. #define BUTTONSTATE_PUSHED 1
  66. #define SKINBITMAP_SCROLLBARUPBUTTON 1 // Generate a scrollbar up button bitmap. states are button states
  67. #define SKINBITMAP_SCROLLBARDOWNBUTTON 2 // Generate a scrollbar down button bitmap. states are button states
  68. #define SKINBITMAP_SCROLLBARLEFTBUTTON 3 // Generate a scrollbar left button bitmap. states are button states
  69. #define SKINBITMAP_SCROLLBARRIGHTBUTTON 4 // Generate a scrollbar right button bitmap. states are button states
  70. #define SKINBITMAP_SCROLLBARVBUTTON 5 // Generate a scrollbar vertical button bitmap. states are button states
  71. #define SKINBITMAP_SCROLLBARHBUTTON 6 // Generate a scrollbar vertical button bitmap. states are button states
  72. // -----------------------------------------------------------------------------------------------
  73. // ----- IPC_FF_ONCOLORTHEMECHANGED: CALLBACK - sent when the skin's color theme has changed -----
  74. // -----------------------------------------------------------------------------------------------
  75. #define IPC_FF_ONCOLORTHEMECHANGED IPC_FF_FIRST + 3 // data = name of the new color theme (const char *)
  76. #define IPC_FF_ISMAINWND IPC_FF_FIRST + 4 // data = hwnd, returns 1 if hwnd is main window or any of its windowshade
  77. #define IPC_FF_GETCONTENTWND IPC_FF_FIRST + 5 // data = HWND, returns the wa2 window that is embedded in the window's container (ie if hwnd is the pledit windowshade hwnd, it returns the wa2 pledit hwnd). if no content is found (ie, the window has nothing embedded) it returns the parameter you gave it
  78. #define IPC_FF_NOTIFYHOTKEY IPC_FF_FIRST + 6 // data = const char * to hotkey description
  79. #endif