diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/frame.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/frame.c b/src/frame.c index 1fa48182e5e..a47dff82f5d 100644 --- a/src/frame.c +++ b/src/frame.c | |||
| @@ -118,6 +118,8 @@ Lisp_Object Vdefault_frame_scroll_bars; | |||
| 118 | Lisp_Object Vmouse_position_function; | 118 | Lisp_Object Vmouse_position_function; |
| 119 | Lisp_Object Vmouse_highlight; | 119 | Lisp_Object Vmouse_highlight; |
| 120 | Lisp_Object Vdelete_frame_functions; | 120 | Lisp_Object Vdelete_frame_functions; |
| 121 | |||
| 122 | int focus_follows_mouse; | ||
| 121 | 123 | ||
| 122 | static void | 124 | static void |
| 123 | set_menu_bar_lines_1 (window, n) | 125 | set_menu_bar_lines_1 (window, n) |
| @@ -4151,6 +4153,21 @@ displayed. | |||
| 4151 | 4153 | ||
| 4152 | This variable is local to the current terminal and cannot be buffer-local. */); | 4154 | This variable is local to the current terminal and cannot be buffer-local. */); |
| 4153 | 4155 | ||
| 4156 | DEFVAR_BOOL ("focus-follows-mouse", &focus_follows_mouse, | ||
| 4157 | doc: /* Non-nil if window system changes focus when you move the mouse. | ||
| 4158 | You should set this variable to tell Emacs how your window manager | ||
| 4159 | handles focus, since there is no way in general for Emacs to find out | ||
| 4160 | automatically. */); | ||
| 4161 | #ifdef HAVE_WINDOW_SYSTEM | ||
| 4162 | #if defined(HAVE_NTGUI) || defined(MAC_OS) | ||
| 4163 | focus_follows_mouse = 0; | ||
| 4164 | #else | ||
| 4165 | focus_follows_mouse = 1; | ||
| 4166 | #endif | ||
| 4167 | #else | ||
| 4168 | focus_follows_mouse = 0; | ||
| 4169 | #endif | ||
| 4170 | |||
| 4154 | staticpro (&Vframe_list); | 4171 | staticpro (&Vframe_list); |
| 4155 | 4172 | ||
| 4156 | defsubr (&Sactive_minibuffer_window); | 4173 | defsubr (&Sactive_minibuffer_window); |