-
Notifications
You must be signed in to change notification settings - Fork 742
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7500 from MartinZikmund/dev/mazi/ratingcontrol-up…
…dates `RatingControl` updates, Fluent theme resources update
- Loading branch information
Showing
18 changed files
with
473 additions
and
945 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
...no.UI.FluentTheme.v2/Resources/Version2/PriorityDefault/RatingControl_themeresources.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
src/Uno.UI.RuntimeTests/MUX/Microsoft_UI_Xaml_Controls/RatingControl/RatingControlTests.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
48 changes: 48 additions & 0 deletions
48
src/Uno.UI/Microsoft/UI/Xaml/Controls/RatingControl/RatingControl.Header.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
// Copyright (c) Microsoft Corporation. All rights reserved. | ||
// Licensed under the MIT License. See LICENSE in the project root for license information. | ||
// MUX Reference RatingControl.h, commit b853109 | ||
|
||
#nullable enable | ||
|
||
using Uno.Disposables; | ||
using Uno.UI.Helpers.WinUI; | ||
using Windows.UI.Composition; | ||
using Windows.UI.Xaml.Controls; | ||
|
||
namespace Microsoft.UI.Xaml.Controls; | ||
|
||
public partial class RatingControl | ||
{ | ||
private bool IsItemInfoPresentAndFontInfo() | ||
{ | ||
return m_infoType == RatingInfoType.Font; | ||
} | ||
private bool IsItemInfoPresentAndImageInfo() | ||
{ | ||
return m_infoType == RatingInfoType.Image; | ||
} | ||
|
||
// Private members | ||
private TextBlock? m_captionTextBlock = null; | ||
|
||
private CompositionPropertySet? m_sharedPointerPropertySet = null; | ||
|
||
private StackPanel? m_backgroundStackPanel = null; | ||
private StackPanel? m_foregroundStackPanel = null; | ||
|
||
private bool m_isPointerOver = false; | ||
private bool m_isPointerDown = false; | ||
private double m_mousePercentage = 0.0; | ||
|
||
private RatingInfoType m_infoType = RatingInfoType.Font; | ||
|
||
// Holds the value of the Rating control at the moment of engagement, | ||
// used to handle cancel-disengagements where we reset the value. | ||
private double m_preEngagementValue = 0.0; | ||
private bool m_disengagedWithA = false; | ||
private bool m_shouldDiscardValue = true; | ||
|
||
private long m_fontFamilyChangedToken; | ||
|
||
private DispatcherHelper? m_dispatcherHelper = null; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.