aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEli Zaretskii2012-08-13 21:34:37 +0300
committerEli Zaretskii2012-08-13 21:34:37 +0300
commitb7f501c736b4f45b4dee1d4d54a6f710c52f2530 (patch)
tree931a312238eb9ffb6151b30132bb600dea3980e1 /src
parent4432d2e25bc56cd06c9ed0c987d6570b2d57f230 (diff)
downloademacs-b7f501c736b4f45b4dee1d4d54a6f710c52f2530.tar.gz
emacs-b7f501c736b4f45b4dee1d4d54a6f710c52f2530.zip
Backport: Don't disable Unicode menus on Windows NT and later.
src/w32menu.c: Include w32heap.h. (add_menu_item): If the call to AppendMenuW (via unicode_append_menu) fails, disable Unicode menus only if we are running on Windows 9X/Me. src/makefile.w32-in ($(BLD)/w32menu.$(O)): Depend on w32heap.h.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog7
-rw-r--r--src/makefile.w32-in1
-rw-r--r--src/w32menu.c9
3 files changed, 15 insertions, 2 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 96c6d244bd1..fbe4f06da58 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,12 @@
12012-08-13 Eli Zaretskii <eliz@gnu.org> 12012-08-13 Eli Zaretskii <eliz@gnu.org>
2 2
3 * w32menu.c: Include w32heap.h.
4 (add_menu_item): If the call to AppendMenuW (via
5 unicode_append_menu) fails, disable Unicode menus only if we are
6 running on Windows 9X/Me.
7
8 * makefile.w32-in ($(BLD)/w32menu.$(O)): Depend on w32heap.h.
9
3 * window.c (Fdelete_other_windows_internal) 10 * window.c (Fdelete_other_windows_internal)
4 (Fdelete_window_internal): Don't access frame's mouse highlight 11 (Fdelete_window_internal): Don't access frame's mouse highlight
5 info of the initial frame. (Bug#11677) 12 info of the initial frame. (Bug#11677)
diff --git a/src/makefile.w32-in b/src/makefile.w32-in
index d7ca325e223..06e633c1443 100644
--- a/src/makefile.w32-in
+++ b/src/makefile.w32-in
@@ -1506,6 +1506,7 @@ $(BLD)/w32menu.$(O) : \
1506 $(SRC)/w32menu.c \ 1506 $(SRC)/w32menu.c \
1507 $(SRC)/buffer.h \ 1507 $(SRC)/buffer.h \
1508 $(SRC)/keymap.h \ 1508 $(SRC)/keymap.h \
1509 $(SRC)/w32heap.h \
1509 $(BLOCKINPUT_H) \ 1510 $(BLOCKINPUT_H) \
1510 $(CHARSET_H) \ 1511 $(CHARSET_H) \
1511 $(CODING_H) \ 1512 $(CODING_H) \
diff --git a/src/w32menu.c b/src/w32menu.c
index 9091cb81627..0f45532ed53 100644
--- a/src/w32menu.c
+++ b/src/w32menu.c
@@ -40,6 +40,8 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
40 if this is not done before the other system files. */ 40 if this is not done before the other system files. */
41#include "w32term.h" 41#include "w32term.h"
42 42
43#include "w32heap.h"
44
43/* Load sys/types.h if not already loaded. 45/* Load sys/types.h if not already loaded.
44 In some systems loading it twice is suicidal. */ 46 In some systems loading it twice is suicidal. */
45#ifndef makedev 47#ifndef makedev
@@ -1498,8 +1500,11 @@ add_menu_item (HMENU menu, widget_value *wv, HMENU item)
1498 AppendMenu (menu, fuFlags, 1500 AppendMenu (menu, fuFlags,
1499 item != NULL ? (UINT) item: (UINT) wv->call_data, 1501 item != NULL ? (UINT) item: (UINT) wv->call_data,
1500 out_string); 1502 out_string);
1501 /* Don't use Unicode menus in future. */ 1503 /* Don't use Unicode menus in future, unless this is Windows
1502 unicode_append_menu = NULL; 1504 NT or later, where a failure of AppendMenuW does NOT mean
1505 Unicode menus are unsupported. */
1506 if (osinfo_cache.dwPlatformId != VER_PLATFORM_WIN32_NT)
1507 unicode_append_menu = NULL;
1503 } 1508 }
1504 1509
1505 if (unicode_append_menu && (fuFlags & MF_OWNERDRAW)) 1510 if (unicode_append_menu && (fuFlags & MF_OWNERDRAW))