]> git.tdb.fi Git - geometrycompositor.git/commitdiff
Use None in place of 0 for XIDs
authorMikko Rasa <tdb@tdb.fi>
Mon, 14 Dec 2015 11:19:03 +0000 (13:19 +0200)
committerMikko Rasa <tdb@tdb.fi>
Mon, 14 Dec 2015 11:19:03 +0000 (13:19 +0200)
source/main.c

index 23c061b86fc3a5557dfba3b2266499f29b36ef1c..6e92cae153ebc5c3d8d6c439432fe71df4bb33fb 100644 (file)
@@ -827,14 +827,14 @@ void update_root_pixmap(Compositor *compositor, CompositedScreen *screen)
        if(screen->root_glx_pixmap)
        {
                glXDestroyPixmap(compositor->display, screen->root_glx_pixmap);
-               screen->root_glx_pixmap = 0;
+               screen->root_glx_pixmap = None;
        }
 
        XGetWindowProperty(compositor->display, screen->root, compositor->root_pmap_atom, 0, 1, False, XA_PIXMAP,
                &prop_type, &prop_format, &length, &overflow, (unsigned char **)&pixmap);
        if(prop_type!=XA_PIXMAP || prop_format!=32)
        {
-               screen->root_pixmap = 0;
+               screen->root_pixmap = None;
                return;
        }
 
@@ -892,8 +892,8 @@ int initialize_screen(Compositor *compositor, unsigned number)
                        return 0;
        XRRFreeScreenResources(xrr_res);
 
-       screen->root_pixmap = 0;
-       screen->root_glx_pixmap = 0;
+       screen->root_pixmap = None;
+       screen->root_glx_pixmap = None;
 
        update_geometry_correction(compositor, screen);
        update_root_pixmap(compositor, screen);
@@ -1023,7 +1023,7 @@ void shutdown_screen(Compositor *compositor, CompositedScreen *screen)
        for(i=0; i<3; ++i)
                glDeleteShader(screen->shaders[i]);
 
-       glXMakeContextCurrent(compositor->display, 0, 0, NULL);
+       glXMakeContextCurrent(compositor->display, None, None, NULL);
        glXDestroyContext(compositor->display, screen->glx_context);
        glXDestroyWindow(compositor->display, screen->glx_window);
        XDestroyWindow(compositor->display, screen->render_window);