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

Upgrading to Visual Studio 17.5 broke MAUI Windows Slider #13917

Closed
vsfeedback opened this issue Mar 14, 2023 · 3 comments
Closed

Upgrading to Visual Studio 17.5 broke MAUI Windows Slider #13917

vsfeedback opened this issue Mar 14, 2023 · 3 comments
Labels
area-controls-slider Slider i/regression This issue described a confirmed regression on a currently supported version platform/windows 🪟 t/bug Something isn't working
Milestone

Comments

@vsfeedback
Copy link

vsfeedback commented Mar 14, 2023

This issue has been moved from a ticket on Developer Community.


[severity:I'm unable to use this version] [regression] [worked-in:17.4.4]
Upgrading the Visual Studio 17.5 caused some minor spacing and alignment to change in my .net MAUI app deployed to windows and also broke our slider in the application.

Steps to reproduce

  1. Create a MAUI .net Application
  2. Create a ViewModel for the slider with the following properties
    • public double SliderPercentage { get; set; }
    • public ICommand DragStartedCommand { get; }
    • public ICommand DragCompletedCommand { get; }
      • The commands do not have to do anything
  3. Set the view model as the binding context for the page and pass the view model to the page somehow.
  4. Create an svg file called scrollable_icon.svg in the resources/Images folder for the thumb image. Change the build action to MAUI image. The file contains (this site doesn't accept svg files as attachments):
<svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="747.000000pt" height="716.000000pt" viewBox="0 0 747.000000 716.000000" preserveAspectRatio="xMidYMid meet">
  <g transform="translate(0.000000,716.000000) scale(0.100000,-0.100000)" fill="#000000" stroke="none">
    <path d="M1820 7023 c-94 -16 -203 -66 -264 -122 -15 -14 -116 -158 -224 -320 -245 -370 -277 -412 -427 -576 -115 -125 -129 -143 -159 -202 -54 -107 -56 -132 -56 -585 0 -468 -1 -460 70 -521 79 -67 97 -70 459 -76 l325 -6 29 -50 c99 -168 295 -291 537 -336 105 -20 310 -15 417 9 225 51 412 175 501 333 l27 49 730 0 730 0 23 -44 c58 -108 190 -221 332 -282 123 -53 242 -77 395 -77 191 0 316 28 466 104 122 63 241 177 278 267 l13 30 266 4 c299 5 326 10 402 75 71 61 70 53 70 515 0 397 -1 413 -21 455 -24 50 -82 103 -147 133 -30 15 -161 42 -386 81 -384 66 -396 69 -486 114 -114 57 -122 66 -708 730 -172 195 -206 222 -348 272 l-79 28 -1370 1 c-753 1 -1381 0 -1395 -3z m765 -678 l0 -410 -425 -3 c-464 -3 -515 1 -550 45 -34 44 -47 7 177 503 41 91 82 173 92 184 24 27 99 68 150 82 32 9 124 12 301 11 l255 -2 0 -410z m1860 391 c123 -48 112 -36 546 -555 142 -170 153 -195 102 -228 -25 -17 -90 -18 -1040 -21 l-1013 -2 0 415 0 416 678 -3 c638 -3 680 -4 727 -22z m-2007 -1693 c241 -60 326 -289 161 -437 -158 -143 -466 -139 -614 9 -132 132 -89 308 98 400 111 54 218 63 355 28z m2955 6 c202 -39 321 -222 241 -369 -109 -201 -478 -242 -663 -74 -153 137 -95 344 119 425 96 36 184 41 303 18z" />
    <path d="M370 3445 l0 -745 3200 0 3200 0 0 745 0 745 -3200 0 -3200 0 0 -745z" />
    <path d="M3583 304 c-13 -32 -10 -221 4 -235 20 -20 28 16 28 128 0 67 -4 106 -12 114 -10 10 -14 8 -20 -7z" />
  </g>
</svg>
  1. Add a slider to the MAUI app with the following attributes and bindings and surrounding Grid:
<Grid>
    <Grid.ColumnDefinitions>
        <ColumnDefinition Width="100" />
        <ColumnDefinition Width="*" />
        <ColumnDefinition Width="100" />
    </Grid.ColumnDefinitions>

    <Slider x:Name="Slider" 
            ThumbImageSource="scrollable_icon.png"
            MinimumTrackColor="Red"
            MaximumTrackColor="Green"
            Value="{Binding SliderPercentage}"
            DragStartedCommand="{Binding DragStartedCommand}"
            DragCompletedCommand="{Binding DragCompletedCommand}"
            Minimum="0"
            Maximum="1"
            Margin="20,0"
            Grid.Column="0"
            Grid.ColumnSpan="3"/>

</Grid>
  1. Run the application on Windows 10 Home 22H2

Expected behaviour
The slider can move from the beginning to the end when the user drags it back and forth
Actual Behaviour
The slider gets stuck at about one third of the way across and does not move after that


Original Comments

Feedback Bot on 3/1/2023, 05:51 PM:

(private comment, text removed)


Original Solutions

(no solutions)

@samhouts samhouts added t/bug Something isn't working legacy-area-controls Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor area-controls-slider Slider i/regression This issue described a confirmed regression on a currently supported version labels Mar 14, 2023
@PureWeen PureWeen added this to the Backlog milestone Mar 14, 2023
@ghost
Copy link

ghost commented Mar 14, 2023

We've added this issue to our backlog, and we will work to address it as time and resources allow. If you have any additional information or questions about this issue, please leave a comment. For additional info about issue management, please read our Triage Process.

@RohitYeast
Copy link

@samhouts I have re-updated my Visual Studio to 17.5.2 and could not reproduce this problem at that version. The original issue was found running my Maui App on windows through Visual Studio version 17.5.1. Does this resolve the issue?

@samhouts
Copy link
Member

samhouts commented Apr 5, 2023

Duplicate of #13061

@samhouts samhouts marked this as a duplicate of #13061 Apr 5, 2023
@samhouts samhouts closed this as completed Apr 5, 2023
@ghost ghost locked as resolved and limited conversation to collaborators May 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
area-controls-slider Slider i/regression This issue described a confirmed regression on a currently supported version platform/windows 🪟 t/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants