mirror of
https://github.com/0intro/wmii
synced 2024-11-21 21:31:33 +03:00
Fix compiler warnings.
This commit is contained in:
parent
0d268397c5
commit
b340936d27
@ -188,7 +188,7 @@ main(int argc, char *argv[]) {
|
||||
xext_init();
|
||||
tray_init();
|
||||
|
||||
client_init(nil);
|
||||
client_init(address);
|
||||
|
||||
if(tray.edge == 0)
|
||||
tray.edge = West | (!strcmp(readctl("/ctl", "bar on "), "top") ? North : South);
|
||||
|
@ -251,7 +251,6 @@ apply_rules(Client *c) {
|
||||
void
|
||||
client_manage(Client *c) {
|
||||
Client *leader;
|
||||
Frame *f;
|
||||
char *tags;
|
||||
bool dotags;
|
||||
|
||||
@ -290,17 +289,17 @@ client_manage(Client *c) {
|
||||
&& !client_viewframe(group_leader(c->group),
|
||||
c->sel->view);
|
||||
|
||||
f = c->sel;
|
||||
/* f = c->sel; */
|
||||
if(!(c->w.ewmh.type & TypeSplash))
|
||||
if(newgroup) {
|
||||
/* XXX: Look over this.
|
||||
if(f->area != f->view->sel)
|
||||
f->view->oldsel = f->view->sel;
|
||||
*/
|
||||
}else {
|
||||
frame_restack(c->sel, c->sel->area->sel);
|
||||
view_restack(c->sel->view);
|
||||
}
|
||||
if(newgroup) {
|
||||
/* XXX: Look over this.
|
||||
if(f->area != f->view->sel)
|
||||
f->view->oldsel = f->view->sel;
|
||||
*/
|
||||
}else {
|
||||
frame_restack(c->sel, c->sel->area->sel);
|
||||
view_restack(c->sel->view);
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
@ -874,7 +873,7 @@ client_prop(Client *c, Atom a) {
|
||||
/* Handlers */
|
||||
static bool
|
||||
configreq_event(Window *w, void *aux, XConfigureRequestEvent *e) {
|
||||
Rectangle r, cr;
|
||||
Rectangle r;
|
||||
Client *c;
|
||||
|
||||
c = aux;
|
||||
@ -895,7 +894,6 @@ configreq_event(Window *w, void *aux, XConfigureRequestEvent *e) {
|
||||
c->border = e->border_width;
|
||||
|
||||
r.max = addpt(r.min, r.max);
|
||||
cr = r;
|
||||
r = client_grav(c, r);
|
||||
|
||||
if(c->sel->area->floating)
|
||||
|
@ -143,14 +143,15 @@ static void column_scale(Area*);
|
||||
void
|
||||
column_attachrect(Area *a, Frame *f, Rectangle r) {
|
||||
Frame *fp, *pos;
|
||||
int before, after;
|
||||
|
||||
pos = nil;
|
||||
for(fp=a->frame; fp; pos=fp, fp=fp->anext) {
|
||||
if(r.max.y < fp->r.min.y || r.min.y > fp->r.max.y)
|
||||
continue;
|
||||
/*
|
||||
before = fp->r.min.y - r.min.y;
|
||||
after = -fp->r.max.y + r.max.y;
|
||||
*/
|
||||
}
|
||||
column_insert(a, f, pos);
|
||||
column_resizeframe_h(f, r);
|
||||
|
@ -188,11 +188,9 @@ ewmh_initclient(Client *c) {
|
||||
|
||||
void
|
||||
ewmh_destroyclient(Client *c) {
|
||||
Ewmh *e;
|
||||
|
||||
ewmh_updateclientlist();
|
||||
|
||||
e = &c->w.ewmh;
|
||||
free(c->strut);
|
||||
}
|
||||
|
||||
|
@ -96,10 +96,8 @@ frame_insert(Frame *f, Frame *pos) {
|
||||
|
||||
bool
|
||||
frame_restack(Frame *f, Frame *above) {
|
||||
Client *c;
|
||||
Area *a;
|
||||
|
||||
c = f->client;
|
||||
a = f->area;
|
||||
if(!a->floating)
|
||||
return false;
|
||||
|
@ -523,7 +523,7 @@ fs_write(Ixp9Req *r) {
|
||||
t->max);
|
||||
else
|
||||
goto done;
|
||||
ixp_respond(r, nil);
|
||||
ixp_respond(r, errstr);
|
||||
found++;
|
||||
}
|
||||
done:
|
||||
|
@ -135,7 +135,7 @@ fake_keypress(ulong mod, KeyCode key) {
|
||||
static Key *
|
||||
match_keys(Key *k, ulong mod, KeyCode keycode, bool seq) {
|
||||
Key *ret, *next;
|
||||
volatile int i; /* shut up ken */
|
||||
int i; /* shut up ken */
|
||||
|
||||
ret = nil;
|
||||
for(next = k->tnext; k; i = (k=next) && (next=k->tnext)) {
|
||||
@ -146,6 +146,7 @@ match_keys(Key *k, ulong mod, KeyCode keycode, bool seq) {
|
||||
ret = k;
|
||||
}
|
||||
}
|
||||
USED(i);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -147,12 +147,9 @@ vplace(Framewin *fw, Point pt) {
|
||||
Rectangle r;
|
||||
Frame *f;
|
||||
Area *a;
|
||||
View *v;
|
||||
long l;
|
||||
int hr;
|
||||
|
||||
v = selview;
|
||||
|
||||
a = find_area(pt);
|
||||
if(a == nil)
|
||||
return;
|
||||
@ -200,11 +197,8 @@ done:
|
||||
static void
|
||||
hplace(Framewin *fw, Point pt) {
|
||||
Area *a;
|
||||
View *v;
|
||||
int minw;
|
||||
|
||||
v = selview;
|
||||
|
||||
a = find_area(pt);
|
||||
if(a == nil)
|
||||
return; /* XXX: Multihead. */
|
||||
|
@ -7,14 +7,12 @@
|
||||
void
|
||||
stack_scale(Frame *first, int height) {
|
||||
Frame *f;
|
||||
Area *a;
|
||||
uint dy;
|
||||
int surplus;
|
||||
|
||||
a = first->area;
|
||||
|
||||
/*
|
||||
* Will need something like this.
|
||||
a = first->area;
|
||||
column_fit(a, &ncol, &nuncol);
|
||||
*/
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user