Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
809428e4
Commit
809428e4
authored
Oct 12, 2005
by
claes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no_con_obstacle added for CArea objects
parent
7c56bb0d
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
26 additions
and
19 deletions
+26
-19
xtt/lib/flow/src/flow.h
xtt/lib/flow/src/flow.h
+2
-1
xtt/lib/flow/src/flow_api.cpp
xtt/lib/flow/src/flow_api.cpp
+6
-1
xtt/lib/flow/src/flow_api.h
xtt/lib/flow/src/flow_api.h
+2
-1
xtt/lib/flow/src/flow_node.cpp
xtt/lib/flow/src/flow_node.cpp
+2
-2
xtt/lib/flow/src/flow_nodeclass.cpp
xtt/lib/flow/src/flow_nodeclass.cpp
+11
-13
xtt/lib/flow/src/flow_nodeclass.h
xtt/lib/flow/src/flow_nodeclass.h
+3
-1
No files found.
xtt/lib/flow/src/flow.h
View file @
809428e4
/*
* Proview $Id: flow.h,v 1.
7 2005-09-01 14:56:12
claes Exp $
* Proview $Id: flow.h,v 1.
8 2005-10-12 12:56:28
claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
...
...
@@ -395,6 +395,7 @@ typedef enum {
flow_eSave_NodeClass_nc_name
=
300
,
flow_eSave_NodeClass_a
=
301
,
flow_eSave_NodeClass_group
=
302
,
flow_eSave_NodeClass_no_con_obstacle
=
303
,
flow_eSave_ConClass_cc_name
=
400
,
flow_eSave_ConClass_con_type
=
401
,
flow_eSave_ConClass_corner
=
402
,
...
...
xtt/lib/flow/src/flow_api.cpp
View file @
809428e4
/*
* Proview $Id: flow_api.cpp,v 1.
3 2005-09-01 14:56:12
claes Exp $
* Proview $Id: flow_api.cpp,v 1.
4 2005-10-12 12:56:28
claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
...
...
@@ -675,3 +675,8 @@ void flow_SetClickSensitivity( flow_tCtx ctx, int value)
{
flow_draw_set_click_sensitivity
(
ctx
,
value
);
}
void
flow_SetNoConObstacle
(
flow_tNodeClass
nc
,
int
no_obstacle
)
{
((
FlowNodeClass
*
)
nc
)
->
set_no_con_obstacle
(
no_obstacle
);
}
xtt/lib/flow/src/flow_api.h
View file @
809428e4
/*
* Proview $Id: flow_api.h,v 1.
3 2005-09-01 14:56:12
claes Exp $
* Proview $Id: flow_api.h,v 1.
4 2005-10-12 12:56:28
claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
...
...
@@ -230,6 +230,7 @@ int flow_GetConPointTraceAttr( flow_tObject object, int num, char *trace_attr,
int
flow_GetConPoint
(
flow_tObject
object
,
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
);
void
flow_SetClickSensitivity
(
flow_tCtx
ctx
,
int
value
);
void
flow_SetNoConObstacle
(
flow_tNodeClass
nc
,
int
no_obstacle
);
#if defined __cplusplus
}
...
...
xtt/lib/flow/src/flow_node.cpp
View file @
809428e4
/*
* Proview $Id: flow_node.cpp,v 1.
4 2005-09-01 14:56:12
claes Exp $
* Proview $Id: flow_node.cpp,v 1.
5 2005-10-12 12:56:28
claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
...
...
@@ -968,7 +968,7 @@ void FlowNode::get_borders()
x_left
=
y_low
=
1e37
;
x_right
=
y_high
=
-
1e37
;
get_node_borders
();
if
(
nc
->
group
==
flow_eNodeGroup_Document
)
if
(
nc
->
group
==
flow_eNodeGroup_Document
||
nc
->
no_con_obstacle
)
{
obst_x_left
=
obst_y_low
=
1e37
;
obst_x_right
=
obst_y_high
=
-
1e37
;
...
...
xtt/lib/flow/src/flow_nodeclass.cpp
View file @
809428e4
/*
* Proview $Id: flow_nodeclass.cpp,v 1.
4 2005-09-01 14:56:12
claes Exp $
* Proview $Id: flow_nodeclass.cpp,v 1.
5 2005-10-12 12:56:28
claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
...
...
@@ -29,7 +29,7 @@
FlowNodeClass
::
FlowNodeClass
(
FlowCtx
*
flow_ctx
,
char
*
name
,
flow_eNodeGroup
grp
)
:
ctx
(
flow_ctx
),
a
(
10
,
10
),
group
(
grp
)
:
ctx
(
flow_ctx
),
a
(
10
,
10
),
group
(
grp
)
,
no_con_obstacle
(
0
)
{
strcpy
(
nc_name
,
name
);
}
...
...
@@ -55,6 +55,7 @@ void FlowNodeClass::save( ofstream& fp, flow_eSaveMode mode)
fp
<<
int
(
flow_eSave_NodeClass_a
)
<<
endl
;
a
.
save
(
fp
,
mode
);
fp
<<
int
(
flow_eSave_NodeClass_group
)
<<
FSPACE
<<
int
(
group
)
<<
endl
;
fp
<<
int
(
flow_eSave_NodeClass_no_con_obstacle
)
<<
FSPACE
<<
no_con_obstacle
<<
endl
;
fp
<<
int
(
flow_eSave_End
)
<<
endl
;
}
...
...
@@ -76,6 +77,7 @@ void FlowNodeClass::open( ifstream& fp)
break
;
case
flow_eSave_NodeClass_a
:
a
.
open
(
ctx
,
fp
);
break
;
case
flow_eSave_NodeClass_group
:
fp
>>
tmp
;
group
=
(
flow_eNodeGroup
)
tmp
;
break
;
case
flow_eSave_NodeClass_no_con_obstacle
:
fp
>>
no_con_obstacle
;
break
;
case
flow_eSave_End
:
end_found
=
1
;
break
;
default:
cout
<<
"FlowNodeClass:open syntax error"
<<
endl
;
...
...
@@ -308,18 +310,14 @@ void FlowNodeClass::get_obstacle_borders( double pos_x, double pos_y, double *x_
{
int
i
;
switch
(
group
)
{
case
flow_eNodeGroup_Document
:
for
(
i
=
0
;
i
<
a
.
a_size
;
i
++
)
{
if
(
a
.
a
[
i
]
->
type
()
==
flow_eObjectType_Rect
)
a
.
a
[
i
]
->
get_borders
(
pos_x
,
pos_y
,
x_right
,
x_left
,
y_high
,
y_low
,
node
);
}
break
;
default:
a
.
get_borders
(
pos_x
,
pos_y
,
x_right
,
x_left
,
y_high
,
y_low
,
node
);
if
(
group
==
flow_eNodeGroup_Document
||
no_con_obstacle
)
{
for
(
i
=
0
;
i
<
a
.
a_size
;
i
++
)
{
if
(
a
.
a
[
i
]
->
type
()
==
flow_eObjectType_Rect
)
a
.
a
[
i
]
->
get_borders
(
pos_x
,
pos_y
,
x_right
,
x_left
,
y_high
,
y_low
,
node
);
}
}
else
a
.
get_borders
(
pos_x
,
pos_y
,
x_right
,
x_left
,
y_high
,
y_low
,
node
);
}
void
FlowNodeClass
::
get_object_name
(
char
*
name
)
...
...
xtt/lib/flow/src/flow_nodeclass.h
View file @
809428e4
/*
* Proview $Id: flow_nodeclass.h,v 1.
3 2005-09-01 14:56:12
claes Exp $
* Proview $Id: flow_nodeclass.h,v 1.
4 2005-10-12 12:56:28
claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
...
...
@@ -67,10 +67,12 @@ class FlowNodeClass : public FlowArrayElem {
void
move_widgets
(
void
*
node
,
int
x
,
int
y
);
int
get_conpoint_trace_attr
(
int
num
,
char
*
trace_attr
,
flow_eTraceType
*
type
);
void
set_no_con_obstacle
(
int
no_obstacle
)
{
no_con_obstacle
=
no_obstacle
;}
FlowCtx
*
ctx
;
FlowArray
a
;
char
nc_name
[
80
];
flow_eNodeGroup
group
;
int
no_con_obstacle
;
};
#endif
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment