summaryrefslogtreecommitdiffstats
path: root/win/tkWinClipboard.c
diff options
context:
space:
mode:
authornijtmans <nijtmans>2010-11-03 12:11:44 (GMT)
committernijtmans <nijtmans>2010-11-03 12:11:44 (GMT)
commit1bf8f221df1b86e8c623d37a0f7f20e52da060ad (patch)
tree2b0fbd8966932f7c2c4c80b17100ce6d2dd66b06 /win/tkWinClipboard.c
parenteac7d6560603161bdf15eff58f8e556341cd9a50 (diff)
downloadtk-1bf8f221df1b86e8c623d37a0f7f20e52da060ad.zip
tk-1bf8f221df1b86e8c623d37a0f7f20e52da060ad.tar.gz
tk-1bf8f221df1b86e8c623d37a0f7f20e52da060ad.tar.bz2
[FRQ 2965056]: Windows build with -DUNICODE
Diffstat (limited to 'win/tkWinClipboard.c')
-rw-r--r--win/tkWinClipboard.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/win/tkWinClipboard.c b/win/tkWinClipboard.c
index f062ae2..120df4e 100644
--- a/win/tkWinClipboard.c
+++ b/win/tkWinClipboard.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinClipboard.c,v 1.13 2010/10/06 14:33:29 nijtmans Exp $
+ * RCS: @(#) $Id: tkWinClipboard.c,v 1.14 2010/11/03 12:11:44 nijtmans Exp $
*/
#include "tkWinInt.h"
@@ -295,7 +295,7 @@ TkWinClipboardRender(
* encoding before placing it on the clipboard.
*/
- if (TkWinGetPlatformId() != VER_PLATFORM_WIN32_WINDOWS) {
+#ifdef UNICODE
Tcl_DStringInit(&ds);
Tcl_UtfToUniCharDString(rawText, -1, &ds);
ckfree(rawText);
@@ -311,7 +311,7 @@ TkWinClipboardRender(
GlobalUnlock(handle);
Tcl_DStringFree(&ds);
SetClipboardData(CF_UNICODETEXT, handle);
- } else {
+#else
Tcl_UtfToExternalDString(NULL, rawText, -1, &ds);
ckfree(rawText);
handle = GlobalAlloc(GMEM_MOVEABLE|GMEM_DDESHARE,
@@ -326,7 +326,7 @@ TkWinClipboardRender(
GlobalUnlock(handle);
Tcl_DStringFree(&ds);
SetClipboardData(CF_TEXT, handle);
- }
+#endif
}
/*