Commit graph

9 commits

Author SHA1 Message Date
Adrián Medraño Calvo
983fd468dc Add missing declarations
* exwm-systemtray.el :
	* exwm-manage.el :
	* exwm-layout.el :
	* exwm-input.el :
	* exwm-floating.el :
	* exwm-core.el : Add missing function declarations.
2016-07-17 12:00:00 +00:00
Chris Feng
39dc328157 Fix various stability issues
* exwm-input.el (exwm-input--on-KeyPress-line-mode)
(exwm-input--on-KeyPress-char-mode): Append events at the tail.

* exwm-manage.el (exwm-manage--unmanage-window): Remove the
_NET_WM_DESKTOP property when an X window is withdrawn.

* exwm-systemtray.el (exwm-systemtray--init):
* exwm-workspace.el (exwm-workspace--confirm-kill-emacs):
Issue warning rather than error when there's an existing tray running.

* exwm.el (exwm--on-ClientMessage): The buffer window can be on a
floating frame.
2016-07-14 22:08:27 +08:00
Chris Feng
1b2ae3749e Add cleanup codes for Emacs daemon
* exwm-floating.el (exwm-floating--exit):
* exwm-input.el (exwm-input--exit):
* exwm-layout.el (exwm-layout--exit):
* exwm-manage.el (exwm-manage--exit):
* exwm-randr.el (exwm-randr--exit):
* exwm-systemtray.el (exwm-systemtray--exit):
* exwm-workspace.el (exwm-workspace--exit):
New functions for cleanup each module.

* exwm-input.el (exwm-input--on-pre-command, exwm-input--on-post-command)
(exwm-input--init): Name lambda functions.

* exwm-layout.el (exwm-layout--timer, exwm-layout--init): Save timer.

* exwm-randr.el (exwm-randr-enable): Register the cleanup function.

* exwm-systemtray.el (exwm-systemtray--init): Force refresh atoms in XEMBED
and system tray protocols.
(exwm-systemtray-enable): Register the cleanup function.

* exwm-workspace.el (exwm-workspace--client): Save the server process.
(exwm-workspace--confirm-kill-emacs): Add emacsclient-specific
cleanup codes.
(exwm-workspace--timer): Save the timer.
(exwm-workspace--init): Save the server process and timer;
fix problems with emacsclient frames.

* exwm.el (exwm-init): Always select the newly created frame;
force refresh ICCCM & EWMH atoms.
(exwm-exit-hook): New hook for holding cleanup codes.
(exwm--exit): Run `exwm-exit-hook', execute cleanup codes for
each module and reset the environment.
2016-05-23 19:13:42 +08:00
Chris Feng
2dcb26ce9d Use xcb:connect' instead of xcb:connect-to-socket'
* exwm.el (exwm-init):
* exwm-systemtray.el (exwm-systemtray--init):
Use `xcb:connect' instead of `xcb:connect-to-socket'.
2016-05-13 00:11:12 +08:00
Chris Feng
009854e766 Announce manager selection with client message
* exwm-systemtray.el (exwm-systemtray--init): Send a client message to
announce the manager selection.
(xcb:systemtray:-ClientMessage): The client message.
2016-04-21 21:37:02 +08:00
Chris Feng
55cec760ca Fix emacsclient related issues
* exwm-systemtray.el (exwm-systemtray-height): The value is not available
when emacsclient has just loaded the library (and it crashes emacsclient).

* exwm-workspace.el (exwm-workspace--init): Set `default-minibuffer-frame'
later to prevent it from being modified when using emacsclient.

* exwm-floating.el:
* exwm-randr.el:
* exwm-systemtray.el:
* exwm-workspace.el:
* exwm.el: Use `exwm-workspace--minibuffer-own-frame-p' instead of the raw
variable.
2016-02-21 20:19:45 +08:00
Chris Feng
08bf970b16 Minor fixes for system tray
* exwm-systemtray.el (exwm-systemtray--embed): Default to visible if the
XEMBED_MAPPED flag is not set.
(exwm-systemtray--on-ClientMessage): Only embed new icons.  Ignore balloon
messages.
2016-02-19 20:18:29 +08:00
Chris Feng
fc589b899b Fix system tray issues after updating workspaces
* exwm-workspace.el (exwm-workspace-switch-hook): New hook run by
`exwm-workspace-switch'.
* exwm-randr.el (exwm-randr-refresh-hook): New hook run by
`exwm-randr--refresh'.
* exwm-systemtray.el (exwm-systemtray--on-randr-refresh)
(exwm-systemtray--on-workspace-switch, exwm-systemtray--init): Update the
system tray in `exwm-randr-refresh-hook' and `exwm-workspace-switch-hook'.

* exwm-layout.el (exwm-layout--set-frame-fullscreen):
* exwm-workspace.el (exwm-workspace--post-init): Wait until all workspace
frames are set fullscreen.

* exwm-workspace.el (exwm-workspace--current-width)
(exwm-workspace--current-height): New functions for retrieving the width
and height of the current workspace.
* exwm-layout.el (exwm-layout-set-fullscreen):
* exwm-manage.el (exwm-manage--manage-window)
(exwm-manage--on-ConfigureRequest):
* exwm-systemtray.el (exwm-systemtray--refresh, exwm-systemtray--init):
* exwm-workspace.le (exwm-workspace--resize-minibuffer-frame)
(exwm-workspace--on-ConfigureNotify): Switch to
`exwm-workspace--current-width' and `exwm-workspace--current-height'.

* exwm-core.el:
* exwm-floating.el:
* exwm-floating.el:
* exwm-input.el:
* exwm-layout.el:
* exwm-manage.el:
* exwm-randr.el:
* exwm-systemtray.el:
* exwm-workspace.el:
* exwm.el:
Clean up loading file.  Set/Unset some functions as commands.

* README.md: Add intro to system tray.
2016-02-19 17:12:43 +08:00
Chris Feng
bfd43feb49 Add system tray support
* exwm-systemtray.el: New module adds a simple system tray (using the X11
System Tray protocol).

* exwm-workspace.el (exwm-workspace-switch-hook, exwm-workspace-switch):
New hook run after switching workspace.
2016-02-19 11:02:37 +08:00