Code example for TypedArray

Methods: getInt

0
        mValueText.setText(mSuffix == null ? t : t.concat(mSuffix));
    } 
 
    @Override 
    protected Object onGetDefaultValue(TypedArray a, int index) {
        return a.getInt(index, 0);
    } 
 
    @Override 
    protected void onSetInitialValue(boolean restore, Object defaultValue) {
        mValue = getPersistedInt(defaultValue == null ? 0 : (Integer) defaultValue);
    } 
 
    @Override 
    protected void onDialogClosed(boolean positiveResult) {
        super.onDialogClosed(positiveResult);
 
        if (positiveResult) {
            int value = mSeekBar.getProgress()+mMin;
            if (callChangeListener(value)) {
                setValue(value);