File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 44using Trimble . Modus . Components . Popup . Services ;
55
66namespace Trimble . Modus . Components ;
7- public partial class TMDropDown : ContentView , IDisposable
7+ public partial class TMDropDown : ContentView
88{
99 #region Private fields
1010 private double desiredHeight ;
@@ -136,6 +136,7 @@ public TMDropDown()
136136 InitializeComponent ( ) ;
137137 this . SetDynamicResource ( StyleProperty , "DefaultStyle" ) ;
138138 PopupService . Instance . Dismissed += OnPopupRemoved ;
139+ this . Unloaded += OnUnloaded ;
139140 }
140141 #endregion
141142
@@ -383,8 +384,16 @@ protected override void OnHandlerChanged()
383384 public void Dispose ( )
384385 {
385386 PopupService . Instance . Dismissed -= OnPopupRemoved ;
387+ this . Unloaded -= OnUnloaded ;
386388 SelectionChanged = null ;
387389 SelectionChangedCommand = null ;
388390 ItemsSource = null ;
391+ dropDownContents = null ;
392+ previousSelection = null ;
393+ }
394+
395+ private void OnUnloaded ( object sender , EventArgs e )
396+ {
397+ Dispose ( ) ;
389398 }
390399}
Original file line number Diff line number Diff line change 2727 <GeneratePackageOnBuild >True</GeneratePackageOnBuild >
2828 <PackageId >Trimble.Modus.Components</PackageId >
2929 <Title >Trimble Modus</Title >
30- <Version >1.4.0</Version >
30+ <Version >1.4.0.1 </Version >
3131 <Authors >Trimble Inc</Authors >
3232 <Company >Trimble Inc</Company >
3333 <Product >Trimble.Modus.Components</Product >
You can’t perform that action at this time.
0 commit comments