aboutsummaryrefslogtreecommitdiffstats
path: root/kbfunc.c
diff options
context:
space:
mode:
authorokan2014-01-22 21:48:27 +0000
committerokan2014-01-22 21:48:27 +0000
commitd86dc240a824ab0c88be47a7c951517b8a07fdde (patch)
tree817269e43357f67bfcbaab33f728076e706d9484 /kbfunc.c
parent129338185f898dfe060a3de1b5b7aba429161b81 (diff)
downloadcwm-d86dc240a824ab0c88be47a7c951517b8a07fdde.tar.gz
Somewhat streamline event loop/restart/quit handling; most notable
change allows a restart to trigger proper teardown first, even though teardown is not (yet) complete. After some discussion with oga@nicotinebsd.org regarding a more complicated version/idea.
Diffstat (limited to '')
-rw-r--r--kbfunc.c16
1 files changed, 3 insertions, 13 deletions
diff --git a/kbfunc.c b/kbfunc.c
index 4ad5db3..f0b3608 100644
--- a/kbfunc.c
+++ b/kbfunc.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: kbfunc.c,v 1.90 2014/01/21 15:42:45 okan Exp $
+ * $OpenBSD: kbfunc.c,v 1.91 2014/01/22 21:48:27 okan Exp $
*/
#include <sys/param.h>
@@ -35,9 +35,6 @@
#define HASH_MARKER "|1|"
-extern char **cwm_argv;
-extern sig_atomic_t xev_quit;
-
void
kbfunc_client_lower(struct client_ctx *cc, union arg *arg)
{
@@ -464,16 +461,9 @@ kbfunc_client_freeze(struct client_ctx *cc, union arg *arg)
}
void
-kbfunc_quit_wm(struct client_ctx *cc, union arg *arg)
-{
- xev_quit = 1;
-}
-
-void
-kbfunc_restart(struct client_ctx *cc, union arg *arg)
+kbfunc_cwm_status(struct client_ctx *cc, union arg *arg)
{
- (void)setsid();
- (void)execvp(cwm_argv[0], cwm_argv);
+ cwm_status = arg->i;
}
void