BottomSheet

michal3377 edited this page Aug 11, 2016 · 3 revisions

BottomSheetDialog

BottomSheetDialog is a custom full screen Dialog that slide in from bottom.

Usage

Initialize in code:

    BottomSheetDialog mDialog = new BottomSheetDialog(context);

    BottomSheetDialog mDialog = new BottomSheetDialog(context, styleId);

You can chain methods to style BottomSheetDialog:

    mDialog.applyStyle(styleId)
        .contentView(view)
        .heightParam(ViewGroup.LayoutParams.WRAP_CONTENT)
        .inDuration(500)
        .cancelable(true)
        ...
        .show();

Attributes

  • bsd_inDuration - The duration of animation when dialog slide in.

  • bsd_inInterpolator - The interpolator of animation when dialog slide in.

  • bsd_outDuration - The duration of animation when dialog slide out.

  • bsd_outInterpolator - The interpolator of animation when dialog slide out.

  • bsd_cancelable - Indicate that dialog is cancelable.

  • bsd_canceledOnTouchOutside - Indicate that dialog will be canceled when touch outside.

  • bsd_dimAmount - The amount of dim applied to background outside dialog.

  • android:layout_height - The height of dialog's layout params. Can be dimension value or match_parent or wrap_content enum.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.