mirror of
https://github.com/dylanaraps/sowm.git
synced 2025-05-19 01:20:23 -07:00
sowm: turns out we can't pass 0 as an error handler. :P
This commit is contained in:
parent
60d88980fb
commit
3662ca427d
@ -2,7 +2,7 @@
|
||||
|
||||
<a href="https://user-images.githubusercontent.com/6799467/66687576-9747c200-ec72-11e9-947d-5b96753eab03.jpg"><img src="https://user-images.githubusercontent.com/6799467/66687576-9747c200-ec72-11e9-947d-5b96753eab03.jpg" width="43%" align="right"></a>
|
||||
|
||||
An itsy bitsy floating window manager (*260~ sloc / 24kb compiled!*).
|
||||
An itsy bitsy floating window manager (*250~ sloc / 24kb compiled!*).
|
||||
|
||||
- Floating only.
|
||||
- Fullscreen toggle.
|
||||
|
5
sowm.c
5
sowm.c
@ -50,6 +50,7 @@ static void win_to_ws(const Arg arg);
|
||||
static void ws_go(const Arg arg);
|
||||
static void ws_save(int i);
|
||||
static void ws_sel(int i);
|
||||
static int xerror() { return 0;}
|
||||
|
||||
static client *list = {0};
|
||||
static desktop ws_list[10];
|
||||
@ -495,7 +496,7 @@ void configure_request(XEvent *e) {
|
||||
void map_request(XEvent *e) {
|
||||
Window w = e->xmaprequest.window;
|
||||
|
||||
XSelectInput(d, w, StructureNotifyMask|EnterWindowMask|LeaveWindowMask);
|
||||
XSelectInput(d, w, StructureNotifyMask|EnterWindowMask);
|
||||
|
||||
win_center((Arg){.i = w});
|
||||
XMapWindow(d, w);
|
||||
@ -532,7 +533,7 @@ int main(void) {
|
||||
if (!(d = XOpenDisplay(0x0))) return 0;
|
||||
|
||||
signal(SIGCHLD, SIG_IGN);
|
||||
XSetErrorHandler(0);
|
||||
XSetErrorHandler(xerror);
|
||||
|
||||
int s = DefaultScreen(d);
|
||||
root = RootWindow(d, s);
|
||||
|
Loading…
x
Reference in New Issue
Block a user