Example usage for android.os Bundle putIntegerArrayList

List of usage examples for android.os Bundle putIntegerArrayList

Introduction

In this page you can find the example usage for android.os Bundle putIntegerArrayList.

Prototype

@Override
public void putIntegerArrayList(@Nullable String key, @Nullable ArrayList<Integer> value) 

Source Link

Document

Inserts an ArrayList value into the mapping of this Bundle, replacing any existing value for the given key.

Usage

From source file:com.codetroopers.betterpickers.radialtimepicker.RadialTimePickerDialog.java

@Override
public void onSaveInstanceState(Bundle outState) {
    if (mTimePicker != null) {
        outState.putInt(KEY_HOUR_OF_DAY, mTimePicker.getHours());
        outState.putInt(KEY_MINUTE, mTimePicker.getMinutes());
        outState.putBoolean(KEY_IS_24_HOUR_VIEW, mIs24HourMode);
        outState.putInt(KEY_CURRENT_ITEM_SHOWING, mTimePicker.getCurrentItemShowing());
        outState.putBoolean(KEY_IN_KB_MODE, mInKbMode);
        if (mInKbMode) {
            outState.putIntegerArrayList(KEY_TYPED_TIMES, mTypedTimes);
        }/*  w  w  w. j  a  va 2s.c o m*/
        outState.putInt(KEY_STYLE, mStyleResId);
    }
}

From source file:com.philliphsu.hybridtimepicker.HybridTimePickerDialog.java

@Override
public void onSaveInstanceState(Bundle outState) {
    if (mGridPicker != null) {
        outState.putInt(KEY_HOUR_OF_DAY, mGridPicker.getHours());
        outState.putInt(KEY_MINUTE, mGridPicker.getMinutes());
        outState.putBoolean(KEY_IS_24_HOUR_VIEW, mIs24HourMode);
        outState.putInt(KEY_CURRENT_ITEM_SHOWING, mGridPicker.getCurrentItemShowing());
        outState.putBoolean(KEY_IN_KB_MODE, mInKbMode);
        if (mInKbMode) {
            outState.putIntegerArrayList(KEY_TYPED_TIMES, mTypedTimes);
        }//from   w  w  w.  ja  v a2 s .  c  om
        outState.putBoolean(KEY_DARK_THEME, mThemeDark);
    }
}

From source file:com.philliphsu.bottomsheetpickers.time.grid.GridTimePickerDialog.java

@Override
public void onSaveInstanceState(Bundle outState) {
    if (mTimePicker != null) {
        outState.putInt(KEY_HOUR_OF_DAY, mTimePicker.getHours());
        outState.putInt(KEY_MINUTE, mTimePicker.getMinutes());
        outState.putBoolean(KEY_IS_24_HOUR_VIEW, mIs24HourMode);
        outState.putInt(KEY_CURRENT_ITEM_SHOWING, mTimePicker.getCurrentItemShowing());
        outState.putBoolean(KEY_IN_KB_MODE, mInKbMode);
        if (mInKbMode) {
            outState.putIntegerArrayList(KEY_TYPED_TIMES, mTypedTimes);
        }/* ww  w .  j ava 2s  .  c o  m*/
        outState.putBoolean(KEY_DARK_THEME, mThemeDark);
        outState.putBoolean(KEY_THEME_SET_AT_RUNTIME, mThemeSetAtRuntime);
    }
}

From source file:com.irccloud.android.fragment.BuffersListFragment.java

@Override
public void onSaveInstanceState(Bundle state) {
    if (adapter != null && adapter.data != null && adapter.data.size() > 0) {
        ArrayList<Integer> expandedArchives = new ArrayList<Integer>();
        SparseArray<ServersDataSource.Server> servers = ServersDataSource.getInstance().getServers();
        for (int i = 0; i < servers.size(); i++) {
            ServersDataSource.Server s = servers.valueAt(i);
            if (mExpandArchives.get(s.cid, false))
                expandedArchives.add(s.cid);
        }//from  w  w  w .ja v a  2s  .c o m
        state.putIntegerArrayList("expandedArchives", expandedArchives);
        if (listView != null)
            state.putInt("scrollPosition", listView.getFirstVisiblePosition());
    }
}

From source file:com.binomed.showtime.android.screen.results.tablet.CineShowTimeResultsTabletActivity.java

