[Cogl] [PATCH] onscreen: remove unused _cogl_onscreen_new

Robert Bragg robert at sixbynine.org
Mon Nov 26 15:26:36 PST 2012


From: Robert Bragg <robert at linux.intel.com>

---
 cogl/cogl-onscreen-private.h |    3 ---
 cogl/cogl-onscreen.c         |   28 ----------------------------
 2 files changed, 0 insertions(+), 31 deletions(-)

diff --git a/cogl/cogl-onscreen-private.h b/cogl/cogl-onscreen-private.h
index 06bdd4d..d5a3707 100644
--- a/cogl/cogl-onscreen-private.h
+++ b/cogl/cogl-onscreen-private.h
@@ -83,9 +83,6 @@ struct _CoglOnscreen
   void *winsys;
 };
 
-CoglOnscreen *
-_cogl_onscreen_new (void);
-
 void
 _cogl_framebuffer_winsys_update_size (CoglFramebuffer *framebuffer,
                                       int width, int height);
diff --git a/cogl/cogl-onscreen.c b/cogl/cogl-onscreen.c
index b766469..99a0ea0 100644
--- a/cogl/cogl-onscreen.c
+++ b/cogl/cogl-onscreen.c
@@ -52,34 +52,6 @@ _cogl_onscreen_init_from_template (CoglOnscreen *onscreen,
   cogl_object_ref (framebuffer->config.swap_chain);
 }
 
-/* XXX: While we still have backend in Clutter we need a dummy object
- * to represent the CoglOnscreen framebuffer that the backend
- * creates... */
-CoglOnscreen *
-_cogl_onscreen_new (void)
-{
-  CoglOnscreen *onscreen = g_new0 (CoglOnscreen, 1);
-
-  _COGL_GET_CONTEXT (ctx, NULL);
-
-  _cogl_framebuffer_init (COGL_FRAMEBUFFER (onscreen),
-                          ctx,
-                          COGL_FRAMEBUFFER_TYPE_ONSCREEN,
-                          COGL_PIXEL_FORMAT_RGBA_8888_PRE,
-                          0x1eadbeef, /* width */
-                          0x1eadbeef); /* height */
-  /* NB: make sure to pass positive width/height numbers here
-   * because otherwise we'll hit input validation assertions!*/
-
-  _cogl_onscreen_init_from_template (onscreen, ctx->display->onscreen_template);
-
-  COGL_FRAMEBUFFER (onscreen)->allocated = TRUE;
-
-  /* XXX: Note we don't initialize onscreen->winsys in this case. */
-
-  return _cogl_onscreen_object_new (onscreen);
-}
-
 CoglOnscreen *
 cogl_onscreen_new (CoglContext *ctx, int width, int height)
 {
-- 
1.7.7.6



More information about the Cogl mailing list