// Decompiled by Jad v1.5.8e. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/kpdus/jad.html
// Decompiler options: braces fieldsfirst space lnc 

package com.weidongjian.meitu.wheelviewdemo.view;

import java.util.TimerTask;

final class SmoothScrollTimerTask extends TimerTask {

    int realTotalOffset;
    int realOffset;
    int offset;
    final LoopView loopView;

    SmoothScrollTimerTask(LoopView loopview, int offset) {
        this.loopView = loopview;
        this.offset = offset;
        realTotalOffset = Integer.MAX_VALUE;
        realOffset = 0;
    }

    @Override
    public final void run() {
        if (realTotalOffset == Integer.MAX_VALUE) {
            float itemHeight = loopView.lineSpacingMultiplier * loopView.maxTextHeight;
            // ���ƫ����Ϊ����תΪ����
            offset = (int)((offset + itemHeight) % itemHeight);
            if ((float) offset > itemHeight / 2.0F) {
                realTotalOffset = (int) (itemHeight - (float) offset);
            } else {
                realTotalOffset = -offset;
            }
        }
        realOffset = (int) ((float) realTotalOffset * 0.1F);

        if (realOffset == 0) {
            if (realTotalOffset < 0) {
                realOffset = -1;
            } else {
                realOffset = 1;
            }
        }
        if (Math.abs(realTotalOffset) <= 0) {
            loopView.cancelFuture();
            loopView.handler.sendEmptyMessage(MessageHandler.WHAT_ITEM_SELECTED);
        } else {
            loopView.totalScrollY = loopView.totalScrollY + realOffset;
            loopView.handler.sendEmptyMessage(MessageHandler.WHAT_INVALIDATE_LOOP_VIEW);
            realTotalOffset = realTotalOffset - realOffset;
        }
    }
}

@@ -796,27 +796,21 @@
  // 
-%EF%BF%BD%EF%BF%BD%EF%BF%BD%C6%AB%EF%BF%BD%EF%BF%BD%EF%BF%BD%EF%BF%BD%CE%AA%EF%BF%BD%EF%BF%BD%EF%BF%BD%EF%BF%BD%D7%AA%CE%AA%EF%BF%BD%EF%BF%BD%EF%BF%BD%EF%BF%BD
+%E5%A6%82%E6%9E%9C%E5%81%8F%E7%A7%BB%E9%87%8F%E4%B8%BA%E8%B4%9F%E6%95%B0%EF%BC%8C%E8%BD%AC%E4%B8%BA%E6%AD%A3%E6%95%B0
 %0A   

Update SmoothScrollTimerTask.java