@Override
protected void onSaveInstanceState(Bundle outState) {
    if ((getModelActivity().getNearResp() != null) || (fragmentMovie != null)) {
        outState.putBoolean(ParamIntent.BUNDLE_SAVE, true);
        // Save results state
        if (getModelActivity().getNearResp() != null) {
            outState.putParcelable(ParamIntent.NEAR_RESP, getModelActivity().getNearResp());
        } else {/*from  w w  w . ja  va2s .  co  m*/
            outState.putBoolean(ParamIntent.ACTIVITY_SEARCH_FORCE_REQUEST,
                    getModelActivity().isForceResearch());
        }
        if (getModelActivity().getLocalisation() != null) {
            outState.putDouble(ParamIntent.ACTIVITY_SEARCH_LATITUDE,
                    getModelActivity().getLocalisation().getLatitude());
            outState.putDouble(ParamIntent.ACTIVITY_SEARCH_LONGITUDE,
                    getModelActivity().getLocalisation().getLongitude());
        }
        outState.putString(ParamIntent.ACTIVITY_SEARCH_THEATER_ID, getModelActivity().getFavTheaterId());
        outState.putInt(ParamIntent.ACTIVITY_SEARCH_DAY, getModelActivity().getDay());
        outState.putString(ParamIntent.ACTIVITY_SEARCH_CITY, getModelActivity().getCityName());
        outState.putString(ParamIntent.ACTIVITY_SEARCH_MOVIE_NAME, getModelActivity().getMovieName());
        outState.putIntegerArrayList(ParamIntent.ACTIVITY_SEARCH_GROUP_EXPAND,
                new ArrayList<Integer>(getModelActivity().getGroupExpanded()));

        // Save movie state
        if ((fragmentMovie != null) && (getModelActivity().getMovie() != null)) {
            outState.putParcelable(ParamIntent.MOVIE, getModelActivity().getMovie());
            outState.putParcelable(ParamIntent.THEATER, getModelActivity().getTheater());
            outState.putDouble(ParamIntent.ACTIVITY_MOVIE_LATITUDE,
                    (getModelActivity().getLocalisation() != null)
                            ? getModelActivity().getLocalisation().getLatitude()
                            : -1);
            outState.putDouble(ParamIntent.ACTIVITY_MOVIE_LONGITUDE,
                    (getModelActivity().getLocalisation() != null)
                            ? getModelActivity().getLocalisation().getLongitude()
                            : -1);
        }
    }
    super.onSaveInstanceState(outState);
}

From source file:com.github.chenxiaolong.dualbootpatcher.switcher.RomDetailActivity.java

@Override
protected void onSaveInstanceState(Bundle outState) {
    super.onSaveInstanceState(outState);
    outState.putInt(EXTRA_STATE_TASK_ID_CACHE_WALLPAPER, mTaskIdCacheWallpaper);
    outState.putInt(EXTRA_STATE_TASK_ID_SWITCH_ROM, mTaskIdSwitchRom);
    outState.putInt(EXTRA_STATE_TASK_ID_SET_KERNEL, mTaskIdSetKernel);
    outState.putInt(EXTRA_STATE_TASK_ID_UPDATE_RAMDISK, mTaskIdUpdateRamdisk);
    outState.putInt(EXTRA_STATE_TASK_ID_WIPE_ROM, mTaskIdWipeRom);
    outState.putInt(EXTRA_STATE_TASK_ID_CREATE_LAUNCHER, mTaskIdCreateLauncher);
    outState.putInt(EXTRA_STATE_TASK_ID_GET_ROM_DETAILS, mTaskIdGetRomDetails);
    outState.putIntegerArrayList(EXTRA_STATE_TASK_IDS_TO_REMOVE, mTaskIdsToRemove);
    outState.putParcelable(EXTRA_STATE_RESULT_INTENT, mResultIntent);
    if (mBackupTargets != null) {
        outState.putStringArray(EXTRA_STATE_BACKUP_TARGETS, mBackupTargets);
    }/* w  w  w.  j ava 2s .  c  om*/
}

From source file:com.borax12.materialdaterangepicker.single.time.TimePickerDialog.java

@Override
public void onSaveInstanceState(@NonNull Bundle outState) {
    if (mTimePicker != null) {
        outState.putParcelable(KEY_INITIAL_TIME, mTimePicker.getTime());
        outState.putBoolean(KEY_IS_24_HOUR_VIEW, mIs24HourMode);
        outState.putInt(KEY_CURRENT_ITEM_SHOWING, mTimePicker.getCurrentItemShowing());
        outState.putBoolean(KEY_IN_KB_MODE, mInKbMode);
        if (mInKbMode) {
            outState.putIntegerArrayList(KEY_TYPED_TIMES, mTypedTimes);
        }/*from w ww .  ja  v a 2  s  .  c  om*/
        outState.putString(KEY_TITLE, mTitle);
        outState.putBoolean(KEY_THEME_DARK, mThemeDark);
        outState.putBoolean(KEY_THEME_DARK_CHANGED, mThemeDarkChanged);
        outState.putInt(KEY_ACCENT, mAccentColor);
        outState.putBoolean(KEY_VIBRATE, mVibrate);
        outState.putBoolean(KEY_DISMISS, mDismissOnPause);
        outState.putParcelableArray(KEY_SELECTABLE_TIMES, mSelectableTimes);
        outState.putParcelable(KEY_MIN_TIME, mMinTime);
        outState.putParcelable(KEY_MAX_TIME, mMaxTime);
        outState.putBoolean(KEY_ENABLE_SECONDS, mEnableSeconds);
        outState.putInt(KEY_OK_RESID, mOkResid);
        outState.putString(KEY_OK_STRING, mOkString);
        outState.putInt(KEY_CANCEL_RESID, mCancelResid);
        outState.putString(KEY_CANCEL_STRING, mCancelString);
    }
}

