diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/xselect.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/xselect.c b/src/xselect.c index 40b6571e0ad..a234c7188f3 100644 --- a/src/xselect.c +++ b/src/xselect.c | |||
| @@ -353,7 +353,10 @@ x_get_local_selection (Lisp_Object selection_symbol, Lisp_Object target_type, | |||
| 353 | 353 | ||
| 354 | if (!NILP (handler_fn)) | 354 | if (!NILP (handler_fn)) |
| 355 | value = call3 (handler_fn, selection_symbol, | 355 | value = call3 (handler_fn, selection_symbol, |
| 356 | (local_request ? Qnil : target_type), | 356 | ((local_request |
| 357 | && NILP (Vx_treat_local_requests_remotely)) | ||
| 358 | ? Qnil | ||
| 359 | : target_type), | ||
| 357 | tem); | 360 | tem); |
| 358 | else | 361 | else |
| 359 | value = Qnil; | 362 | value = Qnil; |
| @@ -2798,6 +2801,14 @@ A value of 0 means wait as long as necessary. This is initialized from the | |||
| 2798 | \"*selectionTimeout\" resource. */); | 2801 | \"*selectionTimeout\" resource. */); |
| 2799 | x_selection_timeout = 0; | 2802 | x_selection_timeout = 0; |
| 2800 | 2803 | ||
| 2804 | DEFVAR_LISP ("x-treat-local-requests-remotely", Vx_treat_local_requests_remotely, | ||
| 2805 | doc: /* Whether to treat local selection requests as remote ones. | ||
| 2806 | |||
| 2807 | If non-nil, selection converters for string types (`STRING', | ||
| 2808 | `UTF8_STRING', `COMPOUND_TEXT', etc) will encode the strings, even | ||
| 2809 | when Emacs itself is converting the selection. */); | ||
| 2810 | Vx_treat_local_requests_remotely = Qnil; | ||
| 2811 | |||
| 2801 | /* QPRIMARY is defined in keyboard.c. */ | 2812 | /* QPRIMARY is defined in keyboard.c. */ |
| 2802 | DEFSYM (QSECONDARY, "SECONDARY"); | 2813 | DEFSYM (QSECONDARY, "SECONDARY"); |
| 2803 | DEFSYM (QSTRING, "STRING"); | 2814 | DEFSYM (QSTRING, "STRING"); |