Thread: [Gpredict-svn] SF.net SVN: gpredict:[795] trunk (Page 4)
Real time satellite tracking and orbit prediction
Status: Beta
Brought to you by:
csete
From: <aa...@us...> - 2011-03-26 17:38:23
|
Revision: 795 http://gpredict.svn.sourceforge.net/gpredict/?rev=795&view=rev Author: aa1vs Date: 2011-03-26 17:38:17 +0000 (Sat, 26 Mar 2011) Log Message: ----------- Change get current pass to log error if non-current pass returned. Modified Paths: -------------- trunk/ChangeLog trunk/src/predict-tools.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-03-26 17:13:33 UTC (rev 794) +++ trunk/ChangeLog 2011-03-26 17:38:17 UTC (rev 795) @@ -1,3 +1,8 @@ +2011-03-26 Charles Suprin <hamaa1vs at gmail.com> + + * src/predict-tools.c + Change get_current_pass to log error if returned pass is not current. + 2011-03-25 Charles Suprin <hamaa1vs at gmail.com> * AUTHORS Modified: trunk/src/predict-tools.c =================================================================== --- trunk/src/predict-tools.c 2011-03-26 17:13:33 UTC (rev 794) +++ trunk/src/predict-tools.c 2011-03-26 17:38:17 UTC (rev 795) @@ -913,9 +913,11 @@ pass_t * get_current_pass (sat_t *sat_in, qth_t *qth, gdouble start) { - gdouble t; + gdouble t,t0; + gdouble el0; sat_t *sat,sat_working; - + pass_t *pass; + /*copy sat_in to a working structure*/ sat = memcpy(&sat_working,sat_in,sizeof(sat_t)); @@ -925,6 +927,10 @@ t = get_current_daynum (); predict_calc (sat, qth, t); + /*save initial conditions for later comparison*/ + t0 = t; + el0 = sat->el; + /* check whether satellite has aos */ if (!has_aos (sat, qth)) { @@ -933,10 +939,26 @@ } /* find a time before AOS */ - while (sat->el > -2.0) { + while (sat->el > 0.0) { predict_calc (sat, qth, t); t -= 0.007; // +10 min } - return get_pass_no_min_el (sat, qth, t, 0.0); + pass = get_pass_no_min_el (sat, qth, t, 0.0); + if (el0 > 0.0) { + /* this function is only specified if the elevation + is greater than zero at the time it is called*/ + if (pass){ + if (pass->aos > t0) + sat_log_log (SAT_LOG_LEVEL_ERROR, + _("%s: Returning a pass for %s that starts after the seeded time."), + __FUNCTION__,sat->nickname); + + if (pass->los < t0) + sat_log_log (SAT_LOG_LEVEL_ERROR, + _("%s: Returning a pass for %s that ends before the seeded time."), + __FUNCTION__,sat->nickname); + } + } + return pass; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-03-29 00:55:13
|
Revision: 801 http://gpredict.svn.sourceforge.net/gpredict/?rev=801&view=rev Author: aa1vs Date: 2011-03-29 00:55:07 +0000 (Tue, 29 Mar 2011) Log Message: ----------- Update ChangeLog and NEWS Modified Paths: -------------- trunk/ChangeLog trunk/NEWS Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-03-29 00:42:01 UTC (rev 800) +++ trunk/ChangeLog 2011-03-29 00:55:07 UTC (rev 801) @@ -1,3 +1,29 @@ +2011-03-28 Charles Suprin <hamaa1vs at gmail.com> + + * src/gtk-rig-ctrl.c + * src/gtk-rot-ctrl.c + Apply Stephane Fillods patch to repair Win32 networking. + + * src/gtk-sat-selector.c + Remove strverscmp reference. + +2011-03-27 Charles Suprin <hamaa1vs at gmail.com> + + * src/gtk-azel-plot.c + * src/gtk-polar-plot.c + * src/gtk-polar-view-popup.c + * src/gtk-polar-view.c + * src/gtk-sat-list.c + * src/gtk-sat-module.c + * src/gtk-sat-selector.c + * src/gtk-single-sat.c + * src/gtk-sky-glance.c + * src/pass-to-txt.c + * src/sat-pass-dialogs.c + * src/time-tools.c + * src/time-tools.h + Rename julian_print_time daynum_to_str. + 2011-03-26 Charles Suprin <hamaa1vs at gmail.com> * src/predict-tools.c @@ -3,4 +29,12 @@ Change get_current_pass to log error if returned pass is not current. + * src/gtk-polar-view.c + * src/gtk-sat-list.c + * src/gtk-sat-map.c + * src/gtk-sat-selector.c + * src/sat-pass-dialogs.c + Clean up compiler warnings. + + 2011-03-25 Charles Suprin <hamaa1vs at gmail.com> Modified: trunk/NEWS =================================================================== --- trunk/NEWS 2011-03-29 00:42:01 UTC (rev 800) +++ trunk/NEWS 2011-03-29 00:55:07 UTC (rev 801) @@ -3,6 +3,7 @@ - Feature request 3141555: gpsd support. - Applied and extended patch 3237220: natural sort for sat list in module config - Improve handling of decayed satellites. +- Fixed bug 3250344: Win32 uild not working with hamlib Changes in version 1.3 (1 Mar 2011) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-03-30 23:50:41
|
Revision: 803 http://gpredict.svn.sourceforge.net/gpredict/?rev=803&view=rev Author: aa1vs Date: 2011-03-30 23:50:34 +0000 (Wed, 30 Mar 2011) Log Message: ----------- Change definition of HAS_LIBGPS. Modified Paths: -------------- trunk/configure.ac trunk/src/qth-data.c trunk/src/qth-editor.c trunk/src/sat-pref-qth-editor.c trunk/src/sat-pref-qth.c Modified: trunk/configure.ac =================================================================== --- trunk/configure.ac 2011-03-30 23:16:02 UTC (rev 802) +++ trunk/configure.ac 2011-03-30 23:50:34 UTC (rev 803) @@ -37,8 +37,6 @@ AC_DEFINE(HAS_LIBGPS, 1, [Define if libgps is available]) ], [ havelibgps=false; - AC_DEFINE(HAS_LIBGPS, 0, [Define if libgps is unvailable]) - ]) dnl Hamlib not needed if we go for the TCP based I/F Modified: trunk/src/qth-data.c =================================================================== --- trunk/src/qth-data.c 2011-03-30 23:16:02 UTC (rev 802) +++ trunk/src/qth-data.c 2011-03-30 23:50:34 UTC (rev 803) @@ -40,7 +40,7 @@ #include "orbit-tools.h" #include "time-tools.h" #include "locator.h" -#if HAS_LIBGPS +#ifdef HAS_LIBGPS # include <gps.h> #endif @@ -499,7 +499,7 @@ } if (qth->gps_data!=NULL) { -#if HAS_LIBGPS +#ifdef HAS_LIBGPS switch (GPSD_API_MAJOR_VERSION){ case 4: #if GPSD_API_MAJOR_VERSION==4 @@ -621,7 +621,7 @@ /*nothing to do. the data never updates*/ break; case QTH_GPSD_TYPE: -#if HAS_LIBGPS +#ifdef HAS_LIBGPS switch (GPSD_API_MAJOR_VERSION) { case 4: #if GPSD_API_MAJOR_VERSION==4 @@ -696,7 +696,7 @@ /* close gpsd socket */ if (qth->gps_data !=NULL){ -#if HAS_LIBGPS +#ifdef HAS_LIBGPS switch (GPSD_API_MAJOR_VERSION) { case 4: gps_close(qth->gps_data); Modified: trunk/src/qth-editor.c =================================================================== --- trunk/src/qth-editor.c 2011-03-30 23:16:02 UTC (rev 802) +++ trunk/src/qth-editor.c 2011-03-30 23:50:34 UTC (rev 803) @@ -73,9 +73,11 @@ static GtkWidget *location; /* QTH location */ static GtkWidget *desc; /* QTH description */ static GtkWidget *lat,*lon,*alt; /* LAT, LON and ALT */ +#ifdef HAS_LIBGPS static GtkWidget *type; /* GPSD type */ static GtkWidget *server; /* GPSD Server */ static GtkWidget *port; /* GPSD Port */ +#endif static GtkWidget *ns,*ew; static GtkWidget *qra; /* QRA locator */ @@ -376,7 +378,7 @@ GUINT_TO_POINTER (SELECTION_MODE_WX)); gtk_table_attach_defaults (GTK_TABLE (table), wxbut, 3, 4, 7, 8); -# if HAS_LIBGPS +# ifdef HAS_LIBGPS /* GPSD enabled*/ label = gtk_label_new (_("QTH Type")); gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); @@ -506,9 +508,11 @@ const gchar *qthdesc = NULL; const gchar *qthwx = NULL; const gchar *qthqra= NULL; +#ifdef HAS_LIBGPS const gchar *gpsdserver= NULL; guint gpsdport; guint gpsdenabled; +#endif gdouble qthlat; gdouble qthlon; guint qthalt; @@ -533,9 +537,11 @@ qthalt = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (alt)); qthqra = gtk_entry_get_text (GTK_ENTRY (qra)); +#ifdef HAS_LIBGPS gpsdenabled = gtk_combo_box_get_active ( GTK_COMBO_BOX (type) ); gpsdserver = gtk_entry_get_text (GTK_ENTRY (server)); gpsdport = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (port)); +#endif /* clear qth struct if not empty */ /* if (qth->name != NULL) */ @@ -571,14 +577,18 @@ if (qthqra != NULL) qth->qra = g_strdup (qthqra); +#ifdef HAS_LIBGPS if (gpsdserver != NULL) qth->gpsd_server = g_strdup (gpsdserver); - +#endif qth->lat = qthlat; qth->lon = qthlon; qth->alt = qthalt; + +#ifdef HAS_LIBGPS qth->type = gpsdenabled; qth->gpsd_port = gpsdport; +#endif /* store values */ confdir = get_user_conf_dir (); Modified: trunk/src/sat-pref-qth-editor.c =================================================================== --- trunk/src/sat-pref-qth-editor.c 2011-03-30 23:16:02 UTC (rev 802) +++ trunk/src/sat-pref-qth-editor.c 2011-03-30 23:50:34 UTC (rev 803) @@ -80,9 +80,11 @@ static GtkWidget *ns,*ew; static GtkWidget *qra; /* QRA locator */ +#ifdef HAS_LIBGPS static GtkWidget *type; /* GPSD type */ static GtkWidget *server; /* GPSD Server */ static GtkWidget *port; /* GPSD Port */ +#endif static gulong latsigid,lonsigid,nssigid,ewsigid,qrasigid; static GtkWidget *wx; /* weather station */ @@ -361,7 +363,7 @@ GUINT_TO_POINTER (SELECTION_MODE_WX)); gtk_table_attach_defaults (GTK_TABLE (table), wxbut, 3, 4, 7, 8); -# if HAS_LIBGPS +# ifdef HAS_LIBGPS /* GPSD enabled*/ label = gtk_label_new (_("QTH Type")); gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); @@ -468,11 +470,12 @@ gtk_entry_set_text (GTK_ENTRY (wx), qthwx); g_free (qthwx); } +#ifdef HAS_LIBGPS if (qthgpsdserver) { gtk_entry_set_text (GTK_ENTRY (server), qthgpsdserver); g_free (qthgpsdserver); } - +#endif if (qthlat < 0.00) gtk_combo_box_set_active (GTK_COMBO_BOX (ns), 1); else @@ -488,8 +491,10 @@ gtk_spin_button_set_value (GTK_SPIN_BUTTON (lon), fabs (qthlon)); gtk_spin_button_set_value (GTK_SPIN_BUTTON (alt), qthalt); +#ifdef HAS_LIBGPS gtk_spin_button_set_value (GTK_SPIN_BUTTON (port), qthgpsdport); gtk_combo_box_set_active (GTK_COMBO_BOX (type), qthtype); +#endif sat_log_log (SAT_LOG_LEVEL_DEBUG, _("%s:%d: Loaded %s for editing:\n"\ @@ -560,7 +565,10 @@ qthloc = gtk_entry_get_text (GTK_ENTRY (location)); qthdesc = gtk_entry_get_text (GTK_ENTRY (desc)); qthwx = gtk_entry_get_text (GTK_ENTRY (wx)); + +#ifdef HAS_LIBGPS qthgpsdserver = gtk_entry_get_text (GTK_ENTRY (server)); +#endif qthlat = gtk_spin_button_get_value (GTK_SPIN_BUTTON (lat)); if (gtk_combo_box_get_active (GTK_COMBO_BOX (ns))) @@ -571,8 +579,11 @@ qthlon = -qthlon; qthalt = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (alt)); + +#ifdef HAS_LIBGPS qthgpsdport = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (port)); qthtype = gtk_combo_box_get_active ( GTK_COMBO_BOX (type)); +#endif /* get liststore */ liststore = GTK_LIST_STORE (gtk_tree_view_get_model (treeview)); Modified: trunk/src/sat-pref-qth.c =================================================================== --- trunk/src/sat-pref-qth.c 2011-03-30 23:16:02 UTC (rev 802) +++ trunk/src/sat-pref-qth.c 2011-03-30 23:50:34 UTC (rev 803) @@ -270,7 +270,7 @@ g_signal_connect (qthlist, "row-activated", G_CALLBACK (row_activated_cb), NULL); -# if HAS_LIBGPS +# ifdef HAS_LIBGPS /* GPSD enabled*/ /*server*/ renderer = gtk_cell_renderer_text_new (); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-03-31 00:03:55
|
Revision: 804 http://gpredict.svn.sourceforge.net/gpredict/?rev=804&view=rev Author: aa1vs Date: 2011-03-31 00:03:48 +0000 (Thu, 31 Mar 2011) Log Message: ----------- Update Authors and about.c for Win32 network fixes. Modified Paths: -------------- trunk/AUTHORS trunk/src/about.c trunk/src/main.c Modified: trunk/AUTHORS =================================================================== --- trunk/AUTHORS 2011-03-30 23:50:34 UTC (rev 803) +++ trunk/AUTHORS 2011-03-31 00:03:48 UTC (rev 804) @@ -12,7 +12,8 @@ see http://www.dachaplin.dsl.pipex.com/goocanvas/ - Maidenhead locator functions are based on work done by Stephane Fillod, Nate Bargmann, Dave Hines, Mirko Caserta, and S. R. Sampson. -- Paul Schulz, various patches. +- Win32 networking in rig and rotor control fixed by Stephane Fillod, +- Paul Schulz, VK5FPAW (various patches). - Martin Pool, for his natural string compare routines see http://sourcefrog.net/projects/natsort/ Modified: trunk/src/about.c =================================================================== --- trunk/src/about.c 2011-03-30 23:50:34 UTC (rev 803) +++ trunk/src/about.c 2011-03-31 00:03:48 UTC (rev 804) @@ -48,12 +48,12 @@ "John A. Magliacane, KD2BD (prediction code)", "Neoklis Kyriazis, 5B4AZ (SGP4/SDP4 in C)", "William J Beksi, KC2EXL (GtkSatMap)", - "Stephane Fillod (Rig controller and locator.c)", + "Stephane Fillod (Win32 network fixes, rig controller and locator.c)", "Nate Bargmann (locator.c)", "Dave Hines (locator.c)", "Mirko Caserta (locator.c)", "S. R. Sampson (locator.c)", - "Paul Schulz (various patches)", + "Paul Schulz, VK5FPAW (various patches)", "Martin Pool (natural sorting)", "", "Imagery:", Modified: trunk/src/main.c =================================================================== --- trunk/src/main.c 2011-03-30 23:50:34 UTC (rev 803) +++ trunk/src/main.c 2011-03-31 00:03:48 UTC (rev 804) @@ -438,7 +438,7 @@ * * If the time to update the TLE has come, it will either notify * the user, or fork a separate task which will update the TLE data - * in the background (depending on user settings. + * in the background (depending on user settings). * * In case of notification, the task will be removed in order to * avoid a new notification the next time the taks would be run. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <cs...@us...> - 2011-04-01 12:15:31
|
Revision: 806 http://gpredict.svn.sourceforge.net/gpredict/?rev=806&view=rev Author: csete Date: 2011-04-01 12:15:25 +0000 (Fri, 01 Apr 2011) Log Message: ----------- Trying to sync AUTHORS and about.c Modified Paths: -------------- trunk/AUTHORS trunk/ChangeLog trunk/src/about.c Modified: trunk/AUTHORS =================================================================== --- trunk/AUTHORS 2011-04-01 11:48:05 UTC (rev 805) +++ trunk/AUTHORS 2011-04-01 12:15:25 UTC (rev 806) @@ -3,8 +3,8 @@ Contributors: - William J Beksi, KC2EXL, Map view. -- Charles Suprin, AA1VS, various multithread fixes. -- Valentin Yakovenkov, Windows build. +- Charles Suprin, AA1VS, GPS support and many other improvements. +- Alan Moffet KE7IJZ and Valentin Yakovenkov, Windows build. - David VK5DG, transponder data files - Dr. T.S. Kelso, the author original SGP4/SDP4 algorithms in FORTRAN and Pascal. - Neoklis Kyriazis, 5B4AZ, conversion of the algorithms to C. @@ -16,7 +16,9 @@ - Paul Schulz, VK5FPAW (various patches). - Martin Pool, for his natural string compare routines see http://sourcefrog.net/projects/natsort/ +- Patrick Strasser, OE6PSE (natural sorting) + Imagery: Most of the maps originate from NASA Visible Earth, http://visibleearth.nasa.gov/ Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-04-01 11:48:05 UTC (rev 805) +++ trunk/ChangeLog 2011-04-01 12:15:25 UTC (rev 806) @@ -8,6 +8,10 @@ * src/gtk-polar-view.c Appied patch 3261586: Remove leading zero code from time formatting functions (thanks to Paul Schulz). + + * src/about.c + * AUTHORS + Trying to sync AUTHORS and about.c 2011-03-28 Charles Suprin <hamaa1vs at gmail.com> Modified: trunk/src/about.c =================================================================== --- trunk/src/about.c 2011-04-01 11:48:05 UTC (rev 805) +++ trunk/src/about.c 2011-04-01 12:15:25 UTC (rev 806) @@ -40,9 +40,9 @@ "", "Contributors:", "David VK5DG (Transponder data files)", - "Charles Suprin, AA1VS (Various multithread fixes)", + "Charles Suprin, AA1VS (GPS support and many other improvements)", + "Alan Moffet, KE7IJZ (windows build)," "Valentin Yakovenkov (Windows build)", - "Bruce Cowan (Gio port of TLE updater)", "Damon Chaplin (GooCanvas)", "Dr. T.S. Kelso (SGP4/SDP4 algorithms)", "John A. Magliacane, KD2BD (prediction code)", @@ -54,6 +54,7 @@ "Mirko Caserta (locator.c)", "S. R. Sampson (locator.c)", "Paul Schulz, VK5FPAW (various patches)", + "Patrick Strasser, OE6PSE (natural sorting)", "Martin Pool (natural sorting)", "", "Imagery:", @@ -64,7 +65,7 @@ const gchar license[] = N_("Copyright (C) 2001-2011 Alexandru Csete OZ9AEC and contributors.\n"\ - "Contact: oz9aec at googlemail.com\n\n"\ + "Contact: oz9aec at gmail.com\n\n"\ "Gpredict is free software; you can redistribute it and "\ "mofdify it under the terms of the GNU General Public License "\ "as published by the Free Software Foundation; either version 2 "\ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <cs...@us...> - 2011-04-03 14:51:39
|
Revision: 812 http://gpredict.svn.sourceforge.net/gpredict/?rev=812&view=rev Author: csete Date: 2011-04-03 14:51:33 +0000 (Sun, 03 Apr 2011) Log Message: ----------- Updated user manual with info about using mouse wheel on frequency and rotor digits. Modified Paths: -------------- trunk/ChangeLog trunk/doc/um/gpredict-user-manual.odt Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-04-03 14:45:09 UTC (rev 811) +++ trunk/ChangeLog 2011-04-03 14:51:33 UTC (rev 812) @@ -6,6 +6,9 @@ * src/gtk-freq-knob.h Allow changing radio frequency and rotator position using mouse buttons and wheel (feature req 2130926). Up/down arrows are kept for now. + + * doc/um/gpredict-user-manual.odt + Updated with info about using the mouse wheel over the digits. 2011-04-01 Charles Suprin <hamaa1vs at gmail.com> Modified: trunk/doc/um/gpredict-user-manual.odt =================================================================== (Binary files differ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <cs...@us...> - 2011-04-29 18:28:22
|
Revision: 817 http://gpredict.svn.sourceforge.net/gpredict/?rev=817&view=rev Author: csete Date: 2011-04-29 18:28:15 +0000 (Fri, 29 Apr 2011) Log Message: ----------- Fixed bug 3294829: Program name wrong in desktop files. Modified Paths: -------------- trunk/ChangeLog trunk/NEWS trunk/data/desktop/gpredict.desktop.in Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-04-21 11:23:02 UTC (rev 816) +++ trunk/ChangeLog 2011-04-29 18:28:15 UTC (rev 817) @@ -1,3 +1,9 @@ +2011-04-29 Alexandru Csete <oz9aec at gmail.com> + + * data/desktop/gpredict.desktop.in + Fixed bug 3294829: Program name wrong in desktop files. + + 2011-04-03 Alexandru Csete <oz9aec at gmail.com> * src/gtk-rot-knob.c Modified: trunk/NEWS =================================================================== --- trunk/NEWS 2011-04-21 11:23:02 UTC (rev 816) +++ trunk/NEWS 2011-04-29 18:28:15 UTC (rev 817) @@ -4,7 +4,8 @@ - Feature request 2130926: Change frequency using mouse wheel. Also for rotator controller. - Applied and extended patch 3237220: natural sort for sat list in module config - Improve handling of decayed satellites. -- Fixed bug 3250344: Win32 uild not working with hamlib +- Fixed bug 3250344: Win32 uild not working with hamlib. +- Fixed bug 3294829: Program name wrong in desktop files. Changes in version 1.3 (1 Mar 2011) Modified: trunk/data/desktop/gpredict.desktop.in =================================================================== --- trunk/data/desktop/gpredict.desktop.in 2011-04-21 11:23:02 UTC (rev 816) +++ trunk/data/desktop/gpredict.desktop.in 2011-04-29 18:28:15 UTC (rev 817) @@ -1,5 +1,5 @@ [Desktop Entry] -Name=Gredict +Name=Gpredict Comment=Satellite tracker Exec=gpredict Icon=gpredict-icon This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <cs...@us...> - 2011-05-01 11:12:09
|
Revision: 818 http://gpredict.svn.sourceforge.net/gpredict/?rev=818&view=rev Author: csete Date: 2011-05-01 11:12:02 +0000 (Sun, 01 May 2011) Log Message: ----------- New module menu item to allow selection of a satellite in all views at the same time. Related to feature request 3179102: Right click on satellite to add the track (probably the closest we can get to global selection without breaking the design). Modified Paths: -------------- trunk/ChangeLog trunk/NEWS trunk/src/gtk-event-list.c trunk/src/gtk-event-list.h trunk/src/gtk-polar-view.c trunk/src/gtk-polar-view.h trunk/src/gtk-sat-list.c trunk/src/gtk-sat-list.h trunk/src/gtk-sat-map.c trunk/src/gtk-sat-map.h trunk/src/gtk-sat-module-popup.c trunk/src/gtk-sat-module.c trunk/src/gtk-sat-module.h trunk/src/gtk-single-sat.c trunk/src/gtk-single-sat.h Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/ChangeLog 2011-05-01 11:12:02 UTC (rev 818) @@ -1,3 +1,24 @@ +2011-05-01 Alexandru Csete <oz9aec at gmail.com> + + * src/gtk-sat-module-popup.c + * src/gtk-sat-module.c + * src/gtk-sat-module.h + * src/gtk-sat-list.c + * src/gtk-sat-list.h + * src/gtk-single-sat.c + * src/gtk-single-sat.h + * src/gtk-event-list.c + * src/gtk-event-list.h + * src/gtk-sat-map.c + * src/gtk-sat-map.h + * src/gtk-polar-view.c + * src/gtk-polar-view.h + New module menu item to allow selection of a satellite in all views at the + same time. Related to feature request 3179102: Right click on satellite to + add the track (probably the closest we can get to "global selection" without + breaking the design). + + 2011-04-29 Alexandru Csete <oz9aec at gmail.com> * data/desktop/gpredict.desktop.in Modified: trunk/NEWS =================================================================== --- trunk/NEWS 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/NEWS 2011-05-01 11:12:02 UTC (rev 818) @@ -1,5 +1,6 @@ Changes in version 1.4 (TBD) +- New menu item in the module menu for selecting a satellite in all views. - Feature request 3141555: gpsd support. - Feature request 2130926: Change frequency using mouse wheel. Also for rotator controller. - Applied and extended patch 3237220: natural sort for sat list in module config Modified: trunk/src/gtk-event-list.c =================================================================== --- trunk/src/gtk-event-list.c 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-event-list.c 2011-05-01 11:12:02 UTC (rev 818) @@ -2,7 +2,7 @@ /* Gpredict: Real-time satellite tracking and orbit prediction program - Copyright (C) 2001-2009 Alexandru Csete, OZ9AEC. + Copyright (C) 2001-2011 Alexandru Csete, OZ9AEC. Authors: Alexandru Csete <oz...@gm...> @@ -844,3 +844,39 @@ { GTK_EVENT_LIST (evlist)->satellites = sats; } + + +/** \brief Select satellite. */ +void gtk_event_list_select_sat (GtkWidget *widget, gint catnum) +{ + GtkEventList *list; + GtkTreeModel *model; + GtkTreeSelection *selection; + GtkTreeIter iter; + gint i,n; + gint sat; + + + list = GTK_EVENT_LIST(widget); + model = gtk_tree_view_get_model(GTK_TREE_VIEW(list->treeview)); + selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(list->treeview)); + + /* iterate over the satellite list until a amtch is found */ + n = g_hash_table_size(list->satellites); + for (i = 0; i < n; i++) { + + if (gtk_tree_model_iter_nth_child(model, &iter, NULL, i)) { + gtk_tree_model_get(model, &iter, EVENT_LIST_COL_CATNUM, &sat, -1); + if (sat == catnum) { + gtk_tree_selection_select_iter(selection, &iter); + i = n; + } + } + else { + sat_log_log(SAT_LOG_LEVEL_ERROR, + _("%s: GtkEventList has not child with index %d"), + __FUNCTION__, i); + } + } + +} Modified: trunk/src/gtk-event-list.h =================================================================== --- trunk/src/gtk-event-list.h 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-event-list.h 2011-05-01 11:12:02 UTC (rev 818) @@ -2,7 +2,7 @@ /* Gpredict: Real-time satellite tracking and orbit prediction program - Copyright (C) 2001-2009 Alexandru Csete, OZ9AEC. + Copyright (C) 2001-2011 Alexandru Csete, OZ9AEC. Authors: Alexandru Csete <oz...@gm...> @@ -114,8 +114,8 @@ void gtk_event_list_reconf (GtkWidget *widget, GKeyFile *cfgdat); void gtk_event_list_reload_sats (GtkWidget *satlist, GHashTable *sats); +void gtk_event_list_select_sat (GtkWidget *widget, gint catnum); - #ifdef __cplusplus } #endif /* __cplusplus */ Modified: trunk/src/gtk-polar-view.c =================================================================== --- trunk/src/gtk-polar-view.c 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-polar-view.c 2011-05-01 11:12:02 UTC (rev 818) @@ -1616,7 +1616,54 @@ } +/** \brief Select a satellite (puublic) + * + * \todo Current selection is loast when satellite goes LOS + */ +void gtk_polar_view_select_sat (GtkWidget *widget, gint catnum) +{ + GtkPolarView *polv = GTK_POLAR_VIEW(widget); + gint *catpoint = NULL; + sat_obj_t *obj = NULL; + guint32 color; + catpoint = g_try_new0 (gint, 1); + *catpoint = catnum; + + + obj = SAT_OBJ (g_hash_table_lookup (polv->obj, catpoint)); + if (obj == NULL) { + sat_log_log (SAT_LOG_LEVEL_DEBUG, + _("%s Requested satellite (%d) is not within range"), + __FUNCTION__, catnum); + } + else { + obj->selected = TRUE; + + color = mod_cfg_get_int (polv->cfgdata, + MOD_CFG_POLAR_SECTION, + MOD_CFG_POLAR_SAT_SEL_COL, + SAT_CFG_INT_POLAR_SAT_SEL_COL); + + g_object_set (obj->marker, + "fill-color-rgba", color, + "stroke-color-rgba", color, + NULL); + g_object_set (obj->label, + "fill-color-rgba", color, + "stroke-color-rgba", color, + NULL); + + } + + /* clear previous selection, if any */ + g_hash_table_foreach (polv->obj, clear_selection, catpoint); + + g_free (catpoint); + +} + + /** \brief Convert LOS timestamp to human readable countdown string */ static gchar *los_time_to_str (GtkPolarView *polv, sat_t *sat) { Modified: trunk/src/gtk-polar-view.h =================================================================== --- trunk/src/gtk-polar-view.h 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-polar-view.h 2011-05-01 11:12:02 UTC (rev 818) @@ -2,7 +2,7 @@ /* Gpredict: Real-time satellite tracking and orbit prediction program - Copyright (C) 2001-2009 Alexandru Csete, OZ9AEC. + Copyright (C) 2001-2011 Alexandru Csete, OZ9AEC. Authors: Alexandru Csete <oz...@gm...> @@ -154,8 +154,8 @@ void xy_to_azel (GtkPolarView *p, gfloat x, gfloat y, gfloat *az, gfloat *el); void gtk_polar_view_reload_sats (GtkWidget *polv, GHashTable *sats); +void gtk_polar_view_select_sat (GtkWidget *widget, gint catnum); - #ifdef __cplusplus } #endif /* __cplusplus */ Modified: trunk/src/gtk-sat-list.c =================================================================== --- trunk/src/gtk-sat-list.c 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-sat-list.c 2011-05-01 11:12:02 UTC (rev 818) @@ -2,7 +2,7 @@ /* Gpredict: Real-time satellite tracking and orbit prediction program - Copyright (C) 2001-2009 Alexandru Csete, OZ9AEC. + Copyright (C) 2001-2011 Alexandru Csete, OZ9AEC. Authors: Alexandru Csete <oz...@gm...> @@ -1387,3 +1387,38 @@ { GTK_SAT_LIST (satlist)->satellites = sats; } + +/** \brief Select a satellite */ +void gtk_sat_list_select_sat (GtkWidget *satlist, gint catnum) +{ + GtkSatList *slist; + GtkTreeModel *model; + GtkTreeSelection *selection; + GtkTreeIter iter; + gint i,n; + gint sat; + + + slist = GTK_SAT_LIST(satlist); + model = gtk_tree_view_get_model(GTK_TREE_VIEW(slist->treeview)); + selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(slist->treeview)); + + /* iterate over the satellite list until a amtch is found */ + n = g_hash_table_size(slist->satellites); + for (i = 0; i < n; i++) { + + if (gtk_tree_model_iter_nth_child(model, &iter, NULL, i)) { + gtk_tree_model_get(model, &iter, SAT_LIST_COL_CATNUM, &sat, -1); + if (sat == catnum) { + gtk_tree_selection_select_iter(selection, &iter); + i = n; + } + } + else { + sat_log_log(SAT_LOG_LEVEL_ERROR, + _("%s: GtkSatList has not child with index %d"), + __FUNCTION__, i); + } + } + +} Modified: trunk/src/gtk-sat-list.h =================================================================== --- trunk/src/gtk-sat-list.h 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-sat-list.h 2011-05-01 11:12:02 UTC (rev 818) @@ -2,7 +2,7 @@ /* Gpredict: Real-time satellite tracking and orbit prediction program - Copyright (C) 2001-2009 Alexandru Csete, OZ9AEC. + Copyright (C) 2001-2011 Alexandru Csete, OZ9AEC. Authors: Alexandru Csete <oz...@gm...> @@ -152,6 +152,7 @@ void gtk_sat_list_reconf (GtkWidget *widget, GKeyFile *cfgdat); void gtk_sat_list_reload_sats (GtkWidget *satlist, GHashTable *sats); +void gtk_sat_list_select_sat (GtkWidget *satlist, gint catnum); #ifdef __cplusplus Modified: trunk/src/gtk-sat-map.c =================================================================== --- trunk/src/gtk-sat-map.c 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-sat-map.c 2011-05-01 11:12:02 UTC (rev 818) @@ -2,7 +2,7 @@ /* Gpredict: Real-time satellite tracking and orbit prediction program - Copyright (C) 2001-2009 Alexandru Csete, OZ9AEC. + Copyright (C) 2001-2011 Alexandru Csete, OZ9AEC. Copyright (C) 2006-2007 William J Beksi, KC2EXL. Copyright (C) 2011 Charles Suprin, AA1VS. @@ -1066,6 +1066,57 @@ } +/** \brief select a satellite */ +void gtk_sat_map_select_sat (GtkWidget *satmap, gint catnum) +{ + GtkSatMap *smap = GTK_SAT_MAP(satmap); + gint *catpoint = NULL; + sat_map_obj_t *obj = NULL; + guint32 col; + + + catpoint = g_try_new0 (gint, 1); + *catpoint = catnum; + + obj = SAT_MAP_OBJ (g_hash_table_lookup (smap->obj, catpoint)); + if (obj == NULL) { + sat_log_log (SAT_LOG_LEVEL_BUG, + _("%s: Can not find clicked object (%d) in hash table"), + __FUNCTION__, catnum); + } + else { + obj->selected = TRUE; + + col = mod_cfg_get_int (smap->cfgdata, + MOD_CFG_MAP_SECTION, + MOD_CFG_MAP_SAT_SEL_COL, + SAT_CFG_INT_MAP_SAT_SEL_COL); + + g_object_set (obj->marker, + "fill-color-rgba", col, + "stroke-color-rgba", col, + NULL); + g_object_set (obj->label, + "fill-color-rgba", col, + "stroke-color-rgba", col, + NULL); + g_object_set (obj->range1, + "stroke-color-rgba", col, + NULL); + + if (obj->oldrcnum == 2) + g_object_set (obj->range2, + "stroke-color-rgba", col, + NULL); + + /* clear other selections */ + g_hash_table_foreach (smap->obj, clear_selection, catpoint); + } + + g_free (catpoint); + +} + /** \brief Reconfigure map. * * This function should eventually reload all configuration for the GtkSatMap. Modified: trunk/src/gtk-sat-map.h =================================================================== --- trunk/src/gtk-sat-map.h 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-sat-map.h 2011-05-01 11:12:02 UTC (rev 818) @@ -2,7 +2,7 @@ /* Gpredict: Real-time satellite tracking and orbit prediction program - Copyright (C) 2001-2009 Alexandru Csete, OZ9AEC. + Copyright (C) 2001-2011 Alexandru Csete, OZ9AEC. Copyright (C) 2006-2007 William J Beksi, KC2EXL. Authors: Alexandru Csete <oz...@gm...> @@ -182,6 +182,7 @@ gdouble *x, gdouble *y); void gtk_sat_map_reload_sats (GtkWidget *satmap, GHashTable *sats); +void gtk_sat_map_select_sat (GtkWidget *satmap, gint catnum); #ifdef __cplusplus } Modified: trunk/src/gtk-sat-module-popup.c =================================================================== --- trunk/src/gtk-sat-module-popup.c 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-sat-module-popup.c 2011-05-01 11:12:02 UTC (rev 818) @@ -53,6 +53,7 @@ static void clone_cb (GtkWidget *menuitem, gpointer data); static void docking_state_cb (GtkWidget *menuitem, gpointer data); static void screen_state_cb (GtkWidget *menuitem, gpointer data); +static void sat_selected_cb (GtkWidget *menuitem, gpointer data); static void sky_at_glance_cb (GtkWidget *menuitem, gpointer data); static void tmgr_cb (GtkWidget *menuitem, gpointer data); static void rigctrl_cb (GtkWidget *menuitem, gpointer data); @@ -78,10 +79,16 @@ */ void gtk_sat_module_popup (GtkSatModule *module) { - GtkWidget *menu; - GtkWidget *menuitem; - GtkWidget *image; - gchar *buff; + GtkWidget *menu; /* The pop-up menu */ + GtkWidget *satsubmenu; /* Satellite selection submenu */ + GtkWidget *menuitem; /* Widget used to create the menu items */ + GtkWidget *image; /* Widget used to create menu item icons */ + + /* misc variables */ + GList *sats; + sat_t *sat; + gchar *buff; + guint i,n; @@ -143,6 +150,27 @@ menuitem = gtk_separator_menu_item_new (); gtk_menu_shell_append (GTK_MENU_SHELL(menu), menuitem); + /* select satellite submenu */ + menuitem = gtk_menu_item_new_with_label(_("Select satellite")); + gtk_menu_shell_append(GTK_MENU_SHELL(menu), menuitem); + + satsubmenu = gtk_menu_new(); + gtk_menu_item_set_submenu(GTK_MENU_ITEM(menuitem), satsubmenu); + + sats = g_hash_table_get_values(module->satellites); // FIXME: sort list + n = g_list_length(sats); + for (i = 0; i < n; i++) { + sat = SAT(g_list_nth_data(sats, i)); + menuitem = gtk_menu_item_new_with_label(sat->nickname); + g_object_set_data(G_OBJECT(menuitem), "catnum", GINT_TO_POINTER(sat->tle.catnr)); + g_signal_connect(menuitem, "activate", G_CALLBACK (sat_selected_cb), module); + gtk_menu_shell_append(GTK_MENU_SHELL(satsubmenu), menuitem); + } + + /* separator */ + menuitem = gtk_separator_menu_item_new (); + gtk_menu_shell_append (GTK_MENU_SHELL(menu), menuitem); + /* sky at a glance */ menuitem = gtk_image_menu_item_new_with_label (_("Sky at a glance")); buff = icon_file_name ("gpredict-planner-small.png"); @@ -747,6 +775,23 @@ } +/** \brief New satellite selected. + * \param data Pointer to the GtkSatModule widget + * + * This menu item is activated when a new satellite is selected in the + * "Select satellite" submenu of the module pop-up. This will trigger a call + * to the select_sat() fuinction of the module, which in turn will call the + * select_sat() function of each child view. + * + * The catalog number of the selected satellite is attached to the menu item + */ +static void sat_selected_cb (GtkWidget *menuitem, gpointer data) +{ + gint catnum = GPOINTER_TO_INT(g_object_get_data(G_OBJECT(menuitem), "catnum")); + GtkSatModule *module = GTK_SAT_MODULE(data); + + gtk_sat_module_select_sat(module, catnum); +} /** \brief Invoke Sky-at-glance. * Modified: trunk/src/gtk-sat-module.c =================================================================== --- trunk/src/gtk-sat-module.c 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-sat-module.c 2011-05-01 11:12:02 UTC (rev 818) @@ -1460,6 +1460,42 @@ } +/** \brief Select a new satellite */ +void gtk_sat_module_select_sat (GtkSatModule *module, gint catnum) +{ + GtkWidget *child; + gint i; + + + /* select satellite in each child */ + for (i = 0; i < module->nviews; i++) { + + child = GTK_WIDGET (g_slist_nth_data (module->views, i)); + + if (IS_GTK_SINGLE_SAT (G_OBJECT (child))) { + gtk_single_sat_select_sat(child, catnum); + } + else if (IS_GTK_SAT_MAP (child)) { + gtk_sat_map_select_sat(child, catnum); + } + else if (IS_GTK_SAT_LIST (child)) { + gtk_sat_list_select_sat(child, catnum); + } + else if (IS_GTK_EVENT_LIST (child)) { + gtk_event_list_select_sat(child, catnum); + } + else if (IS_GTK_POLAR_VIEW (child)) { + gtk_polar_view_select_sat(child, catnum); + } + else { + sat_log_log(SAT_LOG_LEVEL_BUG, _("%s: Unknown child type"), __FUNCTION__); + } + } + +} + + + /** \brief Re-configure module. * \param module The module. * \param local Flag indicating whether reconfiguration is requested from Modified: trunk/src/gtk-sat-module.h =================================================================== --- trunk/src/gtk-sat-module.h 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-sat-module.h 2011-05-01 11:12:02 UTC (rev 818) @@ -174,6 +174,7 @@ void gtk_sat_module_reload_sats (GtkSatModule *module); void gtk_sat_module_reconf (GtkSatModule *module, gboolean local); +void gtk_sat_module_select_sat (GtkSatModule *module, gint catnum); void gtk_sat_module_fix_size (GtkWidget *module); Modified: trunk/src/gtk-single-sat.c =================================================================== --- trunk/src/gtk-single-sat.c 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-single-sat.c 2011-05-01 11:12:02 UTC (rev 818) @@ -325,11 +325,48 @@ } +/** \brief Select new satellite */ +void gtk_single_sat_select_sat (GtkWidget *single_sat, gint catnum) +{ + GtkSingleSat *ssat = GTK_SINGLE_SAT(single_sat); + sat_t *sat = NULL; + gchar *title; + gboolean foundsat = FALSE; + gint i,n; + + /* find satellite with catnum */ + n = g_slist_length (ssat->sats); + for (i = 0; i < n; i++) { + sat = SAT(g_slist_nth_data(ssat->sats, i)); + if (sat->tle.catnr == catnum) { + /* found satellite */ + ssat->selected = i; + foundsat = TRUE; + /* exit loop */ + i = n; + } + } + + if (!foundsat) { + sat_log_log(SAT_LOG_LEVEL_ERROR, + _("%s: Could not find satellite with catalog number %d"), + __FUNCTION__, catnum); + return; + } + + title = g_strdup_printf ("<b>%s</b>", sat->nickname); + gtk_label_set_markup (GTK_LABEL (ssat->header), title); + g_free (title); + +} + + + /** \brief Update satellites */ void gtk_single_sat_update (GtkWidget *widget) Modified: trunk/src/gtk-single-sat.h =================================================================== --- trunk/src/gtk-single-sat.h 2011-04-29 18:28:15 UTC (rev 817) +++ trunk/src/gtk-single-sat.h 2011-05-01 11:12:02 UTC (rev 818) @@ -2,7 +2,7 @@ /* Gpredict: Real-time satellite tracking and orbit prediction program - Copyright (C) 2001-2009 Alexandru Csete, OZ9AEC. + Copyright (C) 2001-2011 Alexandru Csete, OZ9AEC. Authors: Alexandru Csete <oz...@gm...> @@ -166,8 +166,8 @@ void gtk_single_sat_reload_sats (GtkWidget *single_sat, GHashTable *sats); +void gtk_single_sat_select_sat (GtkWidget *single_sat, gint catnum); - #ifdef __cplusplus } #endif /* __cplusplus */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-05-14 12:43:22
|
Revision: 819 http://gpredict.svn.sourceforge.net/gpredict/?rev=819&view=rev Author: aa1vs Date: 2011-05-14 12:43:16 +0000 (Sat, 14 May 2011) Log Message: ----------- Update NOAA-15,-16, and -17 transponder frequencies. Modified Paths: -------------- trunk/ChangeLog trunk/data/trsp/25338.trsp trunk/data/trsp/26536.trsp trunk/data/trsp/27453.trsp Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-05-01 11:12:02 UTC (rev 818) +++ trunk/ChangeLog 2011-05-14 12:43:16 UTC (rev 819) @@ -1,3 +1,10 @@ +2011-05-14 Charles Suprin <hamaa1vs at gmail.com> + + * data/trsp/25338.trsp + * data/trsp/26536.trsp + * data/trsp/27543.trsp + Update NOAA-15,-16,-17 transponder frequencies. + 2011-05-01 Alexandru Csete <oz9aec at gmail.com> * src/gtk-sat-module-popup.c Modified: trunk/data/trsp/25338.trsp =================================================================== --- trunk/data/trsp/25338.trsp 2011-05-01 11:12:02 UTC (rev 818) +++ trunk/data/trsp/25338.trsp 2011-05-14 12:43:16 UTC (rev 819) @@ -1,5 +1,5 @@ [APT] -DOWN_LOW=137500000 +DOWN_LOW=137620000 [HRPT] DOWN_LOW=1702500000 Modified: trunk/data/trsp/26536.trsp =================================================================== --- trunk/data/trsp/26536.trsp 2011-05-01 11:12:02 UTC (rev 818) +++ trunk/data/trsp/26536.trsp 2011-05-14 12:43:16 UTC (rev 819) @@ -1,3 +1,3 @@ [HRPT] -DOWN_LOW=1702500000 +DOWN_LOW=1698000000 Modified: trunk/data/trsp/27453.trsp =================================================================== --- trunk/data/trsp/27453.trsp 2011-05-01 11:12:02 UTC (rev 818) +++ trunk/data/trsp/27453.trsp 2011-05-14 12:43:16 UTC (rev 819) @@ -1,5 +1,5 @@ [APT] -DOWN_LOW=137620000 +DOWN_LOW=137500000 [HRPT] DOWN_LOW=1698000000 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-06-04 21:23:17
|
Revision: 828 http://gpredict.svn.sourceforge.net/gpredict/?rev=828&view=rev Author: aa1vs Date: 2011-06-04 21:23:11 +0000 (Sat, 04 Jun 2011) Log Message: ----------- Reset satellite when reseting NAOS in sat-map and polar views. Modified Paths: -------------- trunk/ChangeLog trunk/src/gtk-polar-view.c trunk/src/gtk-sat-map.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-05-30 11:16:51 UTC (rev 827) +++ trunk/ChangeLog 2011-06-04 21:23:11 UTC (rev 828) @@ -1,3 +1,9 @@ +2011-06-04 Charles Suprin <hamaa1vs at gmail.com> + + * src/gtk-sat-map.c + * src/gtk-polar-view.c + Reset satellite when reseting NAOS in sat-map and polar views. + 2011-05-31 Charles Suprin <hamaa1vs at gmail.com> * src/sgpsdp/sgp_time.c Modified: trunk/src/gtk-polar-view.c =================================================================== --- trunk/src/gtk-polar-view.c 2011-05-30 11:16:51 UTC (rev 827) +++ trunk/src/gtk-polar-view.c 2011-06-04 21:23:11 UTC (rev 828) @@ -694,6 +694,7 @@ /* reset data */ polv->counter = 1; polv->naos = 2458849.5; + polv->ncat = 0; /* update sats */ g_hash_table_foreach (polv->sats, update_sat, polv); Modified: trunk/src/gtk-sat-map.c =================================================================== --- trunk/src/gtk-sat-map.c 2011-05-30 11:16:51 UTC (rev 827) +++ trunk/src/gtk-sat-map.c 2011-06-04 21:23:11 UTC (rev 828) @@ -657,6 +657,7 @@ /* reset data */ satmap->counter = 1; satmap->naos = 2458849.5; + satmap->ncat = 0; /* QTH */ /*update for accuracy*/ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <cs...@us...> - 2011-06-05 17:29:38
|
Revision: 830 http://gpredict.svn.sourceforge.net/gpredict/?rev=830&view=rev Author: csete Date: 2011-06-05 17:29:32 +0000 (Sun, 05 Jun 2011) Log Message: ----------- Add TX cycle function for full duplex radios. Fixes bug 3272993: Issue controlling Yaesu FT-847. Modified Paths: -------------- trunk/ChangeLog trunk/NEWS trunk/src/gtk-rig-ctrl.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-06-04 23:37:21 UTC (rev 829) +++ trunk/ChangeLog 2011-06-05 17:29:32 UTC (rev 830) @@ -1,3 +1,10 @@ +2011-06-05 Alexandru Csete <oz9aec at gmail.com> + + * src/gtk-rig-ctrl.c: + Add TX cycle function for full duplex radios. + Fixes bug 3272993: Issue controlling Yaesu FT-847. + + 2011-06-04 Alexandru Csete <oz9aec at gmail.com> * src/gtk-rig-ctrl.c: Modified: trunk/NEWS =================================================================== --- trunk/NEWS 2011-06-04 23:37:21 UTC (rev 829) +++ trunk/NEWS 2011-06-05 17:29:32 UTC (rev 830) @@ -8,6 +8,7 @@ - Fixed bug 3250344: Win32 build not working with hamlib. - Fixed bug 3294829: Program name wrong in desktop files. - Fixed bug 3309110: 100% on manual time adjustment. +- Fixed bug 3272993: Issue controlling Yaesu FT-847. Changes in version 1.3 (1 Mar 2011) Modified: trunk/src/gtk-rig-ctrl.c =================================================================== --- trunk/src/gtk-rig-ctrl.c 2011-06-04 23:37:21 UTC (rev 829) +++ trunk/src/gtk-rig-ctrl.c 2011-06-05 17:29:32 UTC (rev 830) @@ -108,6 +108,7 @@ static void exec_toggle_cycle (GtkRigCtrl *ctrl); static void exec_toggle_tx_cycle (GtkRigCtrl *ctrl); static void exec_duplex_cycle (GtkRigCtrl *ctrl); +static void exec_duplex_tx_cycle(GtkRigCtrl *ctrl); static void exec_dual_rig_cycle (GtkRigCtrl *ctrl); static gboolean set_freq_simplex (GtkRigCtrl *ctrl, gint sock, gdouble freq); static gboolean get_freq_simplex (GtkRigCtrl *ctrl, gint sock, gdouble *freq); @@ -1755,6 +1756,110 @@ } +/** \brief Execute TX cycle for full duplex radios. + * \param ctrl Pointer to the GtkRigCtrl structure. + * + * This is basically the same as exec_tx_cycle() except that there is no + * check for PTT since for full duplex radios we can always control the + * uplink frequency. + */ +static void exec_duplex_tx_cycle(GtkRigCtrl *ctrl) +{ + gdouble readfreq=0.0, tmpfreq, satfreqd, satfrequ; + gboolean dialchanged = FALSE; + + + /* Dial feedback: + If radio device is engaged read frequency from radio and compare it to the + last set frequency. If different, it means that user has changed frequency + on the radio dial => update transponder knob + + Note: If ctrl->lasttxf = 0.0 the sync has been invalidated (e.g. user pressed "tune") + and no need to execute the dial feedback. + */ + if ((ctrl->engaged) && (ctrl->lasttxf > 0.0)) { + + + if (!get_freq_toggle (ctrl, ctrl->sock, &readfreq)) { + /* error => use a passive value */ + readfreq = ctrl->lasttxf; + ctrl->errcnt++; + } + + if (fabs (readfreq - ctrl->lasttxf) >= 1.0) { + dialchanged = TRUE; + + /* user might have altered radio frequency => update transponder knob */ + gtk_freq_knob_set_value (GTK_FREQ_KNOB (ctrl->RigFreqUp), readfreq); + ctrl->lasttxf = readfreq; + + /* doppler shift; only if we are tracking */ + if (ctrl->tracking) { + satfrequ = readfreq - ctrl->du + ctrl->conf->loup; + } + else { + satfrequ = readfreq + ctrl->conf->loup; + } + gtk_freq_knob_set_value (GTK_FREQ_KNOB (ctrl->SatFreqUp), satfrequ); + + /* Follow with downlink if transponder is locked */ + if (ctrl->trsplock) { + track_uplink (ctrl); + } + } + } + + /* now, forward tracking */ + if (dialchanged) { + /* no need to forward track */ + return; + } + + /* If we are tracking, calculate the radio freq by applying both dopper shift + and tranverter LO frequency. If we are not tracking, apply only LO frequency. + */ + satfreqd = gtk_freq_knob_get_value (GTK_FREQ_KNOB (ctrl->SatFreqDown)); + satfrequ = gtk_freq_knob_get_value (GTK_FREQ_KNOB (ctrl->SatFreqUp)); + if (ctrl->tracking) { + /* downlink */ + gtk_freq_knob_set_value (GTK_FREQ_KNOB (ctrl->RigFreqDown), + satfreqd + ctrl->dd - ctrl->conf->lo); + /* uplink */ + gtk_freq_knob_set_value (GTK_FREQ_KNOB (ctrl->RigFreqUp), + satfrequ + ctrl->du - ctrl->conf->loup); + } + else { + gtk_freq_knob_set_value (GTK_FREQ_KNOB (ctrl->RigFreqDown), + satfreqd - ctrl->conf->lo); + gtk_freq_knob_set_value (GTK_FREQ_KNOB (ctrl->RigFreqUp), + satfrequ - ctrl->conf->loup); + } + + tmpfreq = gtk_freq_knob_get_value(GTK_FREQ_KNOB(ctrl->RigFreqUp)); + + /* if device is engaged, send freq command to radio */ + if ((ctrl->engaged) && (fabs(ctrl->lasttxf - tmpfreq) >= 1.0)) { + if (set_freq_toggle (ctrl, ctrl->sock, tmpfreq)) { + /* reset error counter */ + ctrl->errcnt = 0; + + /* give radio a chance to set frequency */ + g_usleep (WR_DEL); + + /* The actual frequency migh be different from what we have set because + the tuning step is larger than what we work with (e.g. FT-817 has a + smallest tuning step of 10 Hz). Therefore we read back the actual + frequency from the rig. */ + get_freq_toggle (ctrl, ctrl->sock, &tmpfreq); + ctrl->lasttxf = tmpfreq; + } + else { + ctrl->errcnt++; + } + } + +} + /** \brief Execute duplex mode cycle. * \param ctrl Pointer to the GtkRigCtrl widget. * @@ -1763,20 +1868,11 @@ */ static void exec_duplex_cycle (GtkRigCtrl *ctrl) { - if (ctrl->engaged) { - exec_rx_cycle (ctrl); - exec_toggle_tx_cycle (ctrl); - } - else { - /* still execute cycles to update UI widgets - * no data will be sent to RIG */ - exec_rx_cycle (ctrl); - /* toggle_tx does nothing when not engaged - * (was originally written for FT-817-like rigs) */ - exec_tx_cycle (ctrl); - } + exec_rx_cycle (ctrl); + exec_duplex_tx_cycle (ctrl); } + /** \brief Execute dual-rig cycle. * \param ctrl Pointer to the GtkRigCtrl widget. * This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-06-08 02:22:10
|
Revision: 831 http://gpredict.svn.sourceforge.net/gpredict/?rev=831&view=rev Author: aa1vs Date: 2011-06-08 02:22:04 +0000 (Wed, 08 Jun 2011) Log Message: ----------- Remove decayed satellites from polar view. Modified Paths: -------------- trunk/ChangeLog trunk/src/gtk-polar-view.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-06-05 17:29:32 UTC (rev 830) +++ trunk/ChangeLog 2011-06-08 02:22:04 UTC (rev 831) @@ -1,3 +1,9 @@ +2011-06-07 Charles Suprin <hamaa1vs at gmail.com> + + * src/gtk-polar-view.c: + Remove decayed satellites from polar view. + + 2011-06-05 Alexandru Csete <oz9aec at gmail.com> * src/gtk-rig-ctrl.c: Modified: trunk/src/gtk-polar-view.c =================================================================== --- trunk/src/gtk-polar-view.c 2011-06-05 17:29:32 UTC (rev 830) +++ trunk/src/gtk-polar-view.c 2011-06-08 02:22:04 UTC (rev 831) @@ -793,7 +793,7 @@ } /* if sat is out of range */ - if (sat->el < 0.00) { + if ((sat->el < 0.00) || decayed(sat)) { obj = SAT_OBJ(g_hash_table_lookup (polv->obj, catnum)); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-06-20 13:07:51
|
Revision: 833 http://gpredict.svn.sourceforge.net/gpredict/?rev=833&view=rev Author: aa1vs Date: 2011-06-20 13:07:45 +0000 (Mon, 20 Jun 2011) Log Message: ----------- Change naos logic to avoid a daynum 2458849.5 (Y2021?) problem. Modified Paths: -------------- trunk/ChangeLog trunk/src/gtk-polar-view.c trunk/src/gtk-sat-map.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-06-19 13:00:23 UTC (rev 832) +++ trunk/ChangeLog 2011-06-20 13:07:45 UTC (rev 833) @@ -1,3 +1,10 @@ +2011-06-20 Charles Suprin <hamaa1vs at gmail.com> + + * src/gtk-sat-map.c + * src/gtk-polar-view.c + Change naos logic to avoid a daynum 2458849.5 (Y2021?) problem. + + 2011-06-19 Charles Suprin <hamaa1vs at gmail.com> * src/gtk-sat-map.c Modified: trunk/src/gtk-polar-view.c =================================================================== --- trunk/src/gtk-polar-view.c 2011-06-19 13:00:23 UTC (rev 832) +++ trunk/src/gtk-polar-view.c 2011-06-20 13:07:45 UTC (rev 833) @@ -150,7 +150,7 @@ polview->sats = NULL; polview->qth = NULL; polview->obj = NULL; - polview->naos = 2458849.5; + polview->naos = 0.0; polview->ncat = 0; polview->size = 0; polview->r = 0; @@ -693,7 +693,7 @@ else { /* reset data */ polv->counter = 1; - polv->naos = 2458849.5; + polv->naos = 0.0; polv->ncat = 0; /* update sats */ @@ -787,9 +787,11 @@ now = polv->tstamp; /* update next AOS */ - if ((sat->aos > now) && (sat->aos < polv->naos)) { - polv->naos = sat->aos; - polv->ncat = sat->tle.catnr; + if (sat->aos > now) { + if ((sat->aos < polv->naos)|| (polv->naos == 0.0)) { + polv->naos = sat->aos; + polv->ncat = sat->tle.catnr; + } } /* if sat is out of range */ Modified: trunk/src/gtk-sat-map.c =================================================================== --- trunk/src/gtk-sat-map.c 2011-06-19 13:00:23 UTC (rev 832) +++ trunk/src/gtk-sat-map.c 2011-06-20 13:07:45 UTC (rev 833) @@ -170,7 +170,7 @@ satmap->sats = NULL; satmap->qth = NULL; satmap->obj = NULL; - satmap->naos = 2458849.5; + satmap->naos = 0.0; satmap->ncat = 0; satmap->tstamp = 2458849.5; satmap->x0 = 0; @@ -656,7 +656,7 @@ else { /* reset data */ satmap->counter = 1; - satmap->naos = 2458849.5; + satmap->naos = 0.0; satmap->ncat = 0; /* QTH */ @@ -1934,9 +1934,11 @@ now = satmap->tstamp; /* update next AOS */ - if ((sat->aos > now) && (sat->aos < satmap->naos)) { - satmap->naos = sat->aos; - satmap->ncat = sat->tle.catnr; + if (sat->aos > now) { + if ((sat->aos < satmap->naos)|| (satmap->naos == 0.0)) { + satmap->naos = sat->aos; + satmap->ncat = sat->tle.catnr; + } } obj = SAT_MAP_OBJ (g_hash_table_lookup (satmap->obj, catnum)); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-06-20 21:12:49
|
Revision: 834 http://gpredict.svn.sourceforge.net/gpredict/?rev=834&view=rev Author: aa1vs Date: 2011-06-20 21:12:43 +0000 (Mon, 20 Jun 2011) Log Message: ----------- Move log closing and module saving until after gtk has shutdown. Modified Paths: -------------- trunk/ChangeLog trunk/src/main.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-06-20 13:07:45 UTC (rev 833) +++ trunk/ChangeLog 2011-06-20 21:12:43 UTC (rev 834) @@ -4,7 +4,10 @@ * src/gtk-polar-view.c Change naos logic to avoid a daynum 2458849.5 (Y2021?) problem. + * src/main.c + Move log closing and module saving until after gtk has shut down. + 2011-06-19 Charles Suprin <hamaa1vs at gmail.com> * src/gtk-sat-map.c Modified: trunk/src/main.c =================================================================== --- trunk/src/main.c 2011-06-20 13:07:45 UTC (rev 833) +++ trunk/src/main.c 2011-06-20 21:12:43 UTC (rev 834) @@ -184,7 +184,14 @@ gtk_main (); - g_option_context_free(context); + g_option_context_free(context); + + sat_cfg_save (); + sat_log_close (); + sat_cfg_close (); + + + #ifdef WIN32 // Cleanup Windozze Sockets CloseWinSock2(); @@ -368,9 +375,6 @@ sat_cfg_set_int (SAT_CFG_INT_WINDOW_WIDTH, w); sat_cfg_set_int (SAT_CFG_INT_WINDOW_HEIGHT, h); */ - sat_cfg_save (); - sat_log_close (); - sat_cfg_close (); /* exit Gtk+ */ gtk_main_quit (); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-06-26 03:58:14
|
Revision: 835 http://gpredict.svn.sourceforge.net/gpredict/?rev=835&view=rev Author: aa1vs Date: 2011-06-26 03:58:08 +0000 (Sun, 26 Jun 2011) Log Message: ----------- Add support for gpsd 2.96 and cleanup comments. Modified Paths: -------------- trunk/ChangeLog trunk/src/qth-data.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-06-20 21:12:43 UTC (rev 834) +++ trunk/ChangeLog 2011-06-26 03:58:08 UTC (rev 835) @@ -1,3 +1,9 @@ +2011-06-25 Charles Suprin <hamaa1vs at gmail.com> + + * src/qth-data.c + Add support for gpsd 2.96 and cleanup comments. + + 2011-06-20 Charles Suprin <hamaa1vs at gmail.com> * src/gtk-sat-map.c Modified: trunk/src/qth-data.c =================================================================== --- trunk/src/qth-data.c 2011-06-20 21:12:43 UTC (rev 834) +++ trunk/src/qth-data.c 2011-06-26 03:58:08 UTC (rev 835) @@ -227,7 +227,7 @@ qth->type = QTH_STATIC_TYPE; } - /*GPSD Port*/ + /* GPSD Port */ qth->gpsd_port = g_key_file_get_integer (qth->data, QTH_CFG_MAIN_SECTION, QTH_CFG_GPSD_PORT_KEY, @@ -361,7 +361,7 @@ QTH_CFG_GPSD_SERVER_KEY, qth->gpsd_server); } - /*gpsd port*/ + /* gpsd port */ g_key_file_set_integer (qth->data, QTH_CFG_MAIN_SECTION, QTH_CFG_GPSD_PORT_KEY, @@ -442,7 +442,7 @@ void qth_data_free (qth_t *qth) { - /*stop any updating*/ + /* stop any updating */ qth_data_update_stop(qth); if (qth->name) { @@ -484,14 +484,16 @@ */ gboolean qth_data_update(qth_t * qth, gdouble t) { gboolean retval = FALSE; +#ifdef HAS_LIBGPS guint num_loops=0; +#endif switch (qth->type) { case QTH_STATIC_TYPE: - /*never changes*/ + /* never changes */ break; case QTH_GPSD_TYPE: if (((t-qth->gpsd_update)>30.0/86400.0)&&(t-qth->gpsd_connected>30.0/86400.0)){ - /*if needed restart the gpsd interface*/ + /* if needed restart the gpsd interface */ qth_data_update_stop(qth); qth_data_update_init(qth); qth->gpsd_connected=t; @@ -515,8 +517,8 @@ break; } if(gps_poll(qth->gps_data) == 0){ - /*handling packet_set inline with - http://gpsd.berlios.de/client-howto.html + /* handling packet_set inline with + http://gpsd.berlios.de/client-howto.html */ if (qth->gps_data->set&PACKET_SET) { if (qth->gps_data->fix.mode >= MODE_2D) { @@ -548,17 +550,17 @@ break; case 5: #if GPSD_API_MAJOR_VERSION==5 - while(gps_waiting(qth->gps_data) == 1) { - /*see comment from above*/ - /*hopefully not needed but does not hurt anything.*/ + while(gps_waiting(qth->gps_data,0) == 1) { + /* see comment from above */ + /* hopefully not needed but does not hurt anything. */ num_loops++; if (num_loops>1000){ retval=FALSE; break; } if(gps_read(qth->gps_data) == 0){ - /*handling packet_set inline with - http://gpsd.berlios.de/client-howto.html + /* handling packet_set inline with + http://gpsd.berlios.de/client-howto.html */ if (qth->gps_data->set&PACKET_SET) { if (qth->gps_data->fix.mode >= MODE_2D) { @@ -600,7 +602,7 @@ default: break; } - /*check that data is valid*/ + /* check that data is valid */ qth_validate(qth); return retval; } @@ -618,7 +620,7 @@ switch (qth->type){ case QTH_STATIC_TYPE: - /*nothing to do. the data never updates*/ + /* nothing to do. the data never updates */ break; case QTH_GPSD_TYPE: #ifdef HAS_LIBGPS @@ -690,7 +692,7 @@ void qth_data_update_stop (qth_t *qth) { switch (qth->type) { case QTH_STATIC_TYPE: - /*nothing to do. the data never updates*/ + /* nothing to do. the data never updates */ break; case QTH_GPSD_TYPE: @@ -763,7 +765,7 @@ * \param qth the qth data structure to cleanup */ void qth_validate(qth_t*qth){ - /*check that the values are not set to nonsense such as nan or inf. if so error it and set to zero.*/ + /* check that the values are not set to nonsense such as nan or inf. if so error it and set to zero. */ if (!isnormal(qth->lat)){ sat_log_log (SAT_LOG_LEVEL_ERROR, _("%s: QTH data had bogus lat %f"), @@ -784,7 +786,8 @@ qth->alt=0.0; } - /*check that qth->lat and qth->lon are in a reasonable range and if not wrap them back*/ + /* check that qth->lat and qth->lon are in a reasonable range + and if not wrap them back */ if (fabs(qth->lat)>90.0||fabs(qth->lon)>180.0) { sat_log_log (SAT_LOG_LEVEL_ERROR, _("%s: File contained bogus QTH data. Correcting: %s, %.4f, %.4f, %d"), This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-07-02 15:51:50
|
Revision: 838 http://gpredict.svn.sourceforge.net/gpredict/?rev=838&view=rev Author: aa1vs Date: 2011-07-02 15:51:44 +0000 (Sat, 02 Jul 2011) Log Message: ----------- Add check on satellite map object allocation. Modified Paths: -------------- trunk/ChangeLog trunk/src/gtk-sat-map.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-06-30 01:45:58 UTC (rev 837) +++ trunk/ChangeLog 2011-07-02 15:51:44 UTC (rev 838) @@ -1,5 +1,11 @@ 2011-06-29 Charles Suprin <hamaa1vs at gmail.com> + * src/gtk-sat-map.c + Add check on satellite map object allocation. + + +2011-06-29 Charles Suprin <hamaa1vs at gmail.com> + * src/tle-update.c Fix SEGFAULT in tle-update.c when unable to open file for writing in network updates. Modified: trunk/src/gtk-sat-map.c =================================================================== --- trunk/src/gtk-sat-map.c 2011-06-30 01:45:58 UTC (rev 837) +++ trunk/src/gtk-sat-map.c 2011-07-02 15:51:44 UTC (rev 838) @@ -1775,6 +1775,13 @@ /* create and initialize a sat object */ obj = g_try_new (sat_map_obj_t, 1); + if ( obj == NULL ) { + sat_log_log (SAT_LOG_LEVEL_ERROR, + _("%s: Cannot allocate memory for satellite %d."), + __FUNCTION__, sat->tle.catnr); + return; + } + obj->selected = FALSE; obj->showtrack = FALSE; obj->showcov = TRUE; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-07-03 14:05:29
|
Revision: 840 http://gpredict.svn.sourceforge.net/gpredict/?rev=840&view=rev Author: aa1vs Date: 2011-07-03 14:05:23 +0000 (Sun, 03 Jul 2011) Log Message: ----------- Show catalog number in satellite selector. Modified Paths: -------------- trunk/ChangeLog trunk/NEWS trunk/src/gtk-sat-selector.c trunk/src/gtk-sat-selector.h trunk/src/mod-cfg.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-07-02 19:55:16 UTC (rev 839) +++ trunk/ChangeLog 2011-07-03 14:05:23 UTC (rev 840) @@ -1,5 +1,13 @@ -2011-06-29 Charles Suprin <hamaa1vs at gmail.com> +2011-07-03 Charles Suprin <hamaa1vs at gmail.com> + * src/gtk-sat-selector.c + * src/gtk-sat-selector.h + * src/mod-cfg.c + Show catalog number in satellite selector. + Address 3322786: Show More Information in Edit Module Sat Selection. + +2011-07-01 Charles Suprin <hamaa1vs at gmail.com> + * src/gtk-sat-map.c Add check on satellite map object allocation. Modified: trunk/NEWS =================================================================== --- trunk/NEWS 2011-07-02 19:55:16 UTC (rev 839) +++ trunk/NEWS 2011-07-03 14:05:23 UTC (rev 840) @@ -3,6 +3,7 @@ - New menu item in the module menu for selecting a satellite in all views. - Feature request 3141555: gpsd support. - Feature request 2130926: Change frequency using mouse wheel. Also for rotator controller. +- Feature request 3322786: Show More Information in Edit Module Sat Selection. - Applied and extended patch 3237220: natural sort for sat list in module config - Improve handling of decayed satellites. - Fixed bug 3250344: Win32 build not working with hamlib. Modified: trunk/src/gtk-sat-selector.c =================================================================== --- trunk/src/gtk-sat-selector.c 2011-07-02 19:55:16 UTC (rev 839) +++ trunk/src/gtk-sat-selector.c 2011-07-03 14:05:23 UTC (rev 840) @@ -916,18 +916,28 @@ { const gchar *searchstring; gchar *satname; + gint catnr; + gchar *catnrstr; gboolean selected; - + gboolean retval = FALSE; + gtk_tree_model_get( model, iter, GTK_SAT_SELECTOR_COL_NAME, &satname, -1 ); + gtk_tree_model_get( model, iter, GTK_SAT_SELECTOR_COL_CATNUM, &catnr, -1 ); gtk_tree_model_get( model, iter, GTK_SAT_SELECTOR_COL_SELECTED, &selected, -1 ); searchstring = gtk_entry_get_text( entry ); + catnrstr = g_strdup_printf("%d",catnr); + //printf("satname %s catnr %s searchstring %s\n",satname,catnrstr,searchstring); /*if it is already selected then remove it from the available list*/ if (selected) - return( FALSE); - if( gpredict_strcasestr( satname, searchstring ) != (char *)NULL ) - return( TRUE ); - else - return( FALSE ); + retval = FALSE; + else if( gpredict_strcasestr( satname, searchstring ) != (char *)NULL ) + retval = TRUE; + else if( gpredict_strcasestr( catnrstr, searchstring ) != (char *)NULL ) + retval = TRUE; + + g_free (catnrstr); + return (retval); + } /** \brief Searches through all the models for the given satellite and sets its selected value. Modified: trunk/src/gtk-sat-selector.h =================================================================== --- trunk/src/gtk-sat-selector.h 2011-07-02 19:55:16 UTC (rev 839) +++ trunk/src/gtk-sat-selector.h 2011-07-03 14:05:23 UTC (rev 840) @@ -57,7 +57,7 @@ -#define GTK_SAT_SELECTOR_DEFAULT_FLAGS (GTK_SAT_SELECTOR_FLAG_NAME | GTK_SAT_SELECTOR_COL_CATNUM) +#define GTK_SAT_SELECTOR_DEFAULT_FLAGS (GTK_SAT_SELECTOR_FLAG_NAME | GTK_SAT_SELECTOR_FLAG_CATNUM) #define GTK_TYPE_SAT_SELECTOR (gtk_sat_selector_get_type ()) Modified: trunk/src/mod-cfg.c =================================================================== --- trunk/src/mod-cfg.c 2011-07-02 19:55:16 UTC (rev 839) +++ trunk/src/mod-cfg.c 2011-07-03 14:05:23 UTC (rev 840) @@ -623,7 +623,7 @@ "text", GTK_SAT_SELECTOR_COL_CATNUM, NULL); gtk_tree_view_insert_column (GTK_TREE_VIEW (satlist), column, -1); - gtk_tree_view_column_set_visible (column, FALSE); + gtk_tree_view_column_set_visible (column, TRUE); /* epoch */ renderer = gtk_cell_renderer_text_new (); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-07-08 02:10:38
|
Revision: 843 http://gpredict.svn.sourceforge.net/gpredict/?rev=843&view=rev Author: aa1vs Date: 2011-07-08 02:10:32 +0000 (Fri, 08 Jul 2011) Log Message: ----------- Fix compiler error. Modified Paths: -------------- trunk/ChangeLog trunk/src/gtk-polar-view.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-07-04 00:05:11 UTC (rev 842) +++ trunk/ChangeLog 2011-07-08 02:10:32 UTC (rev 843) @@ -1,3 +1,9 @@ +2011-07-07 Charles Suprin <hamaa1vs at gmail.com> + + * src/gtk-polar-view.c + Fix compiler error. + + 2011-07-03 Charles Suprin <hamaa1vs at gmail.com> * src/gtk-sat-selector.c Modified: trunk/src/gtk-polar-view.c =================================================================== --- trunk/src/gtk-polar-view.c 2011-07-04 00:05:11 UTC (rev 842) +++ trunk/src/gtk-polar-view.c 2011-07-08 02:10:32 UTC (rev 843) @@ -43,6 +43,7 @@ #include "gtk-polar-view.h" #include "sat-info.h" #include "time-tools.h" +#include "orbit-tools.h" #ifdef HAVE_CONFIG_H # include <build-config.h> #endif This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-07-30 20:39:35
|
Revision: 877 http://gpredict.svn.sourceforge.net/gpredict/?rev=877&view=rev Author: aa1vs Date: 2011-07-30 20:39:28 +0000 (Sat, 30 Jul 2011) Log Message: ----------- Change gtk headers to only include from short list at <http://developer.gnome.org/gtk3/3.0/gtk-migrating-2-to-3.html>. Modified Paths: -------------- trunk/ChangeLog trunk/src/gtk-azel-plot.h trunk/src/gtk-event-list.h trunk/src/gtk-polar-plot.h trunk/src/gtk-polar-view.h trunk/src/gtk-sat-list.h trunk/src/gtk-sat-map.h trunk/src/gtk-sat-module-tmg.h trunk/src/gtk-sat-module.h trunk/src/gtk-sky-glance.h Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/ChangeLog 2011-07-30 20:39:28 UTC (rev 877) @@ -1,3 +1,17 @@ +2011-07-30 Charles Suprin <hamaa1vs at gmail.com> + + * src/gtk-azel-plot.h + * src/gtk-event-list.h + * src/gtk-polar-plot.h + * src/gtk-polar-view.h + * src/gtk-sat-list.h + * src/gtk-sat-map.h + * src/gtk-sat-module.h + * src/gtk-sat-module-tmg.h + * src/gtk-sky-glance.h + Change gtk headers to only include from short list at <http://developer.gnome.org/gtk3/3.0/gtk-migrating-2-to-3.html>. + + 2011-07-23 Charles Suprin <hamaa1vs at gmail.com> * src/sat-cfg.[ch] Modified: trunk/src/gtk-azel-plot.h =================================================================== --- trunk/src/gtk-azel-plot.h 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/src/gtk-azel-plot.h 2011-07-30 20:39:28 UTC (rev 877) @@ -31,8 +31,7 @@ #include <glib.h> #include <glib/gi18n.h> #include <gdk/gdk.h> -#include <gtk/gtkwidget.h> -#include <gtk/gtkvbox.h> +#include <gtk/gtk.h> #include "gtk-sat-data.h" #include "predict-tools.h" #include <goocanvas.h> Modified: trunk/src/gtk-event-list.h =================================================================== --- trunk/src/gtk-event-list.h 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/src/gtk-event-list.h 2011-07-30 20:39:28 UTC (rev 877) @@ -31,7 +31,7 @@ #include <glib.h> #include <glib/gi18n.h> #include <gdk/gdk.h> -#include <gtk/gtkvbox.h> +#include <gtk/gtk.h> #include "gtk-sat-data.h" Modified: trunk/src/gtk-polar-plot.h =================================================================== --- trunk/src/gtk-polar-plot.h 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/src/gtk-polar-plot.h 2011-07-30 20:39:28 UTC (rev 877) @@ -31,8 +31,7 @@ #include <glib.h> #include <glib/gi18n.h> #include <gdk/gdk.h> -#include <gtk/gtkwidget.h> -#include <gtk/gtkvbox.h> +#include <gtk/gtk.h> #include "gtk-sat-data.h" #include "predict-tools.h" #include <goocanvas.h> Modified: trunk/src/gtk-polar-view.h =================================================================== --- trunk/src/gtk-polar-view.h 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/src/gtk-polar-view.h 2011-07-30 20:39:28 UTC (rev 877) @@ -31,8 +31,7 @@ #include <glib.h> #include <glib/gi18n.h> #include <gdk/gdk.h> -#include <gtk/gtkwidget.h> -#include <gtk/gtkvbox.h> +#include <gtk/gtk.h> #include "gtk-sat-data.h" #include "predict-tools.h" #include <goocanvas.h> Modified: trunk/src/gtk-sat-list.h =================================================================== --- trunk/src/gtk-sat-list.h 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/src/gtk-sat-list.h 2011-07-30 20:39:28 UTC (rev 877) @@ -31,7 +31,7 @@ #include <glib.h> #include <glib/gi18n.h> #include <gdk/gdk.h> -#include <gtk/gtkvbox.h> +#include <gtk/gtk.h> #include "gtk-sat-data.h" Modified: trunk/src/gtk-sat-map.h =================================================================== --- trunk/src/gtk-sat-map.h 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/src/gtk-sat-map.h 2011-07-30 20:39:28 UTC (rev 877) @@ -33,8 +33,7 @@ #include <glib.h> #include <glib/gi18n.h> #include <gdk/gdk.h> -#include <gtk/gtkwidget.h> -#include <gtk/gtkvbox.h> +#include <gtk/gtk.h> #include "gtk-sat-data.h" #include <goocanvas.h> Modified: trunk/src/gtk-sat-module-tmg.h =================================================================== --- trunk/src/gtk-sat-module-tmg.h 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/src/gtk-sat-module-tmg.h 2011-07-30 20:39:28 UTC (rev 877) @@ -38,7 +38,7 @@ #include <glib.h> #include <gdk/gdk.h> -#include <gtk/gtkvbox.h> +#include <gtk/gtk.h> Modified: trunk/src/gtk-sat-module.h =================================================================== --- trunk/src/gtk-sat-module.h 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/src/gtk-sat-module.h 2011-07-30 20:39:28 UTC (rev 877) @@ -31,7 +31,7 @@ #include <glib.h> #include <gdk/gdk.h> -#include <gtk/gtkvbox.h> +#include <gtk/gtk.h> #include "gtk-sat-data.h" #include "qth-data.h" Modified: trunk/src/gtk-sky-glance.h =================================================================== --- trunk/src/gtk-sky-glance.h 2011-07-24 01:17:14 UTC (rev 876) +++ trunk/src/gtk-sky-glance.h 2011-07-30 20:39:28 UTC (rev 877) @@ -31,8 +31,7 @@ #include <glib.h> #include <glib/gi18n.h> #include <gdk/gdk.h> -#include <gtk/gtkwidget.h> -#include <gtk/gtkvbox.h> +#include <gtk/gtk.h> #include "gtk-sat-data.h" #include "predict-tools.h" #include <goocanvas.h> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-07-30 21:05:35
|
Revision: 878 http://gpredict.svn.sourceforge.net/gpredict/?rev=878&view=rev Author: aa1vs Date: 2011-07-30 21:05:28 +0000 (Sat, 30 Jul 2011) Log Message: ----------- Use access functions instead of private elements per <http://developer.gnome.org/gtk3/3.0/gtk-migrating-2-to-3.html>. Modified Paths: -------------- trunk/ChangeLog trunk/src/gpredict-help.c trunk/src/gpredict-utils.c trunk/src/gtk-azel-plot.c trunk/src/gtk-polar-plot.c trunk/src/gtk-polar-view.c trunk/src/gtk-sat-map.c trunk/src/gtk-sat-module-popup.c trunk/src/gtk-sat-module.c trunk/src/gtk-sky-glance.c trunk/src/loc-tree.c trunk/src/main.c trunk/src/menubar.c trunk/src/mod-cfg.c trunk/src/mod-mgr.c trunk/src/qth-editor.c trunk/src/sat-info.c trunk/src/sat-log-browser.c trunk/src/sat-pass-dialogs.c trunk/src/sat-pref-qth-editor.c trunk/src/sat-pref-rig-editor.c trunk/src/sat-pref-rot-editor.c trunk/src/sat-pref.c trunk/src/save-pass.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/ChangeLog 2011-07-30 21:05:28 UTC (rev 878) @@ -11,7 +11,32 @@ * src/gtk-sky-glance.h Change gtk headers to only include from short list at <http://developer.gnome.org/gtk3/3.0/gtk-migrating-2-to-3.html>. + * src/gpredict-help.c + * src/gpredict-utils.c + * src/gtk-azel-plot.c + * src/gtk-polar-plot.c + * src/gtk-polar-view.c + * src/gtk-sat-map.c + * src/gtk-sat-module.c + * src/gtk-sat-module-popup.c + * src/gtk-sky-glance.c + * src/loc-tree.c + * src/main.c + * src/menubar.c + * src/mod-cfg.c + * src/mod-mgr.c + * src/qth-editor.c + * src/sat-info.c + * src/sat-log-browser.c + * src/sat-pass-dialogs.c + * src/sat-pref.c + * src/sat-pref-qth-editor.c + * src/sat-pref-rig-editor.c + * src/sat-pref-rot-editor.c + * src/save-pass.c + Use access functions instead of private elements per <http://developer.gnome.org/gtk3/3.0/gtk-migrating-2-to-3.html>. + 2011-07-23 Charles Suprin <hamaa1vs at gmail.com> * src/sat-cfg.[ch] Modified: trunk/src/gpredict-help.c =================================================================== --- trunk/src/gpredict-help.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/gpredict-help.c 2011-07-30 21:05:28 UTC (rev 878) @@ -110,6 +110,7 @@ { GtkWidget *dialog; GtkWidget *label; + GtkBox *vbox; gint resp; @@ -124,11 +125,11 @@ NULL); label = gtk_label_new (_("Please select a HTML browser to be used to view the help.")); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), label, FALSE, TRUE, 0); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), - sat_pref_help_create (), TRUE, FALSE, 0); + vbox = GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG(dialog))); + gtk_box_pack_start (vbox, label, FALSE, TRUE, 0); + gtk_box_pack_start (vbox, sat_pref_help_create (), TRUE, FALSE, 0); - gtk_widget_show_all (GTK_DIALOG (dialog)->vbox); + gtk_widget_show_all (GTK_WIDGET(vbox)); resp = gtk_dialog_run (GTK_DIALOG (dialog)); @@ -247,7 +248,7 @@ g_signal_connect_swapped (dialog, "response", G_CALLBACK (gtk_widget_destroy), dialog); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG(dialog)->vbox), swin); + gtk_container_add (GTK_CONTAINER(gtk_dialog_get_content_area(GTK_DIALOG(dialog))), swin); gtk_widget_show_all (dialog); } Modified: trunk/src/gpredict-utils.c =================================================================== --- trunk/src/gpredict-utils.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/gpredict-utils.c 2011-07-30 21:05:28 UTC (rev 878) @@ -60,7 +60,6 @@ GtkWidget *image; GtkWidget *box; gchar *path; - GtkTooltips *tips; path = icon_file_name (file); image = gtk_image_new_from_file (path); @@ -71,12 +70,9 @@ gtk_box_pack_start (GTK_BOX (box), gtk_label_new (text), TRUE, TRUE, 0); button = gtk_button_new (); + gtk_widget_set_tooltip_text (button, tooltip); gtk_container_add (GTK_CONTAINER (button), box); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, button, tooltip, NULL); - - return button; } @@ -95,7 +91,6 @@ GtkWidget *image; GtkWidget *box; gchar *path; - GtkTooltips *tips; path = icon_file_name (file); image = gtk_image_new_from_file (path); @@ -106,12 +101,9 @@ gtk_box_pack_start (GTK_BOX (box), gtk_label_new (text), TRUE, TRUE, 0); button = gtk_button_new (); + gtk_widget_set_tooltip_text (button, tooltip); gtk_container_add (GTK_CONTAINER (button), box); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, button, tooltip, NULL); - - return button; } @@ -127,8 +119,6 @@ GtkWidget *button; GtkWidget *image; GtkWidget *box; - GtkTooltips *tips; - image = gtk_image_new_from_stock (stock_id, GTK_ICON_SIZE_BUTTON); box = gtk_hbox_new (FALSE, 0); @@ -137,12 +127,9 @@ gtk_box_pack_start (GTK_BOX (box), gtk_label_new (text), TRUE, TRUE, 0); button = gtk_button_new (); + gtk_widget_set_tooltip_text (button, tooltip); gtk_container_add (GTK_CONTAINER (button), box); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, button, tooltip, NULL); - - return button; } @@ -192,14 +179,7 @@ /* if current child is a button we have BINGO! */ if (GTK_IS_BUTTON (combo)) { - - GtkTooltips *tips; - - tips = gtk_tooltips_new (); - - gtk_tooltips_set_tip (tips, combo, - (gchar *) text, - NULL); + gtk_widget_set_tooltip_text (combo, text); } } @@ -264,7 +244,6 @@ GtkWidget *button; GtkWidget *image; gchar *path; - GtkTooltips *tips; path = icon_file_name (pixmapfile); image = gtk_image_new_from_file (path); @@ -272,12 +251,9 @@ button = gtk_button_new (); gtk_button_set_relief (GTK_BUTTON (button), GTK_RELIEF_NONE); + gtk_widget_set_tooltip_text (button, tooltip); gtk_container_add (GTK_CONTAINER (button), image); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, button, tooltip, NULL); - - return button; } Modified: trunk/src/gtk-azel-plot.c =================================================================== --- trunk/src/gtk-azel-plot.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/gtk-azel-plot.c 2011-07-30 21:05:28 UTC (rev 878) @@ -85,7 +85,7 @@ GtkType gtk_azel_plot_get_type () { - static GType gtk_azel_plot_type = 0; + static GtkType gtk_azel_plot_type = 0; if (!gtk_azel_plot_type) { static const GTypeInfo gtk_azel_plot_info = { @@ -449,7 +449,7 @@ pass_detail_t *detail; - if (GTK_WIDGET_REALIZED (widget)) { + if (gtk_widget_get_realized (widget)) { /* get graph dimensions */ polv = GTK_AZEL_PLOT (data); @@ -605,8 +605,7 @@ { GtkAllocation aloc; - aloc.width = canvas->allocation.width; - aloc.height = canvas->allocation.height; + gtk_widget_get_allocation(canvas, &aloc); size_allocate_cb (canvas, &aloc, data); } Modified: trunk/src/gtk-polar-plot.c =================================================================== --- trunk/src/gtk-polar-plot.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/gtk-polar-plot.c 2011-07-30 21:05:28 UTC (rev 878) @@ -774,7 +774,7 @@ GtkAnchorType anch = GTK_ANCHOR_CENTER; - if (GTK_WIDGET_REALIZED (widget)) { + if (gtk_widget_get_realized (widget)) { /* get graph dimensions */ polv = GTK_POLAR_PLOT (data); @@ -894,8 +894,7 @@ { GtkAllocation aloc; - aloc.width = canvas->allocation.width; - aloc.height = canvas->allocation.height; + gtk_widget_get_allocation (canvas, &aloc); size_allocate_cb (canvas, &aloc, data); } Modified: trunk/src/gtk-polar-view.c =================================================================== --- trunk/src/gtk-polar-view.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/gtk-polar-view.c 2011-07-30 21:05:28 UTC (rev 878) @@ -529,18 +529,16 @@ static void update_polv_size (GtkPolarView *polv) { - //GtkPolarView *polv; GtkAllocation allocation; GooCanvasPoints *prec; gfloat x,y; GtkAnchorType anch = GTK_ANCHOR_CENTER; - if (GTK_WIDGET_REALIZED (polv)) { + if (gtk_widget_get_realized (GTK_WIDGET(polv))) { /* get graph dimensions */ - allocation.width = GTK_WIDGET (polv)->allocation.width; - allocation.height = GTK_WIDGET (polv)->allocation.height; + gtk_widget_get_allocation ( GTK_WIDGET(polv), &allocation); polv->size = MIN(allocation.width, allocation.height); polv->r = (polv->size / 2) - POLV_DEFAULT_MARGIN; @@ -668,8 +666,7 @@ { GtkAllocation aloc; - aloc.width = canvas->allocation.width; - aloc.height = canvas->allocation.height; + gtk_widget_get_allocation (canvas, &aloc); size_allocate_cb (canvas, &aloc, data); } Modified: trunk/src/gtk-sat-map.c =================================================================== --- trunk/src/gtk-sat-map.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/gtk-sat-map.c 2011-07-30 21:05:28 UTC (rev 878) @@ -484,10 +484,9 @@ gfloat ratio; /* ratio between map width and height */ gfloat size; /* size = min (alloc.w, ratio*alloc.h) */ - if (GTK_WIDGET_REALIZED (satmap)) { + if (gtk_widget_get_realized (GTK_WIDGET(satmap))) { /* get graph dimensions */ - allocation.width = GTK_WIDGET (satmap)->allocation.width; - allocation.height = GTK_WIDGET (satmap)->allocation.height; + gtk_widget_get_allocation( GTK_WIDGET(satmap), &allocation); if (satmap->keepratio) { /* Use allocation->width and allocation->height to calculate Modified: trunk/src/gtk-sat-module-popup.c =================================================================== --- trunk/src/gtk-sat-module-popup.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/gtk-sat-module-popup.c 2011-07-30 21:05:28 UTC (rev 878) @@ -313,6 +313,8 @@ GtkWidget *label; GtkWidget *toggle; GtkTooltips *tooltips; + GtkWidget *vbox; + GtkAllocation aloc; guint response; GtkSatModule *module = GTK_SAT_MODULE (data); GtkSatModule *newmod; @@ -335,7 +337,8 @@ /* label */ label = gtk_label_new (_("Name of new module:")); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), label, FALSE, FALSE, 0); + vbox = gtk_dialog_get_content_area(GTK_DIALOG(dialog)); + gtk_box_pack_start (GTK_BOX(vbox), label, FALSE, FALSE, 0); /* name entry */ entry = gtk_entry_new (); @@ -357,8 +360,7 @@ GTK_RESPONSE_OK, FALSE); g_signal_connect (entry, "changed", G_CALLBACK (name_changed), dialog); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), - entry, FALSE, FALSE, 0); + gtk_box_pack_start (GTK_BOX( vbox ), entry, FALSE, FALSE, 0); /* check button */ @@ -369,11 +371,11 @@ _("If checked, the new module will be opened "\ "after it has been created"), NULL); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), + gtk_box_pack_start (GTK_BOX (vbox), toggle, FALSE, FALSE, 20); - gtk_widget_show_all (GTK_DIALOG (dialog)->vbox); + gtk_widget_show_all (vbox); /* run dialog */ response = gtk_dialog_run (GTK_DIALOG (dialog)); @@ -433,9 +435,10 @@ g_free (title); /* use size of source module */ + gtk_widget_get_allocation(GTK_WIDGET (module), &aloc); gtk_window_set_default_size (GTK_WINDOW (newmod->win), - GTK_WIDGET (module)->allocation.width, - GTK_WIDGET (module)->allocation.height); + aloc.width, + aloc.height); g_signal_connect (G_OBJECT (newmod->win), "configure_event", G_CALLBACK (module_window_config_cb), newmod); @@ -496,12 +499,15 @@ static void docking_state_cb (GtkWidget *menuitem, gpointer data) { GtkWidget *module = GTK_WIDGET (data); + GtkAllocation aloc; gint w,h; gchar *icon; /* icon file name */ gchar *title; /* window title */ (void) menuitem; /* avoid unused parameter compiler warning */ + gtk_widget_get_allocation ( module, &aloc); + switch (GTK_SAT_MODULE (module)->state) { case GTK_SAT_MOD_STATE_DOCKED: @@ -517,7 +523,7 @@ NULL); } else { - w = module->allocation.width; + w = aloc.width; } if (g_key_file_has_key (GTK_SAT_MODULE (module)->cfgdata, MOD_CFG_GLOBAL_SECTION, @@ -529,7 +535,7 @@ NULL); } else { - h = module->allocation.height; + h = aloc.height; } /* increase reference count of module */ @@ -1198,7 +1204,7 @@ /* data is only useful when window is visible */ - if (GTK_WIDGET_VISIBLE (widget)) + if (gtk_widget_get_visible (widget)) gtk_window_get_position (GTK_WINDOW (widget), &x, &y); else return FALSE; /* carry on normally */ Modified: trunk/src/gtk-sat-module.c =================================================================== --- trunk/src/gtk-sat-module.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/gtk-sat-module.c 2011-07-30 21:05:28 UTC (rev 878) @@ -774,7 +774,7 @@ break; default: - state = gdk_window_get_state (GDK_WINDOW (GTK_WIDGET (module)->window)); + state = gdk_window_get_state (GDK_WINDOW (gtk_widget_get_window (GTK_WIDGET (module)))); if (state & GDK_WINDOW_STATE_ICONIFIED) { needupdate = FALSE; @@ -1251,6 +1251,7 @@ gtk_sat_module_config_cb (GtkWidget *button, gpointer data) { GtkSatModule *module = GTK_SAT_MODULE (data); + GtkAllocation alloc; GtkWidget *toplevel; gchar *name; gchar *cfgfile; @@ -1307,8 +1308,9 @@ /* store state and size */ laststate = module->state; - w = GTK_WIDGET (module)->allocation.width; - h = GTK_WIDGET (module)->allocation.height; + gtk_widget_get_allocation( GTK_WIDGET(module),&alloc); + w = alloc.width; + h = alloc.height; gtk_sat_module_close_cb (NULL, module); Modified: trunk/src/gtk-sky-glance.c =================================================================== --- trunk/src/gtk-sky-glance.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/gtk-sky-glance.c 2011-07-30 21:05:28 UTC (rev 878) @@ -454,7 +454,7 @@ gdouble x,y,w,h; - if (GTK_WIDGET_REALIZED (widget)) { + if (gtk_widget_get_realized (widget)) { /* get graph dimensions */ skg = GTK_SKY_GLANCE (data); @@ -605,9 +605,8 @@ on_canvas_realized (GtkWidget *canvas, gpointer data) { GtkAllocation aloc; - - aloc.width = canvas->allocation.width; - aloc.height = canvas->allocation.height; + + gtk_widget_get_allocation (canvas, &aloc); size_allocate_cb (canvas, &aloc, data); } Modified: trunk/src/loc-tree.c =================================================================== --- trunk/src/loc-tree.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/loc-tree.c 2011-07-30 21:05:28 UTC (rev 878) @@ -270,7 +270,7 @@ gtk_dialog_set_response_sensitive (GTK_DIALOG (dialog), GTK_RESPONSE_ACCEPT, FALSE); - gtk_box_pack_start_defaults (GTK_BOX (GTK_DIALOG(dialog)->vbox), swin); + gtk_box_pack_start_defaults (GTK_BOX (gtk_dialog_get_content_area(GTK_DIALOG(dialog))), swin); /* connect selection checker for the tree-view; we have waited so far, because we want to pass the dialog as Modified: trunk/src/main.c =================================================================== --- trunk/src/main.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/main.c 2011-07-30 21:05:28 UTC (rev 878) @@ -409,7 +409,7 @@ (void) data; /* prevent unused parameter compiler warning */ /* data is only useful when window is visible */ - if (GTK_WIDGET_VISIBLE (widget)) + if (gtk_widget_get_visible (widget)) gtk_window_get_position (GTK_WINDOW (widget), &x, &y); else return FALSE; /* carry on normally */ Modified: trunk/src/menubar.c =================================================================== --- trunk/src/menubar.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/menubar.c 2011-07-30 21:05:28 UTC (rev 878) @@ -496,7 +496,7 @@ gtk_box_pack_start (GTK_BOX (box), label2, TRUE, TRUE, 0); /* finalise dialog */ - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), box); + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), box); g_signal_connect_swapped (dialog, "response", G_CALLBACK (gtk_widget_destroy), @@ -595,7 +595,7 @@ GTK_STOCK_OK, GTK_RESPONSE_ACCEPT, NULL); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), box, TRUE, TRUE, 30); + gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area(GTK_DIALOG(dialog))), box, TRUE, TRUE, 30); response = gtk_dialog_run (GTK_DIALOG (dialog)); @@ -668,7 +668,7 @@ gtk_box_pack_start (GTK_BOX (box), label2, TRUE, TRUE, 0); /* finalise dialog */ - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), box); + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), box); g_signal_connect_swapped (dialog, "response", G_CALLBACK (gtk_widget_destroy), @@ -793,7 +793,7 @@ button = gtk_link_button_new ("http://gpredict.oz9aec.net/documents.php"); gtk_widget_show (button); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG(dialog)->vbox), button, FALSE, FALSE, 0); + gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area(GTK_DIALOG(dialog))), button, FALSE, FALSE, 0); gtk_dialog_run (GTK_DIALOG (dialog)); gtk_widget_destroy (dialog); @@ -964,7 +964,7 @@ gtk_window_set_default_size (GTK_WINDOW (dialog), -1, 200); gtk_container_add (GTK_CONTAINER (swin), modlist); gtk_widget_show (swin); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), swin); + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), swin); switch (gtk_dialog_run (GTK_DIALOG (dialog))) { @@ -1017,8 +1017,9 @@ gint w,h; gchar *icon; /* icon file name */ gchar *title; /* window title */ + GtkAllocation aloc; - + gtk_widget_get_allocation (module, &aloc); /* get stored size; use size from main window if size not explicitly stoed */ if (g_key_file_has_key (GTK_SAT_MODULE (module)->cfgdata, MOD_CFG_GLOBAL_SECTION, @@ -1030,7 +1031,7 @@ NULL); } else { - w = module->allocation.width; + w = aloc.width; } if (g_key_file_has_key (GTK_SAT_MODULE (module)->cfgdata, MOD_CFG_GLOBAL_SECTION, @@ -1042,7 +1043,7 @@ NULL); } else { - h = module->allocation.height; + h = aloc.height; } /* increase reference count of module */ Modified: trunk/src/mod-cfg.c =================================================================== --- trunk/src/mod-cfg.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/mod-cfg.c 2011-07-30 21:05:28 UTC (rev 878) @@ -441,6 +441,7 @@ GtkWidget *label; GtkWidget *swin; GtkWidget *addbut, *delbut; + GtkWidget *vbox; GtkTooltips *tooltips; gchar *icon; /* window icon file name */ GtkWidget *frame; @@ -541,14 +542,14 @@ gtk_table_attach (GTK_TABLE (table), add, 3, 4, 1, 2, GTK_SHRINK, GTK_SHRINK, 0, 0); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), table, FALSE, FALSE, 0); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), - gtk_hseparator_new (), FALSE, FALSE, 5); + vbox = gtk_dialog_get_content_area (GTK_DIALOG( dialog )); + gtk_box_pack_start (GTK_BOX (vbox), table, FALSE, FALSE, 0); + gtk_box_pack_start (GTK_BOX (vbox), gtk_hseparator_new (), FALSE, FALSE, 5); label = gtk_label_new (NULL); gtk_label_set_markup (GTK_LABEL (label), _("<b>Satellites</b>")); gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), label, FALSE, FALSE, 5); + gtk_box_pack_start (GTK_BOX (vbox), label, FALSE, FALSE, 5); /* satellite selector */ @@ -588,9 +589,9 @@ gtk_table_attach (GTK_TABLE (table), delbut, 4, 5, 5, 6, GTK_SHRINK, GTK_SHRINK, 2, 5); gtk_table_attach_defaults (GTK_TABLE (table), label, 5, 9, 0, 2); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), table, TRUE, TRUE, 0); + gtk_box_pack_start (GTK_BOX (vbox), table, TRUE, TRUE, 0); - gtk_widget_show_all (GTK_DIALOG (dialog)->vbox); + gtk_widget_show_all (vbox); return dialog; } @@ -1063,7 +1064,7 @@ contents = sat_pref_modules_create (cfgdata); gtk_widget_show_all (contents); - gtk_box_pack_start_defaults (GTK_BOX (GTK_DIALOG (dialog)->vbox), contents); + gtk_box_pack_start_defaults (GTK_BOX (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), contents); /* execute dialog */ switch (gtk_dialog_run (GTK_DIALOG (dialog))) { Modified: trunk/src/mod-mgr.c =================================================================== --- trunk/src/mod-mgr.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/mod-mgr.c 2011-07-30 21:05:28 UTC (rev 878) @@ -640,8 +640,9 @@ gint w,h; gchar *icon; /* icon file name */ gchar *title; /* window title */ + GtkAllocation aloc; - + gtk_widget_get_allocation ( module, &aloc); /* get stored size; use size from main window if size not explicitly stoed */ if (g_key_file_has_key (GTK_SAT_MODULE (module)->cfgdata, MOD_CFG_GLOBAL_SECTION, @@ -653,7 +654,7 @@ NULL); } else { - w = module->allocation.width; + w = aloc.width; } if (g_key_file_has_key (GTK_SAT_MODULE (module)->cfgdata, MOD_CFG_GLOBAL_SECTION, @@ -665,7 +666,7 @@ NULL); } else { - h = module->allocation.height; + h = aloc.height; } /* increase reference count of module */ Modified: trunk/src/qth-editor.c =================================================================== --- trunk/src/qth-editor.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/qth-editor.c 2011-07-30 21:05:28 UTC (rev 878) @@ -129,7 +129,7 @@ GTK_RESPONSE_OK, FALSE); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), create_editor_widgets (qth)); /* this hacky-thing is to keep the dialog running in case the Modified: trunk/src/sat-info.c =================================================================== --- trunk/src/sat-info.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/sat-info.c 2011-07-30 21:05:28 UTC (rev 878) @@ -340,7 +340,7 @@ g_signal_connect (dialog, "response", G_CALLBACK (gtk_widget_destroy), NULL); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), notebook); + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), notebook); gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_ACCEPT); Modified: trunk/src/sat-log-browser.c =================================================================== --- trunk/src/sat-log-browser.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/sat-log-browser.c 2011-07-30 21:05:28 UTC (rev 878) @@ -164,7 +164,7 @@ gtk_window_set_default_size (GTK_WINDOW (window), 850, 400); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG(window)->vbox), hbox); + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area (GTK_DIALOG(window))), hbox); /* connect response signal */ g_signal_connect (G_OBJECT (window), "response", Modified: trunk/src/sat-pass-dialogs.c =================================================================== --- trunk/src/sat-pass-dialogs.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/sat-pass-dialogs.c 2011-07-30 21:05:28 UTC (rev 878) @@ -523,7 +523,7 @@ G_CALLBACK (single_pass_dialog_delete), NULL); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), notebook); + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG(dialog))), notebook); gtk_window_set_default_size (GTK_WINDOW (dialog), -1, 300); gtk_widget_show_all (dialog); @@ -1129,7 +1129,7 @@ G_CALLBACK (multi_pass_dialog_delete), NULL); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), swin); + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), swin); gtk_window_set_default_size (GTK_WINDOW (dialog), -1, 300); gtk_widget_show_all (dialog); Modified: trunk/src/sat-pref-qth-editor.c =================================================================== --- trunk/src/sat-pref-qth-editor.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/sat-pref-qth-editor.c 2011-07-30 21:05:28 UTC (rev 878) @@ -132,7 +132,7 @@ GTK_RESPONSE_OK, FALSE); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), create_editor_widgets (treeview, new)); /* this hacky-thing is to keep the dialog running in case the Modified: trunk/src/sat-pref-rig-editor.c =================================================================== --- trunk/src/sat-pref-rig-editor.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/sat-pref-rig-editor.c 2011-07-30 21:05:28 UTC (rev 878) @@ -101,7 +101,7 @@ GTK_RESPONSE_OK, FALSE); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), create_editor_widgets (conf)); /* this hacky-thing is to keep the dialog running in case the Modified: trunk/src/sat-pref-rot-editor.c =================================================================== --- trunk/src/sat-pref-rot-editor.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/sat-pref-rot-editor.c 2011-07-30 21:05:28 UTC (rev 878) @@ -99,7 +99,7 @@ GTK_RESPONSE_OK, FALSE); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), create_editor_widgets (conf)); /* this hacky-thing is to keep the dialog running in case the Modified: trunk/src/sat-pref.c =================================================================== --- trunk/src/sat-pref.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/sat-pref.c 2011-07-30 21:05:28 UTC (rev 878) @@ -174,8 +174,8 @@ NULL); g_free (iconfile); - gtk_box_pack_start_defaults (GTK_BOX (GTK_DIALOG(window)->vbox), hbox); - gtk_box_set_spacing (GTK_BOX (GTK_DIALOG(window)->vbox), 10); + gtk_box_pack_start_defaults (GTK_BOX (gtk_dialog_get_content_area(GTK_DIALOG(window))), hbox); + gtk_box_set_spacing (GTK_BOX (gtk_dialog_get_content_area(GTK_DIALOG(window))), 10); gtk_button_clicked (GTK_BUTTON (genbut)); Modified: trunk/src/save-pass.c =================================================================== --- trunk/src/save-pass.c 2011-07-30 20:39:28 UTC (rev 877) +++ trunk/src/save-pass.c 2011-07-30 21:05:28 UTC (rev 878) @@ -193,7 +193,7 @@ gtk_table_attach_defaults (GTK_TABLE (table), contents, 1, 2, 3, 4); gtk_widget_show_all (table); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), table); + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), table); /* run the dialog */ @@ -354,7 +354,7 @@ gtk_table_attach_defaults (GTK_TABLE (table), contents, 1, 2, 3, 4); gtk_widget_show_all (table); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), table); + gtk_container_add (GTK_CONTAINER (gtk_dialog_get_content_area(GTK_DIALOG (dialog))), table); /* run the dialog */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-07-30 23:24:09
|
Revision: 879 http://gpredict.svn.sourceforge.net/gpredict/?rev=879&view=rev Author: aa1vs Date: 2011-07-30 23:24:01 +0000 (Sat, 30 Jul 2011) Log Message: ----------- Eliminate use of deprecated GtkTooltips for GtkTooltip per <http://developer.gnome.org/gtk/2.22/gtk-migrating-tooltips.html>. Modified Paths: -------------- trunk/ChangeLog trunk/src/gtk-sat-module-popup.c trunk/src/gtk-sat-module-tmg.c trunk/src/gtk-sat-tree.c trunk/src/mod-cfg.c trunk/src/qth-editor.c trunk/src/sat-pref-conditions.c trunk/src/sat-pref-debug.c trunk/src/sat-pref-formats.c trunk/src/sat-pref-layout.c trunk/src/sat-pref-list-view.c trunk/src/sat-pref-map-view.c trunk/src/sat-pref-multi-pass.c trunk/src/sat-pref-polar-view.c trunk/src/sat-pref-qth-editor.c trunk/src/sat-pref-refresh.c trunk/src/sat-pref-single-pass.c trunk/src/sat-pref-single-sat.c trunk/src/sat-pref-sky-at-glance.c trunk/src/sat-pref-tle.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/ChangeLog 2011-07-30 23:24:01 UTC (rev 879) @@ -36,7 +36,28 @@ * src/save-pass.c Use access functions instead of private elements per <http://developer.gnome.org/gtk3/3.0/gtk-migrating-2-to-3.html>. + * src/gtk-sat-module-popup.c + * src/sat-pref-single-sat.c + * src/sat-pref-layout.c + * src/sat-pref-debug.c + * src/sat-pref-qth-editor.c + * src/sat-pref-polar-view.c + * src/sat-pref-map-view.c + * src/sat-pref-multi-pass.c + * src/mod-cfg.c + * src/gtk-sat-module-tmg.c + * src/sat-pref-conditions.c + * src/sat-pref-formats.c + * src/sat-pref-tle.c + * src/sat-pref-sky-at-glance.c + * src/qth-editor.c + * src/sat-pref-list-view.c + * src/sat-pref-single-pass.c + * src/gtk-sat-tree.c + * src/sat-pref-refresh.c + Eliminate use of deprecated GtkTooltips for GtkTooltip per <http://developer.gnome.org/gtk/2.22/gtk-migrating-tooltips.html>. + 2011-07-23 Charles Suprin <hamaa1vs at gmail.com> * src/sat-cfg.[ch] Modified: trunk/src/gtk-sat-module-popup.c =================================================================== --- trunk/src/gtk-sat-module-popup.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/gtk-sat-module-popup.c 2011-07-30 23:24:01 UTC (rev 879) @@ -312,7 +312,6 @@ GtkWidget *entry; GtkWidget *label; GtkWidget *toggle; - GtkTooltips *tooltips; GtkWidget *vbox; GtkAllocation aloc; guint response; @@ -344,14 +343,15 @@ entry = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (entry), 25); gtk_entry_set_text (GTK_ENTRY (entry), module->name); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, entry, + gtk_widget_set_tooltip_text (entry, _("Enter a short name for this module.\n"\ - "Allowed characters: 0..9, a..z, A..Z, - and _"), - _("The name will be used to identify the module "\ + "Allowed characters: 0..9, a..z, A..Z, - and _")); + + /*not sure what to do with the old private tip the new api does not like them + _("The name will be used to identify the module " \ "and it is also used a file name for saving the data."\ "Max length is 25 characters.")); - + */ /* attach changed signal so that we can enable OK button when a proper name has been entered oh, btw. disable OK button to begin with.... @@ -366,11 +366,9 @@ /* check button */ toggle = gtk_check_button_new_with_label (_("Open module when created")); gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (toggle), TRUE); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, toggle, + gtk_widget_set_tooltip_text ( toggle, _("If checked, the new module will be opened "\ - "after it has been created"), - NULL); + "after it has been created")); gtk_box_pack_start (GTK_BOX (vbox), toggle, FALSE, FALSE, 20); Modified: trunk/src/gtk-sat-module-tmg.c =================================================================== --- trunk/src/gtk-sat-module-tmg.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/gtk-sat-module-tmg.c 2011-07-30 23:24:01 UTC (rev 879) @@ -64,7 +64,6 @@ GtkWidget *vbox, *hbox, *table; GtkWidget *image; GtkWidget *label; - GtkTooltips *tips; gchar *title; gchar *buff; @@ -95,8 +94,7 @@ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (mod->tmgFwd), TRUE); image = gtk_image_new_from_stock (GTK_STOCK_MEDIA_PLAY, GTK_ICON_SIZE_BUTTON); gtk_container_add (GTK_CONTAINER (mod->tmgFwd), image); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod->tmgFwd, _("Play forward"), NULL); + gtk_widget_set_tooltip_text (mod->tmgFwd, _("Play forward")); g_signal_connect (mod->tmgFwd, "toggled", G_CALLBACK (tmg_fwd), mod); gtk_box_pack_end (GTK_BOX (hbox), mod->tmgFwd, FALSE, FALSE, 0); @@ -105,8 +103,7 @@ gtk_toggle_button_set_mode (GTK_TOGGLE_BUTTON (mod->tmgStop), FALSE); image = gtk_image_new_from_stock (GTK_STOCK_MEDIA_PAUSE, GTK_ICON_SIZE_BUTTON); gtk_container_add (GTK_CONTAINER (mod->tmgStop), image); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod->tmgStop, _("Stop"), NULL); + gtk_widget_set_tooltip_text (mod->tmgStop, _("Stop")); g_signal_connect (mod->tmgStop, "toggled", G_CALLBACK (tmg_stop), mod); gtk_box_pack_end (GTK_BOX (hbox), mod->tmgStop, FALSE, FALSE, 0); @@ -116,15 +113,13 @@ image = gtk_image_new_from_stock (GTK_STOCK_MEDIA_PLAY, GTK_ICON_SIZE_BUTTON); gtk_widget_set_direction (image, GTK_TEXT_DIR_RTL); gtk_container_add (GTK_CONTAINER (mod->tmgBwd), image); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod->tmgBwd, _("Play backwards"), NULL); + gtk_widget_set_tooltip_text (mod->tmgBwd, _("Play backwards")); g_signal_connect (mod->tmgBwd, "toggled", G_CALLBACK (tmg_bwd), mod); gtk_box_pack_end (GTK_BOX (hbox), mod->tmgBwd, FALSE, FALSE, 0); /* reset time */ mod->tmgReset = gtk_button_new_with_label (_("Reset")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod->tmgReset, _("Reset to current date and time"), NULL); + gtk_widget_set_tooltip_text (mod->tmgReset, _("Reset to current date and time")); g_signal_connect (mod->tmgReset, "clicked", G_CALLBACK (tmg_reset), mod); gtk_box_pack_end (GTK_BOX (hbox), mod->tmgReset, FALSE, FALSE, 10); @@ -168,10 +163,8 @@ gtk_spin_button_set_digits (GTK_SPIN_BUTTON (mod->tmgHour), 0); gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (mod->tmgHour), TRUE); //FIXME gtk_spin_button_set_value (GTK_SPIN_BUTTON (mod->tmgHour), 2); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod->tmgHour, - _("Use this control to set the hour"), - NULL); + gtk_widget_set_tooltip_text (mod->tmgHour, + _("Use this control to set the hour")); g_signal_connect (mod->tmgHour, "value-changed", G_CALLBACK (tmg_time_set), mod); g_signal_connect (mod->tmgHour, "wrapped", G_CALLBACK (tmg_hour_wrap), mod); @@ -190,10 +183,8 @@ gtk_spin_button_set_digits (GTK_SPIN_BUTTON (mod->tmgMin), 0); gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (mod->tmgMin), TRUE); //FIXME gtk_spin_button_set_value (GTK_SPIN_BUTTON (mod->tmgMin), 2); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod->tmgMin, - _("Use this control to set the minutes"), - NULL); + gtk_widget_set_tooltip_text (mod->tmgMin, + _("Use this control to set the minutes")); g_signal_connect (mod->tmgMin, "value-changed", G_CALLBACK (tmg_time_set), mod); g_signal_connect (mod->tmgMin, "wrapped", G_CALLBACK (tmg_min_wrap), mod); @@ -212,10 +203,8 @@ gtk_spin_button_set_digits (GTK_SPIN_BUTTON (mod->tmgSec), 0); gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (mod->tmgSec), TRUE); //FIXME gtk_spin_button_set_value (GTK_SPIN_BUTTON (mod->tmgSec), 2); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod->tmgSec, - _("Use this control to set the seconds"), - NULL); + gtk_widget_set_tooltip_text (mod->tmgSec, + _("Use this control to set the seconds")); g_signal_connect (mod->tmgSec, "value-changed", G_CALLBACK (tmg_time_set), mod); g_signal_connect (mod->tmgSec, "wrapped", G_CALLBACK (tmg_sec_wrap), mod); @@ -234,10 +223,8 @@ gtk_spin_button_set_digits (GTK_SPIN_BUTTON (mod->tmgMsec), 0); gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (mod->tmgMsec), TRUE); //FIXME gtk_spin_button_set_value (GTK_SPIN_BUTTON (mod->tmgMsec), 2); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod->tmgMsec, - _("Use this control to set the milliseconds"), - NULL); + gtk_widget_set_tooltip_text (mod->tmgMsec, + _("Use this control to set the milliseconds")); g_signal_connect (mod->tmgMsec, "value-changed", G_CALLBACK (tmg_time_set), mod); g_signal_connect (mod->tmgMsec, "wrapped", G_CALLBACK (tmg_msec_wrap), mod); @@ -255,10 +242,8 @@ GTK_UPDATE_IF_VALID); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (mod->tmgFactor), 0); gtk_spin_button_set_value (GTK_SPIN_BUTTON (mod->tmgFactor), 1); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod->tmgFactor, - _("Time throttle / compression factor"), - NULL); + gtk_widget_set_tooltip_text (mod->tmgFactor, + _("Time throttle / compression factor")); g_signal_connect (mod->tmgFactor, "value-changed", G_CALLBACK (tmg_throttle), mod); gtk_table_attach (GTK_TABLE (table), mod->tmgFactor, Modified: trunk/src/gtk-sat-tree.c =================================================================== --- trunk/src/gtk-sat-tree.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/gtk-sat-tree.c 2011-07-30 23:24:01 UTC (rev 879) @@ -178,7 +178,6 @@ GtkCellRenderer *renderer; GtkTreeViewColumn *column; GtkWidget *hbox; - GtkTooltips *tips; GtkWidget *expbut; GtkWidget *colbut; Modified: trunk/src/mod-cfg.c =================================================================== --- trunk/src/mod-cfg.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/mod-cfg.c 2011-07-30 23:24:01 UTC (rev 879) @@ -442,7 +442,6 @@ GtkWidget *swin; GtkWidget *addbut, *delbut; GtkWidget *vbox; - GtkTooltips *tooltips; gchar *icon; /* window icon file name */ GtkWidget *frame; @@ -500,14 +499,14 @@ else { /* connect changed signal to text-checker */ gtk_entry_set_max_length (GTK_ENTRY (namew), 25); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, namew, + gtk_widget_set_tooltip_text (namew, _("Enter a short name for this module.\n"\ - "Allowed characters: 0..9, a..z, A..Z, - and _"), - _("The name will be used to identify the module "\ - "and it is also used a file name for saving the data."\ - "Max length is 25 characters.")); - + "Allowed characters: 0..9, a..z, A..Z, - and _")); + /*new tooltip api does not allow for private + _("The name will be used to identify the module " \ + "and it is also used a file name for saving the data." \ + "Max length is 25 characters.")); + */ /* attach changed signal so that we can enable OK button when a proper name has been entered oh, btw. disable OK button to begin with.... Modified: trunk/src/qth-editor.c =================================================================== --- trunk/src/qth-editor.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/qth-editor.c 2011-07-30 23:24:01 UTC (rev 879) @@ -191,7 +191,6 @@ { GtkWidget *table; GtkWidget *label; - GtkTooltips *tooltips; GtkWidget *locbut; GtkWidget *wxbut; @@ -208,13 +207,14 @@ name = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (name), 25); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, name, + gtk_widget_set_tooltip_text (name, _("Enter a short name for this ground station, e.g. callsign.\n"\ - "Allowed characters: 0..9, a..z, A..Z, - and _"), + "Allowed characters: 0..9, a..z, A..Z, - and _")); + /* new api does not allow for private tip _("The name will be used to identify the ground station "\ "when it is presented to the user. Maximum allowed length "\ "is 25 characters.")); + */ gtk_table_attach_defaults (GTK_TABLE (table), name, 1, 4, 0, 1); /* attach changed signal so that we can enable OK button when @@ -229,12 +229,13 @@ desc = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (desc), 256); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, desc, - _("Enter an optional description for this ground station."), + gtk_widget_set_tooltip_text (desc, + _("Enter an optional description for this ground station.")); + /* _("The description for the ground station can be used as additional "\ "information. It may be included when generating reports. "\ "The maximum length for the description is 256 characters.")); + */ gtk_table_attach_defaults (GTK_TABLE (table), desc, 1, 4, 1, 2); /* location */ @@ -244,10 +245,8 @@ location = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (location), 50); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, location, - _("Optional location of the ground station, fx. Copenhagen, Denmark."), - NULL); + gtk_widget_set_tooltip_text (location, + _("Optional location of the ground station, fx. Copenhagen, Denmark.")); gtk_table_attach_defaults (GTK_TABLE (table), location, 1, 3, 2, 3); locbut = gpredict_hstock_button (GTK_STOCK_INDEX, _("Select"), @@ -267,10 +266,8 @@ gtk_spin_button_set_increments (GTK_SPIN_BUTTON (lat), 0.01, 1.0); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (lat), TRUE); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (lat), 4); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, lat, - _("Select the latitude of the ground station in decimal degrees."), - NULL); + gtk_widget_set_tooltip_text (lat, + _("Select the latitude of the ground station in decimal degrees.")); gtk_table_attach_defaults (GTK_TABLE (table), lat, 1, 2, 3, 4); ns = gtk_combo_box_new_text (); @@ -289,9 +286,8 @@ gtk_spin_button_set_increments (GTK_SPIN_BUTTON (lon), 0.01, 1.0); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (lon), TRUE); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (lon), 4); - gtk_tooltips_set_tip (tooltips, lon, - _("Select the longitude of the ground station in decimal degrees."), - NULL); + gtk_widget_set_tooltip_text (lon, + _("Select the longitude of the ground station in decimal degrees.")); gtk_table_attach_defaults (GTK_TABLE (table), lon, 1, 2, 4, 5); ew = gtk_combo_box_new_text (); @@ -326,10 +322,8 @@ qra = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (qra), 6); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, qra, - _("Maidenhead locator grid."), - NULL); + gtk_widget_set_tooltip_text (qra, + _("Maidenhead locator grid.")); gtk_table_attach_defaults (GTK_TABLE (table), qra, 1, 2, 5, 6); qrasigid = g_signal_connect (qra, "changed", G_CALLBACK (qra_changed), @@ -343,10 +337,9 @@ alt = gtk_spin_button_new_with_range (0, 5000, 1); gtk_spin_button_set_increments (GTK_SPIN_BUTTON (alt), 1, 100); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (alt), TRUE); - gtk_tooltips_set_tip (tooltips, alt, + gtk_widget_set_tooltip_text (alt, _("Select the altitude of the ground station in meters or feet "\ - "depending on your settings"), - NULL); + "depending on your settings")); gtk_table_attach_defaults (GTK_TABLE (table), alt, 1, 2, 6, 7); if (sat_cfg_get_bool (SAT_CFG_BOOL_USE_IMPERIAL)) { @@ -365,10 +358,8 @@ wx = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (wx), 4); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, wx, - _("Four letter code for weather station"), - NULL); + gtk_widget_set_tooltip_text (wx, + _("Four letter code for weather station")); gtk_table_attach_defaults (GTK_TABLE (table), wx, 1, 3, 7, 8); wxbut = gpredict_hstock_button (GTK_STOCK_INDEX, _("Select"), @@ -388,9 +379,8 @@ gtk_combo_box_append_text (GTK_COMBO_BOX (type), "Static"); gtk_combo_box_append_text (GTK_COMBO_BOX (type), "GPSD"); gtk_combo_box_set_active (GTK_COMBO_BOX (type), 0); - gtk_tooltips_set_tip (tooltips, type, - _("A qth can be static, ie. it does not change, or gpsd based for computers with gps attached."), - NULL); + gtk_widget_set_tooltip_text (type, + _("A qth can be static, ie. it does not change, or gpsd based for computers with gps attached.")); gtk_table_attach_defaults (GTK_TABLE (table), type, 1, 2, 8, 9); /* GPSD Server */ label = gtk_label_new (_("GPSD Server")); @@ -399,10 +389,8 @@ server = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (server), 6000); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, server, - _("GPSD Server."), - NULL); + gtk_widget_set_tooltip_text (server, + _("GPSD Server.")); gtk_table_attach_defaults (GTK_TABLE (table), server, 1, 2, 9, 10); /* GPSD Port*/ @@ -413,9 +401,8 @@ port = gtk_spin_button_new_with_range (0, 32768, 1); gtk_spin_button_set_increments (GTK_SPIN_BUTTON (port), 1, 100); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (port), TRUE); - gtk_tooltips_set_tip (tooltips, port, - _("Set the port for GPSD to use. Default for gpsd is 2947."), - NULL); + gtk_widget_set_tooltip_text (port, + _("Set the port for GPSD to use. Default for gpsd is 2947.")); gtk_table_attach_defaults (GTK_TABLE (table), port, 1, 2, 10, 11); # endif Modified: trunk/src/sat-pref-conditions.c =================================================================== --- trunk/src/sat-pref-conditions.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/sat-pref-conditions.c 2011-07-30 23:24:01 UTC (rev 879) @@ -61,7 +61,6 @@ { GtkWidget *table; GtkWidget *label; - GtkTooltips *tips; GtkWidget *vbox; @@ -81,12 +80,10 @@ GTK_SHRINK, 0, 0); minel = gtk_spin_button_new_with_range (0, 90, 1); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, minel, + gtk_widget_set_tooltip_text (minel, _("Elevation threshold for passes.\n"\ "Passes with maximum elevation below this limit "\ - "will be omitted"), - NULL); + "will be omitted")); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (minel), 0); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (minel), TRUE); gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (minel), FALSE); @@ -133,10 +130,8 @@ GTK_SHRINK, 0, 0); numpass = gtk_spin_button_new_with_range (5, 50, 1); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, numpass, - _("The maximum number of passes to predict."), - NULL); + gtk_widget_set_tooltip_text (numpass, + _("The maximum number of passes to predict.")); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (numpass), 0); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (numpass), TRUE); gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (numpass), FALSE); @@ -159,11 +154,9 @@ GTK_SHRINK, 0, 0); lookahead = gtk_spin_button_new_with_range (1, 14, 1); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, lookahead, + gtk_widget_set_tooltip_text (lookahead, _("Only passes that occur within the specified "\ - "number of days will be shown."), - NULL); + "number of days will be shown.")); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (lookahead), 0); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (lookahead), TRUE); gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (lookahead), FALSE); @@ -211,11 +204,9 @@ GTK_SHRINK, 0, 0); res = gtk_spin_button_new_with_range (1, 600, 1); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, res, + gtk_widget_set_tooltip_text (res, _("Gpredict will try to show the pass details "\ - "with the specified time resolution."), - NULL); + "with the specified time resolution.")); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (res), 0); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (res), TRUE); gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (res), FALSE); @@ -245,11 +236,9 @@ GTK_SHRINK, 0, 0); nument = gtk_spin_button_new_with_range (10, 200, 1); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, nument, - _("Gpredict will try to keep the number of rows "\ - "in the detailed prediction within this limit."), - NULL); + gtk_widget_set_tooltip_text (nument, + _("Gpredict will try to keep the number of rows " \ + "in the detailed prediction within this limit.")); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (nument), 0); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (nument), TRUE); gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (nument), FALSE); @@ -424,17 +413,14 @@ { GtkWidget *button; GtkWidget *butbox; - GtkTooltips *tips; button = gtk_button_new_with_label (_("Reset")); g_signal_connect (G_OBJECT (button), "clicked", G_CALLBACK (reset_cb), NULL); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, button, - _("Reset settings to the default values."), - NULL); + gtk_widget_set_tooltip_text (button, + _("Reset settings to the default values.")); butbox = gtk_hbutton_box_new (); gtk_button_box_set_layout (GTK_BUTTON_BOX (butbox), GTK_BUTTONBOX_END); Modified: trunk/src/sat-pref-debug.c =================================================================== --- trunk/src/sat-pref-debug.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/sat-pref-debug.c 2011-07-30 23:24:01 UTC (rev 879) @@ -62,7 +62,6 @@ GtkWidget *vbox; /* vbox containing the list part and the details part */ GtkWidget *hbox; GtkWidget *rbut; - GtkTooltips *tips; GtkWidget *label; GtkWidget *butbox; gchar *msg; @@ -139,10 +138,8 @@ /* reset button */ rbut = gtk_button_new_with_label (_("Reset")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, rbut, - _("Reset settings to the default values."), - NULL); + gtk_widget_set_tooltip_text (rbut, + _("Reset settings to the default values.")); g_signal_connect (G_OBJECT (rbut), "clicked", G_CALLBACK (reset_cb), NULL); butbox = gtk_hbutton_box_new (); Modified: trunk/src/sat-pref-formats.c =================================================================== --- trunk/src/sat-pref-formats.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/sat-pref-formats.c 2011-07-30 23:24:01 UTC (rev 879) @@ -89,21 +89,18 @@ GtkWidget *sat_pref_formats_create () { GtkWidget *vbox,*tfbox; - GtkTooltips *tips; gchar *text; /* use local time */ tzcheck = gtk_check_button_new_with_label (_("Show local time instead of UTC.")); gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (tzcheck), sat_cfg_get_bool (SAT_CFG_BOOL_USE_LOCAL_TIME)); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, tzcheck, _(tztips), NULL); + gtk_widget_set_tooltip_text (tzcheck, _(tztips)); /* time format */ tfentry = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (tfentry), TIME_FORMAT_MAX_LENGTH); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, tfentry, _(tftips), NULL); + gtk_widget_set_tooltip_text (tfentry, _(tftips)); text = sat_cfg_get_str (SAT_CFG_STR_TIME_FORMAT); gtk_entry_set_text (GTK_ENTRY (tfentry), text); @@ -117,8 +114,7 @@ /* reset button */ tfreset = gtk_button_new_with_label (_("Reset")); g_signal_connect (tfreset, "clicked", G_CALLBACK (reset_cb), NULL); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, tfreset, _("Reset to default value"), NULL); + gtk_widget_set_tooltip_text (tfreset, _("Reset to default value")); tfbox = gtk_hbox_new (FALSE, 5); gtk_box_pack_start (GTK_BOX (tfbox), gtk_label_new (_("Time format:")), @@ -131,15 +127,13 @@ nsewcheck = gtk_check_button_new_with_label (_("Use N/S/E/W for geographical coordinates.")); gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (nsewcheck), sat_cfg_get_bool (SAT_CFG_BOOL_USE_NSEW)); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, nsewcheck, _(nsewtips), NULL); + gtk_widget_set_tooltip_text (nsewcheck, _(nsewtips)); /* unit */ useimporg = sat_cfg_get_bool (SAT_CFG_BOOL_USE_IMPERIAL); impcheck = gtk_check_button_new_with_label (_("Use Imperial units instead of Metric.")); gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (impcheck), useimporg); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, impcheck, _(imptips), NULL); + gtk_widget_set_tooltip_text (impcheck, _(imptips)); /* connect sat-pref-qth hook */ g_signal_connect (impcheck, "toggled", G_CALLBACK (systog_cb), NULL); Modified: trunk/src/sat-pref-layout.c =================================================================== --- trunk/src/sat-pref-layout.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/sat-pref-layout.c 2011-07-30 23:24:01 UTC (rev 879) @@ -358,7 +358,6 @@ static void create_window_placement (GtkBox *vbox) { GtkWidget *label; - GtkTooltips *tips; /* create header */ @@ -372,13 +371,11 @@ mwin = gtk_check_button_new_with_label (_("Restore position of main window")); gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (mwin), sat_cfg_get_bool (SAT_CFG_BOOL_MAIN_WIN_POS)); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mwin, - _("If you check this button, gpredict will try to "\ - "place the main window at the position it was "\ - "during the last session.\n"\ - "Note that window managers can ignore this request."), - NULL); + gtk_widget_set_tooltip_text (mwin, + _("If you check this button, gpredict will try to " \ + "place the main window at the position it was " \ + "during the last session.\n" \ + "Note that window managers can ignore this request.")); g_signal_connect (G_OBJECT (mwin), "toggled", G_CALLBACK (window_pos_toggle_cb), NULL); gtk_box_pack_start (vbox, mwin, FALSE, FALSE, 0); @@ -387,13 +384,11 @@ mod = gtk_check_button_new_with_label (_("Restore position of module windows")); gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (mod), sat_cfg_get_bool (SAT_CFG_BOOL_MOD_WIN_POS)); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, mod, - _("If you check this button, gpredict will try to "\ - "place the module windows at the position they were "\ - "the last time.\n"\ - "Note that window managers can ignore this request."), - NULL); + gtk_widget_set_tooltip_text (mod, + _("If you check this button, gpredict will try to " \ + "place the module windows at the position they were " \ + "the last time.\n" \ + "Note that window managers can ignore this request.")); g_signal_connect (G_OBJECT (mod), "toggled", G_CALLBACK (window_pos_toggle_cb), NULL); gtk_box_pack_start (vbox, mod, FALSE, FALSE, 0); @@ -402,11 +397,9 @@ state = gtk_check_button_new_with_label (_("Restore the state of modules when reopened (docked or window)")); gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (state), sat_cfg_get_bool (SAT_CFG_BOOL_MOD_STATE)); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, state, - _("If you check this button, gpredict will restore "\ - "the states of the modules from the last time they were used."), - NULL); + gtk_widget_set_tooltip_text (state, + _("If you check this button, gpredict will restore " \ + "the states of the modules from the last time they were used.")); g_signal_connect (G_OBJECT (state), "toggled", G_CALLBACK (window_pos_toggle_cb), NULL); gtk_box_pack_start (vbox, state, FALSE, FALSE, 0); @@ -424,23 +417,19 @@ { GtkWidget *button; GtkWidget *butbox; - GtkTooltips *tips; button = gtk_button_new_with_label (_("Reset")); g_signal_connect (G_OBJECT (button), "clicked", G_CALLBACK (reset_cb), cfg); - tips = gtk_tooltips_new (); if (cfg == NULL) { - gtk_tooltips_set_tip (tips, button, - _("Reset settings to the default values."), - NULL); + gtk_widget_set_tooltip_text (button, + _("Reset settings to the default values.")); } else { - gtk_tooltips_set_tip (tips, button, - _("Reset module settings to the global values."), - NULL); + gtk_widget_set_tooltip_text (button, + _("Reset module settings to the global values.")); } butbox = gtk_hbutton_box_new (); Modified: trunk/src/sat-pref-list-view.c =================================================================== --- trunk/src/sat-pref-list-view.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/sat-pref-list-view.c 2011-07-30 23:24:01 UTC (rev 879) @@ -71,7 +71,6 @@ GtkWidget *sat_pref_list_view_create (GKeyFile *cfg) { GtkWidget *vbox; - GtkTooltips *tips; gint i; GtkWidget *table,*label; @@ -158,13 +157,11 @@ g_signal_connect (G_OBJECT (ruleshint), "toggled", G_CALLBACK (toggle_rh_cb), NULL); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, ruleshint, + gtk_widget_set_tooltip_text (ruleshint, _("Enabling rules hint may make reading across many "\ "columns easier. By default the satlist will be rendered "\ "with alternating colours, but the exact behaviour is "\ - "up to the theme engine."), - NULL); + "up to the theme engine.")); gtk_box_pack_start (GTK_BOX (vbox), gtk_hseparator_new (), FALSE, FALSE, 0); @@ -248,23 +245,19 @@ { GtkWidget *button; GtkWidget *butbox; - GtkTooltips *tips; button = gtk_button_new_with_label (_("Reset")); g_signal_connect (G_OBJECT (button), "clicked", G_CALLBACK (reset_cb), cfg); - tips = gtk_tooltips_new (); if (cfg == NULL) { - gtk_tooltips_set_tip (tips, button, - _("Reset settings to the default values."), - NULL); + gtk_widget_set_tooltip_text (button, + _("Reset settings to the default values.")); } else { - gtk_tooltips_set_tip (tips, button, - _("Reset module settings to the global values."), - NULL); + gtk_widget_set_tooltip_text (button, + _("Reset module settings to the global values.")); } butbox = gtk_hbutton_box_new (); Modified: trunk/src/sat-pref-map-view.c =================================================================== --- trunk/src/sat-pref-map-view.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/sat-pref-map-view.c 2011-07-30 23:24:01 UTC (rev 879) @@ -121,7 +121,6 @@ GtkWidget *table; gchar *mapfile; GdkPixbuf *obuf,*sbuf; - GtkTooltips *tips; /* create header */ @@ -179,9 +178,8 @@ /* select button */ button = gtk_button_new_with_label (_("Select map")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, button, - _("Click to select a map"), NULL); + gtk_widget_set_tooltip_text (button, + _("Click to select a map")); g_signal_connect (G_OBJECT (button), "clicked", G_CALLBACK (select_map_cb), NULL); gtk_table_attach (GTK_TABLE (table), button, 1, 2, 1, 2, @@ -204,7 +202,6 @@ static void create_bool_selectors (GKeyFile *cfg, GtkBox *vbox) { GtkWidget *label; - GtkTooltips *tips; GtkWidget *hbox; @@ -221,10 +218,8 @@ /* QTH info */ qth = gtk_check_button_new_with_label (_("QTH Info")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, qth, - _("Show location information on the map"), - NULL); + gtk_widget_set_tooltip_text (qth, + _("Show location information on the map")); if (cfg != NULL) { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (qth), mod_cfg_get_bool (cfg, @@ -241,10 +236,8 @@ /* Next Event */ next = gtk_check_button_new_with_label (_("Next Event")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, next, - _("Show which satellite comes up next and at what time"), - NULL); + gtk_widget_set_tooltip_text (next, + _("Show which satellite comes up next and at what time")); if (cfg != NULL) { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (next), mod_cfg_get_bool (cfg, @@ -261,10 +254,8 @@ /* Cursor position */ curs = gtk_check_button_new_with_label (_("Cursor Position")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, curs, - _("Show the latitude and longitude of the mouse pointer"), - NULL); + gtk_widget_set_tooltip_text (curs, + _("Show the latitude and longitude of the mouse pointer")); if (cfg != NULL) { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (curs), mod_cfg_get_bool (cfg, @@ -282,10 +273,8 @@ /* Grid */ grid = gtk_check_button_new_with_label (_("Grid Lines")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, grid, - _("Show horizontal and vertical grid lines"), - NULL); + gtk_widget_set_tooltip_text (grid, + _("Show horizontal and vertical grid lines")); if (cfg != NULL) { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (grid), mod_cfg_get_bool (cfg, @@ -313,7 +302,6 @@ static void create_colour_selectors (GKeyFile *cfg, GtkBox *vbox) { GtkWidget *label; - GtkTooltips *tips; GtkWidget *table; guint rgba; /* RRGGBBAA encoded colour */ guint16 alpha; /* alpha channel 16 bits */ @@ -342,10 +330,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (qthc), TRUE); gtk_table_attach (GTK_TABLE (table), qthc, 1, 2, 0, 1, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, qthc, - _("Click to select a colour"), - NULL); + gtk_widget_set_tooltip_text (qthc, + _("Click to select a colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_MAP_SECTION, @@ -369,10 +355,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (gridc), TRUE); gtk_table_attach (GTK_TABLE (table), gridc, 3, 4, 0, 1, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, gridc, - _("Click to select the grid colour"), - NULL); + gtk_widget_set_tooltip_text (gridc, + _("Click to select the grid colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_MAP_SECTION, @@ -396,10 +380,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (tickc), TRUE); gtk_table_attach (GTK_TABLE (table), tickc, 5, 6, 0, 1, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, tickc, - _("Click to select the colour for tick labels"), - NULL); + gtk_widget_set_tooltip_text (tickc, + _("Click to select the colour for tick labels")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_MAP_SECTION, @@ -423,10 +405,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (satc), TRUE); gtk_table_attach (GTK_TABLE (table), satc, 1, 2, 1, 2, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, satc, - _("Click to select satellite colour"), - NULL); + gtk_widget_set_tooltip_text (satc, + _("Click to select satellite colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_MAP_SECTION, @@ -450,10 +430,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (ssatc), TRUE); gtk_table_attach (GTK_TABLE (table), ssatc, 3, 4, 1, 2, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, ssatc, - _("Click to select colour for selected satellites"), - NULL); + gtk_widget_set_tooltip_text (ssatc, + _("Click to select colour for selected satellites")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_MAP_SECTION, @@ -477,10 +455,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (trackc), TRUE); gtk_table_attach (GTK_TABLE (table), trackc, 5, 6, 1, 2, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, trackc, - _("Click to select ground track colour"), - NULL); + gtk_widget_set_tooltip_text (trackc, + _("Click to select ground track colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_MAP_SECTION, @@ -504,10 +480,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (covc), TRUE); gtk_table_attach (GTK_TABLE (table), covc, 1, 2, 2, 3, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, covc, - _("Colour for coverage Area (make it transparent)"), - NULL); + gtk_widget_set_tooltip_text (covc, + _("Colour for coverage Area (make it transparent)")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_MAP_SECTION, @@ -531,10 +505,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (infofg), TRUE); gtk_table_attach (GTK_TABLE (table), infofg, 3, 4, 2, 3, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, infofg, - _("Click to select info text foreground colour"), - NULL); + gtk_widget_set_tooltip_text (infofg, + _("Click to select info text foreground colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_MAP_SECTION, @@ -559,10 +531,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (infobg), TRUE); gtk_table_attach (GTK_TABLE (table), infobg, 5, 6, 2, 3, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, infobg, - _("Click to select info text background colour"), - NULL); + gtk_widget_set_tooltip_text (infobg, + _("Click to select info text background colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_MAP_SECTION, @@ -672,23 +642,19 @@ { GtkWidget *button; GtkWidget *butbox; - GtkTooltips *tips; button = gtk_button_new_with_label (_("Reset")); g_signal_connect (G_OBJECT (button), "clicked", G_CALLBACK (reset_cb), cfg); - tips = gtk_tooltips_new (); if (cfg == NULL) { - gtk_tooltips_set_tip (tips, button, - _("Reset settings to the default values."), - NULL); + gtk_widget_set_tooltip_text (button, + _("Reset settings to the default values.")); } else { - gtk_tooltips_set_tip (tips, button, - _("Reset module settings to the global values."), - NULL); + gtk_widget_set_tooltip_text (button, + _("Reset module settings to the global values.")); } butbox = gtk_hbutton_box_new (); Modified: trunk/src/sat-pref-multi-pass.c =================================================================== --- trunk/src/sat-pref-multi-pass.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/sat-pref-multi-pass.c 2011-07-30 23:24:01 UTC (rev 879) @@ -184,17 +184,14 @@ { GtkWidget *button; GtkWidget *butbox; - GtkTooltips *tips; button = gtk_button_new_with_label (_("Reset")); g_signal_connect (G_OBJECT (button), "clicked", G_CALLBACK (reset_cb), NULL); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, button, - _("Reset settings to the default values."), - NULL); + gtk_widget_set_tooltip_text (button, + _("Reset settings to the default values.")); butbox = gtk_hbutton_box_new (); gtk_button_box_set_layout (GTK_BUTTON_BOX (butbox), GTK_BUTTONBOX_END); Modified: trunk/src/sat-pref-polar-view.c =================================================================== --- trunk/src/sat-pref-polar-view.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/sat-pref-polar-view.c 2011-07-30 23:24:01 UTC (rev 879) @@ -116,10 +116,8 @@ { GtkWidget *label; GtkWidget *hbox; - GtkTooltips *tips; - /* create header */ label = gtk_label_new (NULL); gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); @@ -134,42 +132,33 @@ /* N/E/S/W */ nesw = gtk_radio_button_new_with_label (NULL, "N/E/S/W"); gtk_box_pack_start (GTK_BOX (hbox), nesw, FALSE, TRUE, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, nesw, - "\tN\n"\ - "W\t\tE\n"\ - "\tS", - NULL); + gtk_widget_set_tooltip_text (nesw, + "\tN\n" \ + "W\t\tE\n" \ + "\tS"); /* N/W/S/E */ nwse = gtk_radio_button_new_with_label_from_widget (GTK_RADIO_BUTTON (nesw), "N/W/S/E"); gtk_box_pack_start (GTK_BOX (hbox), nwse, FALSE, TRUE, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, nwse, - "\tN\n"\ - "E\t\tW\n"\ - "\tS", - NULL); - + gtk_widget_set_tooltip_text (nwse, + "\tN\n" \ + "E\t\tW\n" \ + "\tS"); /* S/E/N/W */ senw = gtk_radio_button_new_with_label_from_widget (GTK_RADIO_BUTTON (nesw), "S/E/N/W"); gtk_box_pack_start (GTK_BOX (hbox), senw, FALSE, TRUE, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, senw, - "\tS\n"\ - "W\t\tE\n"\ - "\tN", - NULL); + gtk_widget_set_tooltip_text (senw, + "\tS\n" \ + "W\t\tE\n" \ + "\tN"); /* S/W/N/E */ swne = gtk_radio_button_new_with_label_from_widget (GTK_RADIO_BUTTON (nesw), "S/W/N/E"); gtk_box_pack_start (GTK_BOX (hbox), swne, FALSE, TRUE, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, swne, - "\tS\n"\ - "E\t\tW\n"\ - "\tW", - NULL); + gtk_widget_set_tooltip_text (swne, + "\tS\n" \ + "E\t\tW\n" \ + "\tW"); /* read orientation */ if (cfg != NULL) { @@ -237,7 +226,6 @@ static void create_bool_selectors (GKeyFile *cfg, GtkBox *vbox) { GtkWidget *label; - GtkTooltips *tips; GtkWidget *hbox; @@ -254,10 +242,8 @@ /* QTH info */ qth = gtk_check_button_new_with_label (_("QTH Info")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, qth, - _("Show location information on the polar plot"), - NULL); + gtk_widget_set_tooltip_text (qth, + _("Show location information on the polar plot")); if (cfg != NULL) { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (qth), mod_cfg_get_bool (cfg, @@ -274,10 +260,8 @@ /* Next Event */ next = gtk_check_button_new_with_label (_("Next Event")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, next, - _("Show which satellites comes up next and at what time"), - NULL); + gtk_widget_set_tooltip_text (next, + _("Show which satellites comes up next and at what time")); if (cfg != NULL) { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (next), mod_cfg_get_bool (cfg, @@ -294,10 +278,8 @@ /* Cursor position */ curs = gtk_check_button_new_with_label (_("Cursor Position")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, curs, - _("Show the azimuth and elevation of the mouse pointer"), - NULL); + gtk_widget_set_tooltip_text (curs, + _("Show the azimuth and elevation of the mouse pointer")); if (cfg != NULL) { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (curs), mod_cfg_get_bool (cfg, @@ -315,10 +297,8 @@ /* Extra tick marks */ xtick = gtk_check_button_new_with_label (_("Extra Az Ticks")); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, xtick, - _("Show extra tick marks for every 30\302\260"), - NULL); + gtk_widget_set_tooltip_text (xtick, + _("Show extra tick marks for every 30\302\260")); if (cfg != NULL) { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (xtick), mod_cfg_get_bool (cfg, @@ -346,7 +326,6 @@ static void create_colour_selectors (GKeyFile *cfg, GtkBox *vbox) { GtkWidget *label; - GtkTooltips *tips; GtkWidget *table; guint rgba; /* RRGGBBAA encoded colour */ guint16 alpha; /* alpha channel 16 bits */ @@ -376,10 +355,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (bgd), TRUE); gtk_table_attach (GTK_TABLE (table), bgd, 1, 2, 0, 1, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, bgd, - _("Click to select background colour"), - NULL); + gtk_widget_set_tooltip_text (bgd, + _("Click to select background colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_POLAR_SECTION, @@ -403,10 +380,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (axis), TRUE); gtk_table_attach (GTK_TABLE (table), axis, 3, 4, 0, 1, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, axis, - _("Click to select the axis colour"), - NULL); + gtk_widget_set_tooltip_text (axis, + _("Click to select the axis colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_POLAR_SECTION, @@ -430,10 +405,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (tick), TRUE); gtk_table_attach (GTK_TABLE (table), tick, 5, 6, 0, 1, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, tick, - _("Click to select the colour for tick labels"), - NULL); + gtk_widget_set_tooltip_text (tick, + _("Click to select the colour for tick labels")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_POLAR_SECTION, @@ -457,10 +430,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (sat), TRUE); gtk_table_attach (GTK_TABLE (table), sat, 1, 2, 1, 2, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, sat, - _("Click to select satellite colour"), - NULL); + gtk_widget_set_tooltip_text (sat, + _("Click to select satellite colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_POLAR_SECTION, @@ -484,10 +455,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (ssat), TRUE); gtk_table_attach (GTK_TABLE (table), ssat, 3, 4, 1, 2, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, ssat, - _("Click to select colour for selected satellites"), - NULL); + gtk_widget_set_tooltip_text (ssat, + _("Click to select colour for selected satellites")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_POLAR_SECTION, @@ -511,10 +480,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (track), TRUE); gtk_table_attach (GTK_TABLE (table), track, 5, 6, 1, 2, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, track, - _("Click to select track colour"), - NULL); + gtk_widget_set_tooltip_text (track, + _("Click to select track colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_POLAR_SECTION, @@ -538,10 +505,8 @@ gtk_color_button_set_use_alpha (GTK_COLOR_BUTTON (info), TRUE); gtk_table_attach (GTK_TABLE (table), info, 1, 2, 2, 3, GTK_FILL , GTK_FILL, 0, 0); - tips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tips, info, - _("Click to select background colour"), - NULL); + gtk_widget_set_tooltip_text (info, + _("Click to select background colour")); if (cfg != NULL) { rgba = mod_cfg_get_int (cfg, MOD_CFG_POLAR_SECTION, Modified: trunk/src/sat-pref-qth-editor.c =================================================================== --- trunk/src/sat-pref-qth-editor.c 2011-07-30 21:05:28 UTC (rev 878) +++ trunk/src/sat-pref-qth-editor.c 2011-07-30 23:24:01 UTC (rev 879) @@ -176,7 +176,6 @@ { GtkWidget *table; GtkWidget *label; - GtkTooltips *tooltips; GtkWidget *locbut; GtkWidget *wxbut; @@ -193,13 +192,14 @@ name = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (name), 25); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, name, - _("Enter a short name for this ground station, e.g. callsign.\n"\ - "Allowed characters: 0..9, a..z, A..Z, - and _"), + gtk_widget_set_tooltip_text (name, + _("Enter a short name for this ground station, e.g. callsign.\n" \ + "Allowed characters: 0..9, a..z, A..Z, - and _")); + /* new api does not allow private tip _("The name will be used to identify the ground station when "\ "it is presented to the user. Maximum allowed length "\ "is 25 characters.")); + */ gtk_table_attach_defaults (GTK_TABLE (table), name, 1, 4, 0, 1); /* attach changed signal so that we can enable OK button when @@ -214,12 +214,13 @@ desc = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (desc), 256); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, desc, - _("Enter an optional description for this ground station."), + gtk_widget_set_tooltip_text (desc, + _("Enter an optional description for this ground station.")); + /* new api does not have private tip _("The description can be used as additional "\ "information. It may be included when generating reports. "\ "The maximum length for the description is 256 characters.")); + */ gtk_table_attach_defaults (GTK_TABLE (table), desc, 1, 4, 1, 2); /* location */ @@ -229,10 +230,8 @@ location = gtk_entry_new (); gtk_entry_set_max_length (GTK_ENTRY (location), 50); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, location, - _("Optional location of the ground station, fx. Copenhagen, Denmark."), - NULL); + gtk_widget_set_tooltip_text (location, + _("Optional location of the ground station, fx. Copenhagen, Denmark.")); gtk_table_attach_defaults (GTK_TABLE (table), location, 1, 3, 2, 3); locbut = gpredict_hstock_button (GTK_STOCK_INDEX, _("Select"), @@ -252,10 +251,8 @@ gtk_spin_button_set_increments (GTK_SPIN_BUTTON (lat), 0.0001, 1.0); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (lat), TRUE); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (lat), 4); - tooltips = gtk_tooltips_new (); - gtk_tooltips_set_tip (tooltips, lat, - _("Select the latitude of the ground station in decimal degrees."), - NULL); + gtk_widget_set_tooltip_text (lat, + _("Select the latitude of the ground station in decimal degrees.")); gtk_table_attach_defaults (GTK_TABLE (table), lat, 1, 2, 3, 4); ns = gtk_combo_box_new_text (); @@ -274,9 +271,8 @@ gtk_spin_button_set_increments (GTK_SPIN_BUTTON (lon), 0.0001, 1.0); gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (lon), TRUE); gtk_spin_button_set_digits (GTK_SPIN_BUTTON (lon), 4); - gtk_tooltips_set_tip (tooltips, lon, - _("Select the longitude of the ground stat... [truncated message content] |
From: <aa...@us...> - 2011-07-31 12:26:14
|
Revision: 880 http://gpredict.svn.sourceforge.net/gpredict/?rev=880&view=rev Author: aa1vs Date: 2011-07-31 12:26:07 +0000 (Sun, 31 Jul 2011) Log Message: ----------- Remove deprecated calls and functions to allow make CFLAGS+="-DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED" to work per <http://developer.gnome.org/gtk3/3.0/gtk-migrating-2-to-3.html>. Modified Paths: -------------- trunk/ChangeLog trunk/src/gtk-azel-plot.c trunk/src/gtk-azel-plot.h trunk/src/gtk-event-list.h trunk/src/gtk-freq-knob.c trunk/src/gtk-freq-knob.h trunk/src/gtk-polar-plot.c trunk/src/gtk-polar-plot.h trunk/src/gtk-polar-view.c trunk/src/gtk-polar-view.h trunk/src/gtk-rig-ctrl.h trunk/src/gtk-rot-ctrl.h trunk/src/gtk-rot-knob.c trunk/src/gtk-rot-knob.h trunk/src/gtk-sat-list-col-sel.h trunk/src/gtk-sat-list.h trunk/src/gtk-sat-map.c trunk/src/gtk-sat-map.h trunk/src/gtk-sat-module.h trunk/src/gtk-sat-selector.h trunk/src/gtk-sat-tree.h trunk/src/gtk-single-sat.h trunk/src/gtk-sky-glance.c trunk/src/gtk-sky-glance.h trunk/src/mod-mgr.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/ChangeLog 2011-07-31 12:26:07 UTC (rev 880) @@ -1,3 +1,32 @@ +2011-07-31 Charles Suprin <hamaa1vs at gmail.com> + + * src/gtk-rot-knob.c + * src/gtk-rot-knob.h + * src/gtk-sky-glance.c + * src/gtk-sky-glance.h + * src/gtk-rig-ctrl.h + * src/gtk-sat-list.h + * src/gtk-sat-module.h + * src/gtk-sat-list-col-sel.h + * src/gtk-sat-selector.h + * src/gtk-single-sat.h + * src/gtk-polar-plot.c + * src/gtk-polar-plot.h + * src/gtk-event-list.h + * src/gtk-sat-map.c + * src/gtk-sat-map.h + * src/gtk-freq-knob.c + * src/gtk-freq-knob.h + * src/gtk-azel-plot.c + * src/gtk-rot-ctrl.h + * src/gtk-azel-plot.h + * src/mod-mgr.c + * src/gtk-polar-view.c + * src/gtk-sat-tree.h + * src/gtk-polar-view.h + Remove deprecated calls and functions to allow make CFLAGS+="-DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED" to work per <http://developer.gnome.org/gtk3/3.0/gtk-migrating-2-to-3.html>. + + 2011-07-30 Charles Suprin <hamaa1vs at gmail.com> * src/gtk-azel-plot.h Modified: trunk/src/gtk-azel-plot.c =================================================================== --- trunk/src/gtk-azel-plot.c 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-azel-plot.c 2011-07-31 12:26:07 UTC (rev 880) @@ -82,10 +82,10 @@ static GtkVBoxClass *parent_class = NULL; -GtkType +GType gtk_azel_plot_get_type () { - static GtkType gtk_azel_plot_type = 0; + static GType gtk_azel_plot_type = 0; if (!gtk_azel_plot_type) { static const GTypeInfo gtk_azel_plot_info = { @@ -206,11 +206,11 @@ /* connect size-request signal */ g_signal_connect (GTK_AZEL_PLOT (polv)->canvas, "size-allocate", - G_CALLBACK (size_allocate_cb), polv); + G_CALLBACK (size_allocate_cb), polv); g_signal_connect (GTK_AZEL_PLOT (polv)->canvas, "item_created", - (GtkSignalFunc) on_item_created, polv); + G_CALLBACK (on_item_created), polv); g_signal_connect_after (GTK_AZEL_PLOT (polv)->canvas, "realize", - (GtkSignalFunc) on_canvas_realized, polv); + G_CALLBACK (on_canvas_realized), polv); gtk_widget_show (GTK_AZEL_PLOT (polv)->canvas); @@ -745,7 +745,7 @@ if (!goo_canvas_item_model_get_parent (model)) { /* root item / canvas */ g_signal_connect (item, "motion_notify_event", - (GtkSignalFunc) on_motion_notify, data); + G_CALLBACK (on_motion_notify), data); } } Modified: trunk/src/gtk-azel-plot.h =================================================================== --- trunk/src/gtk-azel-plot.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-azel-plot.h 2011-07-31 12:26:07 UTC (rev 880) @@ -46,11 +46,11 @@ #define AZEL_PLOT_NUM_TICKS 5 -#define GTK_AZEL_PLOT(obj) GTK_CHECK_CAST (obj, gtk_azel_plot_get_type (), GtkAzelPlot) -#define GTK_AZEL_PLOT_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_azel_plot_get_type (), GtkAzelPlotClass) -#define GTK_IS_AZEL_PLOT(obj) GTK_CHECK_TYPE (obj, gtk_azel_plot_get_type ()) +#define GTK_AZEL_PLOT(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, gtk_azel_plot_get_type (), GtkAzelPlot) +#define GTK_AZEL_PLOT_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, gtk_azel_plot_get_type (), GtkAzelPlotClass) +#define GTK_IS_AZEL_PLOT(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_azel_plot_get_type ()) #define GTK_TYPE_AZEL_PLOT (gtk_azel_plot_get_type ()) -#define IS_GTK_AZEL_PLOT(obj) GTK_CHECK_TYPE (obj, gtk_azel_plot_get_type ()) +#define IS_GTK_AZEL_PLOT(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_azel_plot_get_type ()) typedef struct _GtkAzelPlot GtkAzelPlot; typedef struct _GtkAzelPlotClass GtkAzelPlotClass; @@ -102,7 +102,7 @@ -GtkType gtk_azel_plot_get_type (void); +GType gtk_azel_plot_get_type (void); GtkWidget* gtk_azel_plot_new (qth_t *qth, pass_t *pass); Modified: trunk/src/gtk-event-list.h =================================================================== --- trunk/src/gtk-event-list.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-event-list.h 2011-07-31 12:26:07 UTC (rev 880) @@ -41,15 +41,15 @@ #define GTK_TYPE_EVENT_LIST (gtk_event_list_get_type ()) -#define GTK_EVENT_LIST(obj) GTK_CHECK_CAST (obj,\ +#define GTK_EVENT_LIST(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_event_list_get_type (),\ GtkEventList) -#define GTK_EVENT_LIST_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_EVENT_LIST_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_event_list_get_type (),\ GtkEventListClass) -#define IS_GTK_EVENT_LIST(obj) GTK_CHECK_TYPE (obj, gtk_event_list_get_type ()) +#define IS_GTK_EVENT_LIST(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_event_list_get_type ()) typedef struct _gtk_event_list GtkEventList; @@ -103,7 +103,7 @@ } event_list_flag_t; -GtkType gtk_event_list_get_type (void); +GType gtk_event_list_get_type (void); GtkWidget* gtk_event_list_new (GKeyFile *cfgdata, GHashTable *sats, qth_t *qth, Modified: trunk/src/gtk-freq-knob.c =================================================================== --- trunk/src/gtk-freq-knob.c 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-freq-knob.c 2011-07-31 12:26:07 UTC (rev 880) @@ -199,9 +199,9 @@ idx[i], idx[i]+1, 1, 2, GTK_SHRINK, GTK_FILL | GTK_EXPAND, 0, 0); g_signal_connect (GTK_FREQ_KNOB(widget)->evtbox[i], "button_press_event", - (GtkSignalFunc) on_button_press, widget); + (GCallback) on_button_press, widget); g_signal_connect (GTK_FREQ_KNOB(widget)->evtbox[i], "scroll_event", - (GtkSignalFunc) on_button_scroll, widget); + (GCallback) on_button_scroll, widget); /* UP buttons */ Modified: trunk/src/gtk-freq-knob.h =================================================================== --- trunk/src/gtk-freq-knob.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-freq-knob.h 2011-07-31 12:26:07 UTC (rev 880) @@ -41,15 +41,15 @@ #define GTK_TYPE_FREQ_KNOB (gtk_freq_knob_get_type ()) -#define GTK_FREQ_KNOB(obj) GTK_CHECK_CAST (obj,\ +#define GTK_FREQ_KNOB(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_freq_knob_get_type (),\ GtkFreqKnob) -#define GTK_FREQ_KNOB_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_FREQ_KNOB_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_freq_knob_get_type (),\ GtkFreqKnobClass) -#define IS_GTK_FREQ_KNOB(obj) GTK_CHECK_TYPE (obj, gtk_freq_knob_get_type ()) +#define IS_GTK_FREQ_KNOB(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_freq_knob_get_type ()) typedef struct _gtk_freq_knob GtkFreqKnob; @@ -77,7 +77,7 @@ -GtkType gtk_freq_knob_get_type (void); +GType gtk_freq_knob_get_type (void); GtkWidget* gtk_freq_knob_new (gdouble val, gboolean buttons); void gtk_freq_knob_set_value (GtkFreqKnob *knob, gdouble val); gdouble gtk_freq_knob_get_value (GtkFreqKnob *knob); Modified: trunk/src/gtk-polar-plot.c =================================================================== --- trunk/src/gtk-polar-plot.c 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-polar-plot.c 2011-07-31 12:26:07 UTC (rev 880) @@ -93,7 +93,7 @@ static GtkVBoxClass *parent_class = NULL; -GtkType +GType gtk_polar_plot_get_type () { static GType gtk_polar_plot_type = 0; @@ -211,9 +211,9 @@ g_signal_connect (GTK_POLAR_PLOT (polv)->canvas, "size-allocate", G_CALLBACK (size_allocate_cb), polv); g_signal_connect (GTK_POLAR_PLOT (polv)->canvas, "item_created", - (GtkSignalFunc) on_item_created, polv); + (GCallback) on_item_created, polv); g_signal_connect_after (GTK_POLAR_PLOT (polv)->canvas, "realize", - (GtkSignalFunc) on_canvas_realized, polv); + (GCallback) on_canvas_realized, polv); gtk_widget_show (GTK_POLAR_PLOT (polv)->canvas); @@ -1216,7 +1216,7 @@ if (!goo_canvas_item_model_get_parent (model)) { /* root item / canvas */ g_signal_connect (item, "motion_notify_event", - (GtkSignalFunc) on_motion_notify, data); + (GCallback) on_motion_notify, data); } } Modified: trunk/src/gtk-polar-plot.h =================================================================== --- trunk/src/gtk-polar-plot.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-polar-plot.h 2011-07-31 12:26:07 UTC (rev 880) @@ -46,11 +46,11 @@ #define TRACK_TICK_NUM 5 -#define GTK_POLAR_PLOT(obj) GTK_CHECK_CAST (obj, gtk_polar_plot_get_type (), GtkPolarPlot) -#define GTK_POLAR_PLOT_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_polar_plot_get_type (), GtkPolarPlotClass) -#define GTK_IS_POLAR_PLOT(obj) GTK_CHECK_TYPE (obj, gtk_polar_plot_get_type ()) +#define GTK_POLAR_PLOT(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, gtk_polar_plot_get_type (), GtkPolarPlot) +#define GTK_POLAR_PLOT_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, gtk_polar_plot_get_type (), GtkPolarPlotClass) +#define GTK_IS_POLAR_PLOT(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_polar_plot_get_type ()) #define GTK_TYPE_POLAR_PLOT (gtk_polar_plot_get_type ()) -#define IS_GTK_POLAR_PLOT(obj) GTK_CHECK_TYPE (obj, gtk_polar_plot_get_type ()) +#define IS_GTK_POLAR_PLOT(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_polar_plot_get_type ()) typedef struct _GtkPolarPlot GtkPolarPlot; typedef struct _GtkPolarPlotClass GtkPolarPlotClass; @@ -118,7 +118,7 @@ - GtkType gtk_polar_plot_get_type (void); + GType gtk_polar_plot_get_type (void); GtkWidget* gtk_polar_plot_new (qth_t *qth, pass_t *pass); Modified: trunk/src/gtk-polar-view.c =================================================================== --- trunk/src/gtk-polar-view.c 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-polar-view.c 2011-07-31 12:26:07 UTC (rev 880) @@ -97,7 +97,7 @@ static GtkVBoxClass *parent_class = NULL; -GtkType +GType gtk_polar_view_get_type () { static GType gtk_polar_view_type = 0; @@ -255,9 +255,9 @@ g_signal_connect (GTK_POLAR_VIEW (polv)->canvas, "size-allocate", G_CALLBACK (size_allocate_cb), polv); g_signal_connect (GTK_POLAR_VIEW (polv)->canvas, "item_created", - (GtkSignalFunc) on_item_created, polv); + (GCallback) on_item_created, polv); g_signal_connect_after (GTK_POLAR_VIEW (polv)->canvas, "realize", - (GtkSignalFunc) on_canvas_realized, polv); + (GCallback) on_canvas_realized, polv); gtk_widget_show (GTK_POLAR_VIEW (polv)->canvas); @@ -1395,14 +1395,14 @@ if (!goo_canvas_item_model_get_parent (model)) { /* root item / canvas */ g_signal_connect (item, "motion_notify_event", - (GtkSignalFunc) on_motion_notify, data); + (GCallback) on_motion_notify, data); } else if (!g_object_get_data (G_OBJECT (item), "skip-signal-connection")) { g_signal_connect (item, "button_press_event", - (GtkSignalFunc) on_button_press, data); + (GCallback) on_button_press, data); g_signal_connect (item, "button_release_event", - (GtkSignalFunc) on_button_release, data); + (GCallback) on_button_release, data); } } Modified: trunk/src/gtk-polar-view.h =================================================================== --- trunk/src/gtk-polar-view.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-polar-view.h 2011-07-31 12:26:07 UTC (rev 880) @@ -46,11 +46,11 @@ #define TRACK_TICK_NUM 4 -#define GTK_POLAR_VIEW(obj) GTK_CHECK_CAST (obj, gtk_polar_view_get_type (), GtkPolarView) -#define GTK_POLAR_VIEW_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_polar_view_get_type (), GtkPolarViewClass) -#define GTK_IS_POLAR_VIEW(obj) GTK_CHECK_TYPE (obj, gtk_polar_view_get_type ()) +#define GTK_POLAR_VIEW(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, gtk_polar_view_get_type (), GtkPolarView) +#define GTK_POLAR_VIEW_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, gtk_polar_view_get_type (), GtkPolarViewClass) +#define GTK_IS_POLAR_VIEW(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_polar_view_get_type ()) #define GTK_TYPE_POLAR_VIEW (gtk_polar_view_get_type ()) -#define IS_GTK_POLAR_VIEW(obj) GTK_CHECK_TYPE (obj, gtk_polar_view_get_type ()) +#define IS_GTK_POLAR_VIEW(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_polar_view_get_type ()) typedef struct _GtkPolarView GtkPolarView; typedef struct _GtkPolarViewClass GtkPolarViewClass; @@ -140,7 +140,7 @@ -GtkType gtk_polar_view_get_type (void); +GType gtk_polar_view_get_type (void); GtkWidget* gtk_polar_view_new (GKeyFile *cfgdata, GHashTable *sats, Modified: trunk/src/gtk-rig-ctrl.h =================================================================== --- trunk/src/gtk-rig-ctrl.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-rig-ctrl.h 2011-07-31 12:26:07 UTC (rev 880) @@ -44,15 +44,15 @@ #define GTK_TYPE_RIG_CTRL (gtk_rig_ctrl_get_type ()) -#define GTK_RIG_CTRL(obj) GTK_CHECK_CAST (obj,\ +#define GTK_RIG_CTRL(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_rig_ctrl_get_type (),\ GtkRigCtrl) -#define GTK_RIG_CTRL_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_RIG_CTRL_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_rig_ctrl_get_type (),\ GtkRigCtrlClass) -#define IS_GTK_RIG_CTRL(obj) GTK_CHECK_TYPE (obj, gtk_rig_ctrl_get_type ()) +#define IS_GTK_RIG_CTRL(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_rig_ctrl_get_type ()) typedef struct _gtk_rig_ctrl GtkRigCtrl; @@ -123,7 +123,7 @@ -GtkType gtk_rig_ctrl_get_type (void); +GType gtk_rig_ctrl_get_type (void); GtkWidget* gtk_rig_ctrl_new (GtkSatModule *module); void gtk_rig_ctrl_update (GtkRigCtrl *ctrl, gdouble t); Modified: trunk/src/gtk-rot-ctrl.h =================================================================== --- trunk/src/gtk-rot-ctrl.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-rot-ctrl.h 2011-07-31 12:26:07 UTC (rev 880) @@ -43,15 +43,15 @@ #define GTK_TYPE_ROT_CTRL (gtk_rot_ctrl_get_type ()) -#define GTK_ROT_CTRL(obj) GTK_CHECK_CAST (obj,\ +#define GTK_ROT_CTRL(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_rot_ctrl_get_type (),\ GtkRotCtrl) -#define GTK_ROT_CTRL_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_ROT_CTRL_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_rot_ctrl_get_type (),\ GtkRotCtrlClass) -#define IS_GTK_ROT_CTRL(obj) GTK_CHECK_TYPE (obj, gtk_rot_ctrl_get_type ()) +#define IS_GTK_ROT_CTRL(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_rot_ctrl_get_type ()) typedef struct _gtk_rot_ctrl GtkRotCtrl; @@ -108,7 +108,7 @@ -GtkType gtk_rot_ctrl_get_type (void); +GType gtk_rot_ctrl_get_type (void); GtkWidget* gtk_rot_ctrl_new (GtkSatModule *module); void gtk_rot_ctrl_update (GtkRotCtrl *ctrl, gdouble t); Modified: trunk/src/gtk-rot-knob.c =================================================================== --- trunk/src/gtk-rot-knob.c 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-rot-knob.c 2011-07-31 12:26:07 UTC (rev 880) @@ -299,9 +299,9 @@ i, i+1, 1, 2, GTK_SHRINK, GTK_SHRINK, 0, 0); g_signal_connect (GTK_ROT_KNOB(widget)->evtbox[i], "button_press_event", - (GtkSignalFunc) on_button_press, widget); + (GCallback) on_button_press, widget); g_signal_connect (GTK_ROT_KNOB(widget)->evtbox[i], "scroll_event", - (GtkSignalFunc) on_button_scroll, widget); + (GCallback) on_button_scroll, widget); } Modified: trunk/src/gtk-rot-knob.h =================================================================== --- trunk/src/gtk-rot-knob.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-rot-knob.h 2011-07-31 12:26:07 UTC (rev 880) @@ -41,15 +41,15 @@ #define GTK_TYPE_ROT_KNOB (gtk_rot_knob_get_type ()) -#define GTK_ROT_KNOB(obj) GTK_CHECK_CAST (obj,\ +#define GTK_ROT_KNOB(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_rot_knob_get_type (),\ GtkRotKnob) -#define GTK_ROT_KNOB_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_ROT_KNOB_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_rot_knob_get_type (),\ GtkRotKnobClass) -#define IS_GTK_ROT_KNOB(obj) GTK_CHECK_TYPE (obj, gtk_rot_knob_get_type ()) +#define IS_GTK_ROT_KNOB(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_rot_knob_get_type ()) typedef struct _gtk_rot_knob GtkRotKnob; @@ -77,7 +77,7 @@ -GtkType gtk_rot_knob_get_type (void); +GType gtk_rot_knob_get_type (void); GtkWidget* gtk_rot_knob_new (gdouble min, gdouble max, gdouble val); void gtk_rot_knob_set_value (GtkRotKnob *knob, gdouble val); gdouble gtk_rot_knob_get_value (GtkRotKnob *knob); Modified: trunk/src/gtk-sat-list-col-sel.h =================================================================== --- trunk/src/gtk-sat-list-col-sel.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-sat-list-col-sel.h 2011-07-31 12:26:07 UTC (rev 880) @@ -38,15 +38,15 @@ #define GTK_TYPE_SAT_LIST_COL_SEL (gtk_sat_list_col_sel_get_type ()) -#define GTK_SAT_LIST_COL_SEL(obj) GTK_CHECK_CAST (obj,\ +#define GTK_SAT_LIST_COL_SEL(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_sat_list_col_sel_get_type (),\ GtkSatListColSel) -#define GTK_SAT_LIST_COL_SEL_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_SAT_LIST_COL_SEL_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_sat_list_col_sel_get_type (),\ GtkSatListColSelClass) -#define IS_GTK_SAT_LIST_COL_SEL(obj) GTK_CHECK_TYPE (obj, gtk_sat_list_col_sel_get_type ()) +#define IS_GTK_SAT_LIST_COL_SEL(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_sat_list_col_sel_get_type ()) @@ -70,7 +70,7 @@ }; -GtkType gtk_sat_list_col_sel_get_type (void); +GType gtk_sat_list_col_sel_get_type (void); GtkWidget *gtk_sat_list_col_sel_new (guint32 flags); guint32 gtk_sat_list_col_sel_get_flags (GtkSatListColSel *sel); void gtk_sat_list_col_sel_set_flags (GtkSatListColSel *sel, guint32 flags); Modified: trunk/src/gtk-sat-list.h =================================================================== --- trunk/src/gtk-sat-list.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-sat-list.h 2011-07-31 12:26:07 UTC (rev 880) @@ -41,15 +41,15 @@ #define GTK_TYPE_SAT_LIST (gtk_sat_list_get_type ()) -#define GTK_SAT_LIST(obj) GTK_CHECK_CAST (obj,\ +#define GTK_SAT_LIST(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_sat_list_get_type (),\ GtkSatList) -#define GTK_SAT_LIST_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_SAT_LIST_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_sat_list_get_type (),\ GtkSatListClass) -#define IS_GTK_SAT_LIST(obj) GTK_CHECK_TYPE (obj, gtk_sat_list_get_type ()) +#define IS_GTK_SAT_LIST(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_sat_list_get_type ()) typedef struct _gtk_sat_list GtkSatList; @@ -143,7 +143,7 @@ } sat_list_flag_t; -GtkType gtk_sat_list_get_type (void); +GType gtk_sat_list_get_type (void); GtkWidget* gtk_sat_list_new (GKeyFile *cfgdata, GHashTable *sats, qth_t *qth, Modified: trunk/src/gtk-sat-map.c =================================================================== --- trunk/src/gtk-sat-map.c 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-sat-map.c 2011-07-31 12:26:07 UTC (rev 880) @@ -114,7 +114,7 @@ /** \brief Register the satellite map widget. */ -GtkType +GType gtk_sat_map_get_type () { static GType gtk_sat_map_type = 0; @@ -281,9 +281,9 @@ g_signal_connect (GTK_SAT_MAP (satmap)->canvas, "size-allocate", G_CALLBACK (size_allocate_cb), satmap); g_signal_connect (GTK_SAT_MAP (satmap)->canvas, "item_created", - (GtkSignalFunc) on_item_created, satmap); + (GCallback) on_item_created, satmap); g_signal_connect_after (GTK_SAT_MAP (satmap)->canvas, "realize", - (GtkSignalFunc) on_canvas_realized, satmap); + (GCallback) on_canvas_realized, satmap); gtk_widget_show (GTK_SAT_MAP (satmap)->canvas); @@ -875,14 +875,14 @@ if (!goo_canvas_item_model_get_parent (model)) { /* root item / canvas */ g_signal_connect (item, "motion_notify_event", - (GtkSignalFunc) on_motion_notify, data); + (GCallback) on_motion_notify, data); } else if (!g_object_get_data (G_OBJECT (item), "skip-signal-connection")) { g_signal_connect (item, "button_press_event", - (GtkSignalFunc) on_button_press, data); + (GCallback) on_button_press, data); g_signal_connect (item, "button_release_event", - (GtkSignalFunc) on_button_release, data); + (GCallback) on_button_release, data); } } Modified: trunk/src/gtk-sat-map.h =================================================================== --- trunk/src/gtk-sat-map.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-sat-map.h 2011-07-31 12:26:07 UTC (rev 880) @@ -46,11 +46,11 @@ #define SAT_MAP_RANGE_CIRCLE_POINTS 180 /*!< Number of points used to plot a satellite range half circle. */ -#define GTK_SAT_MAP(obj) GTK_CHECK_CAST (obj, gtk_sat_map_get_type (), GtkSatMap) -#define GTK_SAT_MAP_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_sat_map_get_type (), GtkSatMapClass) -#define GTK_IS_SAT_MAP(obj) GTK_CHECK_TYPE (obj, gtk_sat_map_get_type ()) +#define GTK_SAT_MAP(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, gtk_sat_map_get_type (), GtkSatMap) +#define GTK_SAT_MAP_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, gtk_sat_map_get_type (), GtkSatMapClass) +#define GTK_IS_SAT_MAP(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_sat_map_get_type ()) #define GTK_TYPE_SAT_MAP (gtk_sat_map_get_type ()) -#define IS_GTK_SAT_MAP(obj) GTK_CHECK_TYPE (obj, gtk_sat_map_get_type ()) +#define IS_GTK_SAT_MAP(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_sat_map_get_type ()) //typedef struct _GtkSatMap GtkSatMap; @@ -169,7 +169,7 @@ }; -GtkType gtk_sat_map_get_type (void); +GType gtk_sat_map_get_type (void); GtkWidget* gtk_sat_map_new (GKeyFile *cfgdata, GHashTable *sats, qth_t *qth); Modified: trunk/src/gtk-sat-module.h =================================================================== --- trunk/src/gtk-sat-module.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-sat-module.h 2011-07-31 12:26:07 UTC (rev 880) @@ -72,15 +72,15 @@ #define GTK_TYPE_SAT_MODULE (gtk_sat_module_get_type ()) -#define GTK_SAT_MODULE(obj) GTK_CHECK_CAST (obj,\ +#define GTK_SAT_MODULE(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_sat_module_get_type (), \ GtkSatModule) -#define GTK_SAT_MODULE_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_SAT_MODULE_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_sat_module_get_type (),\ GtkSatModuleClass) -#define IS_GTK_SAT_MODULE(obj) GTK_CHECK_TYPE (obj, gtk_sat_module_get_type ()) +#define IS_GTK_SAT_MODULE(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_sat_module_get_type ()) typedef struct _gtk_sat_module GtkSatModule; @@ -165,7 +165,7 @@ }; -GtkType gtk_sat_module_get_type (void); +GType gtk_sat_module_get_type (void); GtkWidget* gtk_sat_module_new (const gchar *cfgfile); Modified: trunk/src/gtk-sat-selector.h =================================================================== --- trunk/src/gtk-sat-selector.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-sat-selector.h 2011-07-31 12:26:07 UTC (rev 880) @@ -61,15 +61,15 @@ #define GTK_TYPE_SAT_SELECTOR (gtk_sat_selector_get_type ()) -#define GTK_SAT_SELECTOR(obj) GTK_CHECK_CAST (obj,\ +#define GTK_SAT_SELECTOR(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_sat_selector_get_type (),\ GtkSatSelector) -#define GTK_SAT_SELECTOR_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_SAT_SELECTOR_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_sat_selector_get_type (),\ GtkSatSelectorClass) -#define IS_GTK_SAT_SELECTOR(obj) GTK_CHECK_TYPE (obj, gtk_sat_selector_get_type ()) +#define IS_GTK_SAT_SELECTOR(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_sat_selector_get_type ()) /** \brief The GtkSatSelector structure */ @@ -99,7 +99,7 @@ }; -GtkType gtk_sat_selector_get_type (void); +GType gtk_sat_selector_get_type (void); GtkWidget *gtk_sat_selector_new (guint flags); guint32 gtk_sat_selector_get_flags (GtkSatSelector *selector); void gtk_sat_selector_get_selected (GtkSatSelector *selector, gint *catnum, gchar **satname, gdouble *epoch); Modified: trunk/src/gtk-sat-tree.h =================================================================== --- trunk/src/gtk-sat-tree.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-sat-tree.h 2011-07-31 12:26:07 UTC (rev 880) @@ -62,15 +62,15 @@ #define GTK_TYPE_SAT_TREE (gtk_sat_tree_get_type ()) -#define GTK_SAT_TREE(obj) GTK_CHECK_CAST (obj,\ +#define GTK_SAT_TREE(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_sat_tree_get_type (),\ GtkSatTree) -#define GTK_SAT_TREE_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_SAT_TREE_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_sat_tree_get_type (),\ GtkSatTreeClass) -#define IS_GTK_SAT_TREE(obj) GTK_CHECK_TYPE (obj, gtk_sat_tree_get_type ()) +#define IS_GTK_SAT_TREE(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_sat_tree_get_type ()) /** \brief The GtkSatTree structure */ @@ -96,7 +96,7 @@ }; -GtkType gtk_sat_tree_get_type (void); +GType gtk_sat_tree_get_type (void); GtkWidget *gtk_sat_tree_new (guint flags); guint32 gtk_sat_tree_get_flags (GtkSatTree *tree); void gtk_sat_tree_select (GtkSatTree *sat_tree, guint catnum); Modified: trunk/src/gtk-single-sat.h =================================================================== --- trunk/src/gtk-single-sat.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-single-sat.h 2011-07-31 12:26:07 UTC (rev 880) @@ -100,15 +100,15 @@ #define GTK_TYPE_SINGLE_SAT (gtk_single_sat_get_type ()) -#define GTK_SINGLE_SAT(obj) GTK_CHECK_CAST (obj,\ +#define GTK_SINGLE_SAT(obj) G_TYPE_CHECK_INSTANCE_CAST (obj,\ gtk_single_sat_get_type (),\ GtkSingleSat) -#define GTK_SINGLE_SAT_CLASS(klass) GTK_CHECK_CLASS_CAST (klass,\ +#define GTK_SINGLE_SAT_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass,\ gtk_single_sat_get_type (),\ GtkSingleSatClass) -#define IS_GTK_SINGLE_SAT(obj) GTK_CHECK_TYPE (obj, gtk_single_sat_get_type ()) +#define IS_GTK_SINGLE_SAT(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_single_sat_get_type ()) typedef struct _gtk_single_sat GtkSingleSat; @@ -152,7 +152,7 @@ -GtkType gtk_single_sat_get_type (void); +GType gtk_single_sat_get_type (void); GtkWidget* gtk_single_sat_new (GKeyFile *cfgdata, GHashTable *sats, qth_t *qth, Modified: trunk/src/gtk-sky-glance.c =================================================================== --- trunk/src/gtk-sky-glance.c 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-sky-glance.c 2011-07-31 12:26:07 UTC (rev 880) @@ -114,7 +114,7 @@ static GtkVBoxClass *parent_class = NULL; -GtkType +GType gtk_sky_glance_get_type () { static GType gtk_sky_glance_type = 0; @@ -303,9 +303,9 @@ g_signal_connect (GTK_SKY_GLANCE (skg)->canvas, "size-allocate", G_CALLBACK (size_allocate_cb), skg); g_signal_connect (GTK_SKY_GLANCE (skg)->canvas, "item_created", - (GtkSignalFunc) on_item_created, skg); + (GCallback) on_item_created, skg); g_signal_connect_after (GTK_SKY_GLANCE (skg)->canvas, "realize", - (GtkSignalFunc) on_canvas_realized, skg); + (GCallback) on_canvas_realized, skg); gtk_widget_show (GTK_SKY_GLANCE (skg)->canvas); @@ -691,14 +691,14 @@ if (!goo_canvas_item_model_get_parent (model)) { /* root item / canvas */ - g_signal_connect (item, "motion_notify_event", (GtkSignalFunc) on_motion_notify, data); + g_signal_connect (item, "motion_notify_event", (GCallback) on_motion_notify, data); } else if (!g_object_get_data (G_OBJECT (item), "skip-signal-connection")) { - //g_signal_connect (item, "button_press_event", (GtkSignalFunc) on_button_press, data); - g_signal_connect (item, "button_release_event", (GtkSignalFunc) on_button_release, data); - g_signal_connect (item, "enter_notify_event", (GtkSignalFunc) on_mouse_enter, data); - g_signal_connect (item, "leave_notify_event", (GtkSignalFunc) on_mouse_leave, data); + //g_signal_connect (item, "button_press_event", (GCallback) on_button_press, data); + g_signal_connect (item, "button_release_event", (GCallback) on_button_release, data); + g_signal_connect (item, "enter_notify_event", (GCallback) on_mouse_enter, data); + g_signal_connect (item, "leave_notify_event", (GCallback) on_mouse_leave, data); } } Modified: trunk/src/gtk-sky-glance.h =================================================================== --- trunk/src/gtk-sky-glance.h 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/gtk-sky-glance.h 2011-07-31 12:26:07 UTC (rev 880) @@ -43,11 +43,11 @@ -#define GTK_SKY_GLANCE(obj) GTK_CHECK_CAST (obj, gtk_sky_glance_get_type (), GtkSkyGlance) -#define GTK_SKY_GLANCE_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_sky_glance_get_type (), GtkSkyGlanceClass) -#define GTK_IS_SKY_GLANCE(obj) GTK_CHECK_TYPE (obj, gtk_sky_glance_get_type ()) +#define GTK_SKY_GLANCE(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, gtk_sky_glance_get_type (), GtkSkyGlance) +#define GTK_SKY_GLANCE_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, gtk_sky_glance_get_type (), GtkSkyGlanceClass) +#define GTK_IS_SKY_GLANCE(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_sky_glance_get_type ()) #define GTK_TYPE_SKY_GLANCE (gtk_sky_glance_get_type ()) -#define IS_GTK_SKY_GLANCE(obj) GTK_CHECK_TYPE (obj, gtk_sky_glance_get_type ()) +#define IS_GTK_SKY_GLANCE(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, gtk_sky_glance_get_type ()) typedef struct _GtkSkyGlance GtkSkyGlance; typedef struct _GtkSkyGlanceClass GtkSkyGlanceClass; @@ -113,7 +113,7 @@ -GtkType gtk_sky_glance_get_type (void); +GType gtk_sky_glance_get_type (void); GtkWidget* gtk_sky_glance_new (GHashTable *sats, qth_t *qth, gdouble ts); /* Modified: trunk/src/mod-mgr.c =================================================================== --- trunk/src/mod-mgr.c 2011-07-30 23:24:01 UTC (rev 879) +++ trunk/src/mod-mgr.c 2011-07-31 12:26:07 UTC (rev 880) @@ -76,7 +76,7 @@ static void update_window_title (void); static void switch_page_cb (GtkNotebook *notebook, - GtkNotebookPage *page, + gpointer *page, guint page_num, gpointer user_data); @@ -571,7 +571,7 @@ } static void switch_page_cb (GtkNotebook *notebook, - GtkNotebookPage *page, + gpointer *page, guint page_num, gpointer user_data) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-08-09 23:11:39
|
Revision: 882 http://gpredict.svn.sourceforge.net/gpredict/?rev=882&view=rev Author: aa1vs Date: 2011-08-09 23:11:33 +0000 (Tue, 09 Aug 2011) Log Message: ----------- Use newest tle available in file tle update. Modified Paths: -------------- trunk/ChangeLog trunk/src/tle-update.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-08-05 00:46:59 UTC (rev 881) +++ trunk/ChangeLog 2011-08-09 23:11:33 UTC (rev 882) @@ -1,3 +1,10 @@ +2011-08-09 Charles Suprin <hamaa1vs at gmail.com> + + * ChangeLog + * src/tle-update.c + Use newest tle available in file tle update. + + 2011-08-04 Charles Suprin <hamaa1vs at gmail.com> * ChangeLog Modified: trunk/src/tle-update.c =================================================================== --- trunk/src/tle-update.c 2011-08-05 00:46:59 UTC (rev 881) +++ trunk/src/tle-update.c 2011-08-09 23:11:33 UTC (rev 882) @@ -891,11 +891,28 @@ ntle->srcfile = g_strdup (fnam); ntle->isnew = TRUE; /* flag will be reset when using data */ - g_hash_table_insert (data, key, ntle); retcode++; } else { + /* if the satellite in the hash is older than + the one just loaded, copy the values over. */ + ntle = g_hash_table_lookup (data, key); + + if (ntle->epoch <tle.epoch) { + ntle->catnum = catnr; + ntle->epoch = tle.epoch; + g_free (ntle->satname); + ntle->satname = g_strdup (g_strchomp(tle_str[0])); + g_free (ntle->line1); + ntle->line1 = g_strdup (tle_str[1]); + g_free (ntle->line2); + ntle->line2 = g_strdup (tle_str[2]); + g_free (ntle->srcfile); + ntle->srcfile = g_strdup (fnam); + ntle->isnew = TRUE; /* flag will be reset when using data */ + } + /* free the key since we do not commit it to the cache */ g_free (key); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-08-09 23:23:59
|
Revision: 883 http://gpredict.svn.sourceforge.net/gpredict/?rev=883&view=rev Author: aa1vs Date: 2011-08-09 23:23:53 +0000 (Tue, 09 Aug 2011) Log Message: ----------- Fixes bug 3271573: Track button in rotator controller has no effect. Modified Paths: -------------- trunk/ChangeLog trunk/NEWS trunk/src/gtk-rot-ctrl.c Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-08-09 23:11:33 UTC (rev 882) +++ trunk/ChangeLog 2011-08-09 23:23:53 UTC (rev 883) @@ -4,7 +4,12 @@ * src/tle-update.c Use newest tle available in file tle update. + * ChangeLog + * NEWS + * src/gtk-rot-ctrl.c + Fixes bug 3271573: Track button in rotator controller has no effect. + 2011-08-04 Charles Suprin <hamaa1vs at gmail.com> * ChangeLog Modified: trunk/NEWS =================================================================== --- trunk/NEWS 2011-08-09 23:11:33 UTC (rev 882) +++ trunk/NEWS 2011-08-09 23:23:53 UTC (rev 883) @@ -11,6 +11,7 @@ - Fixed bug 3309110: 100% on manual time adjustment. - Fixed bug 3272993: Issue controlling Yaesu FT-847. - Fixed bug 3334657: Old log files not being saved. +- Fixed bug 3271573: Track button in rotator controller has no effect. Changes in version 1.3 (1 Mar 2011) Modified: trunk/src/gtk-rot-ctrl.c =================================================================== --- trunk/src/gtk-rot-ctrl.c 2011-08-09 23:11:33 UTC (rev 882) +++ trunk/src/gtk-rot-ctrl.c 2011-08-09 23:23:53 UTC (rev 883) @@ -930,12 +930,17 @@ if ((ctrl->conf->aztype == ROT_AZ_TYPE_180) && (setaz > 180.0)) { setaz = setaz- 360.0; } + if (!(ctrl->engaged)) { + gtk_rot_knob_set_value (GTK_ROT_KNOB (ctrl->AzSet), setaz); + gtk_rot_knob_set_value (GTK_ROT_KNOB (ctrl->ElSet), setel); + } } else { setaz = gtk_rot_knob_get_value (GTK_ROT_KNOB (ctrl->AzSet)); setel = gtk_rot_knob_get_value (GTK_ROT_KNOB (ctrl->ElSet)); } + if ((ctrl->engaged) && (ctrl->conf != NULL)) { /* read back current value from device */ @@ -1038,7 +1043,7 @@ setaz = sat->az; } } - + /* send controller values to rotator device */ /* this is the newly computed value which should be ahead of the current position */ if (!set_pos (ctrl, setaz, setel)) { @@ -1063,7 +1068,7 @@ _("%s: MAX_ERROR_COUNT (%d) reached. Disengaging device!"), __FUNCTION__, MAX_ERROR_COUNT); ctrl->errcnt = 0; - g_print ("ERROR. WROPS: %d RDOPS: %d\n", ctrl->wrops, ctrl->rdops); + //g_print ("ERROR. WROPS: %d RDOPS: %d\n", ctrl->wrops, ctrl->rdops); } else { /* increment error counter */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aa...@us...> - 2011-08-09 23:30:07
|
Revision: 884 http://gpredict.svn.sourceforge.net/gpredict/?rev=884&view=rev Author: aa1vs Date: 2011-08-09 23:30:00 +0000 (Tue, 09 Aug 2011) Log Message: ----------- Eliminates DATADIR from defines to avoid mingw32 problem with winsock. Modified Paths: -------------- trunk/ChangeLog trunk/src/Makefile.am Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-08-09 23:23:53 UTC (rev 883) +++ trunk/ChangeLog 2011-08-09 23:30:00 UTC (rev 884) @@ -9,7 +9,11 @@ * src/gtk-rot-ctrl.c Fixes bug 3271573: Track button in rotator controller has no effect. + * ChangeLog + * src/Makefile.am + Eliminates DATADIR from defines to avoid mingw32 problem with winsock. + 2011-08-04 Charles Suprin <hamaa1vs at gmail.com> * ChangeLog Modified: trunk/src/Makefile.am =================================================================== --- trunk/src/Makefile.am 2011-08-09 23:23:53 UTC (rev 883) +++ trunk/src/Makefile.am 2011-08-09 23:30:00 UTC (rev 884) @@ -4,7 +4,6 @@ INCLUDES = \ @PACKAGE_CFLAGS@ -I.. \ - -DDATADIR=\""$(datadir)"\" \ -DPACKAGE_DATA_DIR=\""$(datadir)/gpredict"\" \ -DPACKAGE_PIXMAPS_DIR=\""$(datadir)/pixmaps/gpredict"\" \ -DPACKAGE_LOCALE_DIR=\""$(prefix)/share/locale"\" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |