[emerillon/gtk3] Re-add map scale using new champlain api



commit a2e874f7fef7a9236689f77d111f40ba2e2f6555
Author: Andreas Henriksson <andreas fatal se>
Date:   Fri Aug 5 11:59:57 2011 +0200

    Re-add map scale using new champlain api
    
    The old "show-scale" property was simply dropped in commit
    "Removed no longer existing champlain properties/signals".
    
    This adds it back using the new api instead of the old property.

 emerillon/window.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)
---
diff --git a/emerillon/window.c b/emerillon/window.c
index 51c3bac..b366c00 100644
--- a/emerillon/window.c
+++ b/emerillon/window.c
@@ -826,6 +826,7 @@ build_ui (EmerillonWindow *self)
   GtkWidget *viewport;
   GtkWidget *hpaned;
   GtkWidget *embed_view;
+  ClutterActor *scale;
   GError *error = NULL;
 
   /* Action entries. */
@@ -934,6 +935,13 @@ build_ui (EmerillonWindow *self)
       NULL);
   champlain_view_center_on (self->priv->view, 40, 0);
 
+  scale = champlain_scale_new ();
+  champlain_scale_connect_view (CHAMPLAIN_SCALE (scale), self->priv->view);
+
+  /* align to the bottom left */
+  champlain_view_bin_layout_add (self->priv->view, scale,
+      CLUTTER_BIN_ALIGNMENT_START, CLUTTER_BIN_ALIGNMENT_END);
+
   /* Sidebar. */
   self->priv->sidebar = emerillon_sidebar_new ();
   gtk_widget_set_size_request (self->priv->sidebar, 200, -1);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]