You can subscribe to this list here.
2007 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(4) |
Aug
(59) |
Sep
(43) |
Oct
(95) |
Nov
(135) |
Dec
(108) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2008 |
Jan
(229) |
Feb
(141) |
Mar
(59) |
Apr
(70) |
May
(64) |
Jun
(87) |
Jul
(57) |
Aug
(108) |
Sep
(74) |
Oct
(203) |
Nov
(141) |
Dec
(108) |
2009 |
Jan
(114) |
Feb
(91) |
Mar
(101) |
Apr
(69) |
May
(54) |
Jun
(82) |
Jul
(49) |
Aug
(109) |
Sep
(81) |
Oct
(93) |
Nov
(100) |
Dec
(79) |
2010 |
Jan
(46) |
Feb
(36) |
Mar
(135) |
Apr
(103) |
May
(116) |
Jun
(130) |
Jul
(52) |
Aug
(31) |
Sep
(46) |
Oct
(48) |
Nov
(98) |
Dec
(110) |
2011 |
Jan
(234) |
Feb
(184) |
Mar
(150) |
Apr
(43) |
May
(53) |
Jun
(52) |
Jul
(112) |
Aug
(72) |
Sep
(79) |
Oct
(23) |
Nov
(6) |
Dec
(30) |
2012 |
Jan
(39) |
Feb
(37) |
Mar
(49) |
Apr
(60) |
May
(63) |
Jun
(38) |
Jul
(33) |
Aug
(24) |
Sep
(20) |
Oct
(14) |
Nov
(23) |
Dec
(50) |
2013 |
Jan
(30) |
Feb
(32) |
Mar
(27) |
Apr
(41) |
May
(59) |
Jun
(21) |
Jul
(10) |
Aug
(73) |
Sep
(23) |
Oct
(60) |
Nov
(14) |
Dec
(15) |
2014 |
Jan
(4) |
Feb
(8) |
Mar
(11) |
Apr
(6) |
May
(27) |
Jun
(4) |
Jul
(29) |
Aug
(62) |
Sep
(11) |
Oct
(17) |
Nov
(58) |
Dec
(9) |
2015 |
Jan
(23) |
Feb
(3) |
Mar
(26) |
Apr
(47) |
May
(8) |
Jun
(28) |
Jul
(10) |
Aug
(3) |
Sep
|
Oct
|
Nov
|
Dec
|
From: Martin S. <mar...@us...> - 2007-12-06 21:41:23
|
Update of /cvsroot/navit/navit/src/data/textfile In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv22879/data/textfile Modified Files: textfile.c Log Message: Changed map_selection data structure for more flexibility in viewport setup Index: textfile.c =================================================================== RCS file: /cvsroot/navit/navit/src/data/textfile/textfile.c,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** textfile.c 2 Dec 2007 16:29:01 -0000 1.8 --- textfile.c 6 Dec 2007 21:41:22 -0000 1.9 *************** *** 11,15 **** #include "item.h" #include "attr.h" - #include "coord.h" #include "transform.h" #include "file.h" --- 11,14 ---- |
From: Martin S. <mar...@us...> - 2007-12-06 21:41:23
|
Update of /cvsroot/navit/navit/src In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv22879 Modified Files: graphics.c map.h navit.c point.h route.c Log Message: Changed map_selection data structure for more flexibility in viewport setup Index: route.c =================================================================== RCS file: /cvsroot/navit/navit/src/route.c,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** route.c 24 Nov 2007 12:40:25 -0000 1.26 --- route.c 6 Dec 2007 21:41:21 -0000 1.27 *************** *** 298,314 **** if (dx < 0) { sx=-1; ! sel->rect.lu.x=c1->x; ! sel->rect.rl.x=c2->x; } else { ! sel->rect.lu.x=c2->x; ! sel->rect.rl.x=c1->x; } if (dy < 0) { sy=-1; ! sel->rect.lu.y=c2->y; ! sel->rect.rl.y=c1->y; } else { ! sel->rect.lu.y=c1->y; ! sel->rect.rl.y=c2->y; } if (dx*sx > dy*sy) --- 298,314 ---- if (dx < 0) { sx=-1; ! sel->u.c_rect.lu.x=c1->x; ! sel->u.c_rect.rl.x=c2->x; } else { ! sel->u.c_rect.lu.x=c2->x; ! sel->u.c_rect.rl.x=c1->x; } if (dy < 0) { sy=-1; ! sel->u.c_rect.lu.y=c2->y; ! sel->u.c_rect.rl.y=c1->y; } else { ! sel->u.c_rect.lu.y=c1->y; ! sel->u.c_rect.rl.y=c2->y; } if (dx*sx > dy*sy) *************** *** 317,324 **** d=dy*sy; m=d*rel/100+abs; ! sel->rect.lu.x-=m; ! sel->rect.rl.x+=m; ! sel->rect.lu.y+=m; ! sel->rect.rl.y-=m; sel->next=NULL; return sel; --- 317,324 ---- d=dy*sy; m=d*rel/100+abs; ! sel->u.c_rect.lu.x-=m; ! sel->u.c_rect.rl.x+=m; ! sel->u.c_rect.lu.y+=m; ! sel->u.c_rect.rl.y-=m; sel->next=NULL; return sel; Index: graphics.c =================================================================== RCS file: /cvsroot/navit/navit/src/graphics.c,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** graphics.c 22 Nov 2007 19:37:26 -0000 1.20 --- graphics.c 6 Dec 2007 21:41:21 -0000 1.21 *************** *** 465,469 **** pro=map_projection(m); conv=map_requires_conversion(m); ! transform_rect(t, pro, &sel->rect); if (route_selection) mr=map_rect_new(m, route_selection); --- 465,469 ---- pro=map_projection(m); conv=map_requires_conversion(m); ! transform_rect(t, pro, &sel->u.c_rect); if (route_selection) mr=map_rect_new(m, route_selection); Index: navit.c =================================================================== RCS file: /cvsroot/navit/navit/src/navit.c,v retrieving revision 1.44 retrieving revision 1.45 diff -C2 -d -r1.44 -r1.45 *** navit.c 5 Dec 2007 13:47:17 -0000 1.44 --- navit.c 6 Dec 2007 21:41:21 -0000 1.45 *************** *** 852,860 **** #endif center=transform_center(this_->trans); ! sel.rect.lu.x=center->x-dist; ! sel.rect.lu.y=center->y+dist; ! sel.rect.rl.x=center->x+dist; ! sel.rect.rl.y=center->y-dist; ! dbg(2,"0x%x,0x%x - 0x%x,0x%x\n", sel.rect.lu.x, sel.rect.lu.y, sel.rect.rl.x, sel.rect.rl.y); nwi->click=callback_new_2(callback_cast(navit_window_items_click), this_, nwi); nwi->win=gui_datawindow_new(this_->gui, nwi->name, nwi->click, NULL); --- 852,860 ---- #endif center=transform_center(this_->trans); ! sel.u.c_rect.lu.x=center->x-dist; ! sel.u.c_rect.lu.y=center->y+dist; ! sel.u.c_rect.rl.x=center->x+dist; ! sel.u.c_rect.rl.y=center->y-dist; ! dbg(2,"0x%x,0x%x - 0x%x,0x%x\n", sel.u.c_rect.lu.x, sel.u.c_rect.lu.y, sel.u.c_rect.rl.x, sel.u.c_rect.rl.y); nwi->click=callback_new_2(callback_cast(navit_window_items_click), this_, nwi); nwi->win=gui_datawindow_new(this_->gui, nwi->name, nwi->click, NULL); *************** *** 866,870 **** while ((item=map_rect_get_item(mr))) { if (item_coord_get(item, &c, 1)) { ! if (coord_rect_contains(&sel.rect, &c) && g_hash_table_lookup(nwi->hash, &item->type)) { if (! item_attr_get(item, attr_label, &attr)) attr.u.str=""; --- 866,870 ---- while ((item=map_rect_get_item(mr))) { if (item_coord_get(item, &c, 1)) { ! if (coord_rect_contains(&sel.u.c_rect, &c) && g_hash_table_lookup(nwi->hash, &item->type)) { if (! item_attr_get(item, attr_label, &attr)) attr.u.str=""; *************** *** 1300,1302 **** } ! /** @} */ \ No newline at end of file --- 1300,1302 ---- } ! /** @} */ Index: map.h =================================================================== RCS file: /cvsroot/navit/navit/src/map.h,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** map.h 22 Nov 2007 19:37:26 -0000 1.8 --- map.h 6 Dec 2007 21:41:21 -0000 1.9 *************** *** 5,13 **** struct attr; #include "coord.h" #include "layer.h" struct map_selection { struct map_selection *next; ! struct coord_rect rect; int order[layer_end]; }; --- 5,17 ---- struct attr; #include "coord.h" + #include "point.h" #include "layer.h" struct map_selection { struct map_selection *next; ! union { ! struct coord_rect c_rect; ! struct point_rect p_rect; ! } u; int order[layer_end]; }; Index: point.h =================================================================== RCS file: /cvsroot/navit/navit/src/point.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** point.h 9 Oct 2007 16:48:39 -0000 1.2 --- point.h 6 Dec 2007 21:41:21 -0000 1.3 *************** *** 7,9 **** --- 7,13 ---- }; + struct point_rect { + struct point lu; + struct point rl; + }; #endif |
From: Martin S. <mar...@us...> - 2007-12-06 21:41:23
|
Update of /cvsroot/navit/navit/src/data/mg In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv22879/data/mg Modified Files: block.c poly.c town.c Log Message: Changed map_selection data structure for more flexibility in viewport setup Index: block.c =================================================================== RCS file: /cvsroot/navit/navit/src/data/mg/block.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** block.c 6 Nov 2007 22:43:18 -0000 1.4 --- block.c 6 Dec 2007 21:41:22 -0000 1.5 *************** *** 132,136 **** mr->b.bt.block_count=0; } ! if (mr->cur_sel && !coord_rect_overlap(&mr->cur_sel->rect, &mr->b.b_rect)) return 0; return block_next(mr); --- 132,136 ---- mr->b.bt.block_count=0; } ! if (mr->cur_sel && !coord_rect_overlap(&mr->cur_sel->u.c_rect, &mr->b.b_rect)) return 0; return block_next(mr); *************** *** 161,165 **** return 0; } ! if (!mr->cur_sel || coord_rect_overlap(&mr->cur_sel->rect, &mr->b.b->r)) { block_active_count++; block_active_mem+=mr->b.b->blocks*512-sizeof(struct block *); --- 161,165 ---- return 0; } ! if (!mr->cur_sel || coord_rect_overlap(&mr->cur_sel->u.c_rect, &mr->b.b->r)) { block_active_count++; block_active_mem+=mr->b.b->blocks*512-sizeof(struct block *); *************** *** 224,228 **** if (blk_num != -1) { block_mem+=8; ! if (coord_rect_overlap(&mr->cur_sel->rect, &bt->r_curr)) { mr->b.b=block_get_byid(mr->file, blk_num, &mr->b.p); mr->b.block_num=blk_num; --- 224,228 ---- if (blk_num != -1) { block_mem+=8; ! if (coord_rect_overlap(&mr->cur_sel->u.c_rect, &bt->r_curr)) { mr->b.b=block_get_byid(mr->file, blk_num, &mr->b.p); mr->b.block_num=blk_num; Index: town.c =================================================================== RCS file: /cvsroot/navit/navit/src/data/mg/town.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** town.c 18 Sep 2007 14:48:12 -0000 1.4 --- town.c 6 Dec 2007 21:41:22 -0000 1.5 *************** *** 131,135 **** twn->aidx=0; twn->attr_next=attr_label; ! if (! mr->cur_sel || (twn->order <= limit[mr->cur_sel->order[layer_town]] && coord_rect_contains(&mr->cur_sel->rect,&twn->c))) { switch(twn->type) { case 1: --- 131,135 ---- twn->aidx=0; twn->attr_next=attr_label; ! if (! mr->cur_sel || (twn->order <= limit[mr->cur_sel->order[layer_town]] && coord_rect_contains(&mr->cur_sel->u.c_rect,&twn->c))) { switch(twn->type) { case 1: Index: poly.c =================================================================== RCS file: /cvsroot/navit/navit/src/data/mg/poly.c,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** poly.c 23 Nov 2007 13:03:10 -0000 1.8 --- poly.c 6 Dec 2007 21:41:22 -0000 1.9 *************** *** 113,117 **** r.lu=poly->c[0]; r.rl=poly->c[1]; ! if (mr->cur_sel && (poly->order > mr->cur_sel->order[layer_poly]*3 || !coord_rect_overlap(&mr->cur_sel->rect, &r))) { poly->subpoly_num_all+=poly->polys; mr->b.p=poly->poly_next; --- 113,117 ---- r.lu=poly->c[0]; r.rl=poly->c[1]; ! if (mr->cur_sel && (poly->order > mr->cur_sel->order[layer_poly]*3 || !coord_rect_overlap(&mr->cur_sel->u.c_rect, &r))) { poly->subpoly_num_all+=poly->polys; mr->b.p=poly->poly_next; |
From: KaZeR <ka...@us...> - 2007-12-05 13:47:17
|
Update of /cvsroot/navit/navit/src In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv12957 Modified Files: navit.c Log Message: Started doxygen documentation Index: navit.c =================================================================== RCS file: /cvsroot/navit/navit/src/navit.c,v retrieving revision 1.43 retrieving revision 1.44 diff -C2 -d -r1.43 -r1.44 *** navit.c 3 Dec 2007 18:51:03 -0000 1.43 --- navit.c 5 Dec 2007 13:47:17 -0000 1.44 *************** *** 34,37 **** --- 34,41 ---- #define _(STRING) gettext(STRING) + /** + * @defgroup navit the navit core instance + * @{ + */ struct navit_vehicle { *************** *** 247,250 **** --- 251,261 ---- } + /** + * Change the current zoom level, zooming closer to the ground + * + * @param navit The navit instance + * @param factor The zoom factor, usually 2 + * @returns nothing + */ void navit_zoom_in(struct navit *this_, int factor) *************** *** 257,260 **** --- 268,278 ---- } + /** + * Change the current zoom level + * + * @param navit The navit instance + * @param factor The zoom factor, usually 2 + * @returns nothing + */ void navit_zoom_out(struct navit *this_, int factor) *************** *** 481,484 **** --- 499,510 ---- } + /** + * Start the route computing to a given set of coordinates + * + * @param navit The navit instance + * @param c The coordinate to start routing to + * @param description A label which allows the user to later identify this destination in the former destinations selection + * @returns nothing + */ void navit_set_destination(struct navit *this_, struct pcoord *c, char *description) *************** *** 491,495 **** } ! void navit_add_bookmark(struct navit *this_, struct pcoord *c, char *description) --- 517,528 ---- } ! /** ! * Record the given set of coordinates as a bookmark ! * ! * @param navit The navit instance ! * @param c The coordinate to store ! * @param description A label which allows the user to later identify this bookmark ! * @returns nothing ! */ void navit_add_bookmark(struct navit *this_, struct pcoord *c, char *description) *************** *** 500,503 **** --- 533,540 ---- struct navit *global_navit; + + /** + * Deprecated + */ static void navit_debug(struct navit *this_) *************** *** 1020,1023 **** --- 1057,1066 ---- } + /** + * Toggle the tracking : automatic centering of the map on the main vehicle + * + * @param navit The navit instance + * @returns nothing + */ void navit_toggle_tracking(struct navit *this_) *************** *** 1026,1029 **** --- 1069,1078 ---- } + /** + * Toggle the north orientation : forces the map to be aimed at north + * + * @param navit The navit instance + * @returns nothing + */ void navit_toggle_orient_north(struct navit *this_) *************** *** 1032,1035 **** --- 1081,1091 ---- } + /** + * Toggle the cursor update : refresh the map each time the cursor has moved (instead of only when it reaches a border) + * + * @param navit The navit instance + * @returns nothing + */ + static void navit_cursor_update(struct navit *this_, struct cursor *cursor) *************** *** 1097,1100 **** --- 1153,1164 ---- } + /** + * Set the position of the vehicle + * + * @param navit The navit instance + * @param c The coordinate to set as position + * @returns nothing + */ + void navit_set_position(struct navit *this_, struct pcoord *c) *************** *** 1109,1112 **** --- 1173,1187 ---- } + /** + * Register a new vehicle + * + * @param navit The navit instance + * @param v The vehicle instance + * @param name Guess? :) + * @param c The color to use for the cursor, currently only used in GTK + * @param update Wether to refresh the map each time this vehicle position changes (instead of only when it reaches a border) + * @param follow Wether to center the map on this vehicle position + * @returns a vehicle instance + */ struct navit_vehicle * navit_add_vehicle(struct navit *this_, struct vehicle *v, const char *name, struct color *c, int update, int follow) *************** *** 1224,1225 **** --- 1299,1302 ---- navit_draw(nav); } + + /** @} */ \ No newline at end of file |
From: Martin S. <mar...@us...> - 2007-12-05 10:23:08
|
Update of /cvsroot/navit/navit In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv32017 Modified Files: configure.in Log Message: Add better diagnostics of configure failure Index: configure.in =================================================================== RCS file: /cvsroot/navit/navit/configure.in,v retrieving revision 1.59 retrieving revision 1.60 diff -C2 -d -r1.59 -r1.60 *** configure.in 5 Dec 2007 09:54:25 -0000 1.59 --- configure.in 5 Dec 2007 10:23:08 -0000 1.60 *************** *** 43,47 **** X_LIBS="-L$ac_x_libraries" ! PKG_CHECK_MODULES(NAVIT, [glib-2.0 gmodule-2.0]) AC_SUBST(NAVIT_CFLAGS) AC_SUBST(NAVIT_LIBS) --- 43,47 ---- X_LIBS="-L$ac_x_libraries" ! PKG_CHECK_MODULES(NAVIT, [glib-2.0 gmodule-2.0], [], AC_MSG_ERROR([glib-2.0 or gmodule-2.0 not found. Usually you need to install a package named glib2-devel or libglib2.0-dev])) AC_SUBST(NAVIT_CFLAGS) AC_SUBST(NAVIT_LIBS) *************** *** 415,419 **** echo "GTK gui : ENABLED" else ! echo "GTK gui : DISABLED : you are missing a dependency" fi # FIXME : maybe elaborate missing dependencies --- 415,419 ---- echo "GTK gui : ENABLED" else ! echo "GTK gui : DISABLED : you are missing a dependency. To fix this install a package named gtk2-devel or libgtk2.0-dev" fi # FIXME : maybe elaborate missing dependencies |
From: Martin S. <mar...@us...> - 2007-12-05 09:54:59
|
Update of /cvsroot/navit/navit In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv17944 Modified Files: autogen.sh Log Message: Changed order to get more useful output Index: autogen.sh =================================================================== RCS file: /cvsroot/navit/navit/autogen.sh,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** autogen.sh 5 Dec 2007 09:20:15 -0000 1.4 --- autogen.sh 5 Dec 2007 09:55:01 -0000 1.5 *************** *** 1,4 **** #!/bin/sh ! for pkg in pkg-config libtool autoreconf automake aclocal autopoint:gettext do if ! ${pkg%%:*} --version >/dev/null --- 1,4 ---- #!/bin/sh ! for pkg in pkg-config libtool automake aclocal autoreconf autopoint:gettext do if ! ${pkg%%:*} --version >/dev/null |
From: Martin S. <mar...@us...> - 2007-12-05 09:54:23
|
Update of /cvsroot/navit/navit In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv17894 Modified Files: configure.in Log Message: Improved various things Index: configure.in =================================================================== RCS file: /cvsroot/navit/navit/configure.in,v retrieving revision 1.58 retrieving revision 1.59 diff -C2 -d -r1.58 -r1.59 *** configure.in 2 Dec 2007 19:09:00 -0000 1.58 --- configure.in 5 Dec 2007 09:54:25 -0000 1.59 *************** *** 40,48 **** fi - AC_PATH_X - if test x"$have_x" != xyes; then - echo "Can not find X" - exit -1 - fi X_CFLAGS="-I$x_includes" X_LIBS="-L$ac_x_libraries" --- 40,43 ---- *************** *** 282,286 **** py_libdir="${py_prefix}/lib/python${py_ver}" PYTHON_CFLAGS="-I${py_prefix}/include/python${py_ver}" ! if test -f $py_libdir/config/Makefile ; then py_libs=`grep '^LIBS=' $py_libdir/config/Makefile | sed -e 's/^.*=//'` py_libc=`grep '^LIBC=' $py_libdir/config/Makefile | sed -e 's/^.*=//'` --- 277,281 ---- py_libdir="${py_prefix}/lib/python${py_ver}" PYTHON_CFLAGS="-I${py_prefix}/include/python${py_ver}" ! if test -f $py_libdir/config/Makefile -a -f $py_prefix/include/python${py_ver}/Python.h; then py_libs=`grep '^LIBS=' $py_libdir/config/Makefile | sed -e 's/^.*=//'` py_libc=`grep '^LIBC=' $py_libdir/config/Makefile | sed -e 's/^.*=//'` *************** *** 294,298 **** AC_MSG_RESULT($py_libdir) else ! AC_MSG_WARN([$py_libdir/config/Makefile missing, support for python disabled]) fi fi --- 289,293 ---- AC_MSG_RESULT($py_libdir) else ! AC_MSG_WARN([$py_libdir/config/Makefile or $py_prefix/include/python${py_ver}/Python.h missing, support for python disabled]) fi fi *************** *** 446,452 **** if test x"$gpsd" = xyes then ! echo "GPS support : ENABLED" else ! echo "GPS support : DISABLED" fi if test x"$speechd" = xyes --- 441,447 ---- if test x"$gpsd" = xyes then ! echo "GPSD support: ENABLED" else ! echo "GPSD support: DISABLED" fi if test x"$speechd" = xyes |
From: Martin S. <mar...@us...> - 2007-12-05 09:20:22
|
Update of /cvsroot/navit/navit In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv2969 Modified Files: autogen.sh Log Message: Check for more dependencies before running autoreconf Index: autogen.sh =================================================================== RCS file: /cvsroot/navit/navit/autogen.sh,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** autogen.sh 4 Dec 2007 22:08:45 -0000 1.3 --- autogen.sh 5 Dec 2007 09:20:15 -0000 1.4 *************** *** 1,14 **** #!/bin/sh ! if ! pkg-config --version >/dev/null ! then ! echo "You need to install pkg-config" ! exit 1 ! fi ! ! if ! libtool --version >/dev/null ! then ! echo "You need to install libtool" ! exit 1 ! fi autoreconf --force --install -I m4 --- 1,11 ---- #!/bin/sh ! for pkg in pkg-config libtool autoreconf automake aclocal autopoint:gettext ! do ! if ! ${pkg%%:*} --version >/dev/null ! then ! echo "You need to install ${pkg##*:}" ! exit 1 ! fi ! done autoreconf --force --install -I m4 |
From: Martin S. <mar...@us...> - 2007-12-04 22:08:44
|
Update of /cvsroot/navit/navit In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv27075 Modified Files: autogen.sh Log Message: Added checks for pkg-config and libtool to avoid failed autogens Index: autogen.sh =================================================================== RCS file: /cvsroot/navit/navit/autogen.sh,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** autogen.sh 18 Sep 2007 14:48:12 -0000 1.2 --- autogen.sh 4 Dec 2007 22:08:45 -0000 1.3 *************** *** 1,2 **** --- 1,14 ---- #!/bin/sh + if ! pkg-config --version >/dev/null + then + echo "You need to install pkg-config" + exit 1 + fi + + if ! libtool --version >/dev/null + then + echo "You need to install libtool" + exit 1 + fi + autoreconf --force --install -I m4 |
From: KaZeR <ka...@us...> - 2007-12-03 21:22:25
|
Update of /cvsroot/navit/navit/src/gui/sdl In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv31260/sdl Modified Files: gui_sdl_window.cpp sdl_events.cpp Log Message: - fixed a window displaying issue - some code cleanup Index: gui_sdl_window.cpp =================================================================== RCS file: /cvsroot/navit/navit/src/gui/sdl/gui_sdl_window.cpp,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** gui_sdl_window.cpp 3 Dec 2007 20:50:17 -0000 1.32 --- gui_sdl_window.cpp 3 Dec 2007 21:22:24 -0000 1.33 *************** *** 94,98 **** using namespace CEGUI; - extern Window* myRoot; struct navigation_list *list; --- 94,97 ---- *************** *** 153,157 **** using namespace CEGUI; - extern Window* myRoot; --- 152,155 ---- *************** *** 415,420 **** if(VIEW_MODE==VM_2D){ - dbg(1,"Switching to 2D view\n"); - // myRoot->getWindow("OSD/ViewMode")->setText("2D"); glMatrixMode( GL_PROJECTION ); glLoadIdentity(); --- 413,416 ---- *************** *** 425,430 **** glLoadIdentity(); } else { - dbg(1,"Switching to 3D view\n"); - // myRoot->getWindow("OSD/ViewMode")->setText("3D"); // Dimensions de la fenetre de rendu --- 421,424 ---- Index: sdl_events.cpp =================================================================== RCS file: /cvsroot/navit/navit/src/gui/sdl/sdl_events.cpp,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** sdl_events.cpp 3 Dec 2007 20:50:17 -0000 1.19 --- sdl_events.cpp 3 Dec 2007 21:22:24 -0000 1.20 *************** *** 406,415 **** { using namespace CEGUI; if(WindowManager::getSingleton().getWindow("DestinationChoose")->isVisible()){ WindowManager::getSingleton().getWindow("DestinationChoose")->hide(); } else { - WindowManager::getSingleton().getWindow("AdressSearchWindow")->hide(); - WindowManager::getSingleton().getWindow("BookmarkSelection")->hide(); - WindowManager::getSingleton().getWindow("FormerDestSelection")->hide(); WindowManager::getSingleton().getWindow("DestinationChoose")->show(); } --- 406,417 ---- { using namespace CEGUI; + + WindowManager::getSingleton().getWindow("AdressSearchWindow")->hide(); + WindowManager::getSingleton().getWindow("BookmarkSelection")->hide(); + WindowManager::getSingleton().getWindow("FormerDestSelection")->hide(); + if(WindowManager::getSingleton().getWindow("DestinationChoose")->isVisible()){ WindowManager::getSingleton().getWindow("DestinationChoose")->hide(); } else { WindowManager::getSingleton().getWindow("DestinationChoose")->show(); } *************** *** 441,444 **** --- 443,448 ---- { using namespace CEGUI; + WindowManager::getSingleton().getWindow("DestinationChoose")->hide(); + WindowManager::getSingleton().getWindow("AdressSearchWindow")->show(); *************** *** 459,501 **** const CEGUI::WindowEventArgs& we = static_cast<const CEGUI::WindowEventArgs&>(event); - if(WindowManager::getSingleton().getWindow("AdressSearchWindow")->isVisible()){ - WindowManager::getSingleton().getWindow("AdressSearchWindow")->hide(); - } else { - Window* town_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/TownEditbox")); - town_edit->setText(""); - Window* street_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")); - street_edit->setText(""); - town_edit->activate(); ! SDL_dest.current_search=SRCH_COUNTRY; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("AdressSearch/Listbox")); ! mcl->resetList(); ! ! ! // Code to get the current country and set it by default for the search ! struct attr search_attr, country_name, *country_attr; ! struct tracking *tracking; ! struct country_search *cs; ! struct item *item; - Editbox* country_edit = static_cast<Editbox*>(WindowManager::getSingleton().getWindow("AdressSearch/CountryEditbox")); ! country_attr=country_default(); ! tracking=navit_get_tracking(sdl_gui_navit); ! if (tracking && tracking_get_current_attr(tracking, attr_country_id, &search_attr)) ! country_attr=&search_attr; ! cs=country_search_new(country_attr, 0); ! item=country_search_get_item(cs); ! if (item && item_attr_get(item, attr_country_name, &country_name)){ ! country_edit->setText(country_name.u.str); ! handle_destination_change(); ! } ! country_search_destroy(cs); ! WindowManager::getSingleton().getWindow("AdressSearchWindow")->show(); ! SDL_dest.current_search=SRCH_TOWN; ! } return true; --- 463,500 ---- const CEGUI::WindowEventArgs& we = static_cast<const CEGUI::WindowEventArgs&>(event); ! Window* town_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/TownEditbox")); ! town_edit->setText(""); ! Window* street_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")); ! street_edit->setText(""); ! town_edit->activate(); + SDL_dest.current_search=SRCH_COUNTRY; + MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("AdressSearch/Listbox")); + mcl->resetList(); + + + // Code to get the current country and set it by default for the search + struct attr search_attr, country_name, *country_attr; + struct tracking *tracking; + struct country_search *cs; + struct item *item; ! Editbox* country_edit = static_cast<Editbox*>(WindowManager::getSingleton().getWindow("AdressSearch/CountryEditbox")); ! country_attr=country_default(); ! tracking=navit_get_tracking(sdl_gui_navit); ! if (tracking && tracking_get_current_attr(tracking, attr_country_id, &search_attr)) ! country_attr=&search_attr; ! cs=country_search_new(country_attr, 0); ! item=country_search_get_item(cs); ! if (item && item_attr_get(item, attr_country_name, &country_name)){ ! country_edit->setText(country_name.u.str); ! handle_destination_change(); ! } ! country_search_destroy(cs); + SDL_dest.current_search=SRCH_TOWN; return true; |
From: KaZeR <ka...@us...> - 2007-12-03 21:22:25
|
Update of /cvsroot/navit/navit/src/gui/sdl/datafiles/layouts In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv31260/sdl/datafiles/layouts Modified Files: TaharezLook.layout Log Message: - fixed a window displaying issue - some code cleanup Index: TaharezLook.layout =================================================================== RCS file: /cvsroot/navit/navit/src/gui/sdl/datafiles/layouts/TaharezLook.layout,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** TaharezLook.layout 3 Dec 2007 20:50:19 -0000 1.5 --- TaharezLook.layout 3 Dec 2007 21:22:24 -0000 1.6 *************** *** 40,45 **** <Window Type="TaharezLook/MultiColumnList" Name="Bookmarks/Listbox" > <Property Name="Font" Value="DejaVuSans-14" /> ! <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> ! <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.29,0},{0.945,0},{0.905842,0}}" /> </Window> </Window> --- 40,44 ---- <Window Type="TaharezLook/MultiColumnList" Name="Bookmarks/Listbox" > <Property Name="Font" Value="DejaVuSans-14" /> ! <Property Name="UnifiedAreaRect" Value="{{0.05,0},{0.15,0},{0.95,0},{0.9,0}}" /> </Window> </Window> *************** *** 53,58 **** <Window Type="TaharezLook/MultiColumnList" Name="FormerDests/Listbox" > <Property Name="Font" Value="DejaVuSans-14" /> ! <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> ! <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.29,0},{0.945,0},{0.905842,0}}" /> </Window> </Window> --- 52,56 ---- <Window Type="TaharezLook/MultiColumnList" Name="FormerDests/Listbox" > <Property Name="Font" Value="DejaVuSans-14" /> ! <Property Name="UnifiedAreaRect" Value="{{0.05,0},{0.15,0},{0.95,0},{0.9,0}}" /> </Window> </Window> |
From: KaZeR <ka...@us...> - 2007-12-03 20:50:18
|
Update of /cvsroot/navit/navit/src/gui/sdl In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv17184 Modified Files: gui_sdl.h gui_sdl_window.cpp sdl_events.cpp sdl_events.h Log Message: - Added Bookmark as destination support - Added former destinations support - some code cleanup Index: gui_sdl.h =================================================================== RCS file: /cvsroot/navit/navit/src/gui/sdl/gui_sdl.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** gui_sdl.h 5 Nov 2007 21:02:57 -0000 1.3 --- gui_sdl.h 3 Dec 2007 20:50:17 -0000 1.4 *************** *** 11,14 **** --- 11,18 ---- extern struct navit *sdl_gui_navit; + + bool BookmarkGo(const char * name); + bool FormerDestGo(const char * name); + struct gui_priv { /* Index: gui_sdl_window.cpp =================================================================== RCS file: /cvsroot/navit/navit/src/gui/sdl/gui_sdl_window.cpp,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** gui_sdl_window.cpp 25 Nov 2007 15:13:32 -0000 1.31 --- gui_sdl_window.cpp 3 Dec 2007 20:50:17 -0000 1.32 *************** *** 21,24 **** --- 21,25 ---- #include "attr.h" #include "track.h" + #include "menu.h" *************** *** 64,67 **** --- 65,81 ---- #define _(STRING) gettext(STRING) + + struct bookmark{ + char * name; + struct callback *cb; + struct bookmark *next; + } *bookmarks; + + struct former_dest{ + char * name; + struct callback *cb; + struct former_dest *next; + } *former_dests; + static int gui_sdl_set_graphics(struct gui_priv *this_, struct graphics *gra) *************** *** 75,95 **** } - - void drawCursor() { - dbg(1,"Pushing a cursor from GUI\n"); - int x=400; - int y=400; - float cursor_size=15.0f; - glColor4f(0.0f,0.0f,1.0f,0.75f); - glEnable(GL_BLEND); - glBegin(GL_TRIANGLES); - glVertex3f( x, y-cursor_size, 0.0f); - glVertex3f(x-cursor_size,y+cursor_size, 0.0f); - glVertex3f( x+cursor_size,y+cursor_size, 0.0f); - glEnd(); - glDisable(GL_BLEND); - } - - static void sdl_update_roadbook(struct navigation *nav) --- 89,92 ---- *************** *** 169,173 **** using namespace CEGUI; ! dbg(1,"Entering main loop\n"); bool must_quit = false; --- 166,170 ---- using namespace CEGUI; ! dbg(0,"Entering main loop\n"); bool must_quit = false; *************** *** 186,195 **** navit_draw(this_->nav); - GLuint cursorDL; - cursorDL=glGenLists(1); - glNewList(cursorDL,GL_COMPILE); - drawCursor(); - glEndList(); - bool enable_timer=0; --- 183,186 ---- *************** *** 235,246 **** show_road_name(); ! // graphics_get_data(this_->gra,DLid); ! ! #if 0 ! glCallList(*DLid); ! #endif navit_draw_displaylist(sdl_gui_navit); - // glCallList(cursorDL); inject_input(must_quit); if(enable_timer) --- 226,232 ---- show_road_name(); ! navit_draw_displaylist(sdl_gui_navit); inject_input(must_quit); if(enable_timer) *************** *** 283,287 **** --- 269,377 ---- } + static struct menu_priv * + add_menu(struct menu_priv *menu, struct menu_methods *meth, char *name, enum menu_type type, struct callback *cb); + + static struct menu_methods menu_methods = { + add_menu, + }; + + struct menu_priv { + char *path; + // GtkAction *action; + struct gui_priv *gui; + enum menu_type type; + struct callback *cb; + struct menu_priv *child; + struct menu_priv *sibling; + gulong handler_id; + guint merge_id; + }; + + #define MENU_BOOKMARK 2 + #define MENU_FORMER_DEST 3 + + static struct menu_priv * + add_menu(struct menu_priv *menu, struct menu_methods *meth, char *name, enum menu_type type, struct callback *cb) + { + using namespace CEGUI; + *meth=menu_methods; + dbg(0,"callback : %s\n",name); + + if(menu==(struct menu_priv *)(MENU_BOOKMARK)){ + dbg(0,"Item is a bookmark\n"); + MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("Bookmarks/Listbox")); + + ListboxTextItem* itemListbox = new ListboxTextItem((CEGUI::utf8*)(name)); + itemListbox->setSelectionBrushImage("TaharezLook", "MultiListSelectionBrush"); + mcl->addRow(itemListbox,0); + + struct bookmark *newB = g_new0(struct bookmark, 1); + newB->name=g_strdup(name); + newB->cb=cb; + if (newB) { + newB->next = bookmarks; + bookmarks = newB; + } + + } + + if(menu==(struct menu_priv *)(MENU_FORMER_DEST)){ + dbg(0,"Item is a former destination\n"); + MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("FormerDests/Listbox")); + + ListboxTextItem* itemListbox = new ListboxTextItem((CEGUI::utf8*)(name)); + itemListbox->setSelectionBrushImage("TaharezLook", "MultiListSelectionBrush"); + mcl->addRow(itemListbox,0); + + struct former_dest *newB = g_new0(struct former_dest, 1); + newB->name=g_strdup(name); + newB->cb=cb; + if (newB) { + newB->next = former_dests; + former_dests = newB; + } + + } + + if(!strcmp(name,"Bookmarks")){ + dbg(0,"Menu is the bookmark menu!\n"); + return (struct menu_priv *)MENU_BOOKMARK; + } else if(!strcmp(name,"Former Destinations")){ + dbg(0,"Menu is the Former Destinations menu!\n"); + return (struct menu_priv *)MENU_FORMER_DEST; + } else { + return (struct menu_priv *)1; + } + } + + bool BookmarkGo(const char * name) + { + dbg(0,"searching for bookmark %s\n",name); + bookmark * bookmark_search=bookmarks; + while ( bookmark_search ){ + dbg(0,"-> %s\n",bookmark_search->name); + if(!strcmp(bookmark_search->name,name)){ + dbg(0,"Got it :)\n"); + callback_call_0(bookmark_search->cb); + } + bookmark_search=bookmark_search->next; + } + + } + + bool FormerDestGo(const char * name) + { + dbg(0,"searching for former_dest %s\n",name); + former_dest * former_dest_search=former_dests; + while ( former_dest_search ){ + dbg(0,"-> %s\n",former_dest_search->name); + if(!strcmp(former_dest_search->name,name)){ + dbg(0,"Got it :)\n"); + callback_call_0(former_dest_search->cb); + } + former_dest_search=former_dest_search->next; + } + } static struct menu_priv * gui_sdl_toolbar_new(struct gui_priv *this_, struct menu_methods *meth) *************** *** 299,303 **** gui_sdl_menubar_new(struct gui_priv *this_, struct menu_methods *meth) { ! return NULL; //gui_gtk_ui_new(this_, meth, "/ui/MenuBar", nav, 0); } --- 389,394 ---- gui_sdl_menubar_new(struct gui_priv *this_, struct menu_methods *meth) { ! *meth=menu_methods; ! return (struct menu_priv *) 1; //gui_gtk_ui_new(this_, meth, "/ui/MenuBar", nav, 0); } *************** *** 529,555 **** // CEGUI::WindowManager::getSingleton().getWindow("ZoomOutButton")->setText(_("ZoomOut")); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/CountryEditbox")->subscribeEvent(Window::EventKeyUp, Event::Subscriber(DestinationEntryChange)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/CountryEditbox")->subscribeEvent(Window::EventMouseButtonDown, Event::Subscriber(handleMouseEnters)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/TownEditbox")->subscribeEvent(Window::EventKeyUp, Event::Subscriber(DestinationEntryChange)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/TownEditbox")->subscribeEvent(Window::EventMouseButtonDown, Event::Subscriber(handleMouseEnters)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/StreetEditbox")->subscribeEvent(Window::EventKeyUp, Event::Subscriber(DestinationEntryChange)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/StreetEditbox")->subscribeEvent(Window::EventMouseButtonDown, Event::Subscriber(handleMouseEnters)); - CEGUI::WindowManager::getSingleton().getWindow("DestinationButton")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(DialogWindowSwitch)); CEGUI::WindowManager::getSingleton().getWindow("OSD/ViewMode")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(ToggleView)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/GO")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(ButtonGo)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/KB")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(ShowKeyboard)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/Listbox")->subscribeEvent(MultiColumnList::EventSelectionChanged, Event::Subscriber(ItemSelect)); // Translation for StaticTexts (labels) ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/Country")->setText(_("Country")); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/Town")->setText(_("City")); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/Street")->setText(_("Street")); ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("DestinationWindow/Listbox")); mcl->setSelectionMode(MultiColumnList::RowSingle) ; --- 620,653 ---- // CEGUI::WindowManager::getSingleton().getWindow("ZoomOutButton")->setText(_("ZoomOut")); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/CountryEditbox")->subscribeEvent(Window::EventKeyUp, Event::Subscriber(DestinationEntryChange)); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/CountryEditbox")->subscribeEvent(Window::EventMouseButtonDown, Event::Subscriber(handleMouseEnters)); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/TownEditbox")->subscribeEvent(Window::EventKeyUp, Event::Subscriber(DestinationEntryChange)); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/TownEditbox")->subscribeEvent(Window::EventMouseButtonDown, Event::Subscriber(handleMouseEnters)); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")->subscribeEvent(Window::EventKeyUp, Event::Subscriber(DestinationEntryChange)); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")->subscribeEvent(Window::EventMouseButtonDown, Event::Subscriber(handleMouseEnters)); ! ! CEGUI::WindowManager::getSingleton().getWindow("DestinationButton")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(DestinationWindowSwitch)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/Address")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(AddressSearchSwitch)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/Bookmark")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(BookmarkSelectionSwitch)); ! CEGUI::WindowManager::getSingleton().getWindow("DestinationWindow/FormerDest")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(FormerDestSelectionSwitch)); CEGUI::WindowManager::getSingleton().getWindow("OSD/ViewMode")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(ToggleView)); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/GO")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(ButtonGo)); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/KB")->subscribeEvent(PushButton::EventClicked, Event::Subscriber(ShowKeyboard)); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/Listbox")->subscribeEvent(MultiColumnList::EventSelectionChanged, Event::Subscriber(ItemSelect)); ! CEGUI::WindowManager::getSingleton().getWindow("Bookmarks/Listbox")->subscribeEvent(MultiColumnList::EventSelectionChanged, Event::Subscriber(BookmarkSelect)); ! CEGUI::WindowManager::getSingleton().getWindow("FormerDests/Listbox")->subscribeEvent(MultiColumnList::EventSelectionChanged, Event::Subscriber(FormerDestSelect)); // Translation for StaticTexts (labels) ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/Country")->setText(_("Country")); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/Town")->setText(_("City")); ! CEGUI::WindowManager::getSingleton().getWindow("AdressSearch/Street")->setText(_("Street")); ! ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("AdressSearch/Listbox")); mcl->setSelectionMode(MultiColumnList::RowSingle) ; *************** *** 565,568 **** --- 663,676 ---- mcl2->addColumn("Instructions", 0, cegui_absdim(700.0)); + MultiColumnList* mcl3 = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("Bookmarks/Listbox")); + + mcl3->setSelectionMode(MultiColumnList::RowSingle) ; + mcl3->addColumn("Name", 0, cegui_absdim(700.0)); + + MultiColumnList* mcl4 = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("FormerDests/Listbox")); + + mcl4->setSelectionMode(MultiColumnList::RowSingle) ; + mcl4->addColumn("Name", 0, cegui_absdim(700.0)); + BuildKeyboard(); *************** *** 647,651 **** catch (CEGUI::Exception& e) { ! dbg(1,"Warning : you skin doesn't have the satellitebars. You should use Mineque's skin."); } --- 755,759 ---- catch (CEGUI::Exception& e) { ! dbg(1,"Warning : you skin doesn't have the satellitebars. You should use Mineque's skin.\n"); } Index: sdl_events.cpp =================================================================== RCS file: /cvsroot/navit/navit/src/gui/sdl/sdl_events.cpp,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** sdl_events.cpp 23 Nov 2007 17:34:57 -0000 1.18 --- sdl_events.cpp 3 Dec 2007 20:50:17 -0000 1.19 *************** *** 46,50 **** try { ! WindowManager::getSingleton().getWindow("DestinationWindow")->hide(); WindowManager::getSingleton().getWindow("Navit/Routing/Tips")->show(); --- 46,50 ---- try { ! WindowManager::getSingleton().getWindow("AdressSearchWindow")->hide(); WindowManager::getSingleton().getWindow("Navit/Routing/Tips")->show(); *************** *** 70,85 **** using namespace CEGUI; ! extern CEGUI::Window* myRoot; ! ! const CEGUI::WindowEventArgs& we = static_cast<const CEGUI::WindowEventArgs&>(event); String senderID = we.window->getName(); ! Window* editbox = myRoot->getChild("Navit/Keyboard")->getChild("Navit/Keyboard/Input"); String content=editbox->getText(); if(senderID=="OK"){ ! // dbg(1,"Validating : %s\n",content.c_str()); ! myRoot->getChild("Navit/Keyboard")->hide(); return 0; } else if(senderID=="BACK"){ --- 70,82 ---- using namespace CEGUI; ! const WindowEventArgs& we = static_cast<const CEGUI::WindowEventArgs&>(event); String senderID = we.window->getName(); ! Window* editbox = WindowManager::getSingleton().getWindow("Navit/Keyboard/Input"); String content=editbox->getText(); if(senderID=="OK"){ ! WindowManager::getSingleton().getWindow("Navit/Keyboard")->hide(); return 0; } else if(senderID=="BACK"){ *************** *** 91,97 **** } ! Window* country_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/CountryEditbox")); ! Window* town_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/TownEditbox")); ! Window* street_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/StreetEditbox")); switch (SDL_dest.current_search) { --- 88,94 ---- } ! Window* country_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/CountryEditbox")); ! Window* town_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/TownEditbox")); ! Window* street_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")); switch (SDL_dest.current_search) { *************** *** 112,118 **** { using namespace CEGUI; - extern CEGUI::Window* myRoot; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("DestinationWindow/Listbox")); ListboxItem * item = mcl->getItemAtGridReference(MCLGridRef(r,0)); --- 109,114 ---- { using namespace CEGUI; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("AdressSearch/Listbox")); ListboxItem * item = mcl->getItemAtGridReference(MCLGridRef(r,0)); *************** *** 121,127 **** ! Window* country_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/CountryEditbox")); ! Window* twn_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/TownEditbox")); ! Window* street_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/StreetEditbox")); if(SDL_dest.current_search==SRCH_COUNTRY){ --- 117,123 ---- ! Window* country_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/CountryEditbox")); ! Window* twn_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/TownEditbox")); ! Window* street_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")); if(SDL_dest.current_search==SRCH_COUNTRY){ *************** *** 129,133 **** twn_edit->activate(); SDL_dest.current_search=SRCH_TOWN; ! myRoot->getChild("Navit/Keyboard")->getChild("Navit/Keyboard/Input")->setText(""); } else if(SDL_dest.current_search==SRCH_TOWN){ --- 125,129 ---- twn_edit->activate(); SDL_dest.current_search=SRCH_TOWN; ! WindowManager::getSingleton().getWindow("Navit/Keyboard/Input")->setText(""); } else if(SDL_dest.current_search==SRCH_TOWN){ *************** *** 137,144 **** ListboxItem * itemy = mcl->getItemAtGridReference(MCLGridRef(r,4)); ! Window* Dest_x = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/Dest_x")); Dest_x->setText(itemx->getText().c_str()); ! Window* Dest_y = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/Dest_y")); Dest_y->setText(itemy->getText().c_str()); --- 133,140 ---- ListboxItem * itemy = mcl->getItemAtGridReference(MCLGridRef(r,4)); ! Window* Dest_x = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/Dest_x")); Dest_x->setText(itemx->getText().c_str()); ! Window* Dest_y = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/Dest_y")); Dest_y->setText(itemy->getText().c_str()); *************** *** 147,164 **** SDL_dest.current_search=SRCH_STREET; street_edit->activate(); ! myRoot->getChild("Navit/Keyboard")->getChild("Navit/Keyboard/Input")->setText(""); } else if(SDL_dest.current_search==SRCH_STREET){ street_edit->setText(item->getText()); ! myRoot->getChild("Navit/Keyboard")->hide(); ListboxItem * itemx = mcl->getItemAtGridReference(MCLGridRef(r,3)); ListboxItem * itemy = mcl->getItemAtGridReference(MCLGridRef(r,4)); ! Window* Dest_x = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/Dest_x")); Dest_x->setText(itemx->getText().c_str()); ! Window* Dest_y = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/Dest_y")); Dest_y->setText(itemy->getText().c_str()); --- 143,160 ---- SDL_dest.current_search=SRCH_STREET; street_edit->activate(); ! WindowManager::getSingleton().getWindow("Navit/Keyboard/Input")->setText(""); } else if(SDL_dest.current_search==SRCH_STREET){ street_edit->setText(item->getText()); ! WindowManager::getSingleton().getWindow("Navit/Keyboard")->hide(); ListboxItem * itemx = mcl->getItemAtGridReference(MCLGridRef(r,3)); ListboxItem * itemy = mcl->getItemAtGridReference(MCLGridRef(r,4)); ! Window* Dest_x = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/Dest_x")); Dest_x->setText(itemx->getText().c_str()); ! Window* Dest_y = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/Dest_y")); Dest_y->setText(itemy->getText().c_str()); *************** *** 167,171 **** SDL_dest.current_search=SRCH_STREET; ! myRoot->getChild("Navit/Keyboard")->getChild("Navit/Keyboard/Input")->setText(""); --- 163,167 ---- SDL_dest.current_search=SRCH_STREET; ! WindowManager::getSingleton().getWindow("Navit/Keyboard/Input")->setText(""); *************** *** 192,202 **** bool ItemSelect(const CEGUI::EventArgs& event) { using namespace CEGUI; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("DestinationWindow/Listbox")); ListboxItem * item = mcl->getFirstSelectedItem(); handleItemSelect(mcl->getItemRowIndex(item)); } bool handleMouseEnters(const CEGUI::EventArgs& event) { --- 188,228 ---- bool ItemSelect(const CEGUI::EventArgs& event) { + //FIXME maybe merge with handleItemSelect using namespace CEGUI; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("AdressSearch/Listbox")); ListboxItem * item = mcl->getFirstSelectedItem(); handleItemSelect(mcl->getItemRowIndex(item)); } + bool BookmarkSelect(const CEGUI::EventArgs& event) + { + using namespace CEGUI; + dbg(0,"1\n"); + MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("Bookmarks/Listbox")); + dbg(0,"2\n"); + ListboxItem * item = mcl->getFirstSelectedItem(); + if(item){ + dbg(0,"item %s is at row %i\n",item->getText().c_str(),mcl->getItemRowIndex(item)); + BookmarkGo(item->getText().c_str()); + } + WindowManager::getSingleton().getWindow("BookmarkSelection")->hide(); + } + + bool FormerDestSelect(const CEGUI::EventArgs& event) + { + using namespace CEGUI; + dbg(0,"1\n"); + MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("FormerDests/Listbox")); + dbg(0,"2\n"); + ListboxItem * item = mcl->getFirstSelectedItem(); + if(item){ + dbg(0,"item %s is at row %i\n",item->getText().c_str(),mcl->getItemRowIndex(item)); + FormerDestGo(item->getText().c_str()); + } + WindowManager::getSingleton().getWindow("FormerDestSelection")->hide(); + dbg(0,"hided\n"); + } + bool handleMouseEnters(const CEGUI::EventArgs& event) { *************** *** 206,234 **** // FIXME theses variables should be shared extern CEGUI::OpenGLRenderer* renderer; - extern CEGUI::Window* myRoot; using namespace CEGUI; ! myRoot->getChild("Navit/Keyboard")->getChild("Navit/Keyboard/Input")->setText(""); ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("DestinationWindow/Listbox")); String senderID = we.window->getName(); ! if (senderID == "DestinationWindow/CountryEditbox"){ // First, clean off the Street and Town Editbox ! extern Window* myRoot; ! Window* town_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/TownEditbox")); town_edit->setText(""); ! Window* street_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/StreetEditbox")); street_edit->setText(""); SDL_dest.current_search=SRCH_COUNTRY; ! } else if (senderID == "DestinationWindow/TownEditbox"){ // First, clean off the Street Editbox ! extern Window* myRoot; ! Window* street_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/StreetEditbox")); street_edit->setText(""); SDL_dest.current_search=SRCH_TOWN; ! } else if (senderID == "DestinationWindow/StreetEditbox"){ // First, make sure the user selected an entry in the town choice. If he hadn't, select the first for him. if(SDL_dest.current_search==SRCH_TOWN){ --- 232,257 ---- // FIXME theses variables should be shared extern CEGUI::OpenGLRenderer* renderer; using namespace CEGUI; ! WindowManager::getSingleton().getWindow("Navit/Keyboard/Input")->setText(""); ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("AdressSearch/Listbox")); String senderID = we.window->getName(); ! if (senderID == "AdressSearch/CountryEditbox"){ // First, clean off the Street and Town Editbox ! Window* town_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/TownEditbox")); town_edit->setText(""); ! Window* street_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")); street_edit->setText(""); SDL_dest.current_search=SRCH_COUNTRY; ! } else if (senderID == "AdressSearch/TownEditbox"){ // First, clean off the Street Editbox ! Window* street_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")); street_edit->setText(""); SDL_dest.current_search=SRCH_TOWN; ! } else if (senderID == "AdressSearch/StreetEditbox"){ // First, make sure the user selected an entry in the town choice. If he hadn't, select the first for him. if(SDL_dest.current_search==SRCH_TOWN){ *************** *** 247,277 **** using namespace CEGUI; - extern CEGUI::Window* myRoot; - /* - static struct search_param { - struct navit *nav; - struct mapset *ms; - struct search_list *sl; - struct attr attr; - } search_param; - */ struct search_param *search=&search_param; struct search_list_result *res; - /* - // dbg(1,"search->nav=sdl_gui_navit;\n"); - search->nav=sdl_gui_navit; - // dbg(1,"search->ms=navit_get_mapset(sdl_gui_navit);\n"); - search->ms=navit_get_mapset(sdl_gui_navit); - // dbg(1,"search->sl=search_list_new(search->ms);\n"); - search->sl=search_list_new(search->ms); - */ ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("DestinationWindow/Listbox")); if (SDL_dest.current_search==SRCH_COUNTRY) { ! Editbox* country_edit = static_cast<Editbox*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/CountryEditbox")); String content=country_edit->getText(); --- 270,283 ---- using namespace CEGUI; struct search_param *search=&search_param; struct search_list_result *res; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("AdressSearch/Listbox")); if (SDL_dest.current_search==SRCH_COUNTRY) { ! Editbox* country_edit = static_cast<Editbox*>(WindowManager::getSingleton().getWindow("AdressSearch/CountryEditbox")); String content=country_edit->getText(); *************** *** 295,299 **** { ! Editbox* town_edit = static_cast<Editbox*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/TownEditbox")); String content=town_edit->getText(); --- 301,305 ---- { ! Editbox* town_edit = static_cast<Editbox*>(WindowManager::getSingleton().getWindow("AdressSearch/TownEditbox")); String content=town_edit->getText(); *************** *** 342,346 **** } else if (SDL_dest.current_search==SRCH_STREET) { ! Editbox* street_edit = static_cast<Editbox*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/StreetEditbox")); String content=street_edit->getText(); --- 348,352 ---- } else if (SDL_dest.current_search==SRCH_STREET) { ! Editbox* street_edit = static_cast<Editbox*>(WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")); String content=street_edit->getText(); *************** *** 383,389 **** } ! ! // street_name_search(search->map_data, 33, SDL_dest.town_street_assoc, content.c_str(), 1, destination_street_add, search); ! } } --- 389,393 ---- } ! } } *************** *** 399,403 **** } ! bool DialogWindowSwitch(const CEGUI::EventArgs& event) { using namespace CEGUI; --- 403,442 ---- } ! bool DestinationWindowSwitch(const CEGUI::EventArgs& event) ! { ! using namespace CEGUI; ! if(WindowManager::getSingleton().getWindow("DestinationChoose")->isVisible()){ ! WindowManager::getSingleton().getWindow("DestinationChoose")->hide(); ! } else { ! WindowManager::getSingleton().getWindow("AdressSearchWindow")->hide(); ! WindowManager::getSingleton().getWindow("BookmarkSelection")->hide(); ! WindowManager::getSingleton().getWindow("FormerDestSelection")->hide(); ! WindowManager::getSingleton().getWindow("DestinationChoose")->show(); ! } ! } ! ! bool BookmarkSelectionSwitch(const CEGUI::EventArgs& event) ! { ! using namespace CEGUI; ! if(WindowManager::getSingleton().getWindow("BookmarkSelection")->isVisible()){ ! WindowManager::getSingleton().getWindow("BookmarkSelection")->hide(); ! } else { ! WindowManager::getSingleton().getWindow("DestinationChoose")->hide(); ! WindowManager::getSingleton().getWindow("BookmarkSelection")->show(); ! } ! } ! ! bool FormerDestSelectionSwitch(const CEGUI::EventArgs& event) ! { ! using namespace CEGUI; ! if(WindowManager::getSingleton().getWindow("FormerDestSelection")->isVisible()){ ! WindowManager::getSingleton().getWindow("FormerDestSelection")->hide(); ! } else { ! WindowManager::getSingleton().getWindow("DestinationChoose")->hide(); ! WindowManager::getSingleton().getWindow("FormerDestSelection")->show(); ! } ! } ! ! bool AddressSearchSwitch(const CEGUI::EventArgs& event) { using namespace CEGUI; *************** *** 419,435 **** - extern CEGUI::Window* myRoot; const CEGUI::WindowEventArgs& we = static_cast<const CEGUI::WindowEventArgs&>(event); ! if(we.window->getParent()->getChild("DestinationWindow")->isVisible()){ ! we.window->getParent()->getChild("DestinationWindow")->hide(); } else { ! Window* town_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/TownEditbox")); town_edit->setText(""); ! Window* street_edit = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/StreetEditbox")); street_edit->setText(""); town_edit->activate(); SDL_dest.current_search=SRCH_COUNTRY; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("DestinationWindow/Listbox")); mcl->resetList(); --- 458,473 ---- const CEGUI::WindowEventArgs& we = static_cast<const CEGUI::WindowEventArgs&>(event); ! if(WindowManager::getSingleton().getWindow("AdressSearchWindow")->isVisible()){ ! WindowManager::getSingleton().getWindow("AdressSearchWindow")->hide(); } else { ! Window* town_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/TownEditbox")); town_edit->setText(""); ! Window* street_edit = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/StreetEditbox")); street_edit->setText(""); town_edit->activate(); SDL_dest.current_search=SRCH_COUNTRY; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("AdressSearch/Listbox")); mcl->resetList(); *************** *** 442,446 **** ! Editbox* country_edit = static_cast<Editbox*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/CountryEditbox")); country_attr=country_default(); --- 480,484 ---- ! Editbox* country_edit = static_cast<Editbox*>(WindowManager::getSingleton().getWindow("AdressSearch/CountryEditbox")); country_attr=country_default(); *************** *** 456,460 **** country_search_destroy(cs); ! we.window->getParent()->getChild("DestinationWindow")->show(); } --- 494,499 ---- country_search_destroy(cs); ! WindowManager::getSingleton().getWindow("AdressSearchWindow")->show(); ! SDL_dest.current_search=SRCH_TOWN; } *************** *** 477,488 **** { using namespace CEGUI; - extern CEGUI::Window* myRoot; // const CEGUI::WindowEventArgs& we = static_cast<const CEGUI::WindowEventArgs&>(event); ! if(myRoot->getChild("Navit/RoadBook")->isVisible()){ ! myRoot->getChild("Navit/RoadBook")->hide(); WindowManager::getSingleton().getWindow("OSD/RoadbookButton")->show(); } else { ! myRoot->getChild("Navit/RoadBook")->show(); WindowManager::getSingleton().getWindow("OSD/RoadbookButton")->hide(); } --- 516,526 ---- { using namespace CEGUI; // const CEGUI::WindowEventArgs& we = static_cast<const CEGUI::WindowEventArgs&>(event); ! if(WindowManager::getSingleton().getWindow("Navit/RoadBook")->isVisible()){ ! WindowManager::getSingleton().getWindow("Navit/RoadBook")->hide(); WindowManager::getSingleton().getWindow("OSD/RoadbookButton")->show(); } else { ! WindowManager::getSingleton().getWindow("Navit/RoadBook")->show(); WindowManager::getSingleton().getWindow("OSD/RoadbookButton")->hide(); } *************** *** 493,499 **** { using namespace CEGUI; - extern CEGUI::Window* myRoot; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("DestinationWindow/Listbox")); // First, make sure the user selected an entry in the town choice. If he hadn't, select the first for him. if(SDL_dest.current_search==SRCH_TOWN){ --- 531,536 ---- { using namespace CEGUI; ! MultiColumnList* mcl = static_cast<MultiColumnList*>(WindowManager::getSingleton().getWindow("AdressSearch/Listbox")); // First, make sure the user selected an entry in the town choice. If he hadn't, select the first for him. if(SDL_dest.current_search==SRCH_TOWN){ *************** *** 505,510 **** ! Window* Dest_x = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/Dest_x")); ! Window* Dest_y = static_cast<Window*>(myRoot->getChild("DestinationWindow")->getChild("DestinationWindow/Dest_y")); extern struct navit *sdl_gui_navit; --- 542,547 ---- ! Window* Dest_x = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/Dest_x")); ! Window* Dest_y = static_cast<Window*>(WindowManager::getSingleton().getWindow("AdressSearch/Dest_y")); extern struct navit *sdl_gui_navit; Index: sdl_events.h =================================================================== RCS file: /cvsroot/navit/navit/src/gui/sdl/sdl_events.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** sdl_events.h 5 Nov 2007 21:02:57 -0000 1.6 --- sdl_events.h 3 Dec 2007 20:50:17 -0000 1.7 *************** *** 17,21 **** bool DestinationEntryChange(const CEGUI::EventArgs& event); ! bool DialogWindowSwitch(const CEGUI::EventArgs& event); bool Switch_to_nGhost(const CEGUI::EventArgs& event); bool RoadBookSwitch(const CEGUI::EventArgs& event); --- 17,26 ---- bool DestinationEntryChange(const CEGUI::EventArgs& event); ! bool DestinationWindowSwitch(const CEGUI::EventArgs& event); ! bool BookmarkSelectionSwitch(const CEGUI::EventArgs& event); ! bool BookmarkSelect(const CEGUI::EventArgs& event); ! bool FormerDestSelectionSwitch(const CEGUI::EventArgs& event); ! bool FormerDestSelect(const CEGUI::EventArgs& event); ! bool AddressSearchSwitch(const CEGUI::EventArgs& event); bool Switch_to_nGhost(const CEGUI::EventArgs& event); bool RoadBookSwitch(const CEGUI::EventArgs& event); |
From: KaZeR <ka...@us...> - 2007-12-03 20:50:17
|
Update of /cvsroot/navit/navit/src/gui/sdl/datafiles/layouts In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv17184/datafiles/layouts Modified Files: TaharezLook.layout Log Message: - Added Bookmark as destination support - Added former destinations support - some code cleanup Index: TaharezLook.layout =================================================================== RCS file: /cvsroot/navit/navit/src/gui/sdl/datafiles/layouts/TaharezLook.layout,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** TaharezLook.layout 5 Nov 2007 21:35:20 -0000 1.4 --- TaharezLook.layout 3 Dec 2007 20:50:19 -0000 1.5 *************** *** 6,10 **** <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0,0},{0,0},{1,0},{1,0}}" /> ! <Window Type="TaharezLook/FrameWindow" Name="DestinationWindow" > <Property Name="Text" Value="Choose your destination" /> <Property Name="Visible" Value="False" /> --- 6,62 ---- <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0,0},{0,0},{1,0},{1,0}}" /> ! ! <Window Type="TaharezLook/FrameWindow" Name="DestinationChoose" > ! <Property Name="Text" Value="Choose your destination" /> ! <Property Name="Visible" Value="False" /> ! <Property Name="Alpha" Value="0.7" /> ! <Property Name="TitlebarEnabled" Value="True" /> ! <Property Name="UnifiedAreaRect" Value="{{0.001,0},{0.1,0},{0.8,0},{0.4,0}}" /> ! <Window Type="TaharezLook/Button" Name="DestinationWindow/Address" > ! <Property Name="Text" Value="Search Address" /> ! <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> ! <Property Name="UnifiedAreaRect" Value="{{0.02,0},{0.2,0},{0.26,0},{0.8,0}}" /> ! </Window> ! <Window Type="TaharezLook/Button" Name="DestinationWindow/Bookmark" > ! <Property Name="Text" Value="Bookmark" /> ! <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> ! <Property Name="UnifiedAreaRect" Value="{{0.32,0},{0.2,0},{0.57,0},{0.8,0}}" /> ! </Window> ! <Window Type="TaharezLook/Button" Name="DestinationWindow/FormerDest" > ! <Property Name="Text" Value="FormerDest" /> ! <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> ! <Property Name="UnifiedAreaRect" Value="{{0.62,0},{0.2,0},{0.87,0},{0.8,0}}" /> ! </Window> ! ! </Window> ! ! ! <Window Type="TaharezLook/FrameWindow" Name="BookmarkSelection" > ! <Property Name="Text" Value="Choose your destination" /> ! <Property Name="Visible" Value="False" /> ! <Property Name="Alpha" Value="0.7" /> ! <Property Name="TitlebarEnabled" Value="True" /> ! <Property Name="UnifiedAreaRect" Value="{{0.001,0},{0.07,0},{0.8,0},{0.9,0}}" /> ! <Window Type="TaharezLook/MultiColumnList" Name="Bookmarks/Listbox" > ! <Property Name="Font" Value="DejaVuSans-14" /> ! <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> ! <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.29,0},{0.945,0},{0.905842,0}}" /> ! </Window> ! </Window> ! ! <Window Type="TaharezLook/FrameWindow" Name="FormerDestSelection" > ! <Property Name="Text" Value="Choose your destination" /> ! <Property Name="Visible" Value="False" /> ! <Property Name="Alpha" Value="0.7" /> ! <Property Name="TitlebarEnabled" Value="True" /> ! <Property Name="UnifiedAreaRect" Value="{{0.001,0},{0.07,0},{0.8,0},{0.9,0}}" /> ! <Window Type="TaharezLook/MultiColumnList" Name="FormerDests/Listbox" > ! <Property Name="Font" Value="DejaVuSans-14" /> ! <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> ! <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.29,0},{0.945,0},{0.905842,0}}" /> ! </Window> ! </Window> ! ! <Window Type="TaharezLook/FrameWindow" Name="AdressSearchWindow" > <Property Name="Text" Value="Choose your destination" /> <Property Name="Visible" Value="False" /> *************** *** 12,71 **** <Property Name="TitlebarEnabled" Value="True" /> <Property Name="UnifiedAreaRect" Value="{{0.001,0},{0.07,0},{0.8,0},{0.9,0}}" /> ! <Window Type="TaharezLook/StaticText" Name="DestinationWindow/Country" > <Property Name="Text" Value="Country :" /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.05,0},{0.271871,0},{0.1,0}}" /> </Window> ! <Window Type="TaharezLook/Editbox" Name="DestinationWindow/CountryEditbox" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.3,0},{0.05,0},{0.9,0},{0.1,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="DestinationWindow/Town" > <Property Name="Text" Value="Town : " /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.11,0},{0.275,0},{0.16,0}}" /> </Window> ! <Window Type="TaharezLook/Editbox" Name="DestinationWindow/TownEditbox" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.3,0},{0.11,0},{0.9,0},{0.16,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="DestinationWindow/Street" > <Property Name="Text" Value="Street : " /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.17,0},{0.275,0},{0.22,0}}" /> </Window> ! <Window Type="TaharezLook/Editbox" Name="DestinationWindow/StreetEditbox" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.3,0},{0.17,0},{0.9,0},{0.22,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="DestinationWindow/Label1" > <Property Name="Text" Value="Pick your choice :" /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.23,0},{0.9,0},{0.28,0}}" /> </Window> ! <Window Type="TaharezLook/MultiColumnList" Name="DestinationWindow/Listbox" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.29,0},{0.945,0},{0.905842,0}}" /> </Window> ! <Window Type="TaharezLook/Button" Name="DestinationWindow/KB" > <Property Name="Text" Value="Keyboard" /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.54,0},{0.92,0},{0.70,0},{0.98,0}}" /> </Window> ! <Window Type="TaharezLook/Button" Name="DestinationWindow/GO" > <Property Name="Text" Value="Go!" /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.72,0},{0.92,0},{0.97,0},{0.98,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="DestinationWindow/Dest_x" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.92,0},{0.12,0},{0.98,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="DestinationWindow/Dest_y" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.12,0},{0.92,0},{0.23,0},{0.98,0}}" /> </Window> - </Window> <Window Type="TaharezLook/StaticText" Name="Navit/Routing/Tips" > <Property Name="Font" Value="DejaVuSans-14" /> --- 64,124 ---- <Property Name="TitlebarEnabled" Value="True" /> <Property Name="UnifiedAreaRect" Value="{{0.001,0},{0.07,0},{0.8,0},{0.9,0}}" /> ! <Window Type="TaharezLook/StaticText" Name="AdressSearch/Country" > <Property Name="Text" Value="Country :" /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.05,0},{0.271871,0},{0.1,0}}" /> </Window> ! <Window Type="TaharezLook/Editbox" Name="AdressSearch/CountryEditbox" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.3,0},{0.05,0},{0.9,0},{0.1,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="AdressSearch/Town" > <Property Name="Text" Value="Town : " /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.11,0},{0.275,0},{0.16,0}}" /> </Window> ! <Window Type="TaharezLook/Editbox" Name="AdressSearch/TownEditbox" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.3,0},{0.11,0},{0.9,0},{0.16,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="AdressSearch/Street" > <Property Name="Text" Value="Street : " /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.17,0},{0.275,0},{0.22,0}}" /> </Window> ! <Window Type="TaharezLook/Editbox" Name="AdressSearch/StreetEditbox" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.3,0},{0.17,0},{0.9,0},{0.22,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="AdressSearch/Label1" > <Property Name="Text" Value="Pick your choice :" /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.23,0},{0.9,0},{0.28,0}}" /> </Window> ! <Window Type="TaharezLook/MultiColumnList" Name="AdressSearch/Listbox" > ! <Property Name="Font" Value="DejaVuSans-14" /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.29,0},{0.945,0},{0.905842,0}}" /> </Window> ! <Window Type="TaharezLook/Button" Name="AdressSearch/KB" > <Property Name="Text" Value="Keyboard" /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.54,0},{0.92,0},{0.70,0},{0.98,0}}" /> </Window> ! <Window Type="TaharezLook/Button" Name="AdressSearch/GO" > <Property Name="Text" Value="Go!" /> <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.72,0},{0.92,0},{0.97,0},{0.98,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="AdressSearch/Dest_x" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.01,0},{0.92,0},{0.12,0},{0.98,0}}" /> </Window> ! <Window Type="TaharezLook/StaticText" Name="AdressSearch/Dest_y" > <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" /> <Property Name="UnifiedAreaRect" Value="{{0.12,0},{0.92,0},{0.23,0},{0.98,0}}" /> </Window> </Window> + <Window Type="TaharezLook/StaticText" Name="Navit/Routing/Tips" > <Property Name="Font" Value="DejaVuSans-14" /> |
From: Martin S. <mar...@us...> - 2007-12-03 18:51:05
|
Update of /cvsroot/navit/navit/src In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv18742 Modified Files: navit.c Log Message: Bugfix for crash when using bookmark as destination Index: navit.c =================================================================== RCS file: /cvsroot/navit/navit/src/navit.c,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -d -r1.42 -r1.43 *** navit.c 3 Dec 2007 13:17:19 -0000 1.42 --- navit.c 3 Dec 2007 18:51:03 -0000 1.43 *************** *** 470,482 **** static void ! navit_set_destination_from_destination(struct navit *this_, int offset) { ! navit_set_destination_from_file(this_, "destination.txt", 0, offset); } static void ! navit_set_destination_from_bookmark(struct menu *menu, void *this_p, void *offset_p) { ! navit_set_destination_from_file((struct navit *)this_p, "bookmark.txt", 1, (int)offset_p); } --- 470,482 ---- static void ! navit_set_destination_from_destination(struct navit *this_, void *offset_p) { ! navit_set_destination_from_file(this_, "destination.txt", 0, (int)offset_p); } static void ! navit_set_destination_from_bookmark(struct navit *this_, void *offset_p) { ! navit_set_destination_from_file(this_, "bookmark.txt", 1, (int)offset_p); } |
From: KaZeR <ka...@us...> - 2007-12-03 18:19:01
|
Update of /cvsroot/navit/navit/src In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv4903 Modified Files: menu.c Log Message: Added a check for set and get toggles before actually calling them Index: menu.c =================================================================== RCS file: /cvsroot/navit/navit/src/menu.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** menu.c 3 Dec 2007 13:17:19 -0000 1.4 --- menu.c 3 Dec 2007 18:18:54 -0000 1.5 *************** *** 1,4 **** --- 1,5 ---- #include <glib.h> #include "menu.h" + #include "debug.h" void *************** *** 43,47 **** menu_set_toggle(struct menu *menu, int active) { ! (*menu->meth.set_toggle)(menu->priv, active); } --- 44,50 ---- menu_set_toggle(struct menu *menu, int active) { ! if(*menu->meth.set_toggle){ ! (*menu->meth.set_toggle)(menu->priv, active); ! } } *************** *** 49,52 **** menu_get_toggle(struct menu *menu) { ! return (*menu->meth.get_toggle)(menu->priv); } --- 52,55 ---- menu_get_toggle(struct menu *menu) { ! return ((*menu->meth.get_toggle) && (*menu->meth.get_toggle)(menu->priv)); } |
From: Martin S. <mar...@us...> - 2007-12-03 13:17:18
|
Update of /cvsroot/navit/navit/src In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv19270 Modified Files: callback.c callback.h menu.c menu.h navit.c popup.c Log Message: Converted menu callbacks to new callback api Index: callback.c =================================================================== RCS file: /cvsroot/navit/navit/src/callback.c,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** callback.c 22 Jul 2007 18:04:30 -0000 1.6 --- callback.c 3 Dec 2007 13:17:19 -0000 1.7 *************** *** 38,41 **** --- 38,49 ---- void + callback_set_arg(struct callback *cb, int arg, void *p) + { + if (arg < 0 || arg > cb->pcount) + return; + cb->p[arg]=p; + } + + void callback_list_add(struct callback_list *l, struct callback *cb) { Index: callback.h =================================================================== RCS file: /cvsroot/navit/navit/src/callback.h,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** callback.h 9 Oct 2007 16:44:03 -0000 1.9 --- callback.h 3 Dec 2007 13:17:19 -0000 1.10 *************** *** 10,13 **** --- 10,14 ---- struct callback_list *callback_list_new(void); struct callback *callback_new(void (*func)(void), int pcount, void **p); + void callback_set_arg(struct callback *cb, int arg, void *p); void callback_list_add(struct callback_list *l, struct callback *cb); struct callback *callback_list_add_new(struct callback_list *l, void (*func)(void), int pcount, void **p); *************** *** 39,42 **** --- 40,52 ---- } + static inline struct callback *callback_new_3(void (*func)(void), void *p1, void *p2, void *p3) + { + void *p[3]; + p[0]=p1; + p[1]=p2; + p[2]=p3; + return callback_new(func, 3, p); + } + static inline void callback_call_0(struct callback *cb) { Index: popup.c =================================================================== RCS file: /cvsroot/navit/navit/src/popup.c,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** popup.c 25 Nov 2007 01:32:14 -0000 1.17 --- popup.c 3 Dec 2007 13:17:19 -0000 1.18 *************** *** 17,20 **** --- 17,21 ---- #include "graphics.h" #include "item.h" + #include "callback.h" #include "route.h" *************** *** 41,48 **** static void ! popup_set_destination(struct menu *menu, void *data1, void *data2) { - struct navit *nav=data1; - struct pcoord *pc=data2; struct coord c; struct coord_geo g; --- 42,47 ---- static void ! popup_set_destination(struct navit *nav, struct pcoord *pc) { struct coord c; struct coord_geo g; *************** *** 58,65 **** static void ! popup_set_bookmark(struct menu *menu, void *data1, void *data2) { - struct navit *nav=data1; - struct pcoord *pc=data2; struct coord c; struct coord_geo g; --- 57,62 ---- static void ! popup_set_bookmark(struct navit *nav, struct pcoord *pc) { struct coord c; struct coord_geo g; *************** *** 79,88 **** static void ! popup_set_position(struct menu *menu, void *data1, void *data2) { ! struct navit *nav=data1; ! struct pcoord *c=data2; ! dbg(0,"%p %p\n", nav, c); ! navit_set_position(nav, c); } --- 76,83 ---- static void ! popup_set_position(struct navit *nav, struct pcoord *pc) { ! dbg(0,"%p %p\n", nav, pc); ! navit_set_position(nav, pc); } *************** *** 105,112 **** ! #define popup_printf(menu, type, fmt...) popup_printf_cb(menu, type, NULL, NULL, NULL, fmt) static void * ! popup_printf_cb(void *menu, enum menu_type type, void (*callback)(struct menu *menu, void *data1, void *data2), void *data1, void *data2, const char *fmt, ...) { gchar *str; --- 100,107 ---- ! #define popup_printf(menu, type, fmt...) popup_printf_cb(menu, type, NULL, fmt) static void * ! popup_printf_cb(void *menu, enum menu_type type, struct callback *cb, const char *fmt, ...) { gchar *str; *************** *** 117,121 **** str=g_strdup_vprintf(fmt, ap); dbg(0,"%s\n", str); ! ret=menu_add(menu, str, type, callback, data1, data2); va_end(ap); g_free(str); --- 112,116 ---- str=g_strdup_vprintf(fmt, ap); dbg(0,"%s\n", str); ! ret=menu_add(menu, str, type, cb); va_end(ap); g_free(str); *************** *** 240,246 **** c.x = co.x; c.y = co.y; ! popup_printf_cb(men, menu_type_menu, popup_set_position, nav, &c, "Set as position"); ! popup_printf_cb(men, menu_type_menu, popup_set_destination, nav, &c, "Set as destination"); ! popup_printf_cb(men, menu_type_menu, popup_set_bookmark, nav, &c, "Add as bookmark"); popup_display(nav, popup, p); } --- 235,241 ---- c.x = co.x; c.y = co.y; ! popup_printf_cb(men, menu_type_menu, callback_new_2(callback_cast(popup_set_position), nav, &c), "Set as position"); ! popup_printf_cb(men, menu_type_menu, callback_new_2(callback_cast(popup_set_destination), nav, &c), "Set as destination"); ! popup_printf_cb(men, menu_type_menu, callback_new_2(callback_cast(popup_set_bookmark), nav, &c), "Add as bookmark"); popup_display(nav, popup, p); } Index: menu.h =================================================================== RCS file: /cvsroot/navit/navit/src/menu.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** menu.h 9 Oct 2007 16:48:37 -0000 1.3 --- menu.h 3 Dec 2007 13:17:19 -0000 1.4 *************** *** 11,15 **** struct menu_methods { ! struct menu_priv *(*add)(struct menu_priv *menu, struct menu_methods *meth, char *name, enum menu_type type, void (*callback)(struct menu *data_menu, void *data1, void *data2), struct menu *data_menu, void *data1, void *data2); void (*set_toggle)(struct menu_priv *menu, int active); int (*get_toggle)(struct menu_priv *menu); --- 11,15 ---- struct menu_methods { ! struct menu_priv *(*add)(struct menu_priv *menu, struct menu_methods *meth, char *name, enum menu_type type, struct callback *cb); void (*set_toggle)(struct menu_priv *menu, int active); int (*get_toggle)(struct menu_priv *menu); *************** *** 22,33 **** /* prototypes */ struct container; struct menu; void menu_route_do_update(struct container *co); void menu_route_update(struct container *co); ! struct menu *menu_add(struct menu *menu, char *name, enum menu_type type, void (*callback)(struct menu *menu, void *data1, void *data2), void *data1, void *data2); void menu_set_toggle(struct menu *menu, int active); int menu_get_toggle(struct menu *menu); ! #endif - --- 22,34 ---- /* prototypes */ + enum menu_type; + struct callback; struct container; struct menu; void menu_route_do_update(struct container *co); void menu_route_update(struct container *co); ! struct menu *menu_add(struct menu *menu, char *name, enum menu_type type, struct callback *cb); void menu_set_toggle(struct menu *menu, int active); int menu_get_toggle(struct menu *menu); ! /* end of prototypes */ #endif Index: menu.c =================================================================== RCS file: /cvsroot/navit/navit/src/menu.c,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** menu.c 4 Jul 2007 22:44:27 -0000 1.3 --- menu.c 3 Dec 2007 13:17:19 -0000 1.4 *************** *** 27,35 **** struct menu * ! menu_add(struct menu *menu, char *name, enum menu_type type, void (*callback)(struct menu *menu, void *data1, void *data2), void *data1, void *data2) { struct menu *this; this=g_new0(struct menu, 1); ! this->priv=(*menu->meth.add)(menu->priv, &this->meth, name, type, callback, this, data1, data2); if (! this->priv) { g_free(this); --- 27,35 ---- struct menu * ! menu_add(struct menu *menu, char *name, enum menu_type type, struct callback *cb) { struct menu *this; this=g_new0(struct menu, 1); ! this->priv=(*menu->meth.add)(menu->priv, &this->meth, name, type, cb); if (! this->priv) { g_free(this); Index: navit.c =================================================================== RCS file: /cvsroot/navit/navit/src/navit.c,v retrieving revision 1.41 retrieving revision 1.42 diff -C2 -d -r1.41 -r1.42 *** navit.c 25 Nov 2007 01:32:14 -0000 1.41 --- navit.c 3 Dec 2007 13:17:19 -0000 1.42 *************** *** 326,342 **** static void ! navit_map_toggle(struct menu *menu, void *this__p, void *map_p) { ! if ((menu_get_toggle(menu) != 0) != (map_get_active(map_p) != 0)) { ! map_set_active(map_p, (menu_get_toggle(menu) != 0)); ! navit_draw(this__p); } } static void ! navit_projection_set(struct menu *menu, void *this__p, void *pro_p) { - struct navit *this_=this__p; - enum projection pro=(enum projection) pro_p; struct coord_geo g; struct coord *c; --- 326,340 ---- static void ! navit_map_toggle(struct menu *menu, struct navit *this_, struct map *map) { ! if ((menu_get_toggle(menu) != 0) != (map_get_active(map) != 0)) { ! map_set_active(map, (menu_get_toggle(menu) != 0)); ! navit_draw(this_); } } static void ! navit_projection_set(struct navit *this_, enum projection pro) { struct coord_geo g; struct coord *c; *************** *** 350,354 **** static void ! navit_add_menu_destinations(struct navit *this_, char *name, int offset, struct menu *rmen, GHashTable *h, void (*callback)(struct menu *menu, void *data1, void *data2)) { char buffer2[2048]; --- 348,352 ---- static void ! navit_add_menu_destinations(struct navit *this_, char *name, struct menu *rmen, GHashTable *h, struct callback *cb) { char buffer2[2048]; *************** *** 364,368 **** buffer2[i-name]='\0'; if (!(nmen=g_hash_table_lookup(h, buffer2))) { ! nmen=menu_add(men, buffer2+(n-name), menu_type_submenu, NULL, NULL, NULL); g_hash_table_insert(h, g_strdup(buffer2), nmen); } --- 362,366 ---- buffer2[i-name]='\0'; if (!(nmen=g_hash_table_lookup(h, buffer2))) { ! nmen=menu_add(men, buffer2+(n-name), menu_type_submenu, NULL); g_hash_table_insert(h, g_strdup(buffer2), nmen); } *************** *** 370,374 **** men=nmen; } ! menu_add(men, n, menu_type_menu, callback, this_, (void *)offset); } } --- 368,372 ---- men=nmen; } ! menu_add(men, n, menu_type_menu, cb); } } *************** *** 387,391 **** } static void ! navit_append_coord(struct navit *this_, char *file, struct pcoord *c, char *type, char *description, struct menu *rmen, GHashTable *h, void (*callback)(struct menu *menu, void *data1, void *data2)) { FILE *f; --- 385,389 ---- } static void ! navit_append_coord(struct navit *this_, char *file, struct pcoord *c, char *type, char *description, struct menu *rmen, GHashTable *h, void (*cb_func)(void)) { FILE *f; *************** *** 393,396 **** --- 391,395 ---- char *buffer; const char *prostr; + struct callback *cb; f=fopen(file, "a"); *************** *** 407,411 **** if (c) { buffer=g_strdup(description); ! navit_add_menu_destinations(this_, buffer, offset, rmen, h, callback); g_free(buffer); } --- 406,411 ---- if (c) { buffer=g_strdup(description); ! cb=callback_new_2(cb_func, this_, (void *)offset); ! navit_add_menu_destinations(this_, buffer, rmen, h, cb); g_free(buffer); } *************** *** 470,476 **** static void ! navit_set_destination_from_destination(struct menu *menu, void *this_p, void *offset_p) { ! navit_set_destination_from_file((struct navit *)this_p, "destination.txt", 0, (int)offset_p); } --- 470,476 ---- static void ! navit_set_destination_from_destination(struct navit *this_, int offset) { ! navit_set_destination_from_file(this_, "destination.txt", 0, offset); } *************** *** 484,488 **** navit_set_destination(struct navit *this_, struct pcoord *c, char *description) { ! navit_append_coord(this_, "destination.txt", c, "former_destination", description, this_->destinations, NULL, navit_set_destination_from_destination); if (this_->route) { route_set_destination(this_->route, c); --- 484,488 ---- navit_set_destination(struct navit *this_, struct pcoord *c, char *description) { ! navit_append_coord(this_, "destination.txt", c, "former_destination", description, this_->destinations, NULL, callback_cast(navit_set_destination_from_destination)); if (this_->route) { route_set_destination(this_->route, c); *************** *** 495,499 **** navit_add_bookmark(struct navit *this_, struct pcoord *c, char *description) { ! navit_append_coord(this_,"bookmark.txt", c, "bookmark", description, this_->bookmarks, this_->bookmarks_hash, navit_set_destination_from_bookmark); } --- 495,499 ---- navit_add_bookmark(struct navit *this_, struct pcoord *c, char *description) { ! navit_append_coord(this_,"bookmark.txt", c, "bookmark", description, this_->bookmarks, this_->bookmarks_hash, callback_cast(navit_set_destination_from_bookmark)); } *************** *** 540,544 **** navit_add_menu_layouts(struct navit *this_, struct menu *men) { ! menu_add(men, "Test", menu_type_menu, NULL, NULL, NULL); } --- 540,544 ---- navit_add_menu_layouts(struct navit *this_, struct menu *men) { ! menu_add(men, "Test", menu_type_menu, NULL); } *************** *** 546,550 **** navit_add_menu_layout(struct navit *this_, struct menu *men) { ! navit_add_menu_layouts(this_, menu_add(men, _("Layout"), menu_type_submenu, NULL, NULL, NULL)); } --- 546,550 ---- navit_add_menu_layout(struct navit *this_, struct menu *men) { ! navit_add_menu_layouts(this_, menu_add(men, _("Layout"), menu_type_submenu, NULL)); } *************** *** 552,557 **** navit_add_menu_projections(struct navit *this_, struct menu *men) { ! menu_add(men, "M&G", menu_type_menu, navit_projection_set, this_, (void *)projection_mg); ! menu_add(men, "Garmin", menu_type_menu, navit_projection_set, this_, (void *)projection_garmin); } --- 552,560 ---- navit_add_menu_projections(struct navit *this_, struct menu *men) { ! struct callback *cb; ! cb=callback_new_2(callback_cast(navit_projection_set), this_, (void *)projection_mg); ! menu_add(men, "M&G", menu_type_menu, cb); ! cb=callback_new_2(callback_cast(navit_projection_set), this_, (void *)projection_garmin); ! menu_add(men, "Garmin", menu_type_menu, cb); } *************** *** 559,563 **** navit_add_menu_projection(struct navit *this_, struct menu *men) { ! navit_add_menu_projections(this_, menu_add(men, _("Projection"), menu_type_submenu, NULL, NULL, NULL)); } --- 562,566 ---- navit_add_menu_projection(struct navit *this_, struct menu *men) { ! navit_add_menu_projections(this_, menu_add(men, _("Projection"), menu_type_submenu, NULL)); } *************** *** 568,576 **** struct map *map; struct menu *mmen; handle=mapset_open(ms); while ((map=mapset_next(handle,0))) { char *s=g_strdup_printf("%s:%s", map_get_type(map), map_get_filename(map)); ! mmen=menu_add(men, s, menu_type_toggle, navit_map_toggle, this_, map); menu_set_toggle(mmen, map_get_active(map)); g_free(s); --- 571,582 ---- struct map *map; struct menu *mmen; + struct callback *cb; handle=mapset_open(ms); while ((map=mapset_next(handle,0))) { char *s=g_strdup_printf("%s:%s", map_get_type(map), map_get_filename(map)); ! cb=callback_new_3(callback_cast(navit_map_toggle), NULL, this_, map); ! mmen=menu_add(men, s, menu_type_toggle, cb); ! callback_set_arg(cb, 0, mmen); menu_set_toggle(mmen, map_get_active(map)); g_free(s); *************** *** 580,584 **** static void ! navit_add_menu_destinations_from_file(struct navit *this_, char *file, struct menu *rmen, GHashTable *h, struct route *route, void (*callback)(struct menu *menu, void *data1, void *data2)) { int pos,flag=0; --- 586,590 ---- static void ! navit_add_menu_destinations_from_file(struct navit *this_, char *file, struct menu *rmen, GHashTable *h, struct route *route, void (*cb_func)(void)) { int pos,flag=0; *************** *** 588,591 **** --- 594,598 ---- char *name; int offset=0; + struct callback *cb; f=fopen(file, "r"); *************** *** 593,597 **** while (! feof(f) && (pos=parse_line(f, buffer, &name, &c)) > -3) { if (pos > 0) { ! navit_add_menu_destinations(this_, name, offset, rmen, h, callback); flag=1; } else --- 600,605 ---- while (! feof(f) && (pos=parse_line(f, buffer, &name, &c)) > -3) { if (pos > 0) { ! cb=callback_new_2(cb_func, this_, (void *)offset); ! navit_add_menu_destinations(this_, name, rmen, h, cb); flag=1; } else *************** *** 609,616 **** { if (men) ! this_->destinations=menu_add(men, "Former Destinations", menu_type_submenu, NULL, NULL, NULL); else this_->destinations=NULL; ! navit_add_menu_destinations_from_file(this_, "destination.txt", this_->destinations, NULL, route, navit_set_destination_from_destination); } --- 617,624 ---- { if (men) ! this_->destinations=menu_add(men, "Former Destinations", menu_type_submenu, NULL); else this_->destinations=NULL; ! navit_add_menu_destinations_from_file(this_, "destination.txt", this_->destinations, NULL, route, callback_cast(navit_set_destination_from_destination)); } *************** *** 619,634 **** { if (men) ! this_->bookmarks=menu_add(men, "Bookmarks", menu_type_submenu, NULL, NULL, NULL); else this_->bookmarks=NULL; ! navit_add_menu_destinations_from_file(this_, "bookmark.txt", this_->bookmarks, this_->bookmarks_hash, NULL, navit_set_destination_from_bookmark); } static void ! navit_vehicle_toggle(struct menu *menu, void *this__p, void *nv_p) { ! struct navit *this_=(struct navit *)this__p; ! struct navit_vehicle *nv=(struct navit_vehicle *)nv_p; ! if (menu_get_toggle(menu)) { if (this_->vehicle && this_->vehicle != nv) menu_set_toggle(this_->vehicle->menu, 0); --- 627,640 ---- { if (men) ! this_->bookmarks=menu_add(men, "Bookmarks", menu_type_submenu, NULL); else this_->bookmarks=NULL; ! navit_add_menu_destinations_from_file(this_, "bookmark.txt", this_->bookmarks, this_->bookmarks_hash, NULL, callback_cast(navit_set_destination_from_bookmark)); } static void ! navit_vehicle_toggle(struct navit *this_, struct navit_vehicle *nv) { ! if (menu_get_toggle(nv->menu)) { if (this_->vehicle && this_->vehicle != nv) menu_set_toggle(this_->vehicle->menu, 0); *************** *** 644,652 **** { struct navit_vehicle *nv; GList *l; l=this_->vehicles; while (l) { nv=l->data; ! nv->menu=menu_add(men, nv->name, menu_type_toggle, navit_vehicle_toggle, this_, nv); menu_set_toggle(nv->menu, this_->vehicle == nv); l=g_list_next(l); --- 650,660 ---- { struct navit_vehicle *nv; + struct callback *cb; GList *l; l=this_->vehicles; while (l) { nv=l->data; ! cb=callback_new_2(callback_cast(navit_vehicle_toggle), this_, nv); ! nv->menu=menu_add(men, nv->name, menu_type_toggle, cb); menu_set_toggle(nv->menu, this_->vehicle == nv); l=g_list_next(l); *************** *** 657,661 **** navit_add_menu_vehicle(struct navit *this_, struct menu *men) { ! men=menu_add(men, "Vehicle", menu_type_submenu, NULL, NULL, NULL); navit_add_menu_vehicles(this_, men); } --- 665,669 ---- navit_add_menu_vehicle(struct navit *this_, struct menu *men) { ! men=menu_add(men, "Vehicle", menu_type_submenu, NULL); navit_add_menu_vehicles(this_, men); } *************** *** 771,775 **** static void ! navit_window_items_open(struct menu *men, struct navit *this_, struct navit_window_items *nwi) { struct map_selection sel; --- 779,783 ---- static void ! navit_window_items_open(struct navit *this_, struct navit_window_items *nwi) { struct map_selection sel; *************** *** 812,816 **** sel.rect.rl.y=center->y-dist; dbg(2,"0x%x,0x%x - 0x%x,0x%x\n", sel.rect.lu.x, sel.rect.lu.y, sel.rect.rl.x, sel.rect.rl.y); ! nwi->click=callback_new_2(navit_window_items_click, this_, nwi); nwi->win=gui_datawindow_new(this_->gui, nwi->name, nwi->click, NULL); h=mapset_open(navit_get_mapset(this_)); --- 820,824 ---- sel.rect.rl.y=center->y-dist; dbg(2,"0x%x,0x%x - 0x%x,0x%x\n", sel.rect.lu.x, sel.rect.lu.y, sel.rect.rl.x, sel.rect.rl.y); ! nwi->click=callback_new_2(callback_cast(navit_window_items_click), this_, nwi); nwi->win=gui_datawindow_new(this_->gui, nwi->name, nwi->click, NULL); h=mapset_open(navit_get_mapset(this_)); *************** *** 875,883 **** { struct navit_window_items *nwi; GList *l; l=this_->windows_items; while (l) { nwi=l->data; ! menu_add(men, nwi->name, menu_type_menu, navit_window_items_open, this_, nwi); l=g_list_next(l); } --- 883,893 ---- { struct navit_window_items *nwi; + struct callback *cb; GList *l; l=this_->windows_items; while (l) { nwi=l->data; ! cb=callback_new_2(callback_cast(navit_window_items_open), this_, nwi); ! menu_add(men, nwi->name, menu_type_menu, cb); l=g_list_next(l); } *************** *** 930,934 **** navigation_set_mapset(this_->navigation, ms); if (this_->menubar) { ! men=menu_add(this_->menubar, "Map", menu_type_submenu, NULL, NULL, NULL); if (men) { navit_add_menu_layout(this_, men); --- 940,944 ---- navigation_set_mapset(this_->navigation, ms); if (this_->menubar) { ! men=menu_add(this_->menubar, "Map", menu_type_submenu, NULL); if (men) { navit_add_menu_layout(this_, men); *************** *** 937,941 **** navit_add_menu_maps(this_, ms, men); } ! men=menu_add(this_->menubar, "Route", menu_type_submenu, NULL, NULL, NULL); if (men) { navit_add_menu_former_destinations(this_, men, this_->route); --- 947,951 ---- navit_add_menu_maps(this_, ms, men); } ! men=menu_add(this_->menubar, "Route", menu_type_submenu, NULL); if (men) { navit_add_menu_former_destinations(this_, men, this_->route); *************** *** 952,956 **** } if (this_->menubar) { ! men=menu_add(this_->menubar, "Data", menu_type_submenu, NULL, NULL, NULL); if (men) { navit_add_menu_windows_items(this_, men); --- 962,966 ---- } if (this_->menubar) { ! men=menu_add(this_->menubar, "Data", menu_type_submenu, NULL); if (men) { navit_add_menu_windows_items(this_, men); |
From: Martin S. <mar...@us...> - 2007-12-03 13:17:18
|
Update of /cvsroot/navit/navit/src/gui/gtk In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv19270/gui/gtk Modified Files: gui_gtk_action.c Log Message: Converted menu callbacks to new callback api Index: gui_gtk_action.c =================================================================== RCS file: /cvsroot/navit/navit/src/gui/gtk/gui_gtk_action.c,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** gui_gtk_action.c 24 Nov 2007 12:40:24 -0000 1.21 --- gui_gtk_action.c 3 Dec 2007 13:17:19 -0000 1.22 *************** *** 5,8 **** --- 5,10 ---- #include "menu.h" #include "coord.h" + #include "callback.h" + #include "debug.h" #include "destination.h" *************** *** 16,23 **** struct gui_priv *gui; enum menu_type type; ! void (*callback)(struct menu *menu, void *data1, void *data2); ! struct menu *callback_menu; ! void *callback_data1; ! void *callback_data2; struct menu_priv *child; struct menu_priv *sibling; --- 18,22 ---- struct gui_priv *gui; enum menu_type type; ! struct callback *cb; struct menu_priv *child; struct menu_priv *sibling; *************** *** 405,410 **** activate(void *dummy, struct menu_priv *menu) { ! if (menu->callback) ! (*menu->callback)(menu->callback_menu, menu->callback_data1, menu->callback_data2); } --- 404,409 ---- activate(void *dummy, struct menu_priv *menu) { ! if (menu->cb) ! callback_call_0(menu->cb); } *************** *** 412,416 **** static struct menu_priv * ! add_menu(struct menu_priv *menu, struct menu_methods *meth, char *name, enum menu_type type, void (*callback)(struct menu *data_menu, void *data1, void *data2), struct menu *data_menu, void *data1, void *data2) { struct menu_priv *ret; --- 411,415 ---- static struct menu_priv * ! add_menu(struct menu_priv *menu, struct menu_methods *meth, char *name, enum menu_type type, struct callback *cb) { struct menu_priv *ret; *************** *** 429,433 **** else ret->action=gtk_action_new(dynname, name, NULL, NULL); ! if (callback) ret->handler_id=g_signal_connect(ret->action, "activate", G_CALLBACK(activate), ret); gtk_action_group_add_action(menu->gui->dyn_group, ret->action); --- 428,432 ---- else ret->action=gtk_action_new(dynname, name, NULL, NULL); ! if (cb) ret->handler_id=g_signal_connect(ret->action, "activate", G_CALLBACK(activate), ret); gtk_action_group_add_action(menu->gui->dyn_group, ret->action); *************** *** 438,445 **** ret->path=g_strdup_printf("%s/%s", menu->path, dynname); ret->type=type; ! ret->callback=callback; ! ret->callback_menu=data_menu; ! ret->callback_data1=data1; ! ret->callback_data2=data2; ret->sibling=menu->child; menu->child=ret; --- 437,441 ---- ret->path=g_strdup_printf("%s/%s", menu->path, dynname); ret->type=type; ! ret->cb=cb; ret->sibling=menu->child; menu->child=ret; *************** *** 542,546 **** } else { gtk_menu_popup(GTK_MENU(widget), NULL, NULL, NULL, NULL, 0, gtk_get_current_event_time ()); ! ret->handler_id=g_signal_connect(widget, "deactivate", G_CALLBACK(popup_deactivate), ret); } return ret; --- 538,542 ---- } else { gtk_menu_popup(GTK_MENU(widget), NULL, NULL, NULL, NULL, 0, gtk_get_current_event_time ()); ! ret->handler_id=g_signal_connect(widget, "selection-done", G_CALLBACK(popup_deactivate), ret); } return ret; |
From: Michael F. <ho...@us...> - 2007-12-02 19:25:29
|
Update of /cvsroot/navit/navit/src/graphics/gtk_drawing_area In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv24692 Modified Files: graphics_gtk_drawing_area.c Log Message: fix some more warnings Index: graphics_gtk_drawing_area.c =================================================================== RCS file: /cvsroot/navit/navit/src/graphics/gtk_drawing_area/graphics_gtk_drawing_area.c,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** graphics_gtk_drawing_area.c 25 Nov 2007 01:32:14 -0000 1.20 --- graphics_gtk_drawing_area.c 2 Dec 2007 19:25:29 -0000 1.21 *************** *** 112,129 **** // Trying the Liberation font first sprintf(fontpath,"%s/LiberationSans-Regular.ttf",*filename); ! dbg(1,("font : %s\n",fontpath)); if (!FT_New_Face( gr->library, fontpath, 0, &font->face )) break; //Fallback to arial.ttf, in the same path sprintf(fontpath,"%s/arial.ttf",*filename); ! dbg(1,("font : %s\n",fontpath)); if (!FT_New_Face( gr->library, fontpath, 0, &font->face )) break; sprintf(fontpath,"%s/NcrBI4nh.ttf",*filename); ! dbg(1,("font : %s\n",fontpath)); if (!FT_New_Face( gr->library, fontpath, 0, &font->face )) break; sprintf(fontpath,"%s/luximbi.ttf",*filename); ! dbg(1,("font : %s\n",fontpath)); if (!FT_New_Face( gr->library, fontpath, 0, &font->face )) break; --- 112,129 ---- // Trying the Liberation font first sprintf(fontpath,"%s/LiberationSans-Regular.ttf",*filename); ! dbg(1,"font : %s\n",fontpath); if (!FT_New_Face( gr->library, fontpath, 0, &font->face )) break; //Fallback to arial.ttf, in the same path sprintf(fontpath,"%s/arial.ttf",*filename); ! dbg(1,"font : %s\n",fontpath); if (!FT_New_Face( gr->library, fontpath, 0, &font->face )) break; sprintf(fontpath,"%s/NcrBI4nh.ttf",*filename); ! dbg(1,"font : %s\n",fontpath); if (!FT_New_Face( gr->library, fontpath, 0, &font->face )) break; sprintf(fontpath,"%s/luximbi.ttf",*filename); ! dbg(1,"font : %s\n",fontpath); if (!FT_New_Face( gr->library, fontpath, 0, &font->face )) break; |
From: Michael F. <ho...@us...> - 2007-12-02 19:08:57
|
Update of /cvsroot/navit/navit In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv18004 Modified Files: configure.in Log Message: Fix some GTK warnings Index: configure.in =================================================================== RCS file: /cvsroot/navit/navit/configure.in,v retrieving revision 1.57 retrieving revision 1.58 diff -C2 -d -r1.57 -r1.58 *** configure.in 23 Nov 2007 15:50:04 -0000 1.57 --- configure.in 2 Dec 2007 19:09:00 -0000 1.58 *************** *** 17,22 **** PKG_CHECK_EXISTS - # CFLAGS="$CFLAGS -DG_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGDK_PIXBUF_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED" - AC_DISABLE_STATIC AC_PROG_LIBTOOL --- 17,20 ---- *************** *** 73,76 **** --- 71,77 ---- fi fi + + GTK2_CFLAGS="$GTK2_CFLAGS -DG_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGDK_PIXBUF_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED" + AC_SUBST(GTK2_CFLAGS) AC_SUBST(GTK2_LIBS) |
From: Michael F. <ho...@us...> - 2007-12-02 17:43:31
|
Update of /cvsroot/navit/navit/src In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv16089 Modified Files: vehicle.c Log Message: Fixes two warnings Index: vehicle.c =================================================================== RCS file: /cvsroot/navit/navit/src/vehicle.c,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** vehicle.c 8 Nov 2007 23:07:04 -0000 1.26 --- vehicle.c 2 Dec 2007 17:43:31 -0000 1.27 *************** *** 386,390 **** } if(data->set & PDOP_SET){ ! printf("pdop : %d\n",data->pdop); } } --- 386,390 ---- } if(data->set & PDOP_SET){ ! printf("pdop : %g\n",data->pdop); } } *************** *** 618,622 **** } else if (! strncmp(this_->url,"demo://",7)) { dbg(0,"Creating a demo vehicle\n"); ! g_timeout_add(1000, vehicle_demo_timer, this_); } this_->iochan=g_io_channel_unix_new(fd); --- 618,622 ---- } else if (! strncmp(this_->url,"demo://",7)) { dbg(0,"Creating a demo vehicle\n"); ! g_timeout_add(1000, (GSourceFunc) vehicle_demo_timer, this_); } this_->iochan=g_io_channel_unix_new(fd); |
From: Martin S. <mar...@us...> - 2007-12-02 16:29:03
|
Update of /cvsroot/navit/navit/src/data/mg In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv15678/data/mg Modified Files: mg.h street.c Log Message: Fixed a bug in m&g and textfile driver Index: street.c =================================================================== RCS file: /cvsroot/navit/navit/src/data/mg/street.c,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** street.c 20 Nov 2007 18:55:41 -0000 1.11 --- street.c 2 Dec 2007 16:29:01 -0000 1.12 *************** *** 191,196 **** ret++; count--; ! } else return ret; } return ret; --- 191,198 ---- ret++; count--; ! } else { ! street->more=0; return ret; + } } return ret; *************** *** 307,311 **** int street_get(struct map_rect_priv *mr, struct street_priv *street, struct item *item) ! { if (mr->b.p == mr->b.p_start) { street_get_data(street, &mr->b.p); --- 309,317 ---- int street_get(struct map_rect_priv *mr, struct street_priv *street, struct item *item) ! { ! while (street->more) { ! struct coord c; ! street_coord_get(street, &c, 1); ! } if (mr->b.p == mr->b.p_start) { street_get_data(street, &mr->b.p); *************** *** 414,417 **** --- 420,424 ---- street->name.len=0; street->attr_next=attr_label; + street->more=1; return 1; } Index: mg.h =================================================================== RCS file: /cvsroot/navit/navit/src/data/mg/mg.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** mg.h 28 Aug 2007 17:31:17 -0000 1.6 --- mg.h 2 Dec 2007 16:29:01 -0000 1.7 *************** *** 160,163 **** --- 160,164 ---- struct coord *ref; int bytes; + int more; struct street_name name; enum attr_type attr_next; |
From: Martin S. <mar...@us...> - 2007-12-02 16:29:03
|
Update of /cvsroot/navit/navit/src/data/textfile In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv15678/data/textfile Modified Files: textfile.c textfile.h Log Message: Fixed a bug in m&g and textfile driver Index: textfile.c =================================================================== RCS file: /cvsroot/navit/navit/src/data/textfile/textfile.c,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** textfile.c 3 Oct 2007 13:47:34 -0000 1.7 --- textfile.c 2 Dec 2007 16:29:01 -0000 1.8 *************** *** 124,127 **** --- 124,128 ---- mr->eoc=1; } else { + mr->more=0; break; } *************** *** 223,226 **** --- 224,231 ---- return NULL; } + while (mr->more) { + struct coord c; + textfile_coord_get(mr, &c, 1); + } for(;;) { if (feof(mr->f)) { *************** *** 270,273 **** --- 275,279 ---- } mr->attr_last=attr_none; + mr->more=1; dbg(1,"return attr='%s'\n", mr->attrs); return &mr->item; Index: textfile.h =================================================================== RCS file: /cvsroot/navit/navit/src/data/textfile/textfile.h,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** textfile.h 3 Oct 2007 13:47:35 -0000 1.4 --- textfile.h 2 Dec 2007 16:29:01 -0000 1.5 *************** *** 23,26 **** --- 23,27 ---- struct coord c; int eoc; + int more; struct map_priv *m; struct item item; |
From: KaZeR <ka...@us...> - 2007-11-30 22:21:54
|
Update of /cvsroot/navit/navit/src In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv25303 Modified Files: color.h xmlconfig.c Log Message: Added an alpha channel to colors Index: color.h =================================================================== RCS file: /cvsroot/navit/navit/src/color.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** color.h 9 Oct 2007 16:44:03 -0000 1.3 --- color.h 30 Nov 2007 22:21:56 -0000 1.4 *************** *** 3,7 **** struct color { ! int r,g,b; }; --- 3,7 ---- struct color { ! int r,g,b,a; }; Index: xmlconfig.c =================================================================== RCS file: /cvsroot/navit/navit/src/xmlconfig.c,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** xmlconfig.c 19 Nov 2007 19:58:18 -0000 1.19 --- xmlconfig.c 30 Nov 2007 22:21:56 -0000 1.20 *************** *** 80,93 **** { const char *value; ! int r,g,b; value=find_attribute(state, "color", required); if (! value) return 0; ! ! sscanf(value,"#%02x%02x%02x", &r, &g, &b); ! color->r = (r << 8) | r; ! color->g = (g << 8) | g; ! color->b = (b << 8) | b; return 1; } --- 80,103 ---- { const char *value; ! int r,g,b,a; value=find_attribute(state, "color", required); if (! value) return 0; ! if(strlen(value)==7){ ! sscanf(value,"#%02x%02x%02x", &r, &g, &b); ! color->r = (r << 8) | r; ! color->g = (g << 8) | g; ! color->b = (b << 8) | b; ! color->a = (65535); ! } else if(strlen(value)==9){ ! sscanf(value,"#%02x%02x%02x%02x", &r, &g, &b, &a); ! color->r = (r << 8) | r; ! color->g = (g << 8) | g; ! color->b = (b << 8) | b; ! color->a = (a << 8) | a; ! } else { ! dbg(0,"color %i has unknown format\n",value); ! } return 1; } |
From: KaZeR <ka...@us...> - 2007-11-30 22:21:54
|
Update of /cvsroot/navit/navit/src/graphics/opengl In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv25303/graphics/opengl Modified Files: graphics_opengl.c Log Message: Added an alpha channel to colors Index: graphics_opengl.c =================================================================== RCS file: /cvsroot/navit/navit/src/graphics/opengl/graphics_opengl.c,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** graphics_opengl.c 31 Oct 2007 16:43:04 -0000 1.12 --- graphics_opengl.c 30 Nov 2007 22:21:57 -0000 1.13 *************** *** 2,9 **** #include <glib.h> #include "config.h" - #if 0 - #include <ft2build.h> - #include FT_FREETYPE_H - #endif #include <GL/glc.h> #include "point.h" --- 2,5 ---- *************** *** 143,147 **** gc->fg=c->g/65535.0; gc->fb=c->b/65535.0; ! gc->fa=0; } --- 139,144 ---- gc->fg=c->g/65535.0; gc->fb=c->b/65535.0; ! gc->fa=c->a/65535.0; ! // printf("new alpha : %i\n",c->a); } *************** *** 152,156 **** gc->bg=c->g/65535.0; gc->bb=c->b/65535.0; ! gc->ba=0; } --- 149,153 ---- gc->bg=c->g/65535.0; gc->bb=c->b/65535.0; ! gc->ba=c->a/65535.0; } *************** *** 198,203 **** draw_lines(struct graphics_priv *gr, struct graphics_gc_priv *gc, struct point *p, int count) { - // printf("draw_lines\n"); - // glClear(GL_COLOR_BUFFER_BIT| GL_DEPTH_BUFFER_BIT); int i; /* --- 195,198 ---- |
From: Martin S. <mar...@us...> - 2007-11-29 09:44:00
|
Update of /cvsroot/navit/navit/src In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv22537 Modified Files: osm2navit.c Log Message: Added malloc debugging Index: osm2navit.c =================================================================== RCS file: /cvsroot/navit/navit/src/osm2navit.c,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** osm2navit.c 27 Nov 2007 11:10:28 -0000 1.12 --- osm2navit.c 29 Nov 2007 09:44:03 -0000 1.13 *************** *** 3,6 **** --- 3,7 ---- #define _LARGEFILE64_SOURCE #include <glib.h> + #include <assert.h> #include <malloc.h> #include <string.h> *************** *** 366,369 **** --- 367,371 ---- b->malloced+=b->malloced_step; b->base=realloc(b->base, b->malloced); + assert(b->base != NULL); } *************** *** 633,636 **** --- 635,639 ---- fseek(f, 0, SEEK_SET); b->base=malloc(b->size); + assert(b->base != NULL); fread(b->base, b->size, 1, f); fclose(f); *************** *** 838,841 **** --- 841,845 ---- if (! th) { th=malloc(sizeof(*th)+strlen(tile)+1); + assert(th != NULL); strcpy(th->subtiles, tile); th->size=strlen(tile)+1; *************** *** 886,889 **** --- 890,894 ---- } else { thb=realloc(thb, sizeof(*thb)+ths->size+thb->size); + assert(thb != NULL); memcpy(thb->subtiles+thb->size, ths->subtiles, ths->size); thb->size+=ths->size; *************** *** 1441,1444 **** --- 1446,1450 ---- slice_data=malloc(size); + assert(slice_data != NULL); zip_data=slice_data; th=tile_head_root; |