summaryrefslogtreecommitdiffstats
path: root/win/tclWinNotify.c
diff options
context:
space:
mode:
authornijtmans <nijtmans>2010-05-04 11:05:34 (GMT)
committernijtmans <nijtmans>2010-05-04 11:05:34 (GMT)
commit12f45b93f54d74dcc7e81bd9b04f9734f832f72f (patch)
tree766c8aedc9843dd60ab666a1ce391251c3c4bea4 /win/tclWinNotify.c
parent603632160ce039289adcabac2684febc649c535b (diff)
downloadtcl-12f45b93f54d74dcc7e81bd9b04f9734f832f72f.zip
tcl-12f45b93f54d74dcc7e81bd9b04f9734f832f72f.tar.gz
tcl-12f45b93f54d74dcc7e81bd9b04f9734f832f72f.tar.bz2
TCHAR-related fixes, making those files compile fine when TCHAR != char
Please see comments in [Freq 2965056] (2965056-1.patch).
Diffstat (limited to 'win/tclWinNotify.c')
-rw-r--r--win/tclWinNotify.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/win/tclWinNotify.c b/win/tclWinNotify.c
index 9e0db15..352379d 100644
--- a/win/tclWinNotify.c
+++ b/win/tclWinNotify.c
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclWinNotify.c,v 1.26 2009/11/18 21:59:49 nijtmans Exp $
+ * RCS: @(#) $Id: tclWinNotify.c,v 1.27 2010/05/04 11:05:34 nijtmans Exp $
*/
#include "tclInt.h"
@@ -52,6 +52,7 @@ static Tcl_ThreadDataKey dataKey;
*/
static int notifierCount = 0;
+static const TCHAR classname[] = TEXT("TclNotifier");
TCL_DECLARE_MUTEX(notifierMutex)
/*
@@ -99,12 +100,12 @@ Tcl_InitNotifier(void)
class.hInstance = TclWinGetTclInstance();
class.hbrBackground = NULL;
class.lpszMenuName = NULL;
- class.lpszClassName = "TclNotifier";
+ class.lpszClassName = classname;
class.lpfnWndProc = NotifierProc;
class.hIcon = NULL;
class.hCursor = NULL;
- if (!RegisterClassA(&class)) {
+ if (!RegisterClass(&class)) {
Tcl_Panic("Unable to register TclNotifier window class");
}
}
@@ -187,7 +188,7 @@ Tcl_FinalizeNotifier(
Tcl_MutexLock(&notifierMutex);
notifierCount--;
if (notifierCount == 0) {
- UnregisterClassA("TclNotifier", TclWinGetTclInstance());
+ UnregisterClass(classname, TclWinGetTclInstance());
}
Tcl_MutexUnlock(&notifierMutex);
}
@@ -351,7 +352,7 @@ Tcl_ServiceModeHook(
*/
if (mode == TCL_SERVICE_ALL && !tsdPtr->hwnd) {
- tsdPtr->hwnd = CreateWindowA("TclNotifier", "TclNotifier",
+ tsdPtr->hwnd = CreateWindow(classname, classname,
WS_TILED, 0, 0, 0, 0, NULL, NULL, TclWinGetTclInstance(),
NULL);