MSMaterialDrawer

chompina

Member
Licensed User
Longtime User

hi, i clean install, b4x 10.6, last sdk & resources, jettified library msmaterialdrawer.. same error...

lot hour of searching, i got solution,very simple, in the additional res md-lib folder

edit md-lib\res\layout\material_drawer.xml

Change this:
<?xml version="1.0" encoding="utf-8"?>
<android.support.v4.widget.DrawerLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:id="@+id/drawer_layout"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <!--
    the clickable here should fix the hanging which occurs sometimes
    http://stackoverflow.com/questions/18044277/android-navigation-drawer-bug-using-the-sample
    -->
    <com.mikepenz.materialdrawer.view.ScrimInsetsFrameLayout
        android:clickable="true"
        android:id="@+id/content_layout"
        android:layout_width="match_parent"
        android:layout_height="match_parent"/>
</android.support.v4.widget.DrawerLayout>

To this:
<?xml version="1.0" encoding="utf-8"?>
<androidx.drawerlayout.widget.DrawerLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:id="@+id/drawer_layout"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <!--
    the clickable here should fix the hanging which occurs sometimes
    http://stackoverflow.com/questions/18044277/android-navigation-drawer-bug-using-the-sample
    -->
    <com.mikepenz.materialdrawer.view.ScrimInsetsFrameLayout
        android:clickable="true"
        android:id="@+id/content_layout"
        android:layout_width="match_parent"
        android:layout_height="match_parent"/>
</androidx.drawerlayout.widget.DrawerLayout>


in another words , converted to androidx something like that
before -> android.support.v4.widget.DrawerLayout after -> androidx.drawerlayout.widget.DrawerLayout

save it,, set android target to 30
compile and test it., this solution work for me to build the menu, i dont know if there is another issues.

hope this helps
 

Attachments

  • WhatsApp Image 2021-02-22 at 1.02.57 PM.jpeg
    22.7 KB · Views: 271
Cookies are required to use this site. You must accept them to continue using the site. Learn more…