|
|
| version 1.6, 2005/02/07 14:46:14 | version 1.7, 2007/11/11 07:11:26 |
|---|---|
| Line 34 static void getmaincenter(POINT *cp) { | Line 34 static void getmaincenter(POINT *cp) { |
| RECT rct; | RECT rct; |
| GetWindowRect(hWndMain, &rct); | GetWindowRect(g_hWndMain, &rct); |
| cp->x = (rct.right + rct.left) / 2; | cp->x = (rct.right + rct.left) / 2; |
| cp->y = (rct.bottom + rct.top) / 2; | cp->y = (rct.bottom + rct.top) / 2; |
| } | } |
| Line 45 static void mousecapture(BOOL capture) { | Line 45 static void mousecapture(BOOL capture) { |
| POINT cp; | POINT cp; |
| RECT rct; | RECT rct; |
| style = GetClassLong(hWndMain, GCL_STYLE); | style = GetClassLong(g_hWndMain, GCL_STYLE); |
| if (capture) { | if (capture) { |
| ShowCursor(FALSE); | ShowCursor(FALSE); |
| getmaincenter(&cp); | getmaincenter(&cp); |
| Line 62 static void mousecapture(BOOL capture) { | Line 62 static void mousecapture(BOOL capture) { |
| ClipCursor(NULL); | ClipCursor(NULL); |
| style |= CS_DBLCLKS; | style |= CS_DBLCLKS; |
| } | } |
| SetClassLong(hWndMain, GCL_STYLE, style); | SetClassLong(g_hWndMain, GCL_STYLE, style); |
| } | } |
| void mousemng_initialize(void) { | void mousemng_initialize(void) { |