-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Fix 13077 Add missed events to ToolStripDesigner #13093
base: main
Are you sure you want to change the base?
Fix 13077 Add missed events to ToolStripDesigner #13093
Conversation
058748a
to
5b7a4f5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Overview
This pull request updates the ToolStripDesigner to add missing event-handling and improve event subscription and disposal logic, addressing issue #13077.
- Added missing UndoEngine field and its event subscriptions.
- Updated and refactored event hook-ups and unsubscriptions for the overflow drop-down and related components.
- Cleaned up array initializations and simplified property implementations.
Reviewed Changes
File | Description |
---|---|
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/ToolStripDesigner.cs | Updates to event subscription, disposal routines, and minor code cleanups to match the VS repository changes |
Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.
Comments suppressed due to low confidence (1)
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/ToolStripDesigner.cs:996
- [nitpick] Consider clarifying this comment to explain what 'DummyItem' refers to, for improved readability.
// We are DummyItem to the ToolStrip.
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/ToolStripDesigner.cs
Outdated
Show resolved
Hide resolved
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #13093 +/- ##
===================================================
+ Coverage 61.28341% 61.33731% +0.05389%
===================================================
Files 1541 1543 +2
Lines 158281 158393 +112
Branches 14743 14754 +11
===================================================
+ Hits 97000 97154 +154
+ Misses 60584 60543 -41
+ Partials 697 696 -1
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/ToolStripDesigner.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/ToolStripDesigner.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/ToolStripDesigner.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/ToolStripDesigner.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms.Design/src/System/Windows/Forms/Design/ToolStripDesigner.cs
Outdated
Show resolved
Hide resolved
_undoEngine.Undoing += OnUndoing; | ||
_undoEngine.Undone += OnUndone; | ||
} | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
_undoEngine?? = GetService(typeof(UndoEngine)) as UndoEngine;
if (_undoEngine is not null)
{
_undoEngine.Undoing += OnUndoing;
_undoEngine.Undone += OnUndone;
}
Fixes #13077
Proposed changes
Customer Impact
Regression?
Risk
Screenshots
Before
After
Test methodology
Test environment(s)
Microsoft Reviewers: Open in CodeFlow