Tuesday, June 2, 2009

move a dialog without a caption

how can you move a dialog without a caption (title)?

Thanks to bimba.






simply add this code:

UINT CClientRectDlg:: OnNcHitTest(CPoint point)
{
UINT ret = CDialog:: OnNcHitTest(point);
if(ret == HTCLIENT)
return HTCAPTION;
else return ret;
}

you have to add this to the message_map ON_WM_NCHITTEST()

Nice ah?

0 תגובות:

Post a Comment

 
Home | About | Link | Link
Simple Proff Blogger Template Created By Herro | Inspiring By Busy Bee Woo Themes