1 /*
   2  * Copyright (c) 1996, 2011, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.  Oracle designates this
   8  * particular file as subject to the "Classpath" exception as provided
   9  * by Oracle in the LICENSE file that accompanied this code.
  10  *
  11  * This code is distributed in the hope that it will be useful, but WITHOUT
  12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14  * version 2 for more details (a copy is included in the LICENSE file that
  15  * accompanied this code).
  16  *
  17  * You should have received a copy of the GNU General Public License version
  18  * 2 along with this work; if not, write to the Free Software Foundation,
  19  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20  *
  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any
  23  * questions.
  24  */
  25 
  26 #ifndef AWTMSG_H
  27 #define AWTMSG_H
  28 
  29 #include <awt.h>
  30 
  31 extern const UINT SYSCOMMAND_IMM;
  32 
  33 /*
  34  * #defines for MouseWheel support
  35  *
  36  * Most of this is defined in winuser.h, however
  37  * it is enclosed by #ifdefs that aren't true
  38  * for all windows platforms.  To ensure that
  39  * necessary #defines are always available,
  40  * they're defined here as necessary.
  41  * See winuser.h for details.
  42  */
  43 
  44 #ifndef WM_MOUSEWHEEL
  45 #define WM_MOUSEWHEEL                   0x020A
  46 #endif //WM_MOUSEWHEEL
  47 
  48 #ifndef WHEEL_DELTA
  49 #define WHEEL_DELTA                     120
  50 #endif //WHEEL_DELTA
  51 
  52 #ifndef WHEEL_PAGESCROLL
  53 #define WHEEL_PAGESCROLL                (UINT_MAX)
  54 #endif //WHEEL_PAGESCROLL
  55 
  56 #ifndef SPI_GETWHEELSCROLLLINES
  57 #define SPI_GETWHEELSCROLLLINES         104
  58 #endif //SPI_GETWHEELSCROLLLINES
  59 
  60 #ifndef SM_MOUSEWHEELPRESENT
  61 #define SM_MOUSEWHEELPRESENT            75
  62 #endif //SPI_GETWHEELSCROLLLINES
  63 
  64 #ifndef COLOR_HOTLIGHT
  65 #define COLOR_HOTLIGHT                  26
  66 #endif //COLOR_HOTLIGHT
  67 
  68 #ifndef COLOR_GRADIENTACTIVECAPTION
  69 #define COLOR_GRADIENTACTIVECAPTION     27
  70 #endif //COLOR_GRADIENTACTIVECAPTION
  71 
  72 #ifndef COLOR_GRADIENTINACTIVECAPTION
  73 #define COLOR_GRADIENTINACTIVECAPTION   28
  74 #endif //COLOR_GRADIENTINACTIVECAPTION
  75 
  76 #ifndef SPI_GETACTIVEWINDOWTRACKING
  77 #define SPI_GETACTIVEWINDOWTRACKING     0x1000
  78 #endif //SPI_GETACTIVEWINDOWTRACKING
  79 
  80 #ifndef SPI_GETMENUANIMATION
  81 #define SPI_GETMENUANIMATION            0x1002
  82 #endif //SPI_GETMENUANIMATION
  83 
  84 #ifndef SPI_GETCOMBOBOXANIMATION
  85 #define SPI_GETCOMBOBOXANIMATION        0x1004
  86 #endif //SPI_GETCOMBOBOXANIMATION
  87 
  88 #ifndef SPI_GETLISTBOXSMOOTHSCROLLING
  89 #define SPI_GETLISTBOXSMOOTHSCROLLING   0x1006
  90 #endif //SPI_GETLISTBOXSMOOTHSCROLLING
  91 
  92 #ifndef SPI_GETGRADIENTCAPTIONS
  93 #define SPI_GETGRADIENTCAPTIONS         0x1008
  94 #endif //SPI_GETGRADIENTCAPTIONS
  95 
  96 #ifndef SPI_GETKEYBOARDCUES
  97 #define SPI_GETKEYBOARDCUES             0x100A
  98 #endif //SPI_GETKEYBOARDCUES
  99 
 100 #ifndef SPI_GETACTIVEWNDTRKZORDER
 101 #define SPI_GETACTIVEWNDTRKZORDER       0x100C
 102 #endif //SPI_GETACTIVEWNDTRKZORDER
 103 
 104 #ifndef SPI_GETHOTTRACKING
 105 #define SPI_GETHOTTRACKING              0x100E
 106 #endif //SPI_GETHOTTRACKING
 107 
 108 #ifndef SPI_GETMENUFADE
 109 #define SPI_GETMENUFADE                 0x1012
 110 #endif //SPI_GETMENUFADE
 111 
 112 #ifndef SPI_GETSELECTIONFADE
 113 #define SPI_GETSELECTIONFADE            0x1014
 114 #endif //SPI_GETSELECTIONFADE
 115 
 116 #ifndef SPI_GETTOOLTIPANIMATION
 117 #define SPI_GETTOOLTIPANIMATION         0x1016
 118 #endif //SPI_GETTOOLTIPANIMATION
 119 
 120 #ifndef SPI_GETTOOLTIPFADE
 121 #define SPI_GETTOOLTIPFADE              0x1018
 122 #endif //SPI_GETTOOLTIPFADE
 123 
 124 #ifndef SPI_GETFOREGROUNDLOCKTIMEOUT
 125 #define SPI_GETFOREGROUNDLOCKTIMEOUT    0x2000
 126 #endif //SPI_GETFOREGROUNDLOCKTIMEOUT
 127 
 128 #ifndef SPI_GETACTIVEWNDTRKTIMEOUT
 129 #define SPI_GETACTIVEWNDTRKTIMEOUT      0x2002
 130 #endif //SPI_GETACTIVEWNDTRKTIMEOUT
 131 
 132 #ifndef SPI_GETFOREGROUNDFLASHCOUNT
 133 #define SPI_GETFOREGROUNDFLASHCOUNT     0x2004
 134 #endif //SPI_GETFOREGROUNDFLASHCOUNT
 135 
 136 #ifndef SPI_GETFONTSMOOTHINGTYPE
 137 #define SPI_GETFONTSMOOTHINGTYPE        0x200A
 138 #endif //SPI_GETFONTSMOOTHINGTYPE
 139 
 140 #ifndef SPI_GETFONTSMOOTHINGCONTRAST
 141 #define SPI_GETFONTSMOOTHINGCONTRAST    0x200C
 142 #endif //SPI_GETFONTSMOOTHINGCONTRAST
 143 
 144 
 145 //
 146 // Flags for AnimateWindow
 147 //
 148 #ifndef AW_HOR_POSITIVE
 149 #define AW_HOR_POSITIVE             0x00000001
 150 #endif //AW_HOR_POSITIVE
 151 
 152 #ifndef AW_HOR_NEGATIVE
 153 #define AW_HOR_NEGATIVE             0x00000002
 154 #endif //AW_HOR_NEGATIVE
 155 
 156 #ifndef AW_VER_POSITIVE
 157 #define AW_VER_POSITIVE             0x00000004
 158 #endif //AW_VER_POSITIVE
 159 
 160 #ifndef AW_VER_NEGATIVE
 161 #define AW_VER_NEGATIVE             0x00000008
 162 #endif //AW_VER_NEGATIVE
 163 
 164 #ifndef AW_CENTER
 165 #define AW_CENTER                   0x00000010
 166 #endif //AW_CENTER
 167 
 168 #ifndef AW_HIDE
 169 #define AW_HIDE                     0x00010000
 170 #endif //AW_HIDE
 171 
 172 #ifndef AW_ACTIVATE
 173 #define AW_ACTIVATE                 0x00020000
 174 #endif //AW_ACTIVATE
 175 
 176 #ifndef AW_SLIDE
 177 #define AW_SLIDE                    0x00040000
 178 #endif //AW_SLIDE
 179 
 180 #ifndef AW_BLEND
 181 #define AW_BLEND                    0x00080000
 182 #endif //AW_BLEND
 183 
 184 
 185 // AwtComponent messages
 186 enum {
 187     // 6427323: unfortunately WM_APP+nnn conflicts with edit control messages
 188     // on XP with IME support, so we're shifting our messages
 189     // to some random value just to avoid the conflict
 190     WM_AWT_COMPONENT_CREATE = WM_APP+0x1800,
 191     WM_AWT_DESTROY_WINDOW,
 192     WM_AWT_MOUSEENTER,
 193     WM_AWT_MOUSEEXIT,
 194     WM_AWT_COMPONENT_SHOW,
 195     WM_AWT_COMPONENT_HIDE,
 196     WM_AWT_COMPONENT_SETFOCUS,
 197     WM_AWT_WINDOW_SETACTIVE,
 198     WM_AWT_LIST_SETMULTISELECT,
 199     WM_AWT_HANDLE_EVENT,
 200     WM_AWT_PRINT_COMPONENT,
 201     WM_AWT_RESHAPE_COMPONENT,
 202     WM_AWT_SETALWAYSONTOP,
 203     WM_AWT_BEGIN_VALIDATE,
 204     WM_AWT_END_VALIDATE,
 205     WM_AWT_FORWARD_CHAR,
 206     WM_AWT_FORWARD_BYTE,
 207     WM_AWT_SET_SCROLL_INFO,
 208     WM_AWT_CREATECONTEXT,
 209     WM_AWT_DESTROYCONTEXT,
 210     WM_AWT_ASSOCIATECONTEXT,
 211     WM_AWT_GET_DEFAULT_IME_HANDLER,
 212     WM_AWT_HANDLE_NATIVE_IME_EVENT,
 213     WM_AWT_PRE_KEYDOWN,
 214     WM_AWT_PRE_KEYUP,
 215     WM_AWT_PRE_SYSKEYDOWN,
 216     WM_AWT_PRE_SYSKEYUP,
 217 
 218     /* deleted DND mesg's */
 219 
 220     WM_AWT_ENDCOMPOSITION,
 221     WM_AWT_DISPOSE,
 222     WM_AWT_DISPOSEPDATA,
 223     WM_AWT_DELETEOBJECT,
 224     WM_AWT_SETCONVERSIONSTATUS,
 225     WM_AWT_GETCONVERSIONSTATUS,
 226     WM_AWT_SETOPENSTATUS,
 227     WM_AWT_GETOPENSTATUS,
 228     WM_AWT_ACTIVATEKEYBOARDLAYOUT,
 229     WM_AWT_OPENCANDIDATEWINDOW,
 230     WM_AWT_DLG_SHOWMODAL,
 231     WM_AWT_DLG_ENDMODAL,
 232     WM_AWT_SETCURSOR,
 233     WM_AWT_WAIT_FOR_SINGLE_OBJECT,
 234     WM_AWT_INVOKE_METHOD,
 235     WM_AWT_INVOKE_VOID_METHOD,
 236     WM_AWT_EXECUTE_SYNC,
 237     WM_AWT_OBJECTLISTCLEANUP,
 238 
 239     WM_AWT_CURSOR_SYNC,
 240     WM_AWT_GETDC,
 241     WM_AWT_RELEASEDC,
 242     WM_AWT_RELEASE_ALL_DCS,
 243     WM_AWT_SHOWCURSOR,
 244     WM_AWT_HIDECURSOR,
 245     WM_AWT_CREATE_PRINTED_PIXELS,
 246 
 247     // Tray messages
 248     WM_AWT_TRAY_NOTIFY,
 249 
 250     WM_SYNC_WAIT
 251 };
 252 
 253 #ifndef WM_UNDOCUMENTED_CLICKMENUBAR
 254 #define WM_UNDOCUMENTED_CLICKMENUBAR 0x0313
 255 #endif
 256 
 257 #ifndef WM_UNDOCUMENTED_CLIENTSHUTDOWN
 258 #define WM_UNDOCUMENTED_CLIENTSHUTDOWN 0x003b
 259 #endif
 260 
 261 #endif  // AWTMSG_H