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

Stepper doesn't change increment value when being bound to a double in MVVM context (Windows) #24396

Open
wants to merge 7 commits into
base: net9.0
Choose a base branch
from

Conversation

devanathan-vaithiyanathan
Copy link
Contributor

@devanathan-vaithiyanathan devanathan-vaithiyanathan commented Aug 23, 2024

Root cause

When the stepper value is updated dynamically, the current increment value isn't properly passed to the PlatformView, which is supposed to update through the IStepper.Interval property.

Description of Change

The interface Interval has been renamed to Increment and is now mapped to the mapIncrement method. All references to Interval have also been renamed to Increment.

API changes

Renamed IStepper.Interval to IStepper.Increment

Issues Fixed

Fixes #20706

Validated the behaviour in the following platforms

  • Android
  • Windows
  • iOS
  • Mac

Output Screenshot

Before Changes

357055938-668993ec-532d-43b4-8b1a-47b98c8ec077.mp4

After Changes

357056346-be60183c-883c-4f72-a49c-06c9f3d6b489.mp4

@dotnet-policy-service dotnet-policy-service bot added the community ✨ Community Contribution label Aug 23, 2024
@PureWeen
Copy link
Member

/azp run

Copy link

Azure Pipelines successfully started running 3 pipeline(s).

@@ -1112,7 +1112,6 @@ Microsoft.Maui.IStackNavigation.NavigationFinished(System.Collections.Generic.IR
Microsoft.Maui.IStackNavigation.RequestNavigation(Microsoft.Maui.NavigationRequest! eventArgs) -> void
Microsoft.Maui.IStackNavigationView
Microsoft.Maui.IStepper
Microsoft.Maui.IStepper.Interval.get -> double
Copy link
Member

Choose a reason for hiding this comment

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

To fix these errors you have to add a Removed line into the UNShipped.txt file

for example,

*REMOVED*override Microsoft.Maui.Platform.ContentView.SetNeedsLayout() -> void
*REMOVED*override Microsoft.Maui.Platform.ContentView.SizeThatFits(CoreGraphics.CGSize size) -> CoreGraphics.CGSize
*REMOVED*override Microsoft.Maui.Platform.LayoutView.LayoutSubviews() -> void
*REMOVED*override Microsoft.Maui.Platform.LayoutView.SetNeedsLayout() -> void
*REMOVED*override Microsoft.Maui.Platform.LayoutView.SetNeedsLayout() -> void
*REMOVED*override Microsoft.Maui.Platform.LayoutView.SizeThatFits(CoreGraphics.CGSize size) -> CoreGraphics.CGSize
*REMOVED*override Microsoft.Maui.Platform.ContentView.SetNeedsLayout() -> void

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have added the required 'Removed' line to the UnShipped.txt file and pushed the changes. Please review the changes and let me know if there are any additional adjustments needed.

@rmarinho
Copy link
Member

/azp run

Copy link

Azure Pipelines successfully started running 3 pipeline(s).

Copy link
Member

@PureWeen PureWeen left a comment

Choose a reason for hiding this comment

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

ChangeIncrementValue failing

@devanathan-vaithiyanathan
Copy link
Contributor Author

Hi @PureWeen ,
I have reviewed the issue and am currently working on a fix for the ChangeIncrementValue functionality.

@rmarinho
Copy link
Member

Needs rebase

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-controls-stepper Stepper community ✨ Community Contribution
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants