Professional UI Solutions
Site Map   /  Register
 
 

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.

Forums » Prof-UIS General Discussion » Tooltip problem Collapse All
Subject Author Date
Mori Dec 14, 2002 - 12:55 PM

Hi Sergiy,

I don’t know if you already fix this problem, but I notice that when you insert a combo box in toolbar, the tooltip for some buttons disappear.
You can see that in ProfStudio sample.

Regards,
Mori

Sergiy Lavrynenko Dec 15, 2002 - 11:49 AM

Hi Mori,

I can not confirm this bug. The toolbar button have tool-tip/status-tiip if it have appropriate texts for these tips in the application’s string-table resource. I was too lazy to type tips for all the toolbar buttons in the ProfStudio example :-)

Best regards,
Sergiy Lavrynenko.

Mori Dec 15, 2002 - 2:46 PM

Hi Sergiy,

The problem occurr in Standard toolbar with combo box (if no combo it’s ok),
the entries in string table exists and ready for tooltips (...\n...).
The sequence of buttons is:
ID_FILE_NEW, ID_FILE_SAVE, ID_FILE_SAVE_ALL, ID_FILE_PRINT and etc.
If you use a Combobox in Toolbar the tooltip are functional for all items except for ID_FILE_NEW, ID_FILE_SAVE, ID_FILE_SAVE_ALL.

Others toolbars are ok.

Best regards,
Mori

Sergiy Lavrynenko Dec 17, 2002 - 12:09 AM

Dear Mori,

You really found a bug which is related to the standard MFC tooltip hit testing mechanism usage. I apologize. Please replace CExtToolControlBar::OnToolHitTest() function in the ExtToolControlBar.h file with this new one:

-------------------------------------------
int CExtToolControlBar::OnToolHitTest(
CPoint point,
TOOLINFO* pTI
) const
{
ASSERT_VALID( this );

if( CExtToolControlBar::g_bMenuTracking
|| CExtPopupMenuWnd::IsMenuTracking()
)
return -1;

int nToolTipHit =
((CExtToolControlBar*)this)->
HitTest(point);
if( nToolTipHit < 0 )
return -1;
CExtBarButton * pTBB =
_GetButtonPtr( nToolTipHit );
ASSERT_VALID( pTBB );
if( pTBB != NULL )
{
nToolTipHit = pTBB->OnToolHitTest( point, pTI );
if( nToolTipHit != -1 )
return nToolTipHit;
}

nToolTipHit =
CExtControlBar::OnToolHitTest(
point,
pTI
);
return nToolTipHit;
}
-------------------------------------------

Best regards,
Sergiy Lavrynenko.