Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to open long press on Android #366

Open
cesargdm opened this issue Apr 17, 2022 · 0 comments
Open

Fails to open long press on Android #366

cesargdm opened this issue Apr 17, 2022 · 0 comments

Comments

@cesargdm
Copy link

I'm getting

E/AndroidRuntime: FATAL EXCEPTION: main
    Process: app.cretia.android, PID: 20666
    java.lang.NullPointerException: Attempt to invoke virtual method 'void android.graphics.drawable.Drawable.setTintList(android.content.res.ColorStateList)' on a null object reference
        at com.reactnativemenu.MenuView.prepareMenuItem(MenuView.kt:148)
        at com.reactnativemenu.MenuView.prepareMenu(MenuView.kt:207)
        at com.reactnativemenu.MenuView.access$prepareMenu(MenuView.kt:18)
        at com.reactnativemenu.MenuView$1.onLongPress(MenuView.kt:32)
        at android.view.GestureDetector.dispatchLongPress(GestureDetector.java:963)
        at android.view.GestureDetector.access$300(GestureDetector.java:70)
        at android.view.GestureDetector$GestureHandler.handleMessage(GestureDetector.java:340)
        at android.os.Handler.dispatchMessage(Handler.java:106)
        at android.os.Looper.loop(Looper.java:246)
        at android.app.ActivityThread.main(ActivityThread.java:8653)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:602)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130)

Versions
"react-native": "0.68.1"
"@react-native-menu/menu": "0.5.2"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant