GError *error = NULL;
gboolean ret=TRUE;
gfloat p=0;
+gchar *w="Starting";
switch (mis) {
case MAPPER_INIT_START:
route_init();
mis=MAPPER_INIT_CONFIG;
p=0.1;
+ w="Init";
break;
case MAPPER_INIT_CONFIG:
config_init();
map_download_init();
mis=MAPPER_INIT_GPS;
p=0.2;
+ w="Config";
break;
case MAPPER_INIT_GPS:
gps_init();
mis=MAPPER_INIT_DB;
p=0.3;
+ w="GPS";
break;
case MAPPER_INIT_DB:
if (db_connect(&_db, _mapper_db)) {
mis=MAPPER_INIT_VOICE;
}
p=0.5;
+ w="Database";
break;
case MAPPER_INIT_POI:
poi_init(&_db);
mis=MAPPER_INIT_OSM;
p=0.6;
+ w="POIs";
break;
case MAPPER_INIT_OSM:
osm_init(&_db);
mis=MAPPER_INIT_VOICE;
p=0.8;
+ w="OSM";
break;
case MAPPER_INIT_VOICE:
#if defined (WITH_GST) && defined (WITH_ESPEAK)
#endif
mis=MAPPER_INIT_MISC;
p=0.85;
+ w="Speech";
break;
case MAPPER_INIT_MISC:
/* Initialize D-Bus system connection. */
#endif
mis=MAPPER_INIT_UI;
p=0.9;
+ w="Misc";
break;
case MAPPER_INIT_UI:
mapper_ui_init();
mis=MAPPER_INIT_GOTO;
p=0.99;
+ w="UI";
break;
case MAPPER_INIT_GOTO:
if (map_goto_position(&_home)==FALSE)
map_center_unit(_center.unitx, _center.unity);
mis=MAPPER_INIT_DONE;
p=1.0;
+ w="Done";
break;
case MAPPER_INIT_DONE:
progress_dialog_remove(init_dialog);
break;
}
-#if 1
gtk_progress_bar_set_fraction(GTK_PROGRESS(init_progress), p);
-#else
-gtk_progress_bar_pulse(GTK_PROGRESS(init_progress));
-#endif
+gtk_progress_bar_set_text(GTK_PROGRESS(init_progress), w);
return ret;
}