Exemple #1
0
void HUD_Tooltip::Update( float fTime )
{
	if ( m_bEnabled == false)
		return;

	m_Panel.Update(fTime);
	
	// TODO: call HUD_Object static function MOUSE COLLIDE
	POINT pMousePos;
	GetCursorPos(&pMousePos);
	ScreenToClient(CRenderManager::GetInstance()->WindowHandle(), &pMousePos);
	//////////////////////////////////////////////////////////////////////////

	xPosition( float(pMousePos.x) );
	yPosition(pMousePos.y - m_rBorder.m_fHeight);
	m_txtHeader.XPosition( m_rBorder.m_fX );
	m_txtHeader.YPosition( m_rBorder.m_fY );
	m_txtBody.XPosition(m_txtHeader.XPosition());
	m_txtBody.YPosition(m_txtHeader.Height() + m_txtHeader.YPosition());
	m_Panel.XPosition(m_rBorder.m_fX);
	m_Panel.YPosition(m_rBorder.m_fY);
}
Exemple #2
0
int LocationCamera::x()
{
    return xPosition() - width()/2;
}
unsigned int LocationCamera::x()
{
    return xPosition() - width()*0.5;
}