aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGlenn Morris2014-05-07 20:41:21 -0700
committerGlenn Morris2014-05-07 20:41:21 -0700
commitfb3f83f5fd9e80347c8b8e36f6eaefbb912fe57b (patch)
treef106c360c3aef01bcacdc77b66b7c5b20261502e /src
parent1ba38c429fa6ce17568771ef51c8e53b1a72bb94 (diff)
parent606695a67801acfd1792110e4ea3228b50b0117d (diff)
downloademacs-fb3f83f5fd9e80347c8b8e36f6eaefbb912fe57b.tar.gz
emacs-fb3f83f5fd9e80347c8b8e36f6eaefbb912fe57b.zip
Merge from emacs-24; up to 2014-05-08T03:34:20Z!rgm@gnu.org
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog26
-rw-r--r--src/keyboard.c13
-rw-r--r--src/minibuf.c16
-rw-r--r--src/nsselect.m4
-rw-r--r--src/w32fns.c10
5 files changed, 52 insertions, 17 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 3aef0c729f6..72e78724bab 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,29 @@
12014-05-08 Paul Eggert <eggert@cs.ucla.edu>
2
3 * minibuf.c (read_minibuf): Avoid C99ism in previous patch (Bug#17430).
4
52014-05-08 Jarek Czekalski <jarekczek@poczta.onet.pl>
6
7 Fix initialization of minibuffer history variable (Bug#17430).
8 * minibuf.c (read_minibuf): Initialize histval to Qnil if unbound.
9 Move the initialization up to prevent any "value void" message.
10
112014-05-08 Samuel Bronson <naesten@gmail.com>
12
13 * keyboard.c (Frecursive_edit): Ensure inc&dec of command_loop_level
14 are matched (bug#17413).
15
162014-05-08 Jarek Czekalski <jarekczek@poczta.onet.pl>
17
18 Stop tooltips pulling Emacs window to front (Bug#17408).
19 * w32fns.c (Fx_show_tip): Add SWP_NOOWNERZORDER flag to
20 SetWindowPos invocations.
21
222014-05-08 Jan Djärv <jan.h.d@swipnet.se>
23
24 * nsselect.m (Fx_selection_exists_p): Just return Qnil if window system
25 not initialized (Bug#17398).
26
12014-05-07 Paul Eggert <eggert@cs.ucla.edu> 272014-05-07 Paul Eggert <eggert@cs.ucla.edu>
2 28
3 * image.c: Include <png.h> before <setjmp.h> (Bug#17429). 29 * image.c: Include <png.h> before <setjmp.h> (Bug#17429).
diff --git a/src/keyboard.c b/src/keyboard.c
index d52483e6a18..a5a9ad93047 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -825,22 +825,25 @@ This function is called by the editor initialization to begin editing. */)
825 if (input_blocked_p ()) 825 if (input_blocked_p ())
826 return Qnil; 826 return Qnil;
827 827
828 command_loop_level++; 828 if (command_loop_level >= 0
829 update_mode_lines = 17;
830
831 if (command_loop_level
832 && current_buffer != XBUFFER (XWINDOW (selected_window)->contents)) 829 && current_buffer != XBUFFER (XWINDOW (selected_window)->contents))
833 buffer = Fcurrent_buffer (); 830 buffer = Fcurrent_buffer ();
834 else 831 else
835 buffer = Qnil; 832 buffer = Qnil;
836 833
834 /* Don't do anything interesting between the increment and the
835 record_unwind_protect! Otherwise, we could get distracted and
836 never decrement the counter again. */
837 command_loop_level++;
838 update_mode_lines = 17;
839 record_unwind_protect (recursive_edit_unwind, buffer);
840
837 /* If we leave recursive_edit_1 below with a `throw' for instance, 841 /* If we leave recursive_edit_1 below with a `throw' for instance,
838 like it is done in the splash screen display, we have to 842 like it is done in the splash screen display, we have to
839 make sure that we restore single_kboard as command_loop_1 843 make sure that we restore single_kboard as command_loop_1
840 would have done if it were left normally. */ 844 would have done if it were left normally. */
841 if (command_loop_level > 0) 845 if (command_loop_level > 0)
842 temporarily_switch_to_single_kboard (SELECTED_FRAME ()); 846 temporarily_switch_to_single_kboard (SELECTED_FRAME ());
843 record_unwind_protect (recursive_edit_unwind, buffer);
844 847
845 recursive_edit_1 (); 848 recursive_edit_1 ();
846 return unbind_to (count, Qnil); 849 return unbind_to (count, Qnil);
diff --git a/src/minibuf.c b/src/minibuf.c
index 8b742cf88ca..06fe0c07df6 100644
--- a/src/minibuf.c
+++ b/src/minibuf.c
@@ -384,6 +384,7 @@ read_minibuf (Lisp_Object map, Lisp_Object initial, Lisp_Object prompt,
384 EMACS_INT pos = 0; 384 EMACS_INT pos = 0;
385 /* String to add to the history. */ 385 /* String to add to the history. */
386 Lisp_Object histstring; 386 Lisp_Object histstring;
387 Lisp_Object histval;
387 388
388 Lisp_Object empty_minibuf; 389 Lisp_Object empty_minibuf;
389 Lisp_Object dummy, frame; 390 Lisp_Object dummy, frame;
@@ -535,6 +536,14 @@ read_minibuf (Lisp_Object map, Lisp_Object initial, Lisp_Object prompt,
535 if (!NILP (Vminibuffer_completing_file_name)) 536 if (!NILP (Vminibuffer_completing_file_name))
536 Vminibuffer_completing_file_name = Qlambda; 537 Vminibuffer_completing_file_name = Qlambda;
537 538
539 /* If variable is unbound, make it nil. */
540 histval = find_symbol_value (Vminibuffer_history_variable);
541 if (EQ (histval, Qunbound))
542 {
543 Fset (Vminibuffer_history_variable, Qnil);
544 histval = Qnil;
545 }
546
538 if (inherit_input_method) 547 if (inherit_input_method)
539 { 548 {
540 /* `current-input-method' is buffer local. So, remember it in 549 /* `current-input-method' is buffer local. So, remember it in
@@ -703,13 +712,6 @@ read_minibuf (Lisp_Object map, Lisp_Object initial, Lisp_Object prompt,
703 { 712 {
704 /* If the caller wanted to save the value read on a history list, 713 /* If the caller wanted to save the value read on a history list,
705 then do so if the value is not already the front of the list. */ 714 then do so if the value is not already the front of the list. */
706 Lisp_Object histval;
707
708 /* If variable is unbound, make it nil. */
709
710 histval = find_symbol_value (Vminibuffer_history_variable);
711 if (EQ (histval, Qunbound))
712 Fset (Vminibuffer_history_variable, Qnil);
713 715
714 /* The value of the history variable must be a cons or nil. Other 716 /* The value of the history variable must be a cons or nil. Other
715 values are unacceptable. We silently ignore these values. */ 717 values are unacceptable. We silently ignore these values. */
diff --git a/src/nsselect.m b/src/nsselect.m
index f4713cb5e10..038849c0aed 100644
--- a/src/nsselect.m
+++ b/src/nsselect.m
@@ -429,7 +429,9 @@ On Nextstep, TERMINAL is unused. */)
429 id pb; 429 id pb;
430 NSArray *types; 430 NSArray *types;
431 431
432 check_window_system (NULL); 432 if (!window_system_available (NULL))
433 return Qnil;
434
433 CHECK_SYMBOL (selection); 435 CHECK_SYMBOL (selection);
434 if (EQ (selection, Qnil)) selection = QPRIMARY; 436 if (EQ (selection, Qnil)) selection = QPRIMARY;
435 if (EQ (selection, Qt)) selection = QSECONDARY; 437 if (EQ (selection, Qt)) selection = QSECONDARY;
diff --git a/src/w32fns.c b/src/w32fns.c
index 77476757c2f..fa988583f33 100644
--- a/src/w32fns.c
+++ b/src/w32fns.c
@@ -6035,12 +6035,13 @@ Text larger than the specified size is clipped. */)
6035 /* Put tooltip in topmost group and in position. */ 6035 /* Put tooltip in topmost group and in position. */
6036 SetWindowPos (FRAME_W32_WINDOW (f), HWND_TOPMOST, 6036 SetWindowPos (FRAME_W32_WINDOW (f), HWND_TOPMOST,
6037 root_x, root_y, 0, 0, 6037 root_x, root_y, 0, 0,
6038 SWP_NOSIZE | SWP_NOACTIVATE); 6038 SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOOWNERZORDER);
6039 6039
6040 /* Ensure tooltip is on top of other topmost windows (eg menus). */ 6040 /* Ensure tooltip is on top of other topmost windows (eg menus). */
6041 SetWindowPos (FRAME_W32_WINDOW (f), HWND_TOP, 6041 SetWindowPos (FRAME_W32_WINDOW (f), HWND_TOP,
6042 0, 0, 0, 0, 6042 0, 0, 0, 0,
6043 SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE); 6043 SWP_NOMOVE | SWP_NOSIZE
6044 | SWP_NOACTIVATE | SWP_NOOWNERZORDER);
6044 6045
6045 unblock_input (); 6046 unblock_input ();
6046 goto start_timer; 6047 goto start_timer;
@@ -6238,12 +6239,13 @@ Text larger than the specified size is clipped. */)
6238 SetWindowPos (FRAME_W32_WINDOW (f), HWND_TOPMOST, 6239 SetWindowPos (FRAME_W32_WINDOW (f), HWND_TOPMOST,
6239 root_x, root_y, 6240 root_x, root_y,
6240 rect.right - rect.left + FRAME_COLUMN_WIDTH (f), 6241 rect.right - rect.left + FRAME_COLUMN_WIDTH (f),
6241 rect.bottom - rect.top, SWP_NOACTIVATE); 6242 rect.bottom - rect.top, SWP_NOACTIVATE | SWP_NOOWNERZORDER);
6242 6243
6243 /* Ensure tooltip is on top of other topmost windows (eg menus). */ 6244 /* Ensure tooltip is on top of other topmost windows (eg menus). */
6244 SetWindowPos (FRAME_W32_WINDOW (f), HWND_TOP, 6245 SetWindowPos (FRAME_W32_WINDOW (f), HWND_TOP,
6245 0, 0, 0, 0, 6246 0, 0, 0, 0,
6246 SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE); 6247 SWP_NOMOVE | SWP_NOSIZE
6248 | SWP_NOACTIVATE | SWP_NOOWNERZORDER);
6247 6249
6248 /* Let redisplay know that we have made the frame visible already. */ 6250 /* Let redisplay know that we have made the frame visible already. */
6249 SET_FRAME_VISIBLE (f, 1); 6251 SET_FRAME_VISIBLE (f, 1);