summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authorstanton <stanton>1998-11-25 21:16:28 (GMT)
committerstanton <stanton>1998-11-25 21:16:28 (GMT)
commit0fe03c2e56a2ab06690ea189ab1136b35f5f80b6 (patch)
tree4ad0c5e136a5786750291df60b74a1358a56c774 /win
parentcfaf90b6bd984f4e72ed307384968bcad79500d5 (diff)
downloadtk-0fe03c2e56a2ab06690ea189ab1136b35f5f80b6.zip
tk-0fe03c2e56a2ab06690ea189ab1136b35f5f80b6.tar.gz
tk-0fe03c2e56a2ab06690ea189ab1136b35f5f80b6.tar.bz2
* integrated tk8.0.4 changes.
* generic/tkBind.c: fixed deletion order bug where a crash would result if a binding deleted "."
Diffstat (limited to 'win')
-rw-r--r--win/README2
-rw-r--r--win/makefile.bc2
-rw-r--r--win/makefile.vc10
-rw-r--r--win/tkWinMenu.c18
-rw-r--r--win/tkWinWm.c3
-rw-r--r--win/tkWinX.c29
6 files changed, 49 insertions, 15 deletions
diff --git a/win/README b/win/README
index 24000f4..c325b3d 100644
--- a/win/README
+++ b/win/README
@@ -4,7 +4,7 @@ by Scott Stanton
Scriptics Corporation
scott.stanton@scriptics.com
-RCS: @(#) $Id: README,v 1.1.4.2 1998/09/30 02:19:25 stanton Exp $
+RCS: @(#) $Id: README,v 1.1.4.3 1998/11/25 21:16:42 stanton Exp $
1. Introduction
---------------
diff --git a/win/makefile.bc b/win/makefile.bc
index 8c59bb1..e27362a 100644
--- a/win/makefile.bc
+++ b/win/makefile.bc
@@ -5,7 +5,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: makefile.bc,v 1.1.4.2 1998/09/30 02:19:26 stanton Exp $
+# RCS: @(#) $Id: makefile.bc,v 1.1.4.3 1998/11/25 21:16:42 stanton Exp $
#
diff --git a/win/makefile.vc b/win/makefile.vc
index 0f9e971..1f98001 100644
--- a/win/makefile.vc
+++ b/win/makefile.vc
@@ -4,7 +4,7 @@
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# Copyright (c) 1995-1997 Sun Microsystems, Inc.
-# RCS: @(#) $Id: makefile.vc,v 1.1.4.4 1998/10/06 20:34:11 stanton Exp $
+# RCS: @(#) $Id: makefile.vc,v 1.1.4.5 1998/11/25 21:16:42 stanton Exp $
# Does not depend on the presence of any environment variables in
# order to compile tcl; all needed information is derived from
@@ -233,11 +233,11 @@ guilflags = $(lflags) -subsystem:windows -entry:WinMainCRTStartup
dlllflags = $(lflags) -entry:_DllMainCRTStartup$(DLLENTRY) -dll
!IF "$(MACHINE)" == "PPC"
-libc = libc.lib
-libcdll = crtdll.lib
+libc = libc$(DBGX).lib
+libcdll = crtdll$(DBGX).lib
!ELSE
-libc = libc.lib oldnames.lib
-libcdll = msvcrt.lib oldnames.lib
+libc = libc$(DBGX).lib oldnames.lib
+libcdll = msvcrt$(DBGX).lib oldnames.lib
!ENDIF
baselibs = kernel32.lib $(optlibs) advapi32.lib
diff --git a/win/tkWinMenu.c b/win/tkWinMenu.c
index ddb7caf..cf81655 100644
--- a/win/tkWinMenu.c
+++ b/win/tkWinMenu.c
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinMenu.c,v 1.1.4.5 1998/11/24 21:42:48 stanton Exp $
+ * RCS: @(#) $Id: tkWinMenu.c,v 1.1.4.6 1998/11/25 21:16:42 stanton Exp $
*/
#define OEMRESOURCE
@@ -600,14 +600,21 @@ ReconfigureWindowsMenu(
if ((menuPtr->menuType == MENUBAR)
&& !(mePtr->childMenuRefPtr->menuPtr->menuFlags
& MENU_SYSTEM_MENU)) {
+ Tcl_DString ds;
TkMenuReferences *menuRefPtr;
TkMenu *systemMenuPtr = mePtr->childMenuRefPtr
->menuPtr;
- char *systemMenuName = ckalloc(strlen(
- Tk_PathName(menuPtr->masterMenuPtr->tkwin))
- + strlen(".system") + 1);
+
+ Tcl_DStringInit(&ds);
+ Tcl_DStringAppend(&ds,
+ Tk_PathName(menuPtr->masterMenuPtr->tkwin), -1);
+ Tcl_DStringAppend(&ds, ".system", 7);
+
menuRefPtr = TkFindMenuReferences(menuPtr->interp,
- systemMenuName);
+ Tcl_DStringValue(&ds));
+
+ Tcl_DStringFree(&ds);
+
if ((menuRefPtr != NULL)
&& (menuRefPtr->menuPtr != NULL)
&& (menuPtr->parentTopLevelPtr != NULL)
@@ -632,7 +639,6 @@ ReconfigureWindowsMenu(
}
}
}
- ckfree(systemMenuName);
}
if (mePtr->childMenuRefPtr->menuPtr->menuFlags
& MENU_SYSTEM_MENU) {
diff --git a/win/tkWinWm.c b/win/tkWinWm.c
index 92ce55e..97d3c07 100644
--- a/win/tkWinWm.c
+++ b/win/tkWinWm.c
@@ -7,11 +7,12 @@
* to the window manager.
*
* Copyright (c) 1995-1997 Sun Microsystems, Inc.
+ * Copyright (c) 1998 by Scriptics Corporation.
*
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinWm.c,v 1.1.4.4 1998/11/20 02:35:12 stanton Exp $
+ * RCS: @(#) $Id: tkWinWm.c,v 1.1.4.5 1998/11/25 21:16:43 stanton Exp $
*/
#include "tkWinInt.h"
diff --git a/win/tkWinX.c b/win/tkWinX.c
index a47b78a..b4ffa17 100644
--- a/win/tkWinX.c
+++ b/win/tkWinX.c
@@ -5,16 +5,23 @@
*
* Copyright (c) 1995-1996 Sun Microsystems, Inc.
* Copyright (c) 1994 Software Research Associates, Inc.
+ * Copyright (c) 1998 by Scriptics Corporation.
*
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinX.c,v 1.1.4.4 1998/11/20 02:35:15 stanton Exp $
+ * RCS: @(#) $Id: tkWinX.c,v 1.1.4.5 1998/11/25 21:16:44 stanton Exp $
*/
#include "tkWinInt.h"
/*
+ * The zmouse.h file includes the definition for WM_MOUSEWHEEL.
+ */
+
+#include <zmouse.h>
+
+/*
* Definitions of extern variables supplied by this file.
*/
@@ -590,6 +597,7 @@ Tk_TranslateWinEvent(hwnd, message, wParam, lParam, resultPtr)
case WM_SYSKEYUP:
case WM_KEYDOWN:
case WM_KEYUP:
+ case WM_MOUSEWHEEL:
GenerateXEvent(hwnd, message, wParam, lParam);
return 1;
case WM_MENUCHAR:
@@ -697,6 +705,13 @@ GenerateXEvent(hwnd, message, wParam, lParam)
event.xselectionclear.time = TkpGetMS();
break;
+ case WM_MOUSEWHEEL:
+ /*
+ * The mouse wheel event is closer to a key event than a
+ * mouse event in that the message is sent to the window
+ * that has focus.
+ */
+
case WM_CHAR:
case WM_SYSKEYDOWN:
case WM_SYSKEYUP:
@@ -738,6 +753,18 @@ GenerateXEvent(hwnd, message, wParam, lParam)
*/
switch (message) {
+ case WM_MOUSEWHEEL:
+ /*
+ * We have invented a new X event type to handle
+ * this event. It still uses the KeyPress struct.
+ * However, the keycode field has been overloaded
+ * to hold the zDelta of the wheel.
+ */
+
+ event.type = MouseWheelEvent;
+ event.xany.send_event = -1;
+ event.xkey.keycode = (short) HIWORD(wParam);
+ break;
case WM_SYSKEYDOWN:
case WM_KEYDOWN:
/*