]> err.no Git - libchamplain/commitdiff
Partly fix Bug 577591: Adopt the new coding style for champlain-map.h
authorSimon Wenner <simon@wenner.ch>
Sat, 11 Apr 2009 23:53:44 +0000 (19:53 -0400)
committerPierre-Luc Beaudoin <pierre-luc@pierlux.com>
Sat, 11 Apr 2009 23:54:59 +0000 (19:54 -0400)
and champlain-zoom-level.c

champlain/champlain-map.c
champlain/champlain-map.h
champlain/champlain-zoom-level.c
champlain/champlain-zoom-level.h

index a239ff42b3273d4898af53469ee673e2274eacdc..a69feda376b220dfa30b41b471e8bc50059504a6 100644 (file)
@@ -36,7 +36,9 @@ map_new (void)
 }
 
 void
-map_load_level(Map *map, ChamplainMapSource *map_source, gint zoom_level)
+map_load_level(Map *map,
+    ChamplainMapSource *map_source,
+    gint zoom_level)
 {
   if (map->previous_level)
     g_object_unref (map->previous_level);
@@ -54,7 +56,10 @@ map_load_level(Map *map, ChamplainMapSource *map_source, gint zoom_level)
 }
 
 void
-map_load_visible_tiles (Map *map, ChamplainView *view, ChamplainMapSource *source, ChamplainRectangle viewport)
+map_load_visible_tiles (Map *map,
+    ChamplainView *view,
+    ChamplainMapSource *source,
+    ChamplainRectangle viewport)
 {
   gint size;
 
@@ -134,7 +139,8 @@ map_load_visible_tiles (Map *map, ChamplainView *view, ChamplainMapSource *sourc
 }
 
 gboolean
-map_zoom_in (Map *map, ChamplainMapSource *source)
+map_zoom_in (Map *map,
+    ChamplainMapSource *source)
 {
   guint new_level = champlain_zoom_level_get_zoom_level (map->current_level) + 1;
   if(new_level <= champlain_map_source_get_max_zoom_level (source))
@@ -146,7 +152,8 @@ map_zoom_in (Map *map, ChamplainMapSource *source)
 }
 
 gboolean
-map_zoom_out (Map *map, ChamplainMapSource *source)
+map_zoom_out (Map *map,
+    ChamplainMapSource *source)
 {
   gint new_level = champlain_zoom_level_get_zoom_level (map->current_level) - 1;
   if(new_level >= champlain_map_source_get_min_zoom_level (source))
@@ -164,7 +171,9 @@ map_free (Map *map)
 }
 
 gboolean
-map_zoom_to (Map *map, ChamplainMapSource *source, guint zoomLevel)
+map_zoom_to (Map *map,
+    ChamplainMapSource *source,
+    guint zoomLevel)
 {
   if (zoomLevel<= champlain_map_source_get_max_zoom_level (source))
     {
index 4192da6bdac33498fcbf27238a4614fb20256b74..655071208b608f3c3972224653b421b457ec34f7 100644 (file)
@@ -37,16 +37,25 @@ struct _Map
 
 Map *map_new (void);
 
-void map_load_visible_tiles (Map *map, ChamplainView * view, ChamplainMapSource *source, ChamplainRectangle viewport);
+void map_load_visible_tiles (Map *map,
+    ChamplainView * view,
+    ChamplainMapSource *source,
+    ChamplainRectangle viewport);
 
 void map_free (Map *map);
 
-gboolean map_zoom_in (Map *map, ChamplainMapSource *map_source);
+gboolean map_zoom_in (Map *map,
+    ChamplainMapSource *map_source);
 
-gboolean map_zoom_out (Map *map, ChamplainMapSource *map_source);
+gboolean map_zoom_out (Map *map,
+    ChamplainMapSource *map_source);
 
-gboolean map_zoom_to (Map *map, ChamplainMapSource *map_source, guint zoomLevel);
+gboolean map_zoom_to (Map *map,
+    ChamplainMapSource *map_source,
+    guint zoomLevel);
 
-void map_load_level(Map *map, ChamplainMapSource *map_source, gint zoom_level);
+void map_load_level(Map *map,
+    ChamplainMapSource *map_source,
+    gint zoom_level);
 
 #endif
index cfae4f7451165223d5221d7e2da9884db233bcab..3f533a22a07518946d5ec5caf323a591c1449b54 100644 (file)
@@ -57,9 +57,9 @@ struct _ChamplainZoomLevelPrivate {
 
 static void
 champlain_zoom_level_get_property (GObject *object,
-                                   guint property_id,
-                                   GValue *value,
-                                   GParamSpec *pspec)
+    guint property_id,
+    GValue *value,
+    GParamSpec *pspec)
 {
   ChamplainZoomLevel *self = CHAMPLAIN_ZOOM_LEVEL (object);
   switch (property_id)
@@ -83,9 +83,9 @@ champlain_zoom_level_get_property (GObject *object,
 
 static void
 champlain_zoom_level_set_property (GObject *object,
-                                   guint property_id,
-                                   const GValue *value,
-                                   GParamSpec *pspec)
+    guint property_id,
+    const GValue *value,
+    GParamSpec *pspec)
 {
   ChamplainZoomLevel *self = CHAMPLAIN_ZOOM_LEVEL (object);
   switch (property_id)
@@ -156,40 +156,40 @@ champlain_zoom_level_class_init (ChamplainZoomLevelClass *klass)
   g_object_class_install_property (object_class,
       PROP_WIDTH,
       g_param_spec_uint ("width",
-        "Width",
-        "The width of this zoom level",
-        0,
-        G_MAXINT,
-        0,
-        G_PARAM_READWRITE));
+          "Width",
+          "The width of this zoom level",
+          0,
+          G_MAXINT,
+          0,
+          G_PARAM_READWRITE));
 
   g_object_class_install_property (object_class,
       PROP_HEIGHT,
       g_param_spec_uint ("height",
-        "height",
-        "The height of this zoom level",
-        0,
-        G_MAXINT,
-        0,
-        G_PARAM_READWRITE));
+          "height",
+          "The height of this zoom level",
+          0,
+          G_MAXINT,
+          0,
+          G_PARAM_READWRITE));
 
   g_object_class_install_property (object_class,
       PROP_ZOOM_LEVEL,
       g_param_spec_int ("zoom-level",
-        "zoom-level",
-        "The level of this zoom level",
-        G_MININT,
-        G_MAXINT,
-        0,
-        G_PARAM_READWRITE));
+          "zoom-level",
+          "The level of this zoom level",
+          G_MININT,
+          G_MAXINT,
+          0,
+          G_PARAM_READWRITE));
 
   g_object_class_install_property (object_class,
       PROP_ACTOR,
       g_param_spec_object ("actor",
-        "Actor",
-        "The actor containing all the tiles",
-        CLUTTER_TYPE_ACTOR,
-        G_PARAM_READABLE));
+          "Actor",
+          "The actor containing all the tiles",
+          CLUTTER_TYPE_ACTOR,
+          G_PARAM_READABLE));
 }
 
 static void
