Diff of /trunk/src/osm.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 9 by harbaum, Fri Dec 12 20:06:32 2008 UTC revision 28 by achadwick, Wed Dec 24 14:17:20 2008 UTC
# Line 31  Line 31 
31  #include <libxml/tree.h>  #include <libxml/tree.h>
32    
33  #include "appdata.h"  #include "appdata.h"
34    #include "banner.h"
35    
36  #ifndef LIBXML_TREE_ENABLED  #ifndef LIBXML_TREE_ENABLED
37  #error "Tree not enabled in libxml"  #error "Tree not enabled in libxml"
# Line 1310  static osm_t *process_osm(xmlTextReaderP Line 1311  static osm_t *process_osm(xmlTextReaderP
1311    g_assert(name);    g_assert(name);
1312    
1313    /* read next node */    /* read next node */
1314      int num_elems = 0;
1315      const int tick_every = 50; // Balance responsive appearance with performance.
1316    int ret = xmlTextReaderRead(reader);    int ret = xmlTextReaderRead(reader);
1317    while(ret == 1) {    while(ret == 1) {
1318    
# Line 1346  static osm_t *process_osm(xmlTextReaderP Line 1349  static osm_t *process_osm(xmlTextReaderP
1349        break;        break;
1350      }      }
1351      ret = xmlTextReaderRead(reader);      ret = xmlTextReaderRead(reader);
1352    
1353        if (num_elems++ > tick_every) {
1354          num_elems = 0;
1355          banner_busy_tick();
1356        }
1357    }    }
1358    
1359    g_assert(0);    g_assert(0);
# Line 2192  tag_t *osm_tags_copy(tag_t *src_tag, gbo Line 2200  tag_t *osm_tags_copy(tag_t *src_tag, gbo
2200    
2201    return new_tags;    return new_tags;
2202  }  }
2203    // vim:et:ts=8:sw=2:sts=2:ai

Legend:
Removed from v.9  
changed lines
  Added in v.28