几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量

几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 (http://www.dimcax.com/hust/index.php)
-   DirectDWG (http://www.dimcax.com/hust/forumdisplay.php?f=89)
-   -   【转帖】gsmodel and selec (http://www.dimcax.com/hust/showthread.php?t=16447)

yang686526 2009-05-05 11:42 AM

【转帖】gsmodel and selec
 
gsmodel and select
gsmodel and select
i am using the wingdi sample renderer in my viewing application. it is statically linked.
so far, almost everything is working well. i can display, zoom in/out/etc, turn layers on and off, select, and highlight (draw selected elements in our application-defined "select color").
if i enable gsmodel (enablegsmodel(true)), i cannot select elements. the selected function of my odgsselectionreactor object does not get called, even if i put the mouse pointer right on top of an element. i am able to select without any problems if i disable gsmodel (enablegsmodel(false)).
using odamfcapp, i am able to select elements whether or not gsmodel is enabled. so far, i have not been able to find anything special in odamfcapp regarding gsmodel, aside from the calls that enable it or disable it.
is there something special that i need to do to make select work while gsmodel is enabled?
i am using the last version before 1.14.01 (1.13.02?).

dear namesake,
it works in odamfcapp probably due to these lines in file editorobject.cpp, function odexeditorobject::selectobjects.
code:
// currently (v 1.13.0) inside-only-select is not fully supported
// so make rect to specify crossing-select...
if(rect.left < rect.right)
std::swap(rect.left, rect.right);
pview->select((odgsdcpoint*)&rect, 2, &selectionreactor);
these lines are recommended in case 1.14.01 too.
sincerely yours,
george udov
thanks for the information. that fixed my problem.


所有的时间均为北京时间。 现在的时间是 07:03 PM.