d85f2e0fb3
Bootstraper läd jetzt die farbeinstellung sofort und nicht nachträglich cleanup and rework PDF switch to HTML export fix Colorsystem Farben für knöpfe hinzugefügt als anpassung button color button color primary and secondary change
31 lines
870 B
C#
31 lines
870 B
C#
using Microsoft.Maui.ApplicationModel;
|
|
|
|
namespace cfs_tracker.Services;
|
|
|
|
public static class ExportUiHelper
|
|
{
|
|
public static async Task ShowExportSavedActionsAsync(ExportResult result)
|
|
{
|
|
var action = await Shell.Current.DisplayActionSheetAsync(
|
|
$"Export gespeichert:\n{result.FileName}",
|
|
"Schließen",
|
|
null,
|
|
"Öffnen",
|
|
"Teilen");
|
|
|
|
if (action == "Öffnen")
|
|
{
|
|
await Launcher.Default.OpenAsync(new OpenFileRequest(
|
|
"Export öffnen",
|
|
new ReadOnlyFile(result.FilePath)));
|
|
}
|
|
else if (action == "Teilen")
|
|
{
|
|
await Share.Default.RequestAsync(new ShareFileRequest
|
|
{
|
|
Title = "Export teilen",
|
|
File = new ShareFile(result.FilePath)
|
|
});
|
|
}
|
|
}
|
|
} |