Exemplo n.º 1
0
void TreeItem::handleEvent(Event* evt)
{
	StringW* type = evt->get_type();

	EventPhaseType phase = evt->get_eventPhase();
	if (phase != CAPTURING_PHASE)
	{
		if (type == MouseEvent::mousedown)
		{
			OnLButtonDown(static_cast<MouseEvent*>(evt));
			evt->stopPropagation();
		}
		else if (*type == L"ActivateItem")
		{
			m_Span->set_Background(new SolidColorBrush(new Color(120, 140, 200)));
			InvalidateRender();	// TODO, shouldn't be necessary
		}
		else if (*type == L"DeactivateItem")
		{
			m_Span->set_Background(NULL);
			InvalidateRender();	// TODO, shouldn't be necessary
		}
	}
}
Exemplo n.º 2
0
void ScrollContentPresenter::SetVerticalOffset(double verticalOffset)
{
    m_verticalOffset = verticalOffset;
    InvalidateRender();
}
Exemplo n.º 3
0
void ScrollContentPresenter::SetHorizontalOffset(double horizontalOffset)
{
    m_horizontalOffset = horizontalOffset;
    InvalidateRender();
}