Bottom Sheet Dialog Android Studio Kotlin Example Tutorial - ViewModel

Поділитися
Вставка
  • Опубліковано 3 гру 2024

КОМЕНТАРІ • 24

  • @prasanthmanimaran5158
    @prasanthmanimaran5158 2 роки тому +9

    Just a small tips (probably you already know this). If you wanna duplicate a line, just press CTRL + D. It will copy a line below the original line

  • @shivangeerajput8969
    @shivangeerajput8969 Рік тому +1

    Man you are just amazing. After going through lots of videos I found yours and it's really worth it ✨

  • @olmosdavronov1221
    @olmosdavronov1221 2 роки тому +1

    Wow! Just a quick clear video brings to mind the basic structure. Thanks, man👍👍

  • @narendravarma3220
    @narendravarma3220 2 роки тому +1

    use a Modal Bottom Sheet to allow the user to enter some text and create Decisions or Tasks.
    Some users want to close the keyboard and they tap outside of the Bottom Sheet and close it. This is a big issue because all the text is lost.
    The material design documentation states that it can be dismissed when the outside is touched but this doesn't work for me.
    I want to intercept the onOutsideClick event and check the keyboard's state:
    Keyboard shown: Close the soft keyboard
    Keyboard hidden: Dismiss the Bottom Sheet
    Should I use a custom BottomSheetBehavior or can I Override some dialog methods?

  • @huppieflupp
    @huppieflupp Рік тому

    Thank you so much for your work! How would this work if I didn't access the bottom sheet dialogue from main activity, but from another fragment?

  • @jeetshah3373
    @jeetshah3373 Рік тому

    SUPERB EXPLANATION

  • @prasanthmanimaran5158
    @prasanthmanimaran5158 2 роки тому +3

    Great video 😁😁

  • @diniconights
    @diniconights Рік тому

    Hey, how could I use ?attr/colorPrimary instead of purple_500?
    And how can I implement the delete function

  • @syahidbaddry3009
    @syahidbaddry3009 2 роки тому

    thanks bro,but i have some problem i have arraylist for task,and when im press save it not add task and when im open bottomsheetdialog again and just click textinput it will add my task i write before

  • @withMannengcom
    @withMannengcom 7 місяців тому

    my input does not appear, I don't know if its because I am using a fragment

  • @pawanacharya4879
    @pawanacharya4879 Рік тому

    So you are creating view model in Activity and BottomSheetFragment using viewmodel providers method. Doesn't it creates new instance at both place?
    If yes, how are we able to pass data since both place might have different instance of view model
    If no, why?
    Please correct me where I am wrong

    • @CodeWithCal
      @CodeWithCal  Рік тому

      So we do create a referenece in both the fragment and the activity the key part being that the "Owner" in both cases is the Activity.
      Does that answer your question?

  • @manurodriguez8725
    @manurodriguez8725 Рік тому

    Is there a way to send data from Activity to Fragment?

    • @CodeWithCal
      @CodeWithCal  Рік тому

      I think it can share with view model yes

  • @Humor_Ukrainian
    @Humor_Ukrainian 2 роки тому

    How can I make the list persist when the application closes?

    • @CodeWithCal
      @CodeWithCal  2 роки тому +2

      that tutorial is coming...

    • @krat2242
      @krat2242 Рік тому

      @@CodeWithCal link?
      or is it not made yet?

    • @CodeWithCal
      @CodeWithCal  Рік тому +1

      Room Database Android Studio Kotlin Example Tutorial
      ua-cam.com/video/-LNg-K7SncM/v-deo.html

  • @amo5499
    @amo5499 Рік тому

    i keep getting the same error even when onViewCreated fun is used, what should i do?

  • @mdsohanhossiansohan9738
    @mdsohanhossiansohan9738 2 роки тому

    Sir, I need a video of making an app. I will make an app for Bangladesh that can be connected from 64 districts. Can you give a video so that I can make this app?

  • @bilalillahi6347
    @bilalillahi6347 Місяць тому

    this looks difficult for beginners. even no proper explanation