示例#1
0
void ScrollBar::mouseWheelMoved(const MouseWheelEventUnrecPtr e)
{
    if(getEnabled())
    {
        if(e->getScrollType() == MouseWheelEvent::BLOCK_SCROLL)
        {
            scrollBlock(-e->getScrollAmount());
        }
        else if(e->getScrollType() == MouseWheelEvent::UNIT_SCROLL)
        {
            scrollUnit(-e->getUnitsToScroll());
        }
    }
    ComponentContainer::mouseWheelMoved(e);
}
示例#2
0
void ContentPanel::SceneEditorPanelListener::mouseWheelMoved(const MouseWheelEventUnrecPtr e)
{
    Navigator& TheNav(_ContentPanel->_ApplicationPlayer->getDebugSceneNavigator());
    TheNav.setDistance(TheNav.getDistance() + e->getUnitsToScroll() * TheNav.getMotionFactor());
}