remove getfacts() from cfacts, doesn't seem to be necessary
This commit is contained in:
parent
7358db978b
commit
3a7ea6f575
25
speedwm.c
25
speedwm.c
|
@ -403,7 +403,6 @@ typedef struct {
|
|||
/* function declarations */
|
||||
static void applyrules(Client *c);
|
||||
static void getgaps(Monitor *m, int *oh, int *ov, int *ih, int *iv, unsigned int *nc);
|
||||
static void getfacts(Monitor *m, int msize, int ssize, float *mf, float *sf, int *mr, int *sr);
|
||||
static int applysizehints(Client *c, int *x, int *y, int *w, int *h, int interact);
|
||||
static void inplacerotate(const Arg *arg);
|
||||
static void togglesticky(const Arg *arg);
|
||||
|
@ -1832,30 +1831,6 @@ detach(Client *c)
|
|||
*tc = c->next;
|
||||
}
|
||||
|
||||
void
|
||||
getfacts(Monitor *m, int msize, int ssize, float *mf, float *sf, int *mr, int *sr)
|
||||
{
|
||||
unsigned int n;
|
||||
float mfacts, sfacts;
|
||||
int mtotal = 0, stotal = 0;
|
||||
Client *c;
|
||||
|
||||
for (n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), n++);
|
||||
mfacts = MIN(n, m->mastercount);
|
||||
sfacts = n - m->mastercount;
|
||||
|
||||
for (n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), n++)
|
||||
if (n < m->mastercount)
|
||||
mtotal += msize / mfacts;
|
||||
else
|
||||
stotal += ssize / sfacts;
|
||||
|
||||
*mf = mfacts; /* total factor of master area */
|
||||
*sf = sfacts; /* total factor of stack area */
|
||||
*mr = msize - mtotal; /* the remainder (rest) of pixels after an even master split */
|
||||
*sr = ssize - stotal; /* the remainder (rest) of pixels after an even stack split */
|
||||
}
|
||||
|
||||
void
|
||||
detachstack(Client *c)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue