aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/config.h10
-rw-r--r--src/config.h.def12
-rw-r--r--src/dminiwm.c18
3 files changed, 20 insertions, 20 deletions
diff --git a/src/config.h b/src/config.h
index 4f5db48..2462f6b 100644
--- a/src/config.h
+++ b/src/config.h
@@ -1,4 +1,4 @@
- /* config.h for dminiwm.c [ 0.1.6 ]
+ /* config.h for dminiwm.c [ 0.1.7 ]
*
* Started from catwm 31/12/10
* Bad window error checking and numlock checking used from
@@ -76,13 +76,13 @@ const char *mtogglecmd[] = { "mpc", "toggle", NULL };
/** Shortcuts **/
static key keys[] = {
/* modifier key function argument */
- { MOD1, XK_h, resize, {.i = -10}}, /* decrease */
- { MOD1, XK_l, resize, {.i = +10}}, /* increase */
+ { MOD1, XK_h, resize_master, {.i = -10}}, /* decrease */
+ { MOD1, XK_l, resize_master, {.i = +10}}, /* increase */
{ MOD1|ShiftMask, XK_c, kill_client, {NULL} },
{ MOD1, XK_j, next_win, {NULL} },
{ MOD1, XK_k, prev_win, {NULL} },
- { MOD1, XK_o, resize_window, {.i = -10}}, /* shrink */
- { MOD1, XK_p, resize_window, {.i = +10}}, /* grow */
+ { MOD1, XK_o, resize_stack, {.i = -10}}, /* shrink */
+ { MOD1, XK_p, resize_stack, {.i = +10}}, /* grow */
{ MOD1, XK_Return, swap_master, {NULL} },
{ MOD1|ShiftMask, XK_j, move_down, {NULL} },
{ MOD1|ShiftMask, XK_k, move_up, {NULL} },
diff --git a/src/config.h.def b/src/config.h.def
index 75c4f1f..99f485e 100644
--- a/src/config.h.def
+++ b/src/config.h.def
@@ -1,4 +1,4 @@
- /* config.h for dminiwm.c [ 0.1.6 ]
+ /* config.h for dminiwm.c [ 0.1.7 ]
*
* Started from catwm 31/12/10
* Bad window error checking and numlock checking used from
@@ -26,7 +26,7 @@
/* Mod (Mod1 == alt) (Mod4 == Super/windows) */
#define MOD1 Mod1Mask
-#define MOD4 Mod4Mask
+#define MOD4 Mod4Mask
#define MASTER_SIZE 0.52
#define TOP_PANEL 1 /* 1=Don't 0=Have the panel at the top instead of the bottom */
#define PANEL_HEIGHT 18 /* 0 for no space for a panel */
@@ -77,14 +77,14 @@ const char* shutdowncmd[] = {"sudo","shutdown","-h","now",NULL};
// Shortcuts
static key keys[] = {
// MOD KEY FUNCTION ARGS
- { MOD1, XK_h, resize, {.i = -10}}, /* decrease */
- { MOD1, XK_l, resize, {.i = +10}}, /* increase */
+ { MOD1, XK_h, resize_master, {.i = 10}},
+ { MOD1, XK_l, resize_master, {.i = -10}},
{ MOD1, XK_c, kill_client, {NULL}},
{ MOD1, XK_j, next_win, {NULL}},
{ MOD1, XK_k, prev_win, {NULL}},
{ MOD1, XK_v, spawn, {.com = dmenucmd}},
- { MOD1, XK_o, resize_window, {.i = -10}}, /* shrink */
- { MOD1, XK_p, resize_window, {.i = +10}}, /* grow */
+ { MOD1, XK_p, resize_stack, {.i = 10}},
+ { MOD1, XK_o, resize_stack, {.i = -10}},
{ MOD1, XK_Return, spawn, {.com = urxvtcmd}},
{ MOD1, XK_Up, spawn, {.com = volupcmd}},
{ MOD1, XK_Down, spawn, {.com = voldowncmd}},
diff --git a/src/dminiwm.c b/src/dminiwm.c
index d26dfff..2912633 100644
--- a/src/dminiwm.c
+++ b/src/dminiwm.c
@@ -1,4 +1,4 @@
-/* dminiwm.c [ 0.1.6 ]
+/* dminiwm.c [ 0.1.7 ]
*
* I started this from catwm 31/12/10
* Bad window error checking and numlock checking used from
@@ -106,8 +106,6 @@ static void enternotify(XEvent *e);
static void logger(const char* e);
static unsigned long getcolor(const char* color);
static void grabkeys();
-static void resize_window(const Arg arg);
-static void resize(const Arg arg);
static void keypress(XEvent *e);
static void kill_client();
static void maprequest(XEvent *e);
@@ -119,6 +117,8 @@ static void prev_desktop();
static void prev_win();
static void quit(const Arg arg);
static void remove_window(Window w);
+static void resize_master(const Arg arg);
+static void resize_stack(const Arg arg);
static void save_desktop(int i);
static void select_desktop(int i);
static void send_kill_signal(Window w);
@@ -348,11 +348,6 @@ void swap_master() {
}
}
-void resize(const Arg arg) {
- master_size += arg.i;
- tile();
-}
-
/* **************************** Desktop Management ************************************* */
void change_desktop(const Arg arg) {
client *c;
@@ -618,7 +613,12 @@ void switch_grid() {
}
}
-void resize_window(const Arg arg) {
+void resize_master(const Arg arg) {
+ master_size += arg.i;
+ tile();
+}
+
+void resize_stack(const Arg arg) {
growth += arg.i;
tile();
}