Loading INAF.Apps.Uwp.SLabDataManager/App.xaml.cs +2 −1 Original line number Diff line number Diff line Loading @@ -14,6 +14,7 @@ using INAF.Apps.Uwp.SLabDataManager.Models.Containers; using INAF.Apps.Uwp.SLabDataManager.Services; using INAF.Apps.Uwp.SLabDataManager.ViewModels; using INAF.Apps.Uwp.SLabDataManager.ViewModels.ContentDialogsViewModel; using INAF.Apps.Uwp.SLabDataManager.ViewModels.Other; using INAF.Apps.Uwp.SLabDataManager.ViewModels.UserControlViewModels; using INAF.Libraries.NetStandard.Math.Fit.Linear; using INAF.Libraries.NetStandard.Math.Fit.Spline; Loading Loading @@ -76,7 +77,6 @@ namespace INAF.Apps.Uwp.SLabDataManager await ActivationService.ActivateAsync(args); } private void OnAppUnhandledException(object sender, Windows.UI.Xaml.UnhandledExceptionEventArgs e) { // TODO WTS: Please log and handle the exception as appropriate to your scenario Loading Loading @@ -147,6 +147,7 @@ namespace INAF.Apps.Uwp.SLabDataManager /* scoped */ .AddScoped<ActionQuestionViewModel>() .AddScoped<LegendItemsHelper>() .AddScoped<MultipleSelectionViewModel>() .AddScoped<ProcessedSpectraContainer>() .AddScoped<StorageItemsHelper>() /* transient */ Loading INAF.Apps.Uwp.SLabDataManager/Constants/Enums.cs +7 −0 Original line number Diff line number Diff line Loading @@ -53,5 +53,12 @@ namespace INAF.Apps.Uwp.SLabDataManager.Constants SingleItem, MultipleItems } public enum RecentItemsReadingType { None = 0, Single, All, } } } INAF.Apps.Uwp.SLabDataManager/Converters/Converters.cs +24 −0 Original line number Diff line number Diff line Loading @@ -245,6 +245,30 @@ namespace INAF.Apps.Uwp.SLabDataManager.Converters } } public sealed class SelectedFilesNumVisibilityConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, string language) { try { int selectedFilesNum = (int)value; if (selectedFilesNum > 0) return Visibility.Visible; else return Visibility.Collapsed; } catch (Exception) { return Visibility.Collapsed; } } public object ConvertBack(object value, Type targetType, object parameter, string language) { throw new NotImplementedException(); } } public sealed class ShortFilepathConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, string language) Loading INAF.Apps.Uwp.SLabDataManager/Helpers/FileReaders/SpectrumFiles/BaseFileReader.cs +1 −1 Original line number Diff line number Diff line Loading @@ -21,7 +21,7 @@ namespace INAF.Apps.Uwp.SLabDataManager.Helpers.FileReaders this.logger = logger; } public Task<(IChartSpectrumModel spectrum, string exMsg)> readFileAsync(string fileKey) public virtual Task<(IChartSpectrumModel spectrum, string exMsg)> readFileAsync(string fileKey) { throw new NotImplementedException(); } Loading INAF.Apps.Uwp.SLabDataManager/Helpers/FileReaders/SpectrumFiles/XmlSpectrumFileReader.cs +1 −1 Original line number Diff line number Diff line Loading @@ -23,7 +23,7 @@ namespace INAF.Apps.Uwp.SLabDataManager.Helpers.FileReaders this.xmlHelper = xmlHelper; } public async Task<(IChartSpectrumModel spectrum, string exMsg)> readFileAsync(string fileKey) public new async Task<(IChartSpectrumModel spectrum, string exMsg)> readFileAsync(string fileKey) { IChartSpectrumModel chartSpectrumModel = null; string exMsg = string.Empty; Loading Loading
INAF.Apps.Uwp.SLabDataManager/App.xaml.cs +2 −1 Original line number Diff line number Diff line Loading @@ -14,6 +14,7 @@ using INAF.Apps.Uwp.SLabDataManager.Models.Containers; using INAF.Apps.Uwp.SLabDataManager.Services; using INAF.Apps.Uwp.SLabDataManager.ViewModels; using INAF.Apps.Uwp.SLabDataManager.ViewModels.ContentDialogsViewModel; using INAF.Apps.Uwp.SLabDataManager.ViewModels.Other; using INAF.Apps.Uwp.SLabDataManager.ViewModels.UserControlViewModels; using INAF.Libraries.NetStandard.Math.Fit.Linear; using INAF.Libraries.NetStandard.Math.Fit.Spline; Loading Loading @@ -76,7 +77,6 @@ namespace INAF.Apps.Uwp.SLabDataManager await ActivationService.ActivateAsync(args); } private void OnAppUnhandledException(object sender, Windows.UI.Xaml.UnhandledExceptionEventArgs e) { // TODO WTS: Please log and handle the exception as appropriate to your scenario Loading Loading @@ -147,6 +147,7 @@ namespace INAF.Apps.Uwp.SLabDataManager /* scoped */ .AddScoped<ActionQuestionViewModel>() .AddScoped<LegendItemsHelper>() .AddScoped<MultipleSelectionViewModel>() .AddScoped<ProcessedSpectraContainer>() .AddScoped<StorageItemsHelper>() /* transient */ Loading
INAF.Apps.Uwp.SLabDataManager/Constants/Enums.cs +7 −0 Original line number Diff line number Diff line Loading @@ -53,5 +53,12 @@ namespace INAF.Apps.Uwp.SLabDataManager.Constants SingleItem, MultipleItems } public enum RecentItemsReadingType { None = 0, Single, All, } } }
INAF.Apps.Uwp.SLabDataManager/Converters/Converters.cs +24 −0 Original line number Diff line number Diff line Loading @@ -245,6 +245,30 @@ namespace INAF.Apps.Uwp.SLabDataManager.Converters } } public sealed class SelectedFilesNumVisibilityConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, string language) { try { int selectedFilesNum = (int)value; if (selectedFilesNum > 0) return Visibility.Visible; else return Visibility.Collapsed; } catch (Exception) { return Visibility.Collapsed; } } public object ConvertBack(object value, Type targetType, object parameter, string language) { throw new NotImplementedException(); } } public sealed class ShortFilepathConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, string language) Loading
INAF.Apps.Uwp.SLabDataManager/Helpers/FileReaders/SpectrumFiles/BaseFileReader.cs +1 −1 Original line number Diff line number Diff line Loading @@ -21,7 +21,7 @@ namespace INAF.Apps.Uwp.SLabDataManager.Helpers.FileReaders this.logger = logger; } public Task<(IChartSpectrumModel spectrum, string exMsg)> readFileAsync(string fileKey) public virtual Task<(IChartSpectrumModel spectrum, string exMsg)> readFileAsync(string fileKey) { throw new NotImplementedException(); } Loading
INAF.Apps.Uwp.SLabDataManager/Helpers/FileReaders/SpectrumFiles/XmlSpectrumFileReader.cs +1 −1 Original line number Diff line number Diff line Loading @@ -23,7 +23,7 @@ namespace INAF.Apps.Uwp.SLabDataManager.Helpers.FileReaders this.xmlHelper = xmlHelper; } public async Task<(IChartSpectrumModel spectrum, string exMsg)> readFileAsync(string fileKey) public new async Task<(IChartSpectrumModel spectrum, string exMsg)> readFileAsync(string fileKey) { IChartSpectrumModel chartSpectrumModel = null; string exMsg = string.Empty; Loading