[WinForms] Dispose tooltips (#12059)
commit7331c5e1d7cb6ec06c15b6e273aa38e5890880ce
authorPaulBol <38468549+PaulBol@users.noreply.github.com>
Fri, 21 Dec 2018 09:50:12 +0000 (21 10:50 +0100)
committerAlexander Köplinger <alex.koeplinger@outlook.com>
Fri, 21 Dec 2018 09:50:12 +0000 (21 10:50 +0100)
treee59daebf4d32b3d0a2c1f9279f9b1a6acc1e7b81
parent534c98c070b2b173dac7c207b42d0a9334d820a1
[WinForms] Dispose tooltips (#12059)

I noticed that some controls do not dispose tooltips and timers. Depending on the underlying implementation these may use native resources. Therefore I'd suggest to dispose these with the parent control to not rely on the garbage collector to eventually release the resources.

Additionally, in the case of `ToolStrip.cs` `CloseToolTip` would first create the objects before turning them off.
mcs/class/System.Windows.Forms/System.Windows.Forms/DataGridView.cs
mcs/class/System.Windows.Forms/System.Windows.Forms/ListView.cs
mcs/class/System.Windows.Forms/System.Windows.Forms/StatusBar.cs
mcs/class/System.Windows.Forms/System.Windows.Forms/TabControl.cs
mcs/class/System.Windows.Forms/System.Windows.Forms/ToolBar.cs
mcs/class/System.Windows.Forms/System.Windows.Forms/ToolStrip.cs
mcs/class/System.Windows.Forms/System.Windows.Forms/ToolStripTextBox.cs
mcs/class/System.Windows.Forms/System.Windows.Forms/TreeView.cs