• R/O
  • SSH
  • HTTPS

ttssh2: 提交


Commit MetaInfo

修订版7331 (tree)
时间2018-12-18 23:31:04
作者zmatsuo

Log Message

APIのプロトタイプが異なっていたので修正

更改概述

差异

--- trunk/TTProxy/YCL/include/YCL/Window.h (revision 7330)
+++ trunk/TTProxy/YCL/include/YCL/Window.h (revision 7331)
@@ -204,15 +204,15 @@
204204 bool GetScrollInfo(int type, SCROLLINFO& info)const {
205205 return ::GetScrollInfo(window, type, &info) != FALSE;
206206 }
207- long SetLayeredWindowAttributes(long reserved, int parameters, long attribute) {
207+ long SetLayeredWindowAttributes(COLORREF crKey, BYTE bAlpha, DWORD dwFlags) {
208208 static const char USER32[] = "user32.dll";
209209 static const char APINAME[] = "SetLayeredWindowAttributes";
210- static DWORD (WINAPI* api)(HWND, DWORD, BYTE, DWORD)
211- = (DWORD (WINAPI*)(HWND, DWORD, BYTE, DWORD)) ::GetProcAddress(::GetModuleHandle(USER32), APINAME);
212- return api != NULL ? (*api)(window, reserved, parameters, attribute) : 0;
210+ static BOOL (WINAPI* api)(HWND, COLORREF, BYTE, DWORD)
211+ = (BOOL (WINAPI*)(HWND, COLORREF, BYTE, DWORD)) ::GetProcAddress(::GetModuleHandleA(USER32), APINAME);
212+ return api != NULL ? (*api)(window, crKey, bAlpha, dwFlags) : 0;
213213 }
214- long SetLayeredWindowAttributes(int parameters, long attribute) {
215- return SetLayeredWindowAttributes(0, parameters, attribute);
214+ long SetLayeredWindowAttributes(BYTE bAlpha, DWORD dwFlags) {
215+ return SetLayeredWindowAttributes(0, bAlpha, dwFlags);
216216 }
217217 HWND SetClipboardViewer() {
218218 return ::SetClipboardViewer(window);
@@ -311,7 +311,7 @@
311311 #ifndef WS_EX_LAYERED
312312 #define WS_EX_LAYERED 0x80000
313313 #endif
314- void setAlpha(int alpha) {
314+ void setAlpha(BYTE alpha) {
315315 long exStyle = getExStyle();
316316 if ((exStyle & WS_EX_LAYERED) == 0)
317317 setExStyle(exStyle | WS_EX_LAYERED);
Show on old repository browser