From fb01596831cca775c67af516de44befc7851a65c Mon Sep 17 00:00:00 2001 From: 7sharp9 Date: Wed, 25 Jun 2014 17:01:05 +0100 Subject: [PATCH] use Dispose event rather than reimplement disposable --- src/Xamarin.iOSProviders/iOSDesignerProvider.fs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/Xamarin.iOSProviders/iOSDesignerProvider.fs b/src/Xamarin.iOSProviders/iOSDesignerProvider.fs index 8a2fc6d..5de0cc9 100644 --- a/src/Xamarin.iOSProviders/iOSDesignerProvider.fs +++ b/src/Xamarin.iOSProviders/iOSDesignerProvider.fs @@ -271,10 +271,7 @@ type iOSDesignerProvider(config: TypeProviderConfig) as this = do rootType.DefineStaticParameters([ProvidedStaticParameter ("DesignerFile", typeof) ProvidedStaticParameter ("Register", typeof)], buildTypes) this.AddNamespace(ns, [rootType]) - - interface IDisposable with - member x.Dispose() = - if !watchedFile <> null then (!watchedFile).Dispose() + this.Disposing.Add (fun _ -> if !watchedFile <> null then (!watchedFile).Dispose()) [] do() \ No newline at end of file