DYN-6857: Repurposing homepage preferences changes(#15139)#15215
DYN-6857: Repurposing homepage preferences changes(#15139)#15215reddyashish merged 4 commits intoDynamoDS:masterfrom
Conversation
- added a single serialized preferences storage for the HomePage (cherry picked from commit 534f6cf)
There was a problem hiding this comment.
See the ticket for this pull request: https://jira.autodesk.com/browse/DYN-6857
UI Smoke TestsTest: success. 2 passed, 0 failed. |
- added the new serialized property to the preferences DynamoSettings.xml
|
Thanks Deyan, TestImportCopySettings is now passing. The other failing test ContainsEmptyListOrNullTest is flaky. Waiting for the final serlf-serve to pass. |
|
@reddyashish Please address the merge conflict |
|
Resolved the conflicts. The last test job has passed. So will merge this after the basic tests are done. |
| <WindowW>1936</WindowW> | ||
| <WindowH>1056</WindowH> | ||
| <UseHardwareAcceleration>false</UseHardwareAcceleration> | ||
| <HomePageSettingsSerialized>{"recentPageViewMode":"grid","samplesViewMode":"list"}</HomePageSettingsSerialized> |
There was a problem hiding this comment.
@dnenov Why do we serialize the setting as a json block instead of xml list? This is slightly different than other Dynamo settings
There was a problem hiding this comment.
Hi @QilongTang - I am glad you cast a glance at this! What I am trying to achieve is minimize the amount of separate setting variables we introduce for the HomePage while future proofing the process of introducing new settings. With that idea, I wanted to use a Dictionary<string, obj> (name of the property, value of the property) - as we don't know what type of value a certain setting might have. This type of dictionary is not directly serializable though, so I used a slight workaround to go through .json serialized string.
It's the object part that did not allow me to serialize to xaml directly.
There was a problem hiding this comment.
In hindsight, a Dictionary<string, string> might have worked just fine, at least for the time being.
Let me know what you think, I am more than happy to rework that bit of code to make things less complicated if possible!
There was a problem hiding this comment.
I am leaning towards a Dictionary<string, string> instead so we can serialize and stick to XML. In terms of the specific setting, if casting to bool or double is required in the future, we can do that. I do appreciate your thinking on the future proof though, but we also have customers manually create settings template for the whole company so I would like to prioritize consistency. Let me know if you would like to put it as another PR.
There was a problem hiding this comment.
Thanks Aaron. Discussed this with Deyan and he will make that change in a new PR. Will go ahead and merge this.
Purpose
JIRA: https://jira.autodesk.com/browse/DYN-6857
This is to get the changes from a previous PR(#15139) that was reverted as the build was failing with regressions.
Will be fixing the underlying issues in this new PR.
Declarations
Check these if you believe they are true
*.resxfilesRelease Notes
homepage preferences (#15139)
Reviewers
@dnenov @QilongTang
FYIs
(FILL ME IN, Optional) Names of anyone else you wish to be notified of