diff options
author | Joe Mistachkin <joe@mistachkin.com> | 2007-02-04 00:10:54 (GMT) |
---|---|---|
committer | Joe Mistachkin <joe@mistachkin.com> | 2007-02-04 00:10:54 (GMT) |
commit | 564a18890f8852cc78182cfec2cabfb6cb61b2e7 (patch) | |
tree | a7200b20603fda137b889e26b614b01d8df86d05 | |
parent | a74254940bbc0421f26970bcd3a16b660ae0527e (diff) | |
download | tk-564a18890f8852cc78182cfec2cabfb6cb61b2e7.zip tk-564a18890f8852cc78182cfec2cabfb6cb61b2e7.tar.gz tk-564a18890f8852cc78182cfec2cabfb6cb61b2e7.tar.bz2 |
see log
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | win/rules.vc | 11 | ||||
-rw-r--r-- | win/ttkWinMonitor.c | 10 | ||||
-rw-r--r-- | win/ttkWinXPTheme.c | 4 |
4 files changed, 26 insertions, 7 deletions
@@ -1,3 +1,11 @@ +2007-02-03 Joe Mistachkin <joe@mistachkin.com> + + * win/rules.vc: Fix platform specific file copy macros for downlevel + Windows. + * win/ttkWinMonitor.c: Windows portability support. Fix "noxp" build + * win/ttkWinXPTheme.c: option handling and use GetWindowLongPtr and + SetWindowLongPtr only when needed. + 2007-02-02 Pat Thoyts <patthoyts@users.sourceforge.net> * win/ttkWinXPTheme.c: Support IsAppThemed() call. This is what diff --git a/win/rules.vc b/win/rules.vc index e5f59a1..496bb0a 100644 --- a/win/rules.vc +++ b/win/rules.vc @@ -11,7 +11,7 @@ # Copyright (c) 2003-2006 Patrick Thoyts # #------------------------------------------------------------------------------ -# RCS: @(#) $Id: rules.vc,v 1.14 2006/10/31 14:45:04 patthoyts Exp $ +# RCS: @(#) $Id: rules.vc,v 1.15 2007/02/04 00:10:54 mistachkin Exp $ #------------------------------------------------------------------------------ !ifndef _RULES_VC @@ -51,12 +51,15 @@ CFG_ENCODING = \"cp1252\" !if "$(OS)" == "Windows_NT" RMDIR = rmdir /S /Q !if ![ver | find "4.0" > nul] -CPY = echo y | xcopy /i +CPY = echo y | xcopy /i >NUL +COPY = copy >NUL !else CPY = xcopy /i /y >NUL +COPY = copy /y >NUL !endif -!else -CPY = xcopy /i +!else # "$(OS)" != "Windows_NT" +CPY = xcopy /i >_JUNK.OUT # On Win98 NUL does not work here. +COPY = copy >_JUNK.OUT # On Win98 NUL does not work here. RMDIR = deltree /Y !endif MKDIR = mkdir diff --git a/win/ttkWinMonitor.c b/win/ttkWinMonitor.c index bf23e39..c0198d9 100644 --- a/win/ttkWinMonitor.c +++ b/win/ttkWinMonitor.c @@ -1,4 +1,4 @@ -/* $Id: ttkWinMonitor.c,v 1.6 2007/01/11 19:59:26 jenglish Exp $ +/* $Id: ttkWinMonitor.c,v 1.7 2007/02/04 00:10:55 mistachkin Exp $ */ #ifdef _MSC_VER @@ -98,7 +98,11 @@ CreateThemeMonitorWindow(HINSTANCE hinst, Tcl_Interp *interp) hwnd = CreateWindow( name, title, WS_OVERLAPPEDWINDOW, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, NULL, NULL, hinst, NULL ); +#ifdef _WIN64 SetWindowLongPtr(hwnd, GWLP_USERDATA, (LONG)interp); +#else + SetWindowLong(hwnd, GWL_USERDATA, (LONG)interp); +#endif ShowWindow(hwnd, SW_HIDE); UpdateWindow(hwnd); } @@ -115,7 +119,11 @@ DestroyThemeMonitorWindow(void *clientData) static LRESULT WINAPI WndProc(HWND hwnd, UINT msg, WPARAM wp, LPARAM lp) { +#ifdef _WIN64 Tcl_Interp *interp = (Tcl_Interp *)GetWindowLongPtr(hwnd, GWLP_USERDATA); +#else + Tcl_Interp *interp = (Tcl_Interp *)GetWindowLong(hwnd, GWL_USERDATA); +#endif Ttk_Theme theme; switch (msg) { diff --git a/win/ttkWinXPTheme.c b/win/ttkWinXPTheme.c index 5dbf553..b166f1e 100644 --- a/win/ttkWinXPTheme.c +++ b/win/ttkWinXPTheme.c @@ -1,5 +1,5 @@ /* - * $Id: ttkWinXPTheme.c,v 1.7 2007/02/02 10:58:35 patthoyts Exp $ + * $Id: ttkWinXPTheme.c,v 1.8 2007/02/04 00:10:55 mistachkin Exp $ * * Tk theme engine which uses the Windows XP "Visual Styles" API * Adapted from Georgios Petasis' XP theme patch. @@ -21,7 +21,7 @@ /* Stub for platforms that lack the XP theme API headers: */ #include <windows.h> #include <tcl.h> -int XPTheme_Init(Tcl_Interp *interp, HWND hwnd) { return TCL_OK; } +int TtkXPTheme_Init(Tcl_Interp *interp, HWND hwnd) { return TCL_OK; } #else #define WINVER 0x0501 /* Requires Windows XP APIs */ |