Commit 893ee66d authored by Claes Sjofors's avatar Claes Sjofors

rt_xtt evenlist, block events wasn't inserted in correct order

parent bec79080
...@@ -1044,6 +1044,7 @@ void EvList::event_block( mh_sBlock *msg) ...@@ -1044,6 +1044,7 @@ void EvList::event_block( mh_sBlock *msg)
char name[80]; char name[80];
flow_eDest dest_code; flow_eDest dest_code;
brow_tNode dest_node; brow_tNode dest_node;
ItemAlarm *dest;
sts = gdh_ObjidToName( msg->Outunit, name, sizeof(name), sts = gdh_ObjidToName( msg->Outunit, name, sizeof(name),
cdh_mName_path | cdh_mName_object); cdh_mName_path | cdh_mName_object);
...@@ -1068,8 +1069,15 @@ void EvList::event_block( mh_sBlock *msg) ...@@ -1068,8 +1069,15 @@ void EvList::event_block( mh_sBlock *msg)
} }
strcat( text, name); strcat( text, name);
sts = get_destination( net_NetTimeToTime( &event->Info.EventTime), (void **)&dest);
if ( EVEN(sts)) {
dest_code = flow_eDest_IntoLast; dest_code = flow_eDest_IntoLast;
dest_node = NULL; dest_node = NULL;
}
else {
dest_code = flow_eDest_Before;
dest_node = dest->node;
}
ItemAlarm *item = new ItemAlarm( this, "Alarm", ItemAlarm *item = new ItemAlarm( this, "Alarm",
net_NetTimeToTime( &event->Info.EventTime), text, net_NetTimeToTime( &event->Info.EventTime), text,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment