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

[Android] Avoid issues creating a Borderless Entry with a custom Handler #17778

Merged
merged 4 commits into from Oct 20, 2023

Conversation

jsuarezruiz
Copy link
Contributor

@jsuarezruiz jsuarezruiz commented Oct 2, 2023

Description of Change

Avoid issues creating a Borderless Entry with a custom Handler on Android.

fix-17448

Added a new sample in the Entry page from the .NET MAUI Gallery.

Issues Fixed

Fixes #17448
Fixes #17860

@jsuarezruiz jsuarezruiz requested a review from a team as a code owner October 2, 2023 14:34
@ghost ghost added the legacy-area-controls Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor label Oct 2, 2023
@npostma
Copy link

npostma commented Oct 5, 2023

I've merged this fix into my local net8.0 branch. I can confirm that the border is now gone :-) 👍

image

@samhouts samhouts added this to the .NET 8 GA milestone Oct 5, 2023
@@ -272,6 +272,21 @@ static bool LogEvent(string eventName, string type = null)

// If someone wanted to completely turn off the CascadeInputTransparent behavior in their application, this next line would be an easy way to do it
// Microsoft.Maui.Controls.Layout.ControlsLayoutMapper.ModifyMapping(nameof(Microsoft.Maui.Controls.Layout.CascadeInputTransparent), (_, _, _) => { });

Microsoft.Maui.Handlers.EntryHandler.Mapper.AppendToMapping(nameof(TransparentEntry), (handler, view) =>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we add a new test using this code?

@PureWeen PureWeen modified the milestones: .NET 8 GA, .NET 8 SR1 Oct 9, 2023
@Equabyte
Copy link

This is not yet fixed in RC2 released today. Is there a workaround?

@jsuarezruiz
Copy link
Contributor Author

This is not yet fixed in RC2 released today. Is there a workaround?

RC2 not contains this changes, are still in review process. Hopefully, will be available with GA.

@Equabyte
Copy link

I found a workaround and published a test app with .NET8 RC2 https://play.google.com/store/apps/details?id=com.equabyte.DCF_Calc_V1

@gabsamples6
Copy link

@Equabyte hi - what is the workaround? @jsuarezruiz do you think this will be merged for GA or any night build before hand

thanks

@Equabyte
Copy link

Equabyte commented Oct 16, 2023

@Equabyte hi - what is the workaround?

@gabsamples6 in my app I used this:
handler.PlatformView.BackgroundTintList = Android.Content.Res.ColorStateList.ValueOf(Colors.Transparent.ToAndroid());

@gabsamples6
Copy link

@Equabyte thank you! let me try

@samhouts samhouts merged commit 556dc23 into main Oct 20, 2023
47 checks passed
@samhouts samhouts deleted the fix-17448 branch October 20, 2023 22:49
@github-actions github-actions bot locked and limited conversation to collaborators Dec 6, 2023
@Eilon Eilon removed the legacy-area-controls Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor label May 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
8 participants