aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEli Zaretskii2012-04-26 13:07:35 +0300
committerEli Zaretskii2012-04-26 13:07:35 +0300
commit1c6900d923647582ea9c2ab90f0ccf1fe41603e0 (patch)
tree2cdb4cbe3c49597b669c722cc317cb6c03e3338b /src
parentdce04f7f90fa8f613dd855cb300c837696483f1b (diff)
downloademacs-1c6900d923647582ea9c2ab90f0ccf1fe41603e0.tar.gz
emacs-1c6900d923647582ea9c2ab90f0ccf1fe41603e0.zip
Don't disable Unicode menus on Windows NT and later due to random errors.
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.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog7
-rw-r--r--src/w32menu.c9
2 files changed, 14 insertions, 2 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 06d65c7bf33..8b23806e57f 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,10 @@
12012-04-26 Eli Zaretskii <eliz@gnu.org>
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
12012-04-24 Andreas Schwab <schwab@linux-m68k.org> 82012-04-24 Andreas Schwab <schwab@linux-m68k.org>
2 9
3 * .gdbinit (xpr): Handle USE_2_TAGS_FOR_INTS. 10 * .gdbinit (xpr): Handle USE_2_TAGS_FOR_INTS.
diff --git a/src/w32menu.c b/src/w32menu.c
index 9091cb81627..5b95a083d90 100644
--- a/src/w32menu.c
+++ b/src/w32menu.c
@@ -48,6 +48,8 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
48 48
49#include "dispextern.h" 49#include "dispextern.h"
50 50
51#include "w32heap.h" /* for osinfo_cache */
52
51#undef HAVE_DIALOGS /* TODO: Implement native dialogs. */ 53#undef HAVE_DIALOGS /* TODO: Implement native dialogs. */
52 54
53#ifndef TRUE 55#ifndef TRUE
@@ -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))