aboutsummaryrefslogtreecommitdiff
path: root/generic/Track.c
diff options
context:
space:
mode:
authorlecoanet2000-11-13 09:01:16 +0000
committerlecoanet2000-11-13 09:01:16 +0000
commitec14ac908fd8c0b8b21f4ef456cbc7d9dac890fa (patch)
treefcbfc8dca338786128641ff26bbe28128240471c /generic/Track.c
parentd7c07a327c1c11fba39ead43dffaff871244631f (diff)
downloadtkzinc-ec14ac908fd8c0b8b21f4ef456cbc7d9dac890fa.zip
tkzinc-ec14ac908fd8c0b8b21f4ef456cbc7d9dac890fa.tar.gz
tkzinc-ec14ac908fd8c0b8b21f4ef456cbc7d9dac890fa.tar.bz2
tkzinc-ec14ac908fd8c0b8b21f4ef456cbc7d9dac890fa.tar.xz
La visibilit� est renseign�e dans le retour de SendTrackToOm
(correction bug).
Diffstat (limited to 'generic/Track.c')
-rw-r--r--generic/Track.c31
1 files changed, 26 insertions, 5 deletions
diff --git a/generic/Track.c b/generic/Track.c
index 69121b8..f61c661 100644
--- a/generic/Track.c
+++ b/generic/Track.c
@@ -1015,7 +1015,6 @@ ToArea(Item item,
*
**********************************************************************************
*/
-
static void
Draw(Item item)
{
@@ -1215,6 +1214,22 @@ Draw(Item item)
/*
**********************************************************************************
*
+ * Render --
+ *
+ **********************************************************************************
+ */
+static void
+Render(Item item)
+{
+ /* WidgetInfo *wi = item->wi;
+ TrackItem track = (TrackItem) item;*/
+
+}
+
+
+/*
+ **********************************************************************************
+ *
* IsSensitive --
*
**********************************************************************************
@@ -1418,10 +1433,10 @@ SendTrackToOm(void *ptr,
int *y,
int *sv_dx,
int *sv_dy,
- int *label_x,
+ /* int *label_x,
int *label_y,
int *label_width,
- int *label_height,
+ int *label_height,*/
int *rho,
int *theta,
int *visibility)
@@ -1466,7 +1481,8 @@ SendTrackToOm(void *ptr,
*/
*sv_dx = track->speed_vector.x;
*sv_dy = track->speed_vector.y;
-
+
+ /* Fri Oct 13 15:16:38 2000
*label_x = track->field_set.label_pos.x;
*label_y = wi->height - track->field_set.label_pos.y;
if (track->field_set.label_format) {
@@ -1480,8 +1496,10 @@ SendTrackToOm(void *ptr,
*label_width = 0;
*label_height = 0;
}
+ */
*rho = sqrt(track->label_dx*track->label_dx + track->label_dy*track->label_dy);
*theta = track->label_angle;
+ *visibility = ISSET(current_item->flags, VISIBLE_BIT);
break;
}
@@ -1510,6 +1528,7 @@ SetLabelAngleFromOm(void *ptr, /* No longer in use. */
if ((theta >= 0) && (track->label_angle != theta)) {
track->label_angle = theta;
+ SET(track->flags, POLAR_BIT);
ITEM.Invalidate((Item) item, ZN_COORDS_FLAG);
}
}
@@ -1697,7 +1716,7 @@ Part(Item item,
Tcl_Obj **part_spec,
int *part)
{
- char *part_str;
+ char *part_str="";
int c;
char *end;
@@ -1802,6 +1821,7 @@ static ItemClassStruct TRACK_ITEM_CLASS = {
ComputeCoordinates,
ToArea,
Draw,
+ Render,
IsSensitive,
Pick,
NULL, /* PickVertex */
@@ -1834,6 +1854,7 @@ static ItemClassStruct WAY_POINT_ITEM_CLASS = {
ComputeCoordinates,
ToArea,
Draw,
+ Render,
IsSensitive,
Pick,
NULL, /* PickVertex */