aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormoetunes <moetunes111@gmail.com>2011-10-15 14:55:45 +1000
committermoetunes <moetunes111@gmail.com>2011-10-15 14:55:45 +1000
commita141f4c8bf3188a371ce7a43f27f95f44627d0c0 (patch)
tree10d6b9050b9e727e49fa9609554875c48ce1c63a /src
parent28546a6982fa1b20f4b28ff05fc294f8ecca1e3b (diff)
Fine tuned the maprequest function
Diffstat (limited to 'src')
-rwxr-xr-xsrc/config.h4
-rw-r--r--src/dminiwm.c3
2 files changed, 4 insertions, 3 deletions
diff --git a/src/config.h b/src/config.h
index d0c58f1..10843a3 100755
--- a/src/config.h
+++ b/src/config.h
@@ -35,17 +35,19 @@
#define DEFAULT_MODE 0 /* 0=Vertical, 1=Fullscreen 2=Horizontal 3=grid*/
#define FOLLOW_MOUSE 0 /* 1=Don't 0=Focus the window the mouse just entered */
#define FOLLOW_WINDOW 0 /* 1=Don't 0=Follow the window when moved to a different desktop */
+#define DESKTOPS 6 /* Must edit DESKTOPCHANGE keys to suit */
// Colors
#define FOCUS "#664422" // dkorange
#define UNFOCUS "#004050" // blueish
-// Applications to a set desktop
+// Applications to a specific desktop
static const Convenience convenience[] = { \
/* class desktop follow */
{ "Thunar", 2, 1 },
{ "Leafpad", 2, 1 },
{ "Firefox", 3, 0 },
+ { "MPlayer", 4, 1 },
{ "Thunderbird", 5, 0 },
{ "Pysol", 6, 0 },
};
diff --git a/src/dminiwm.c b/src/dminiwm.c
index 4029cf1..46e80a4 100644
--- a/src/dminiwm.c
+++ b/src/dminiwm.c
@@ -142,7 +142,7 @@ static void (*events[LASTEvent])(XEvent *e) = {
};
// Desktop array
-static desktop desktops[6];
+static desktop desktops[DESKTOPS];
/* ***************************** Window Management ******************************* */
void add_window(Window w) {
@@ -697,7 +697,6 @@ void maprequest(XEvent *e) {
if(XGetClassHint(dis, ev->window, &ch))
for(i=0;i<len;i++)
if(strcmp(ch.res_class, convenience[i].class) == 0) {
- fprintf(stdout, "%s will be moved....\n", ch.res_class);
save_desktop(tmp);
select_desktop(convenience[i].preferredd-1);
add_window(ev->window);