]> Dogcows Code - chaz/openbox/blobdiff - obrender/render.c
Merge branch 'master' into chaz
[chaz/openbox] / obrender / render.c
index 58bf12ec71a702499bfb3e78cd6a4850575f8741..fe9a2a80dd27669b8888b226ab0b62655e52b23a 100644 (file)
@@ -170,6 +170,8 @@ Pixmap RrPaintPixmap(RrAppearance *a, gint w, gint h)
             }
             force_transfer = 1;
         break;
+        case RR_TEXTURE_NUM_TYPES:
+            g_assert_not_reached();
         }
     }
 
@@ -229,6 +231,8 @@ void RrAppearanceClearTextures(RrAppearance *a)
     memset(a->texture, 0, a->textures * sizeof(RrTexture));
 }
 
+/* deep copy of orig, means reset ref to 1 on copy
+ * and copy each thing memwise. */
 RrAppearance *RrAppearanceCopy(RrAppearance *orig)
 {
     RrSurface *spo, *spc;
@@ -314,6 +318,7 @@ RrAppearance *RrAppearanceCopy(RrAppearance *orig)
     return copy;
 }
 
+/* now decrements ref counter, and frees only if ref <= 0 */
 void RrAppearanceFree(RrAppearance *a)
 {
     if (a) {
@@ -377,6 +382,8 @@ void RrMargins (RrAppearance *a, gint *l, gint *t, gint *r, gint *b)
             case RR_BEVEL_2:
                 *l = *t = *r = *b = 2;
                 break;
+            case RR_BEVEL_NUM_TYPES:
+                g_assert_not_reached();
             }
         } else if (a->surface.border) {
             *l = *t = *r = *b = 1;
@@ -426,6 +433,8 @@ gint RrMinWidth(RrAppearance *a)
             w = MAX(w, MAX(a->texture[i].data.lineart.x1 - l - r,
                            a->texture[i].data.lineart.x2 - l - r));
             break;
+        case RR_TEXTURE_NUM_TYPES:
+            g_assert_not_reached();
         }
     }
 
@@ -481,6 +490,8 @@ gint RrMinHeight(RrAppearance *a)
             h = MAX(h, MAX(a->texture[i].data.lineart.y1 - t - b,
                            a->texture[i].data.lineart.y2 - t - b));
             break;
+        case RR_TEXTURE_NUM_TYPES:
+            g_assert_not_reached();
         }
     }
 
This page took 0.02402 seconds and 4 git commands to generate.