app/src/main/java/com/lingju/assistant/view/SwitchButton.java
/**
	 * processing animation
	 *
	 * @param checked checked or unChecked
	 */
processing animation
@param checked checked or unChecked
processing animation @param checked checked or unChecked
protected void animateToState(boolean checked) {
		if (mProcessAnimator == null) {
			return;
		}
		if (mProcessAnimator.isRunning()) {
			mProcessAnimator.cancel();
		}
		mProcessAnimator.setDuration(mAnimationDuration);
		if (checked) {
			mProcessAnimator.setFloatValues(mProcess, 1f);
		} else {
			mProcessAnimator.setFloatValues(mProcess, 0);
		}
		mProcessAnimator.start();
	}
protected void animateToState ( boolean checked ) { if ( mProcessAnimator == null ) { return ; } if ( mProcessAnimator . isRunning ( ) ) { mProcessAnimator . cancel ( ) ; } mProcessAnimator . setDuration ( mAnimationDuration ) ; if ( checked ) { mProcessAnimator . setFloatValues ( mProcess , 1f ) ; } else { mProcessAnimator . setFloatValues ( mProcess , 0 ) ; } mProcessAnimator . start ( ) ; }
processing animation
 @param checked checked or unChecked
processing animation @param checked checked or unChecked