From 94ac70f0eaf29fcca4ae3ff5552c52cad22df492 Mon Sep 17 00:00:00 2001 From: Roy Ben-Shabat Date: Wed, 14 Feb 2018 10:55:19 +0200 Subject: Refactored all studio modules to use StudioModuleBase. --- .../SynchronizationModule.cs | 42 +++++----------------- 1 file changed, 8 insertions(+), 34 deletions(-) (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization') diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/SynchronizationModule.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/SynchronizationModule.cs index bbf0f8ca1..5292c6048 100644 --- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/SynchronizationModule.cs +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Synchronization/SynchronizationModule.cs @@ -16,65 +16,39 @@ namespace Tango.MachineStudio.Synchronization /// Represents a Machine Studio module capable of comparing and synchronizing machines data against Twine remote database. /// /// - public class SynchronizationModule : IStudioModule + public class SynchronizationModule : StudioModuleBase { - private bool _isLoaded; - private bool _isInitialized; - /// /// Gets the module name. /// - public string Name => "Synchronization"; + public override string Name => "Synchronization"; /// /// Gets the module description. /// - public string Description => "Perform local to local or remote to local database synchronization."; + public override string Description => "Perform local to local or remote to local database synchronization."; /// /// Gets the module cover image. /// - public BitmapSource Image => ResourceHelper.GetImageFromResources("Images/synchronization.jpg"); + public override BitmapSource Image => ResourceHelper.GetImageFromResources("Images/synchronization.jpg"); /// /// Gets the module entry point view. /// - public FrameworkElement MainView => new MainView(); - - /// - /// Sets a value indicating whether this module is loaded. - /// - public bool IsLoaded { get => _isLoaded; set => _isLoaded = value; } - - /// - /// Gets a value indicating whether this module has been initialized. - /// - public bool IsInitialized => _isInitialized; + public override FrameworkElement MainView => new MainView(); /// /// Gets the permission required to see and load this module. /// - public Permissions Permission => Permissions.RunSynchronizationModule; + public override Permissions Permission => Permissions.RunSynchronizationModule; /// /// Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. /// - public void Dispose() + public override void Dispose() { - //Dispose... - } - - /// - /// Perform any operations required to initialize this module. - /// - public void Initialize() - { - if (!_isInitialized) - { - //Initialize.. - - _isInitialized = true; - } + } } } -- cgit v1.3.1