Skip to content

Commit

Permalink
Remove method to disable slider popup
Browse files Browse the repository at this point in the history
It causes EVERY popup to be disabled, not just sliders
and yeah, it does it for the entire app LMAO
  • Loading branch information
bagusnl committed Jul 13, 2024
1 parent e8bf71e commit 3769465
Showing 1 changed file with 0 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ public ZenlessGameSettingsPage()
});

LoadPage();
this.ColorFilterSlider.LayoutUpdated += ColFilSlider_DisablePopup;
}
catch (Exception ex)
{
Expand Down Expand Up @@ -300,15 +299,5 @@ private void OnUnload(object sender, RoutedEventArgs e)
RegistryWatcher?.Dispose();
});
}

// https://stackoverflow.com/questions/76737204/regarding-sliders-in-win-ui
private void ColFilSlider_DisablePopup(object _, object n)
{
if (VisualTreeHelper.GetOpenPopupsForXamlRoot(this.ColorFilterSlider.XamlRoot)
.FirstOrDefault() is { } popup)
{
popup.Visibility = Visibility.Collapsed;
}
}
}
}

0 comments on commit 3769465

Please sign in to comment.