|
static void do_ugopen_api(void)1 U* Q* f# J! G: u7 y( R( I- _" B
{- Z, z- ^1 U& y q |9 V# [( r4 n
int irc = 0;
( ^. Y% }) z/ b4 E# ]- K char *message = "Select Objects";
) Y1 E' f" A& Y& H$ y: w8 ^ UF_UI_selection_options_t opts;9 n m) R& b l; y; N S! G
UF_UI_mask_t mask[1] = {{UF_circle_type, 0, 0}};
( W3 `& F9 n9 {! W! h. ^
" H$ ^; s+ s: v( i, ~( O5 u int response, count;
# D( X' p' Q/ Q+ e& c; b5 { tag_t objects;
8 O+ [ m' ?4 ^( M+ k+ S5 Z tag_p_t object;
4 H: Y, r8 }1 K9 K tag_t obj;! \$ J1 D4 g% C1 @7 i: y; G
1 |3 T7 e& E' [& y- z opts.other_options = 0;
! \9 u; f" c& c opts.reserved = NULL;/ ]* E) a. _; V L7 T
opts.num_mask_triples = 1;
& @/ L' S3 P( U8 A7 I2 I2 g) A opts.scope = UF_UI_SEL_SCOPE_ANY_IN_ASSEMBLY;
5 s: m% p3 g6 Z! k( s opts.mask_triples = &mask[0];
6 J4 U' J N) Q/ t //* set selection scope to be work part & occurrence */
& H4 a$ i7 y2 q) Z* H& I irc = UF_UI_select_by_class(' Y7 W5 \. ^ ]5 t
message,&opts,&response,&count,&object );
_9 ^- F9 h: \/ h //* if no error, print information about selected objects */
: t& @1 ]8 c; C
1 l' l3 D6 ~, a/ C2 \5 j if(!irc)
$ P1 e4 T& ~/ C! u& B {
) [0 L% N/ ^) h+ H' z if (object != NULL)) N* i: I" E! U! B6 I( L' P( A' q
{
* u+ O2 P/ ~9 _ UF_DISP_set_highlight(object[0],0);7 a6 d: y4 X1 h f
obj = UF_ASSEM_ask_work_occurrence();
8 B# m) u- _" D, C( ]3 n( S UF_CALL(UF_WAVE_create_linked_body(object[0],obj,true,&objects));8 @8 i* e6 O0 H5 v
UF_MODL_update();: E8 {, a6 y8 t$ o
}" f2 Q+ _% L+ N5 x: V
}
8 ?+ ?, K. i8 [5 R8 S$ x UF_free(object);
1 O: M& v- k( Y}& H% C$ B! g$ R' D- M. a0 W
程序实现后没反应,求高手帮忙指点,是不是我的函数找错了还是函数用错了?? |
|