Implements a reload command

This commit is contained in:
bapt
2009-07-23 16:14:24 +00:00
committed by Michael Stapelberg
parent 9db8535b4c
commit 40750e227d
5 changed files with 69 additions and 19 deletions

View File

@ -26,6 +26,7 @@
#include "client.h"
#include "floating.h"
#include "xcb.h"
#include "config.h"
bool focus_window_in_container(xcb_connection_t *conn, Container *container, direction_t direction) {
/* If this container is empty, were done */
@ -907,6 +908,12 @@ void parse_command(xcb_connection_t *conn, const char *command) {
exit(EXIT_SUCCESS);
}
/* Is it <reload */
if (STARTS_WITH(command, "reload")) {
load_configuration(conn,NULL,true);
return;
}
/* Is it <restart>? Then restart in place. */
if (STARTS_WITH(command, "restart")) {
LOG("restarting \"%s\"...\n", start_argv[0]);