Skip to content

Feature: Mainly for updates of Personalization #935

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

Merged

Conversation

ChenYiLins
Copy link

@ChenYiLins ChenYiLins commented Apr 2, 2025

Feature: Mainly for updates of WallpaperPickerPage

Describe

Refer to TimePage designed by @Jay-o-Way. The function is basically consistent with the original Page.

Screenshot

Take an overall view

Take an overall view

Picture

Picture

Picture mm

Picturemm

Solid color

Solid color

@Jay-o-Way
Copy link

Honestly, I don't think the ComboButton is appropriate here. User can set things for both themes, it's not one-or-the-other.

@Armin2208
Copy link
Member

Honestly, I don't think the ComboButton is appropriate here. User can set things for both themes, it's not one-or-the-other.

Maybe you can realize this with a tab interface in this case.

@ChenYiLins
Copy link
Author

Honestly, I don't think the ComboButton is appropriate here. User can set things for both themes, it's not one-or-the-other.

Actually, only one theme setting will take effect at a time. In the original code, the option of this ComboBox initializes with the current theme of the computer, which is very intuitive.

But your point of view is actually very correct. In the original Pick an accent color Page, it used the method you mentioned.

If we use ComboBox, it may be ambiguous to users, because users will not know for the first time that different types can be adopted under different themes.

image

Copy link

@Jay-o-Way Jay-o-Way left a comment

Choose a reason for hiding this comment

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

Quickly from my phone

@Jay-o-Way
Copy link

Maybe you can realize this with a tab interface in this case.

Or maybe a Selector bar ? Let's give this UX a good night sleep.

@Spiritreader
Copy link
Member

The new wallpaper page looks nice!
Do you know if it's still possible to provide an image preview like with the old UI?

A couple of notes:

In the original code, the option of this ComboBox initializes with the current theme of the computer, which is very intuitive.

This is really important and mandatory. Otherwise it becomes really confusing when trying to configure it (believe me, I experienced this a lot of times before we implemented this)

@ChenYiLins
Copy link
Author

ChenYiLins commented Apr 5, 2025

Code quality: Improve WallpaperPickerPage

Describe

  • Change bool variable to enum.
  • Add picture preview.
  • Add Grid column definition to avoid overlapping controls.
  • Increase Border display color.
  • On the initialization page, set ThemeMode to follow the current system theme.
  • Add converter: EnumToIndexConverter, FlagsToVisibilityConverter.

This is really important and mandatory. Otherwise it becomes really confusing when trying to configure it (believe me, I experienced this a lot of times before we implemented this)

It's right. We use ComboBox is the better choice. Because in the configuration file, not all settings correspond to Light or Dark Mode.

  Component:
    Position: Fill
    Monitors:
    - Id: '\\?\DISPLAY#SKG2725#7&e9a60b&0&UID256#{e6f07b5f-ee97-4a90-b076-33f57bf4eaa7}'

Screenshots

Picture preview

image

Avoid overlapping controls

image

Colorful border

image

@ChenYiLins
Copy link
Author

Code quality: Improve performance

