Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

[C] Keep the Style value as backup #12926

Merged
merged 1 commit into from
Nov 21, 2020
Merged

[C] Keep the Style value as backup #12926

merged 1 commit into from
Nov 21, 2020

Conversation

StephaneDelcroix
Copy link
Member

@StephaneDelcroix StephaneDelcroix commented Nov 20, 2020

Description of Change

When a BP is cleared, (re)apply the style value

Issues Resolved

API Changes

None

Platforms Affected

  • Core/XAML (all platforms)
  • iOS
  • Android
  • UWP

Behavioral/Visual Changes

None

Before/After Screenshots

Before
IMG_9101

After
IMG_9102

Testing Procedure

PR Checklist

  • Targets the correct branch
  • Tests are passing (or failures are unrelated)

@StephaneDelcroix StephaneDelcroix added external-hotreload Non-Forms bugs that affect Hot Reload blocker Issue blocks next stable release. Prioritize fixing and reviewing this issue. labels Nov 20, 2020
When a BP is cleared, (re)apply the style value

- fixes #12874
_dispatcher = value;
}
get => _dispatcher ??= this.GetDispatcher();
internal set => _dispatcher = value;
Copy link

@etvorun etvorun Nov 20, 2020

Choose a reason for hiding this comment

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

[this comment applies to CanBeSetFromStyle; GitHub does not allow comments on "unchanged" code]
nit: given that you made some unrelated improvements in this file you can do one more. Instead of 3 IF checks you can use just one:

const BindableContextAttributes trueAttr =
BindableContextAttributes.IsSetFromStyle |
BindableContextAttributes.IsDefaultValue |
BindableContextAttributes.IsDefaultValueCreated;
return ((context.Attributes & trueAttr) != 0);

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
a/style a/Xaml </> blocker Issue blocks next stable release. Prioritize fixing and reviewing this issue. external-hotreload Non-Forms bugs that affect Hot Reload t/bug 🐛
Projects
None yet
3 participants