List of usage examples for android.os Bundle putBoolean
public void putBoolean(@Nullable String key, boolean value)
From source file:com.ntsync.android.sync.activities.ShopActivity.java
private void onPaymentSuccess(Account account) { MessageDialog.showAndClose(R.string.shop_activity_paymentsuccess, this); // Perform sync Bundle extras = new Bundle(); extras.putBoolean(Constants.PARAM_GETRESTRICTIONS, true); ContentResolver.requestSync(account, Constants.CONTACT_AUTHORITY, extras); }
From source file:net.reichholf.dreamdroid.activities.ServiceListActivity.java
@Override public void onSaveInstanceState(Bundle outState) { super.onSaveInstanceState(outState); outState.putSerializable("history", mHistory); outState.putBoolean("isBouquetList", mIsBouquetList); }
From source file:com.photon.phresco.nativeapp.eshop.activity.PhrescoActivity.java
/** * Call the error dialog handler method to open the normal error dialog box * with OK and Cancel buttons/*from w ww . jav a2s . c om*/ */ public void showErrorDialogWithCancel() { try { PhrescoLogger.info(TAG + " processOnComplete - showErrorDialogHandler :"); Message msg = new Message(); Bundle errorMessageBundle = new Bundle(); errorMessageBundle.putString(errMessage, getString(R.string.http_connect_error_message)); errorMessageBundle.putBoolean(cancelFlag, true); msg.setData(errorMessageBundle); msg.what = ERROR_DIALOG_FLAG; showErrorDialogHandler.sendMessage(msg); } catch (Exception ex) { PhrescoLogger.info(TAG + " - showErrorDialogWithCancel - Exception : " + ex.toString()); PhrescoLogger.warning(ex); } }
From source file:com.uproot.trackme.LocationActivity.java
@Override protected void onSaveInstanceState(Bundle outState) { super.onSaveInstanceState(outState); outState.putBoolean(KEY_FINE, mUseFine); outState.putBoolean(KEY_BOTH, mUseBoth); }
From source file:li.barter.fragments.SelectPreferredLocationFragment.java
@Override public void onSaveInstanceState(final Bundle outState) { super.onSaveInstanceState(outState); outState.putParcelableArray(Keys.LOCATIONS, mVenues); outState.putBoolean(Keys.OVERLAY_VISIBLE, mIsOverlayShown); }
From source file:cn.scujcc.bug.bitcoinplatformandroid.fragment.ActualTransactionFragment.java
@Nullable @Override/*from w w w .ja va 2 s . co m*/ public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { View view = inflater.inflate(R.layout.fragment_tab, container, false); setHasOptionsMenu(true); setTitle(view, ""); SlidingTabLayout slidingTabLayout = (SlidingTabLayout) view.findViewById(R.id.tablayout); ViewPager viewPager = (ViewPager) view.findViewById(R.id.viewpager); mRecyclerViewBuy = (RecyclerView) view.findViewById(R.id.recyclerViewBuy); mRecyclerViewSell = (RecyclerView) view.findViewById(R.id.recyclerViewSell); mBuyList = new ArrayList<>(); mSellList = new ArrayList<>(); for (int i = 0; i < 6; i++) { Trend trend1 = new Trend(); trend1.setCount(0); trend1.setPrice(0); Trend trend2 = new Trend(); trend2.setCount(0); trend2.setPrice(0); mBuyList.add(trend1); mSellList.add(trend2); } mBuyAdapter = new DataAdapter(mBuyList, false); mSellAdapter = new DataAdapter(mSellList, true); mRecyclerViewBuy.setLayoutManager(new LinearLayoutManager(getActivity())); mRecyclerViewSell.setLayoutManager(new LinearLayoutManager(getActivity())); mRecyclerViewBuy.setHasFixedSize(true); mRecyclerViewSell.setHasFixedSize(true); mRecyclerViewBuy.setAdapter(mBuyAdapter); mRecyclerViewSell.setAdapter(mSellAdapter); // ViewPager ArrayList<Fragment> fragments = new ArrayList<Fragment>(); CandlestickChartsFragment candlestickChartsFragment = new CandlestickChartsFragment(); Bundle atChartsBundle = new Bundle(); atChartsBundle.putBoolean(CandlestickChartsFragment.ARGS_IS_FULL, false); candlestickChartsFragment.setArguments(atChartsBundle); fragments.add(candlestickChartsFragment); Fragment buyFragment = new BuyAndSellFragment(); Bundle buyBundle = new Bundle(); buyBundle.putBoolean(BuyAndSellFragment.ARGS_IS_Sell, false); buyFragment.setArguments(buyBundle); Fragment sellFragment = new BuyAndSellFragment(); Bundle SellBundle = new Bundle(); SellBundle.putBoolean(BuyAndSellFragment.ARGS_IS_Sell, true); sellFragment.setArguments(SellBundle); fragments.add(buyFragment); fragments.add(sellFragment); mViewPagerAdapter = new ViewPagerAdapter(getChildFragmentManager(), fragments); viewPager.setOffscreenPageLimit(fragments.size()); viewPager.setAdapter(mViewPagerAdapter); slidingTabLayout.setViewPager(viewPager, calculateScreenX()); return view; }
From source file:com.android.ex.photo.PhotoViewActivity.java
@Override public void onSaveInstanceState(Bundle outState) { super.onSaveInstanceState(outState); outState.putInt(STATE_ITEM_KEY, mViewPager.getCurrentItem()); outState.putBoolean(STATE_FULLSCREEN_KEY, mFullScreen); }
From source file:com.owncloud.android.ui.preview.PreviewImageActivity.java
@Override protected void onSaveInstanceState(Bundle outState) { super.onSaveInstanceState(outState); outState.putBoolean(KEY_WAITING_FOR_BINDER, mRequestWaitingForBinder); }
From source file:com.amazon.android.contentbrowser.helper.AuthHelper.java
/** * Handle success case of subscriber.//from w w w.j a v a 2 s . com * * @param subscriber Subscriber. * @param extras Result bundle. */ private void handleSuccessCase(Subscriber subscriber, Bundle extras) { extras.putBoolean(RESULT, true); if (!subscriber.isUnsubscribed()) { subscriber.onNext(extras); } subscriber.onCompleted(); }
From source file:com.amazon.android.contentbrowser.helper.AuthHelper.java
/** * Handle failure case of subscriber./*from ww w . j a v a2 s . c o m*/ * * @param subscriber Subscriber. * @param extras Result bundle. */ private void handleFailureCase(Subscriber subscriber, Bundle extras) { extras.putBoolean(RESULT, false); if (!subscriber.isUnsubscribed()) { subscriber.onNext(extras); } subscriber.onCompleted(); }