Open JimmyPun610 opened 6 years ago
But the control works if I directly use the MaterialEntry directly in XAML
That's a new one. I guess I never tried inheriting from MaterialEntry
either. What are your linker settings and what Xamarin.Forms version?
What do you mean about linker settings? For XF version, I am using the latest 3.0 version.
There is another issue about MaterialButton.
// we need to reset the StateListAnimator to override the setting of Elevation on touch down and release.
Control.StateListAnimator = new Animation.StateListAnimator();
In your source code of Android Renderer of Material button, above line will throw exception and crash the app on some Android device with low version, eg, Mine is 4.4.4
If you go to your Android and iOS project settings and go to linker there is a setting there. I want to see if it is getting linked out for some reason.
Also good call on the StateListAnimator
. I believe someone has already picked up working on that
The linker settings is none.
I try to do the same but I couldn't. Is there a fix for this?
Any update or workaround for this error?
I was trying to use the MaterialEntry in Xamarin Form project. I created a custom control which inherit MatrialEntry to set the default AccentColor.
Then I use MyMaterialEntry in XAML and run the Android client. Then exception throw.
In MainActivity.cs, I added the Init before/after Forms.Init, but still no luck