@@ -210,7 +210,7 @@ champlain_zoom_level_new (void)
 
 void
 champlain_zoom_level_add_tile (ChamplainZoomLevel *self,
-                               ChamplainTile *tile)
+    ChamplainTile *tile)
 {
   g_return_if_fail (CHAMPLAIN_ZOOM_LEVEL (self));
 
@@ -223,7 +223,7 @@ champlain_zoom_level_add_tile (ChamplainZoomLevel *self,
 
 void
 champlain_zoom_level_remove_tile (ChamplainZoomLevel *self,
-                                  ChamplainTile *tile)
+    ChamplainTile *tile)
 {
   g_return_if_fail (CHAMPLAIN_ZOOM_LEVEL (self));
 
@@ -246,7 +246,7 @@ champlain_zoom_level_tile_count (ChamplainZoomLevel *self)
 
 ChamplainTile *
 champlain_zoom_level_get_nth_tile (ChamplainZoomLevel *self,
-                                   guint index)
+    guint index)
 {
   g_return_val_if_fail (CHAMPLAIN_ZOOM_LEVEL (self), NULL);
 
@@ -288,7 +288,7 @@ champlain_zoom_level_get_zoom_level (ChamplainZoomLevel *self)
 
 void
 champlain_zoom_level_set_width (ChamplainZoomLevel *self,
-                                guint width)
+    guint width)
 {
   g_return_if_fail (CHAMPLAIN_ZOOM_LEVEL (self));
 
@@ -300,7 +300,7 @@ champlain_zoom_level_set_width (ChamplainZoomLevel *self,
 
 void
 champlain_zoom_level_set_height (ChamplainZoomLevel *self,
-                                 guint height)
+    guint height)
 {
   g_return_if_fail (CHAMPLAIN_ZOOM_LEVEL (self));
 
@@ -313,7 +313,7 @@ champlain_zoom_level_set_height (ChamplainZoomLevel *self,
 
 void
 champlain_zoom_level_set_zoom_level (ChamplainZoomLevel *self,
-                                     gint zoom_level)
+    gint zoom_level)
 {
   g_return_if_fail (CHAMPLAIN_ZOOM_LEVEL (self));
 
index b252b90b5ad789a9bd1e7285df25143f24556f25..02281585837be084c01826d85afb2b36312104af 100644 (file)
@@ -63,8 +63,10 @@ guint champlain_zoom_level_get_height (ChamplainZoomLevel *self);
 gint champlain_zoom_level_get_zoom_level (ChamplainZoomLevel *self);
 ClutterActor* champlain_zoom_level_get_actor (ChamplainZoomLevel *self);
 
-void champlain_zoom_level_set_width (ChamplainZoomLevel *self, guint width);
-void champlain_zoom_level_set_height (ChamplainZoomLevel *self, guint height);
+void champlain_zoom_level_set_width (ChamplainZoomLevel *self,
+    guint width);
+void champlain_zoom_level_set_height (ChamplainZoomLevel *self,
+    guint height);
 void champlain_zoom_level_set_zoom_level (ChamplainZoomLevel *self,
     gint zoom_level);