Skip to content

[Breaking change] Fixed View.SystemUiVisibility enum type - #2526

Closed
spixy wants to merge 1 commit into
dotnet:masterfrom
spixy:patch-1
Closed

spixy wants to merge 1 commit into
dotnet:masterfrom
spixy:patch-1

Conversation

@spixy

@spixy spixy commented Dec 13, 2018 •

Copy link
Copy Markdown

Changes View.SystemUiVisibility from StatusBarVisibility to SystemUiFlags which is right enum type.

This also solves #2372 because SystemUiFlags has [Flags] attribute.

Note: it is breaking change

@spixy
spixy requested a review from jonpryor as a code owner December 13, 2018 02:05
@spixy spixy changed the title Fixed View.SystemUiVisibility enum type [Breaking change] Fixed View.SystemUiVisibility enum type Dec 13, 2018
@adrianknight89

Copy link
Copy Markdown

@spixy Thanks for looking into this. I did find some prior discussion related to this: https://bugzilla.xamarin.com/show_bug.cgi?id=58136

At minimum, I'd like to see a Flags attribute on the current enum regardless of whether SystemUiFlags can be used or not.

@jonpryor

Copy link
Copy Markdown
Contributor

We are not making API breakage at this time. :-)

Would a "property overload" work for you?

partial class WindowManagerLayoutParams {
    public SystemUiFlags SystemUiFlags {
        get {return (SystemUiFlags) SystemUiVisibility;}
        set {SystemUiVisibility = (Android.Views.StatusBarVisibility) value;}
    }
}

We could then [Obsolete] the SystemUiVisibility property by setting the @deprecates XML attribute within metadata.

@spixy

spixy commented Dec 13, 2018

Copy link
Copy Markdown
Author

Yes that will be a good solution for now.

@adrianknight89

Copy link
Copy Markdown

I'm fine with the property overload as well. Thanks.

@jonpryor

Copy link
Copy Markdown
Contributor

So will anyone contribute the PR to do the "property overload," or is everyone looking at me? :-)

@xamarin-jenkins

Copy link
Copy Markdown

Hello! I'm the build bot for Xamarin. I need approval from a Xamarin team member to build this pull request. A team member should reply with "approve" to approve a build of this pull request, "whitelist" to whitelist this and all future pull requests from this contributor, or "build" to explicitly request a build, even if one has already been done. Contributors can ignore this message.

@jonpryor
jonpryor requested a review from gugavaro June 6, 2019 15:05
@jonpryor jonpryor closed this Mar 5, 2021
@jonpryor
jonpryor deleted the branch dotnet:master March 5, 2021 23:08
@github-actions github-actions Bot locked and limited conversation to collaborators Feb 1, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants