diff options
Diffstat (limited to 'champlain/champlain-file-tile-source.c')
-rw-r--r-- | champlain/champlain-file-tile-source.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/champlain/champlain-file-tile-source.c b/champlain/champlain-file-tile-source.c index b551ff7..db731d9 100644 --- a/champlain/champlain-file-tile-source.c +++ b/champlain/champlain-file-tile-source.c @@ -156,7 +156,7 @@ tile_rendered_cb (ChamplainTile *tile, { ChamplainTileSource *tile_source = CHAMPLAIN_TILE_SOURCE (map_source); ChamplainTileCache *tile_cache = champlain_tile_source_get_cache (tile_source); - + if (tile_cache && data->data) champlain_tile_cache_store_tile (tile_cache, tile, data->data, data->size); @@ -166,7 +166,7 @@ tile_rendered_cb (ChamplainTile *tile, } else if (next_source) champlain_map_source_fill_tile (next_source, tile); - + g_object_unref (map_source); g_object_unref (tile); } @@ -181,6 +181,9 @@ fill_tile (ChamplainMapSource *map_source, ChamplainMapSource *next_source = champlain_map_source_get_next_source (map_source); + if (champlain_tile_get_state (tile) == CHAMPLAIN_STATE_DONE) + return; + if (champlain_tile_get_state (tile) != CHAMPLAIN_STATE_LOADED) { ChamplainRenderer *renderer; |