File tree 1 file changed +6
-0
lines changed
core/app/src/main/java/com/itsaky/androidide/fragments/sheets
1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 20
20
import android .app .Dialog ;
21
21
import android .os .Bundle ;
22
22
import androidx .annotation .NonNull ;
23
+ import com .google .android .material .bottomsheet .BottomSheetBehavior ;
24
+ import com .google .android .material .bottomsheet .BottomSheetDialog ;
23
25
import com .google .android .material .bottomsheet .BottomSheetDialogFragment ;
24
26
25
27
public abstract class BaseBottomSheetFragment extends BottomSheetDialogFragment {
@@ -30,6 +32,10 @@ public abstract class BaseBottomSheetFragment extends BottomSheetDialogFragment
30
32
@ Override
31
33
public Dialog onCreateDialog (Bundle savedInstanceState ) {
32
34
mDialog = super .onCreateDialog (savedInstanceState );
35
+
36
+ var behavior = ((BottomSheetDialog ) mDialog ).getBehavior ();
37
+ behavior .setPeekHeight (BottomSheetBehavior .PEEK_HEIGHT_AUTO );
38
+ behavior .setState (BottomSheetBehavior .STATE_EXPANDED );
33
39
return mDialog ;
34
40
}
35
41
You can’t perform that action at this time.
0 commit comments