[Gpredict-svn] SF.net SVN: gpredict:[106] trunk
Real time satellite tracking and orbit prediction
Status: Beta
Brought to you by:
csete
|
From: <cs...@us...> - 2008-09-10 23:52:50
|
Revision: 106
http://gpredict.svn.sourceforge.net/gpredict/?rev=106&view=rev
Author: csete
Date: 2008-09-10 23:53:00 +0000 (Wed, 10 Sep 2008)
Log Message:
-----------
Updated.
Modified Paths:
--------------
trunk/ChangeLog
trunk/src/gtk-polar-plot.c
trunk/src/gtk-rot-ctrl.c
trunk/src/gtk-rot-ctrl.h
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2008-09-10 23:24:10 UTC (rev 105)
+++ trunk/ChangeLog 2008-09-10 23:53:00 UTC (rev 106)
@@ -1,3 +1,14 @@
+2008-09-10; Alexandru Csete <oz...@gm...>
+
+ * src/gtk-polar-plot.[ch]:
+ Added API to add/modify/delete the pass.
+ Changed to create local copy of the pass data.
+
+ * src/gtk-rot-ctrl.c:
+ Use new polar plot widget for showing status of target satellite
+ and rotator. However, this part has been disabled for now.
+
+
2008-09-09; Alexandru Csete <oz...@gm...>
* src/sat-pref-conditions.c:
Modified: trunk/src/gtk-polar-plot.c
===================================================================
--- trunk/src/gtk-polar-plot.c 2008-09-10 23:24:10 UTC (rev 105)
+++ trunk/src/gtk-polar-plot.c 2008-09-10 23:53:00 UTC (rev 106)
@@ -241,8 +241,8 @@
{
GooCanvasItemModel *root;
gint idx,i;
-
-#if 0
+
+
/* remove sky track, time ticks and the pass itself */
if (plot->pass != NULL) {
/* remove sat from canvas */
@@ -263,9 +263,10 @@
}
if (pass != NULL) {
- create_track (GTK_POLAR_PLOT (plot));
+ plot->pass = copy_pass (pass);
+ create_track (plot);
}
-#endif
+
}
Modified: trunk/src/gtk-rot-ctrl.c
===================================================================
--- trunk/src/gtk-rot-ctrl.c 2008-09-10 23:24:10 UTC (rev 105)
+++ trunk/src/gtk-rot-ctrl.c 2008-09-10 23:53:00 UTC (rev 106)
@@ -41,6 +41,7 @@
#include "compat.h"
#include "sat-log.h"
#include "predict-tools.h"
+#include "gtk-polar-plot.h"
#include "gtk-rot-knob.h"
#include "gtk-rot-ctrl.h"
#ifdef HAVE_CONFIG_H
@@ -139,6 +140,7 @@
ctrl->target = NULL;
ctrl->pass = NULL;
ctrl->qth = NULL;
+ ctrl->plot = NULL;
ctrl->tracking = FALSE;
ctrl->busy = FALSE;
@@ -196,21 +198,21 @@
gdk_rgb_find_color (gtk_widget_get_colormap (widget), &ColGreen);
/* create contents */
- table = gtk_table_new (3, 2, TRUE);
- gtk_table_set_row_spacings (GTK_TABLE (table), 5);
- gtk_table_set_col_spacings (GTK_TABLE (table), 5);
+ table = gtk_table_new (2, 3, FALSE);
+ gtk_table_set_row_spacings (GTK_TABLE (table), 0);
+ gtk_table_set_col_spacings (GTK_TABLE (table), 0);
gtk_container_set_border_width (GTK_CONTAINER (table), 10);
gtk_table_attach (GTK_TABLE (table), create_az_widgets (GTK_ROT_CTRL (widget)),
- 0, 1, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+ 0, 1, 0, 1, GTK_FILL, GTK_SHRINK, 0, 0);
gtk_table_attach (GTK_TABLE (table), create_el_widgets (GTK_ROT_CTRL (widget)),
- 1, 2, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+ 1, 2, 0, 1, GTK_FILL, GTK_SHRINK, 0, 0);
gtk_table_attach (GTK_TABLE (table), create_target_widgets (GTK_ROT_CTRL (widget)),
- 0, 1, 1, 2, GTK_FILL, GTK_FILL, 0, 0);
+ 0, 1, 1, 2, GTK_FILL, GTK_SHRINK, 0, 0);
gtk_table_attach (GTK_TABLE (table), create_conf_widgets (GTK_ROT_CTRL (widget)),
- 0, 1, 2, 3, GTK_FILL, GTK_FILL, 0, 0);
- gtk_table_attach (GTK_TABLE (table), create_plot_widget (GTK_ROT_CTRL (widget)),
- 1, 2, 1, 3, GTK_FILL, GTK_FILL, 0, 0);
-
+ 1, 2, 1, 2, GTK_FILL, GTK_SHRINK, 0, 0);
+/* gtk_table_attach (GTK_TABLE (table), create_plot_widget (GTK_ROT_CTRL (widget)),
+ 2, 3, 0, 2, GTK_FILL | GTK_EXPAND, GTK_FILL | GTK_EXPAND, 0, 0);
+*/
gtk_container_add (GTK_CONTAINER (widget), table);
GTK_ROT_CTRL (widget)->timerid = g_timeout_add (GTK_ROT_CTRL (widget)->delay,
@@ -528,7 +530,10 @@
{
GtkWidget *frame;
+ ctrl->plot = gtk_polar_plot_new (ctrl->qth, ctrl->pass);
+
frame = gtk_frame_new (NULL);
+ gtk_container_add (GTK_CONTAINER (frame), ctrl->plot);
return frame;
}
@@ -579,6 +584,10 @@
}
}
+
+ /* in either case, we set the new pass (even if NULL) on the polar plot */
+ if (ctrl->plot != NULL)
+ gtk_polar_plot_set_pass (GTK_POLAR_PLOT (ctrl->plot), ctrl->pass);
}
Modified: trunk/src/gtk-rot-ctrl.h
===================================================================
--- trunk/src/gtk-rot-ctrl.h 2008-09-10 23:24:10 UTC (rev 105)
+++ trunk/src/gtk-rot-ctrl.h 2008-09-10 23:53:00 UTC (rev 106)
@@ -71,6 +71,7 @@
/* other widgets */
GtkWidget *SatCnt;
GtkWidget *DevSel;
+ GtkWidget *plot; /*!< Polar plot widget */
/* satellites */
GSList *sats; /*!< List of sats in parent module */
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|