diff options
| author | Joseph Arceneaux | 1992-05-12 03:44:17 +0000 |
|---|---|---|
| committer | Joseph Arceneaux | 1992-05-12 03:44:17 +0000 |
| commit | c047688cf20e884f3db98b58f74bc9655fbcca15 (patch) | |
| tree | 75f50b1397606b3dd4c8009d10df21a82eb6bf0a /src | |
| parent | 3c25457042415d8ad853a8506f24a51561996553 (diff) | |
| download | emacs-c047688cf20e884f3db98b58f74bc9655fbcca15.tar.gz emacs-c047688cf20e884f3db98b58f74bc9655fbcca15.zip | |
*** empty log message ***
Diffstat (limited to 'src')
| -rw-r--r-- | src/xfns.c | 7 | ||||
| -rw-r--r-- | src/xterm.c | 57 | ||||
| -rw-r--r-- | src/xterm.h | 2 |
3 files changed, 61 insertions, 5 deletions
diff --git a/src/xfns.c b/src/xfns.c index 760c09b883c..6673ec1716f 100644 --- a/src/xfns.c +++ b/src/xfns.c | |||
| @@ -171,8 +171,8 @@ extern Atom Xatom_wm_save_yourself; | |||
| 171 | extern Atom Xatom_wm_delete_window; | 171 | extern Atom Xatom_wm_delete_window; |
| 172 | 172 | ||
| 173 | /* Other WM communication */ | 173 | /* Other WM communication */ |
| 174 | Atom Xatom_wm_configure_denied; /* When our config request is denied */ | 174 | extern Atom Xatom_wm_configure_denied; /* When our config request is denied */ |
| 175 | Atom Xatom_wm_window_moved; /* When the WM moves us. */ | 175 | extern Atom Xatom_wm_window_moved; /* When the WM moves us. */ |
| 176 | 176 | ||
| 177 | #else /* X10 */ | 177 | #else /* X10 */ |
| 178 | 178 | ||
| @@ -3922,7 +3922,8 @@ also be depressed for NEWSTRING to appear.") | |||
| 3922 | register Lisp_Object newstring; | 3922 | register Lisp_Object newstring; |
| 3923 | { | 3923 | { |
| 3924 | char *rawstring; | 3924 | char *rawstring; |
| 3925 | register KeySym keysym, modifier_list[16]; | 3925 | register KeySym keysym; |
| 3926 | KeySym modifier_list[16]; | ||
| 3926 | 3927 | ||
| 3927 | CHECK_STRING (x_keysym, 1); | 3928 | CHECK_STRING (x_keysym, 1); |
| 3928 | CHECK_STRING (newstring, 3); | 3929 | CHECK_STRING (newstring, 3); |
diff --git a/src/xterm.c b/src/xterm.c index 1df1c7d36ba..69c16d843b3 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -1691,6 +1691,18 @@ static char *events[] = | |||
| 1691 | sometimes don't work. */ | 1691 | sometimes don't work. */ |
| 1692 | static Time enter_timestamp; | 1692 | static Time enter_timestamp; |
| 1693 | 1693 | ||
| 1694 | /* Communication with window managers. */ | ||
| 1695 | Atom Xatom_wm_protocols; | ||
| 1696 | |||
| 1697 | /* Kinds of protocol things we may receive. */ | ||
| 1698 | Atom Xatom_wm_take_focus; | ||
| 1699 | Atom Xatom_wm_save_yourself; | ||
| 1700 | Atom Xatom_wm_delete_window; | ||
| 1701 | |||
| 1702 | /* Other WM communication */ | ||
| 1703 | Atom Xatom_wm_configure_denied; /* When our config request is denied */ | ||
| 1704 | Atom Xatom_wm_window_moved; /* When the WM moves us. */ | ||
| 1705 | |||
| 1694 | /* Read events coming from the X server. | 1706 | /* Read events coming from the X server. |
| 1695 | This routine is called by the SIGIO handler. | 1707 | This routine is called by the SIGIO handler. |
| 1696 | We return as soon as there are no more events to be read. | 1708 | We return as soon as there are no more events to be read. |
| @@ -1761,6 +1773,51 @@ XTread_socket (sd, bufp, numchars, waitp, expected) | |||
| 1761 | switch (event.type) | 1773 | switch (event.type) |
| 1762 | { | 1774 | { |
| 1763 | #ifdef HAVE_X11 | 1775 | #ifdef HAVE_X11 |
| 1776 | case ClientMessage: | ||
| 1777 | { | ||
| 1778 | if (event.xclient.message_type == Xatom_wm_protocols | ||
| 1779 | && event.xclient.format == 32) | ||
| 1780 | { | ||
| 1781 | if (event.xclient.data.l[0] == Xatom_wm_take_focus) | ||
| 1782 | { | ||
| 1783 | s = x_window_to_screen (event.xclient.window); | ||
| 1784 | if (s) | ||
| 1785 | x_focus_on_screen (s); | ||
| 1786 | /* Not certain about handling scrollbars here */ | ||
| 1787 | } | ||
| 1788 | else if (event.xclient.data.l[0] == Xatom_wm_save_yourself) | ||
| 1789 | { | ||
| 1790 | /* Save state modify the WM_COMMAND property to | ||
| 1791 | something which can reinstate us. This notifies | ||
| 1792 | the session manager, who's looking for such a | ||
| 1793 | PropertyNotify. Can restart processing when | ||
| 1794 | a keyboard or mouse event arrives. */ | ||
| 1795 | if (numchars > 0) | ||
| 1796 | { | ||
| 1797 | } | ||
| 1798 | } | ||
| 1799 | else if (event.xclient.data.l[0] == Xatom_wm_delete_window) | ||
| 1800 | { | ||
| 1801 | struct screen *s = x_window_to_screen (event.xclient.window); | ||
| 1802 | |||
| 1803 | if (s) | ||
| 1804 | if (numchars > 0) | ||
| 1805 | { | ||
| 1806 | } | ||
| 1807 | } | ||
| 1808 | } | ||
| 1809 | else if (event.xclient.message_type == Xatom_wm_configure_denied) | ||
| 1810 | { | ||
| 1811 | } | ||
| 1812 | else if (event.xclient.message_type == Xatom_wm_window_moved) | ||
| 1813 | { | ||
| 1814 | int new_x, new_y; | ||
| 1815 | |||
| 1816 | new_x = event.xclient.data.s[0]; | ||
| 1817 | new_y = event.xclient.data.s[1]; | ||
| 1818 | } | ||
| 1819 | } | ||
| 1820 | break; | ||
| 1764 | 1821 | ||
| 1765 | case SelectionClear: /* Someone has grabbed ownership. */ | 1822 | case SelectionClear: /* Someone has grabbed ownership. */ |
| 1766 | x_disown_selection (event.xselectionclear.window, | 1823 | x_disown_selection (event.xselectionclear.window, |
diff --git a/src/xterm.h b/src/xterm.h index 934a2917f34..9186ef8eacb 100644 --- a/src/xterm.h +++ b/src/xterm.h | |||
| @@ -33,8 +33,6 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ | |||
| 33 | 33 | ||
| 34 | #define EVENT_BUFFER_SIZE 64 | 34 | #define EVENT_BUFFER_SIZE 64 |
| 35 | 35 | ||
| 36 | #define RES_CLASS "emacs" | ||
| 37 | |||
| 38 | /* Max and Min sizes in character columns. */ | 36 | /* Max and Min sizes in character columns. */ |
| 39 | #define MINWIDTH 10 | 37 | #define MINWIDTH 10 |
| 40 | #define MINHEIGHT 10 | 38 | #define MINHEIGHT 10 |