|
|
|
|
Forum
Please
Log In
to post a new message or reply to an existing one. If you are not registered, please
register.
NOTE: Some forums may be read-only if you are not currently subscribed to
our technical support services.
Subject |
Author |
Date |
|
tera tera
|
Aug 26, 2009 - 12:27 AM
|
Hello. When I clicked the point of the red frame, I do not want to perform On/Off of the check box.
When I clicked the point of the green frame, I want to perform On/Off of the check box.
|
|
Technical Support
|
Aug 28, 2009 - 1:48 PM
|
We already fixed this issue. Thank you. Here is the updated tree control:
http://www.prof-uis.com/download/forums/tmp/Updated-CExtTreeCtrl-for-TeraT.zip
Here is the required update for the drag-n-drop detection methods:
bool CExtControlBar::stat_DragDetect_ImplStep(
HWND hWnd,
POINT pt,
UINT nUpMessage // = WM_LBUTTONUP
)
{
if( hWnd == NULL || (! ::IsWindow( hWnd ) ) )
return false;
CSize sizeDrag( ::GetSystemMetrics( SM_CXDRAG ), ::GetSystemMetrics( SM_CYDRAG ) );
CRect rc( pt.x - sizeDrag.cx, pt.y - sizeDrag.cy, pt.x + sizeDrag.cx, pt.y + sizeDrag.cy );
::SetCapture( hWnd );
for( MSG _msg; ::IsWindow( hWnd ) ; )
{
for( ;
::IsWindow( hWnd )
&& ( ::PeekMessage( &_msg, hWnd, WM_MOUSEFIRST, WM_MOUSELAST, PM_NOREMOVE )
|| ::PeekMessage( &_msg, 0, WM_CANCELMODE, WM_CANCELMODE, PM_NOREMOVE )
|| ::PeekMessage( &_msg, 0, WM_ACTIVATEAPP, WM_ACTIVATEAPP, PM_NOREMOVE )
)
;
)
{
if( _msg.message == nUpMessage
|| _msg.message == WM_CANCELMODE
|| _msg.message == WM_ACTIVATEAPP
)
{
::ReleaseCapture();
return false;
}
::PeekMessage( &_msg, hWnd, _msg.message, _msg.message, PM_REMOVE );
if( _msg.message == WM_MOUSEMOVE )
{
CPoint ptMessage( LOWORD( _msg.lParam ), HIWORD( _msg.lParam ) );
if( ! rc.PtInRect( ptMessage ) )
{
ReleaseCapture();
return true;
}
}
}
::WaitMessage();
}
return false;
}
bool CExtControlBar::stat_DoDragDetect(
HWND hWnd,
const POINT & ptWndClient,
UINT nUpMessage // = WM_LBUTTONUP
)
{
if( hWnd == NULL || (! ::IsWindow( hWnd ) ) )
return false;
CPoint ptScreen = ptWndClient;
::ClientToScreen( hWnd, &ptScreen );
for( ; stat_DragDetect_ImplStep( hWnd, ptScreen, nUpMessage ) ; )
{
POINT ptCursorPos = { -32767, -32767 };
if( ! ::GetCursorPos( &ptCursorPos ) )
return false;
if( ptScreen == ptCursorPos )
continue; //only drag time elapsed but mouse is not moved
return true;
}
return false;
}
|
|
tera tera
|
Aug 31, 2009 - 10:53 PM
|
Please upload a revision in profuis-com. Thanks,
|
|
Technical Support
|
Sep 1, 2009 - 11:37 AM
|
We have just uploaded it.
|
|
Technical Support
|
Aug 27, 2009 - 4:55 AM
|
|
|
tera tera
|
Aug 28, 2009 - 12:03 AM
|
The check box does not react even if I click check box.
|
|