* Sets the top scroll position within the scroller.
169953
function(inTop) {
		this.stop();
		if (this.translateOptimized) {
			var m = this.$.scrollMath;
			m.setScrollY(-inTop);
			m.stabilize();
		} else {
			this.inherited(arguments);
		}
	}
1122665
public void resetPosition() {

        // fail if no positioning parent given
        assert m_positioningParent != null;
        if (m_positioningParent != null) {
            setPosition(m_positioningParent.getOffsetHeight(), m_positioningParent.getOffsetWidth(), 0, 0);
        }
    }
617884
@SuppressWarnings("unchecked")
	public void scrollToTop() {
		if(config.commandLogging){
			Log.d(config.commandLoggingTag, "scrollToTop()");
		}
		
		View recyclerView = viewFetcher.getRecyclerView(true, 0);
		if(recyclerView != null){
			waiter.waitForViews(true, AbsListView.class, ScrollView.class, WebView.class, recyclerView.getClass());
		}
		else {
			waiter.waitForViews(true, AbsListView.class, ScrollView.class, WebView.class);
		}
		scroller.scroll(Scroller.UP, true);
	}
429649
private void notifyOnScrolled(final boolean scrolledToTop, final boolean scrolledToBottom) {
        for (ScrollListener listener : scrollListeners) {
            listener.onScrolled(scrolledToTop, scrolledToBottom);
        }
    }
84818
protected void adjustHeight() {

        if ((m_scrollPanel != null) && (m_resourceItem != null)) {
            m_scrollPanel.getElement().getStyle().setPropertyPx(
                "maxHeight",
                getAvailableHeight(m_resourceItem.getOffsetHeight()));
        }
        center();
    }
1292439
function() {
			switch(that.settings.position) {
				case 'top':
					that.bar.css('top', 0);
					break;
				case 'bottom':
					that.bar.css('bottom', 0);
					break;
				default:
					that.bar.css('top', 0);
			}
		}
790098
public void setHeight(int height) {

        m_defaultHeight = height;
        m_scrollPanel.setHeight(m_defaultHeight + "px");
        m_scrollPanel.setDefaultHeight(m_defaultHeight);
        m_scrollPanel.onResizeDescendant();
    }
184409
function() {
        var isWindow = this.container.is(window),
            eTop = this.element.offset().top,
            offset,
            offsets = [];

        if (this.element.css('overflow') === 'auto' && !this.element.is('body')) {
            this.element[0].scrollTop = 0; // Set scroll to top so offsets are correct
        }

        this.targets = $(this.options.target);

        this.markers = $(this.options.marker).each(function(index, marker) {
            offset = $(marker).offset();

            if (!isWindow) {
                offset.top -= eTop;
            }

            offsets.push(offset);
        });

        this.offsets = offsets;
    }
93695
private void onScrollPositionChanged(int oldScrollPosition, int newScrollPosition) {
		int newScrollDirection;

		if (newScrollPosition < oldScrollPosition) {
			newScrollDirection = SCROLL_TO_TOP;
		} else {
			newScrollDirection = SCROLL_TO_BOTTOM;
		}

		if (directionHasChanged(newScrollDirection)) {
			translateYAnimatedView(newScrollDirection);
		}
	}
881421
def go_up(self):
        """"""
        vsb = self.scrollarea.verticalScrollBar()
        vsb.setValue(int(vsb.value() - vsb.singleStep()))
960960
public void setPosition(int height, int width, int positionLeft, int positionTop) {

        positionLeft -= m_borderOffset;

        // make sure highlighting does not introduce additional horizontal scroll-bars
        if ((m_positioningParent == null) && (positionLeft < 0)) {
            // position left should not be negative
            width += positionLeft;
            positionLeft = 0;
        }
        width += (2 * m_borderOffset) - BORDER_WIDTH;
        if ((m_positioningParent == null)
            && (Window.getClientWidth() < (width + positionLeft))
            && (Window.getScrollLeft() == 0)) {
            // highlighting should not extend over the right hand
            width = Window.getClientWidth() - (positionLeft + BORDER_WIDTH);
        }
        Style style = getElement().getStyle();
        style.setLeft(positionLeft, Unit.PX);
        style.setTop(positionTop - m_borderOffset, Unit.PX);
        setHeight((height + (2 * m_borderOffset)) - BORDER_WIDTH);
        setWidth(width);
    }
406936
function setValue(s) {
            var txt = this.getValue();
            if (txt !== s){
                if (this.position !== null) {
                    this.position.setOffset(0);
                }
                this.scrollManager.scrollTo(0, 0);
                this.$super(s);
            }
            return this;
        }
665893
public void scrollUp() {
        logger.entering();
        WebElement webElement = this.findElement(By.className(SCROLLVIEW_CLASS));
        swipeUp(webElement);
        logger.exiting();
    }
16002
void adjustScroll() {

        iTreeHeight = iRowHeight * (iRowCount + 1);

        // correct would be iMaxTextLength + iMaxIndent*iIndentWidth
        iTreeWidth = iMaxTextLength * 2;

        sbHoriz.setValues(iX, iWidth, 0, iTreeWidth);

        int v = iY / iRowHeight,
            h = iHeight / iRowHeight;

        sbVert.setValues(v, h, 0, iRowCount + 1);

        iX = sbHoriz.getValue();
        iY = iRowHeight * sbVert.getValue();
    }
125010
function updateScroll() {
      if (!self.element.li[0]) return;
      var height = self.element.li[0].offsetHeight,
        top = height * self.index,
        bot = top + height,
        hgt = self.element.scroller.clientHeight,
        scrollTop = self.element.scroller.scrollTop;
      if (top<scrollTop) {
        scrollTo(top);
      }else if (bot>scrollTop + hgt) {
        scrollTo(bot - hgt);
      }
    }
790644
public void centerHorizontally(int top) {

        if (Position.FIXED.getCssName().equals(getElement().getStyle().getPosition())) {
            show();
            // keep position fixed, as may have been set to absolute
            setPositionFixed();
            int left = (Window.getClientWidth() - getOffsetWidth()) >> 1;
            setPopupPosition(Math.max(left, 0), Math.max(top, 0));
        } else {
            show();
            int left = (Window.getClientWidth() - getOffsetWidth()) >> 1;
            setPopupPosition(Math.max(Window.getScrollLeft() + left, 0), Math.max(Window.getScrollTop() + top, 0));
        }
    }
211487
public void updateScrollbar()
	{
		UIComponent parent = getParent();
		IScrollable scrollable = getScrollable();
		int delta = 0;// hasVisibleOtherScrollbar() ? scrollThickness() : 0;
		boolean hide = false;
		float offset = offset();
		if (isHorizontal())
		{
			if (scrollable.contentSize().width() <= parent.size().width() - delta)
				hide = true;
		}
		else
		{
			if (scrollable.contentSize().height() <= parent.size().height() - delta)
				hide = true;
		}

		if (hide == isEnabled() || offset < 0)
			scrollTo(0);
		if (offset > 1)
			scrollTo(1);
		//setEnabled(!hide);
		if (autoHide)
			setVisible(!hide);
	}