From source file:com.codetroopers.betterpickers.radialtimepicker.RadialTimePickerDialogFragment.java

@Override
public void onSaveInstanceState(Bundle outState) {
    if (mTimePicker != null) {
        outState.putInt(KEY_HOUR_OF_DAY, mTimePicker.getHours());
        outState.putInt(KEY_MINUTE, mTimePicker.getMinutes());
        outState.putBoolean(KEY_IS_24_HOUR_VIEW, mIs24HourMode);
        outState.putInt(KEY_CURRENT_ITEM_SHOWING, mTimePicker.getCurrentItemShowing());
        outState.putBoolean(KEY_IN_KB_MODE, mInKbMode);
        if (mFutureMinutesLimit != null)
            outState.putInt(KEY_FUTURE_MINUTES_LIMIT, mFutureMinutesLimit);
        if (mPastMinutesLimit != null)
            outState.putInt(KEY_PAST_MINUTES_LIMIT, mPastMinutesLimit);
        outState.putSerializable(KEY_CURRENT_DATE, mValidateDateTime);
        outState.putSerializable(KEY_PICKER_DATE, mPickerDate);
        if (mInKbMode)
            outState.putIntegerArrayList(KEY_TYPED_TIMES, mTypedTimes);
        outState.putInt(KEY_STYLE, mStyleResId);
    }//from www. ja  v  a 2 s  .  c  o  m
}

From source file:com.borax12.materialdaterangepicker.time.TimePickerDialog.java

@Override
public void onSaveInstanceState(@NonNull Bundle outState) {
    if (mTimePicker != null) {
        outState.putInt(KEY_HOUR_OF_DAY, mTimePicker.getHours());
        outState.putInt(KEY_MINUTE, mTimePicker.getMinutes());
        outState.putInt(KEY_HOUR_OF_DAY_END, mTimePickerEnd.getHours());
        outState.putInt(KEY_MINUTE_END, mTimePickerEnd.getMinutes());
        outState.putBoolean(KEY_IS_24_HOUR_VIEW, mIs24HourMode);
        outState.putInt(KEY_CURRENT_ITEM_SHOWING, mTimePicker.getCurrentItemShowing());
        outState.putInt(KEY_CURRENT_ITEM_SHOWING_END, mTimePickerEnd.getCurrentItemShowing());
        outState.putBoolean(KEY_IN_KB_MODE, mInKbMode);
        if (mInKbMode) {
            outState.putIntegerArrayList(KEY_TYPED_TIMES, mTypedTimes);
        }/*from  w w w  .jav a 2 s. c o  m*/
        outState.putString(KEY_TITLE, mTitle);
        outState.putBoolean(KEY_DARK_THEME, mThemeDark);
        outState.putInt(KEY_ACCENT, mAccentColor);
        outState.putBoolean(KEY_VIBRATE, mVibrate);
    }
}

From source file:com.jarklee.materialdatetimepicker.time.TimePickerDialog.java

@Override
public void onSaveInstanceState(@NonNull Bundle outState) {
    if (mTimePicker != null) {
        outState.putParcelable(KEY_INITIAL_TIME, mTimePicker.getTime());
        outState.putBoolean(KEY_IS_24_HOUR_VIEW, mIs24HourMode);
        outState.putInt(KEY_CURRENT_ITEM_SHOWING, mTimePicker.getCurrentItemShowing());
        outState.putBoolean(KEY_IN_KB_MODE, mInKbMode);
        if (mInKbMode) {
            outState.putIntegerArrayList(KEY_TYPED_TIMES, mTypedTimes);
        }/*from   ww w .j av  a 2  s .  com*/
        outState.putString(KEY_TITLE, mTitle);
        outState.putBoolean(KEY_THEME_DARK, mThemeDark);
        outState.putBoolean(KEY_THEME_DARK_CHANGED, mThemeDarkChanged);
        outState.putInt(KEY_ACCENT, mAccentColor);
        outState.putBoolean(KEY_VIBRATE, mVibrate);
        outState.putBoolean(KEY_DISMISS, mDismissOnPause);
        outState.putParcelableArray(KEY_SELECTABLE_TIMES, mSelectableTimes);
        outState.putParcelable(KEY_MIN_TIME, mMinTime);
        outState.putParcelable(KEY_MAX_TIME, mMaxTime);
        outState.putBoolean(KEY_ENABLE_SECONDS, mEnableSeconds);
        outState.putBoolean(KEY_ENABLE_MINUTES, mEnableMinutes);
        outState.putInt(KEY_OK_RESID, mOkResid);
        outState.putString(KEY_OK_STRING, mOkString);
        outState.putInt(KEY_CANCEL_RESID, mCancelResid);
        outState.putString(KEY_CANCEL_STRING, mCancelString);
    }
}