Describe

  • Fix missing enum.
  • Prevent the page from being loaded twice because of the change of the value.
  • Optimized the code for loading the monitors.
  • The method of OnNavigatedFrom is added to View, which makes it possible to remove HandleConfigUpdate when the page leaves. (It's very import! This will cause very serious performance problems! ) (I feel more and more wrong, because it takes a long time to load the page, so I found this problem. (っ °Д °;)っ)

Supplement

In fact, loading monitors in ViewModel will also cause some performance consumption. This is the test result:

Load monitors
Time:104
Time:61
Time:58
Time:55
Time:79

Do not load monitors
Time:22
Time:7
Time:3
Time:26
Time:3

Maybe we should separate this method and avoid using x:bind, but GlobalWallpaperPath depends on SelectMonitor (MonitorSettings), which in turn depends on Monitors. My mood: (;´д`)ゞ

<RadioButton Content="{helpers:ResourceString Name=WallpaperComboBoxItemPicture}" />
<RadioButton Content="{helpers:ResourceString Name=WallpaperComboBoxItemPictureMM}" />
<RadioButton Content="{helpers:ResourceString Name=WallpaperComboBoxItemSolidColor}" />
<RadioButton Content="{helpers:ResourceString Name=ThemePickerTheme11Spotlight}" />
Copy link

@Jay-o-Way Jay-o-Way Apr 8, 2025

Choose a reason for hiding this comment

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

The full string should be "Windows Spotlight". Extra idea: add a Hyperlink to ms-settings:personalization-background ? If we do, we can remove the redundancy in the separator, as in previous comment

Copy link
Author

Choose a reason for hiding this comment

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

Thanks for your idea. Although not all dividing lines can be merged, because multi-monitors and wallpaper filling methods are only suitable for multi-monitors mode. In the test, I can't seem to use NavigateUri, which can't trigger correctly. So I ues Click.

Choose a reason for hiding this comment

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

I can't seem to use NavigateUri, which can't trigger correctly. So I ues Click

Hm, strange, this should just work... 🤔

Copy link
Author

Choose a reason for hiding this comment

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

I found this.

@ChenYiLins
Copy link
Author

Code quality: Add WindowsSpotlight hyperlink

Describe

  • Merage dividing lines.
  • Add a HyperlinkButton to navigate to Windows settings.

Screenshots

image

@ChenYiLins
Copy link
Author

Code quality: Supplementary update

Describe

  • Fixed file name.
  • Add icon for SettingsCard.
  • Visual balance.

Screenshots

image

@ChenYiLins
Copy link
Author

Code quality: Renameed

Describe

  • Buttons should convey their meaning through more detailed words, rather than icons.
  • Rename some names to make them more uniform.

Screenshots

image

@ChenYiLins ChenYiLins changed the title Feature: Mainly for updates of WallpaperPickerPage Feature: Mainly for updates of Personalization Apr 11, 2025
@ChenYiLins ChenYiLins closed this Apr 11, 2025
@ChenYiLins ChenYiLins deleted the winui3-wallpaperpicker-page branch April 11, 2025 12:17
@ChenYiLins ChenYiLins restored the winui3-wallpaperpicker-page branch April 11, 2025 12:20
@ChenYiLins ChenYiLins reopened this Apr 11, 2025
@ChenYiLins
Copy link
Author

Feature: Mainly for updates of ColorizationPage

Describe

Add ColorizationPage.

Screenshots

image

gif

@Jay-o-Way
Copy link

Jay-o-Way commented Apr 11, 2025

Idea: if it were me, I would say
[ Color ... Select color ]

@ChenYiLins
Copy link
Author

Idea: if it were me, I would say [ Color ... Select color ]

@Jay-o-Way I found a example.

image

@Spiritreader
Copy link
Member

Spiritreader commented Apr 12, 2025

Code quality: Improve performance

Describe

* Fix missing enum.

* Prevent the page from being loaded twice because of the change of the value.

* Optimized the code for loading the monitors.

* The method of OnNavigatedFrom is added to View, which makes it possible to remove HandleConfigUpdate when the page leaves. (It's very import! This will cause very serious performance problems! ) (I feel more and more wrong, because it takes a long time to load the page, so I found this problem. (っ °Д °;)っ)

Supplement

In fact, loading monitors in ViewModel will also cause some performance consumption. This is the test result:

Load monitors
Time:104
Time:61
Time:58
Time:55
Time:79

Do not load monitors
Time:22
Time:7
Time:3
Time:26
Time:3

Maybe we should separate this method and avoid using x:bind, but GlobalWallpaperPath depends on SelectMonitor (MonitorSettings), which in turn depends on Monitors. My mood: (;´д`)ゞ

Yeah, getting monitor information from the windows API is unexplicably slow for some reason, which is why there is this caching mechanism. Previously, loading the monitor settings was done asynchronously on page open. Then the page opened quickly and the monitor strings were loaded in deferred.
Is that no longer an option with WinUi3?

Afaik there's no way to speed this operation up, so at some point getting the name string is necessary.

@ChenYiLins
Copy link
Author

Yeah, getting monitor information from the windows API is unexplicably slow for some reason, which is why there is this caching mechanism. Previously, loading the monitor settings was done asynchronously on page open. Then the page opened quickly and the monitor strings were loaded in deferred. Is that no longer an option with WinUi3?

Afaik there's no way to speed this operation up, so at some point getting the name string is necessary.

Actually, maybe I'm a little picky. IIn WinUI, we can completely rely on loading asynchronously, but we need to add something to View. Fortunately, the current processing method will not cause too much performance burden.

@tooomm
Copy link
Contributor

tooomm commented Apr 13, 2025

Idea: if it were me, I would say [ Color ... Select color ]

image

I also feel the wording of the description and the button is not ideal.
Accent color [ ] [ Select color ] or [ Color picker ]

@ChenYiLins
Copy link
Author

Code quality: Fix button's content

Describe

According to everyone's opinions, the Content of the button was modified. Of course, it needs to be added to resw later.

Screenshots

image

@Spiritreader
Copy link
Member

monitor-selector.mp4

Changing the monitor selection does not update the wallpaper path or preview

@ChenYiLins
Copy link
Author

Feature: Add the missing function

Describe

  • Switching monitors options will now match the correct wallpaper.
  • The unconnected monitors can be removed normally.
  • Changed the method of loading the monitors. Due to asynchronous execution, there is almost no additional performance overhead for loading pages.
  • Changed the display mode of TeachingTip, and now it will automatically close if it loses focus.

Screenshots

image

image

@ChenYiLins
Copy link
Author

Feature: Mainly for updates of CursorsPage

Describe

Function of CursorsPage. At the same time, the package of System.Drawing is introduced.

Screenshots

image

@Spiritreader
Copy link
Member

@ChenYiLins I'm gonna go ahead and merge in your changes into the branch such that we can start syncing in stuff :)
Please open another PR for the remaining pages.

@Spiritreader Spiritreader merged commit b0c1f74 into AutoDarkMode:winui3 Apr 14, 2025
@ChenYiLins ChenYiLins deleted the winui3-wallpaperpicker-page branch April 14, 2025 13:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants