Skip to content

Port ToolStripCollectionEditor to the Runtime#12896

Merged
Tanya-Solyanik merged 5 commits intodotnet:mainfrom
LeafShi1:Issue_2341_Port_ToolStripCollectionEditor
Feb 14, 2025
Merged

Port ToolStripCollectionEditor to the Runtime#12896
Tanya-Solyanik merged 5 commits intodotnet:mainfrom
LeafShi1:Issue_2341_Port_ToolStripCollectionEditor

Conversation

@LeafShi1
Copy link
Member

@LeafShi1 LeafShi1 commented Feb 7, 2025

Fixes #2341

Proposed changes

  • Port ToolStripCollectionEditor from VSrepo to the Runtime

Customer Impact

  • The ToolStripCollectionEditor can be used in Runtime.

Regression?

  • No

Risk

  • Minimal

Screenshots

Before

image

After

image

Test methodology

  • Manually

Test environment(s)

  • .net 10.0.0-beta.25074.4
Microsoft Reviewers: Open in CodeFlow

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 16 out of 35 changed files in this pull request and generated no comments.

Files not reviewed (19)
  • src/System.Windows.Forms.Design/src/Resources/SR.resx: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.cs.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.de.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.es.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.fr.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.it.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.ja.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.ko.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.pl.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.pt-BR.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.ru.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.tr.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.zh-Hans.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/SR.zh-Hant.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/ToolStripItemEditorForm.cs.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/ToolStripItemEditorForm.de.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/ToolStripItemEditorForm.es.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/ToolStripItemEditorForm.fr.xlf: Language not supported
  • src/System.Windows.Forms.Design/src/Resources/xlf/ToolStripItemEditorForm.it.xlf: Language not supported

@dotnet-policy-service dotnet-policy-service bot added the draft draft PR label Feb 7, 2025
@@ -0,0 +1,630 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
Copy link
Contributor

Choose a reason for hiding this comment

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

This file should be added to the loc project

@LeafShi1 LeafShi1 marked this pull request as ready for review February 8, 2025 10:11
@LeafShi1 LeafShi1 requested a review from a team as a code owner February 8, 2025 10:11
@dotnet-policy-service dotnet-policy-service bot removed the draft draft PR label Feb 8, 2025
@Tanya-Solyanik Tanya-Solyanik added the waiting-author-feedback The team requires more information from the author label Feb 11, 2025
@LeafShi1 LeafShi1 force-pushed the Issue_2341_Port_ToolStripCollectionEditor branch from 75d4c18 to 8b1915e Compare February 12, 2025 07:05
@codecov
Copy link

codecov bot commented Feb 12, 2025

Codecov Report

Attention: Patch coverage is 0% with 820 lines in your changes missing coverage. Please review.

Project coverage is 75.97975%. Comparing base (7210b61) to head (8b1915e).
Report is 13 commits behind head on main.

Additional details and impacted files
@@                 Coverage Diff                 @@
##                main      #12896         +/-   ##
===================================================
- Coverage   76.07479%   75.97975%   -0.09504%     
===================================================
  Files           3255        3258          +3     
  Lines         642151      642970        +819     
  Branches       47295       47402        +107     
===================================================
+ Hits          488515      488527         +12     
- Misses        150083      150889        +806     
- Partials        3553        3554          +1     
Flag Coverage Δ
Debug 75.97975% <0.00000%> (-0.09504%) ⬇️
integration 18.01591% <0.00000%> (-0.05993%) ⬇️
production 49.86123% <0.00000%> (-0.13860%) ⬇️
test 96.96536% <ø> (-0.00001%) ⬇️
unit 47.31736% <0.00000%> (-0.10574%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

@LeafShi1 LeafShi1 removed the waiting-author-feedback The team requires more information from the author label Feb 12, 2025
@Tanya-Solyanik
Copy link
Contributor

@LeafShi1 - looks good, could you please test editor behavior in a standalone SystemAware and PerMonitorv2 applications? - Modify the scratch project to contain a toolstrip and a property grid, set selected object in property grid to your ToolStrip, verify if the app is SystemAware or PerMonitorv2 and run it on a scaled monitor.

@LeafShi1
Copy link
Member Author

@LeafShi1 - looks good, could you please test editor behavior in a standalone SystemAware and PerMonitorv2 applications? - Modify the scratch project to contain a toolstrip and a property grid, set selected object in property grid to your ToolStrip, verify if the app is SystemAware or PerMonitorv2 and run it on a scaled monitor.

The editor form cannot be opened from scratch project
image

The test result in DemoConsole project
AfterChanges

@dotnet-policy-service dotnet-policy-service bot added untriaged The team needs to look at this issue in the next triage and removed 📭 waiting-author-feedback labels Feb 13, 2025
@LeafShi1 LeafShi1 added waiting-review This item is waiting on review by one or more members of team and removed untriaged The team needs to look at this issue in the next triage labels Feb 14, 2025
@Tanya-Solyanik Tanya-Solyanik removed the waiting-review This item is waiting on review by one or more members of team label Feb 14, 2025
Copy link
Contributor

@Tanya-Solyanik Tanya-Solyanik left a comment

Choose a reason for hiding this comment

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

Thank you!

@Tanya-Solyanik
Copy link
Contributor

@LeafShi1

The editor form cannot be opened from scratch project

This is because to discover your new editor this project should reference the implementation file and the appropriate redirection facades

    <ProjectReference Include="..\..\..\..\System.Windows.Forms.Design\src\System.Windows.Forms.Design.csproj" />
    <ProjectReference Include="..\..\..\..\System.Design\src\System.Design.Facade.csproj" />
    <ProjectReference Include="..\..\..\..\System.Drawing.Design\src\System.Drawing.Design.Facade.csproj" />

I had tested this scenario, PropertyGrid opens this editor in System-Aware mode, so we are good.

@Tanya-Solyanik Tanya-Solyanik merged commit a6268c4 into dotnet:main Feb 14, 2025
8 checks passed
@dotnet-policy-service dotnet-policy-service bot added this to the 10.0 Preview2 milestone Feb 14, 2025
@LeafShi1 LeafShi1 deleted the Issue_2341_Port_ToolStripCollectionEditor branch February 14, 2025 07:45
@Nora-Zhou01
Copy link
Contributor

Verified this PR in Winforms main branch for .NET10.0, ToolStripCollectionEditor is now supported at runtime.
image

@Zheng-Li01
Copy link
Member

Verified the issue with the latest winforms repo from release/10.0-preview2 branch that the ToolStripCollectionEditor is now supported at runtime

LeafShi1 added a commit to LeafShi1/winforms that referenced this pull request Mar 6, 2025
@github-actions github-actions bot locked and limited conversation to collaborators Mar 30, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Port ToolStripCollectionEditor

5 participants