added setfloating function
This commit is contained in:
14
dwm.c
14
dwm.c
@@ -204,6 +204,7 @@ static int sendevent(Client *c, Atom proto);
|
||||
static void sendmon(Client *c, Monitor *m);
|
||||
static void setclientstate(Client *c, long state);
|
||||
static void setfocus(Client *c);
|
||||
static void setfloating(const Arg *arg);
|
||||
static void setfullscreen(Client *c, int fullscreen);
|
||||
static void setlayout(const Arg *arg);
|
||||
static void setmfact(const Arg *arg);
|
||||
@@ -1826,6 +1827,19 @@ togglefloating(const Arg *arg)
|
||||
arrange(selmon);
|
||||
}
|
||||
|
||||
void
|
||||
setfloating(const Arg *arg)
|
||||
{
|
||||
if (!selmon->sel)
|
||||
return;
|
||||
if (selmon->sel->isfullscreen) /* no support for fullscreen windows */
|
||||
return;
|
||||
selmon->sel->isfloating = True;
|
||||
resize(selmon->sel, selmon->sel->x, selmon->sel->y,
|
||||
selmon->sel->w, selmon->sel->h, 0);
|
||||
arrange(selmon);
|
||||
}
|
||||
|
||||
void
|
||||
togglefullscr(const Arg *arg)
|
||||
{
|
||||
|
Reference in New Issue
Block a user