Search in sources :

Example 6 with BottomSheetBehavior

use of com.google.android.material.bottomsheet.BottomSheetBehavior in project android-client by GenesisVision.

the class TrendingBottomSheetView method updatePeekHeight.

private void updatePeekHeight() {
    BottomSheetBehavior bottomsheetBehavior = BottomSheetBehavior.from(this);
    flexBox.post(() -> bottomsheetBehavior.setPeekHeight(TypedValueFormatter.toDp(60) + flexBox.getHeight()));
}
Also used : BottomSheetBehavior(com.google.android.material.bottomsheet.BottomSheetBehavior)

Example 7 with BottomSheetBehavior

use of com.google.android.material.bottomsheet.BottomSheetBehavior in project android-client by GenesisVision.

the class SocialActivity method showTrendingBottomSheet.

@Override
public void showTrendingBottomSheet() {
    BottomSheetBehavior bottomSheetBehavior = BottomSheetBehavior.from(trendingView);
    bottomSheetBehavior.setState(BottomSheetBehavior.STATE_HALF_EXPANDED);
}
Also used : BottomSheetBehavior(com.google.android.material.bottomsheet.BottomSheetBehavior)

Aggregations

BottomSheetBehavior (com.google.android.material.bottomsheet.BottomSheetBehavior)7 View (android.view.View)3 LinearLayout (android.widget.LinearLayout)2 TextView (android.widget.TextView)2 Nullable (androidx.annotation.Nullable)2 CoordinatorLayout (androidx.coordinatorlayout.widget.CoordinatorLayout)2 BottomSheetDialog (com.google.android.material.bottomsheet.BottomSheetDialog)2 Context (android.content.Context)1 DialogInterface (android.content.DialogInterface)1 Intent (android.content.Intent)1 SharedPreferences (android.content.SharedPreferences)1 Bundle (android.os.Bundle)1 Handler (android.os.Handler)1 PowerManager (android.os.PowerManager)1 PreferenceManager (android.preference.PreferenceManager)1 SparseBooleanArray (android.util.SparseBooleanArray)1 ActionMode (android.view.ActionMode)1 LayoutInflater (android.view.LayoutInflater)1 Menu (android.view.Menu)1 MenuInflater (android.view.MenuInflater)1