Revised Tooltip & ContextMenuItem for GC #1002
Draft
+70
−9
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR aims to solve the issues described in: #941:
Tooltip & Menu
_allTooltips
property when the Tooltip is disposed to avoid any left-over references.Example:
Finalizer
A finalizer has been added to the Control class to ensure that Dispose is called when objects are collected by the GC. However, this still does not guarantee that it's disposed when the program is terminated. This is only a problem when classes derived from Control use unmanaged resources that are released by the dispose method.
Potential problems
The DisposeControl method is not guaranteed to be called in every scenario. An example of this is when the program is terminated, because the GC may not have called the finalizer on the control at that point. This means that any unmanaged resources could linger while they should have been released by the DisposeControl method.
Is this a breaking change?
Breaking changes require additional review prior to merging. If you answer yes, please explain what breaking changes have been made.
No