I don't know some changes....

This commit is contained in:
Burak Kaan Köse
2024-07-19 20:31:13 +02:00
parent 026151e7e4
commit 5b68f237f0
384 changed files with 176 additions and 29755 deletions

View File

@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.19041.0</TargetFramework>
<TargetFramework>net8.0-windows10.0.22621.0</TargetFramework>
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
<RootNamespace>Wino.BackgroundTasks.NET8</RootNamespace>
<RuntimeIdentifiers Condition="$([MSBuild]::GetTargetFrameworkVersion('$(TargetFramework)')) &gt;= 8">win-x86;win-x64;win-arm64</RuntimeIdentifiers>

View File

@@ -1,7 +0,0 @@
<Application
x:Class="Wino.Calendar.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:Wino.Calendar">
</Application>

View File

@@ -1,100 +0,0 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Runtime.InteropServices.WindowsRuntime;
using Windows.ApplicationModel;
using Windows.ApplicationModel.Activation;
using Windows.Foundation;
using Windows.Foundation.Collections;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using Windows.UI.Xaml.Controls.Primitives;
using Windows.UI.Xaml.Data;
using Windows.UI.Xaml.Input;
using Windows.UI.Xaml.Media;
using Windows.UI.Xaml.Navigation;
namespace Wino.Calendar
{
/// <summary>
/// Provides application-specific behavior to supplement the default Application class.
/// </summary>
sealed partial class App : Application
{
/// <summary>
/// Initializes the singleton application object. This is the first line of authored code
/// executed, and as such is the logical equivalent of main() or WinMain().
/// </summary>
public App()
{
this.InitializeComponent();
this.Suspending += OnSuspending;
}
/// <summary>
/// Invoked when the application is launched normally by the end user. Other entry points
/// will be used such as when the application is launched to open a specific file.
/// </summary>
/// <param name="e">Details about the launch request and process.</param>
protected override void OnLaunched(LaunchActivatedEventArgs e)
{
Frame rootFrame = Window.Current.Content as Frame;
// Do not repeat app initialization when the Window already has content,
// just ensure that the window is active
if (rootFrame == null)
{
// Create a Frame to act as the navigation context and navigate to the first page
rootFrame = new Frame();
rootFrame.NavigationFailed += OnNavigationFailed;
if (e.PreviousExecutionState == ApplicationExecutionState.Terminated)
{
//TODO: Load state from previously suspended application
}
// Place the frame in the current Window
Window.Current.Content = rootFrame;
}
if (e.PrelaunchActivated == false)
{
if (rootFrame.Content == null)
{
// When the navigation stack isn't restored navigate to the first page,
// configuring the new page by passing required information as a navigation
// parameter
rootFrame.Navigate(typeof(MainPage), e.Arguments);
}
// Ensure the current window is active
Window.Current.Activate();
}
}
/// <summary>
/// Invoked when Navigation to a certain page fails
/// </summary>
/// <param name="sender">The Frame which failed navigation</param>
/// <param name="e">Details about the navigation failure</param>
void OnNavigationFailed(object sender, NavigationFailedEventArgs e)
{
throw new Exception("Failed to load Page " + e.SourcePageType.FullName);
}
/// <summary>
/// Invoked when application execution is being suspended. Application state is saved
/// without knowing whether the application will be terminated or resumed with the contents
/// of memory still intact.
/// </summary>
/// <param name="sender">The source of the suspend request.</param>
/// <param name="e">Details about the suspend request.</param>
private void OnSuspending(object sender, SuspendingEventArgs e)
{
var deferral = e.SuspendingOperation.GetDeferral();
//TODO: Save application state and stop any background activity
deferral.Complete();
}
}
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.1 KiB

View File

@@ -1,14 +0,0 @@
<Page
x:Class="Wino.Calendar.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:Wino.Calendar"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
<Grid>
</Grid>
</Page>

View File

@@ -1,30 +0,0 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Runtime.InteropServices.WindowsRuntime;
using Windows.Foundation;
using Windows.Foundation.Collections;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using Windows.UI.Xaml.Controls.Primitives;
using Windows.UI.Xaml.Data;
using Windows.UI.Xaml.Input;
using Windows.UI.Xaml.Media;
using Windows.UI.Xaml.Navigation;
// The Blank Page item template is documented at https://go.microsoft.com/fwlink/?LinkId=402352&clcid=0x409
namespace Wino.Calendar
{
/// <summary>
/// An empty page that can be used on its own or navigated to within a Frame.
/// </summary>
public sealed partial class MainPage : Page
{
public MainPage()
{
this.InitializeComponent();
}
}
}

View File

@@ -1,58 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Package
xmlns="http://schemas.microsoft.com/appx/manifest/foundation/windows10"
xmlns:mp="http://schemas.microsoft.com/appx/2014/phone/manifest"
xmlns:uap="http://schemas.microsoft.com/appx/manifest/uap/windows10"
IgnorableNamespaces="uap mp">
<!-- Publisher Cache Folders -->
<Extensions>
<Extension Category="windows.publisherCacheFolders">
<PublisherCacheFolders>
<Folder Name="WinoShared" />
</PublisherCacheFolders>
</Extension>
</Extensions>
<Identity
Name="58272BurakKSE.WinoCalendar"
Publisher="CN=51FBDAF3-E212-4149-89A2-A2636B3BC911"
Version="1.0.0.0" />
<mp:PhoneIdentity PhoneProductId="f047b7dd-96ec-4d54-a862-9321e271e449" PhonePublisherId="00000000-0000-0000-0000-000000000000"/>
<Properties>
<DisplayName>Wino Calendar</DisplayName>
<PublisherDisplayName>Burak KÖSE</PublisherDisplayName>
<Logo>Assets\StoreLogo.png</Logo>
</Properties>
<Dependencies>
<TargetDeviceFamily Name="Windows.Universal" MinVersion="10.0.0.0" MaxVersionTested="10.0.0.0" />
</Dependencies>
<Resources>
<Resource Language="x-generate"/>
</Resources>
<Applications>
<Application Id="App"
Executable="$targetnametoken$.exe"
EntryPoint="Wino.Calendar.App">
<uap:VisualElements
DisplayName="Wino Calendar"
Square150x150Logo="Assets\Square150x150Logo.png"
Square44x44Logo="Assets\Square44x44Logo.png"
Description="Wino.Calendar"
BackgroundColor="transparent">
<uap:DefaultTile Wide310x150Logo="Assets\Wide310x150Logo.png"/>
<uap:SplashScreen Image="Assets\SplashScreen.png" />
</uap:VisualElements>
</Application>
</Applications>
<Capabilities>
<Capability Name="internetClient" />
</Capabilities>
</Package>

View File

@@ -1,29 +0,0 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Wino.Calendar")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("Wino.Calendar")]
[assembly: AssemblyCopyright("Copyright © 2023")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: ComVisible(false)]

View File

@@ -1,31 +0,0 @@
<!--
This file contains Runtime Directives used by .NET Native. The defaults here are suitable for most
developers. However, you can modify these parameters to modify the behavior of the .NET Native
optimizer.
Runtime Directives are documented at https://go.microsoft.com/fwlink/?LinkID=391919
To fully enable reflection for App1.MyClass and all of its public/private members
<Type Name="App1.MyClass" Dynamic="Required All"/>
To enable dynamic creation of the specific instantiation of AppClass<T> over System.Int32
<TypeInstantiation Name="App1.AppClass" Arguments="System.Int32" Activate="Required Public" />
Using the Namespace directive to apply reflection policy to all the types in a particular namespace
<Namespace Name="DataClasses.ViewModels" Serialize="All" />
-->
<Directives xmlns="http://schemas.microsoft.com/netfx/2013/01/metadata">
<Application>
<!--
An Assembly element with Name="*Application*" applies to all assemblies in
the application package. The asterisks are not wildcards.
-->
<Assembly Name="*Application*" Dynamic="Required All" />
<!-- Add your application specific runtime directives here. -->
</Application>
</Directives>

View File

@@ -1,172 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<ProjectGuid>{600F4979-DB7E-409D-B7DA-B60BE4C55C35}</ProjectGuid>
<OutputType>AppContainerExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Wino.Calendar</RootNamespace>
<AssemblyName>Wino.Calendar</AssemblyName>
<DefaultLanguage>en-US</DefaultLanguage>
<TargetPlatformIdentifier>UAP</TargetPlatformIdentifier>
<TargetPlatformVersion Condition=" '$(TargetPlatformVersion)' == '' ">10.0.22621.0</TargetPlatformVersion>
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
<MinimumVisualStudioVersion>14</MinimumVisualStudioVersion>
<FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{A5A43C5B-DE2A-4C0C-9213-0A381AF9435A};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<WindowsXamlEnableOverview>true</WindowsXamlEnableOverview>
<AppxPackageSigningEnabled>True</AppxPackageSigningEnabled>
<PackageCertificateThumbprint>125A5273FCFE8D551C3FED87F67C87A663E98F1B</PackageCertificateThumbprint>
<PackageCertificateKeyFile />
<GenerateTemporaryStoreCertificate>True</GenerateTemporaryStoreCertificate>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x86'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\x86\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP</DefineConstants>
<NoWarn>;2008</NoWarn>
<DebugType>full</DebugType>
<PlatformTarget>x86</PlatformTarget>
<UseVSHostingProcess>false</UseVSHostingProcess>
<ErrorReport>prompt</ErrorReport>
<Prefer32Bit>true</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'">
<OutputPath>bin\x86\Release\</OutputPath>
<DefineConstants>TRACE;NETFX_CORE;WINDOWS_UWP</DefineConstants>
<Optimize>true</Optimize>
<NoWarn>;2008</NoWarn>
<DebugType>pdbonly</DebugType>
<PlatformTarget>x86</PlatformTarget>
<UseVSHostingProcess>false</UseVSHostingProcess>
<ErrorReport>prompt</ErrorReport>
<Prefer32Bit>true</Prefer32Bit>
<UseDotNetNativeToolchain>true</UseDotNetNativeToolchain>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|ARM'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\ARM\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP</DefineConstants>
<NoWarn>;2008</NoWarn>
<DebugType>full</DebugType>
<PlatformTarget>ARM</PlatformTarget>
<UseVSHostingProcess>false</UseVSHostingProcess>
<ErrorReport>prompt</ErrorReport>
<Prefer32Bit>true</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|ARM'">
<OutputPath>bin\ARM\Release\</OutputPath>
<DefineConstants>TRACE;NETFX_CORE;WINDOWS_UWP</DefineConstants>
<Optimize>true</Optimize>
<NoWarn>;2008</NoWarn>
<DebugType>pdbonly</DebugType>
<PlatformTarget>ARM</PlatformTarget>
<UseVSHostingProcess>false</UseVSHostingProcess>
<ErrorReport>prompt</ErrorReport>
<Prefer32Bit>true</Prefer32Bit>
<UseDotNetNativeToolchain>true</UseDotNetNativeToolchain>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|ARM64'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\ARM64\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP</DefineConstants>
<NoWarn>;2008</NoWarn>
<DebugType>full</DebugType>
<PlatformTarget>ARM64</PlatformTarget>
<UseVSHostingProcess>false</UseVSHostingProcess>
<ErrorReport>prompt</ErrorReport>
<Prefer32Bit>true</Prefer32Bit>
<UseDotNetNativeToolchain>true</UseDotNetNativeToolchain>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|ARM64'">
<OutputPath>bin\ARM64\Release\</OutputPath>
<DefineConstants>TRACE;NETFX_CORE;WINDOWS_UWP</DefineConstants>
<Optimize>true</Optimize>
<NoWarn>;2008</NoWarn>
<DebugType>pdbonly</DebugType>
<PlatformTarget>ARM64</PlatformTarget>
<UseVSHostingProcess>false</UseVSHostingProcess>
<ErrorReport>prompt</ErrorReport>
<Prefer32Bit>true</Prefer32Bit>
<UseDotNetNativeToolchain>true</UseDotNetNativeToolchain>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\x64\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP</DefineConstants>
<NoWarn>;2008</NoWarn>
<DebugType>full</DebugType>
<PlatformTarget>x64</PlatformTarget>
<UseVSHostingProcess>false</UseVSHostingProcess>
<ErrorReport>prompt</ErrorReport>
<Prefer32Bit>true</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
<OutputPath>bin\x64\Release\</OutputPath>
<DefineConstants>TRACE;NETFX_CORE;WINDOWS_UWP</DefineConstants>
<Optimize>true</Optimize>
<NoWarn>;2008</NoWarn>
<DebugType>pdbonly</DebugType>
<PlatformTarget>x64</PlatformTarget>
<UseVSHostingProcess>false</UseVSHostingProcess>
<ErrorReport>prompt</ErrorReport>
<Prefer32Bit>true</Prefer32Bit>
<UseDotNetNativeToolchain>true</UseDotNetNativeToolchain>
</PropertyGroup>
<PropertyGroup>
<RestoreProjectStyle>PackageReference</RestoreProjectStyle>
</PropertyGroup>
<ItemGroup>
<Compile Include="App.xaml.cs">
<DependentUpon>App.xaml</DependentUpon>
</Compile>
<Compile Include="MainPage.xaml.cs">
<DependentUpon>MainPage.xaml</DependentUpon>
</Compile>
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<AppxManifest Include="Package.appxmanifest">
<SubType>Designer</SubType>
</AppxManifest>
</ItemGroup>
<ItemGroup>
<None Include="Package.StoreAssociation.xml" />
<Content Include="Properties\Default.rd.xml" />
<Content Include="Assets\LockScreenLogo.scale-200.png" />
<Content Include="Assets\SplashScreen.scale-200.png" />
<Content Include="Assets\Square150x150Logo.scale-200.png" />
<Content Include="Assets\Square44x44Logo.scale-200.png" />
<Content Include="Assets\Square44x44Logo.targetsize-24_altform-unplated.png" />
<Content Include="Assets\StoreLogo.png" />
<Content Include="Assets\Wide310x150Logo.scale-200.png" />
</ItemGroup>
<ItemGroup>
<ApplicationDefinition Include="App.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</ApplicationDefinition>
<Page Include="MainPage.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.NETCore.UniversalWindowsPlatform">
<Version>6.2.14</Version>
</PackageReference>
</ItemGroup>
<PropertyGroup Condition=" '$(VisualStudioVersion)' == '' or '$(VisualStudioVersion)' &lt; '14.0' ">
<VisualStudioVersion>14.0</VisualStudioVersion>
</PropertyGroup>
<Import Project="$(MSBuildExtensionsPath)\Microsoft\WindowsXaml\v$(VisualStudioVersion)\Microsoft.Windows.UI.Xaml.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.19041.0</TargetFramework>
<TargetFramework>net8.0-windows10.0.22621.0</TargetFramework>
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
<RootNamespace>Wino.Core.WinUI</RootNamespace>
<RuntimeIdentifiers Condition="$([MSBuild]::GetTargetFrameworkVersion('$(TargetFramework)')) &gt;= 8">win-x86;win-x64;win-arm64</RuntimeIdentifiers>

View File

@@ -1,234 +1,16 @@
<?xml version="1.0" encoding="utf-8" ?>
<?xml version="1.0" encoding="utf-8"?>
<Application
x:Class="Wino.App"
x:Class="Wino.Mail.WinUI.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:controls="using:Wino.Controls"
xmlns:selectors="using:Wino.Selectors"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:Wino.Mail.WinUI">
<Application.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="/Styles/Converters.xaml" />
<ResourceDictionary Source="/Styles/FontIcons.xaml" />
<ResourceDictionary Source="/Styles/Colors.xaml" />
<ResourceDictionary Source="/Styles/ContentPresenters.xaml" />
<ResourceDictionary Source="/Styles/ImagePreviewControl.xaml" />
<ResourceDictionary Source="/Styles/CommandBarItems.xaml" />
<ResourceDictionary Source="/Styles/ItemContainerStyles.xaml" />
<ResourceDictionary Source="/Styles/WinoInfoBar.xaml" />
<ResourceDictionary>
<x:Double x:Key="AppBarButtonContentHeight">19</x:Double>
<x:Double x:Key="NavigationViewItemOnLeftIconBoxHeight">19</x:Double>
<Thickness x:Key="ImapSetupDialogSubPagePadding">24,24,24,24</Thickness>
<Style x:Key="PageStyle" TargetType="Page">
<Setter Property="Margin" Value="-1,0,0,0" />
<Setter Property="Padding" Value="12" />
<Setter Property="Background" Value="{ThemeResource AppBarBackgroundColor}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate>
<Grid Padding="12">
<ContentPresenter />
</Grid>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- Border style for each page's root border for separation of zones. -->
<Style TargetType="Border" x:Key="PageRootBorderStyle">
<Setter Property="Margin" Value="7,0,7,7" />
<Setter Property="Background" Value="{ThemeResource WinoContentZoneBackgroud}" />
<Setter Property="BorderBrush" Value="{StaticResource CardStrokeColorDefaultBrush}" />
<Setter Property="CornerRadius" Value="7" />
<Setter Property="BorderThickness" Value="1" />
</Style>
<!-- Default StackPanel animation. -->
<Style TargetType="StackPanel">
<Setter Property="ChildrenTransitions">
<Setter.Value>
<TransitionCollection>
<EntranceThemeTransition IsStaggeringEnabled="True" />
</TransitionCollection>
</Setter.Value>
</Setter>
</Style>
<!-- Default Style for ContentDialog -->
<Style
x:Key="WinoDialogStyle"
BasedOn="{StaticResource DefaultContentDialogStyle}"
TargetType="ContentDialog" />
<!-- Settings Menu Item Template -->
<Style TargetType="controls:SettingsMenuItemControl">
<Setter Property="HorizontalAlignment" Value="Stretch" />
<Setter Property="VerticalAlignment" Value="Stretch" />
<Setter Property="Padding" Value="0" />
<Setter Property="IsClickable" Value="True" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="controls:SettingsMenuItemControl">
<Grid>
<Button
Padding="0"
HorizontalAlignment="Stretch"
HorizontalContentAlignment="Stretch"
Command="{TemplateBinding Command}"
CommandParameter="{TemplateBinding CommandParameter}"
IsEnabled="{TemplateBinding IsEnabled}"
IsHitTestVisible="{TemplateBinding IsClickable}">
<Grid
Height="70"
Padding="0,6,12,6"
CornerRadius="4">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="50" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<ContentControl
HorizontalAlignment="Center"
VerticalAlignment="Center"
Content="{TemplateBinding Icon}" />
<Grid
Grid.Column="1"
Margin="4,0"
VerticalAlignment="Center"
RowSpacing="3">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<TextBlock
VerticalAlignment="Center"
FontWeight="SemiBold"
Style="{StaticResource BodyTextBlockStyle}"
Text="{TemplateBinding Title}" />
<TextBlock
Grid.Row="1"
VerticalAlignment="Center"
Style="{StaticResource CaptionTextBlockStyle}"
Text="{TemplateBinding Description}" />
</Grid>
<Viewbox
Grid.Column="0"
Grid.ColumnSpan="2"
Width="16"
Height="16"
HorizontalAlignment="Right"
VerticalAlignment="Center"
Visibility="{Binding RelativeSource={RelativeSource Mode=TemplatedParent}, Path=IsNavigateIconVisible}">
<PathIcon Data="F1 M 5.029297 19.091797 L 14.111328 10 L 5.029297 0.908203 L 5.908203 0.029297 L 15.888672 10 L 5.908203 19.970703 Z " />
</Viewbox>
</Grid>
</Button>
<ContentControl
Grid.RowSpan="2"
Margin="0,0,16,0"
HorizontalAlignment="Right"
VerticalAlignment="Center"
Content="{TemplateBinding SideContent}"
IsHitTestVisible="True"
Visibility="{Binding RelativeSource={RelativeSource Mode=TemplatedParent}, Path=IsNavigateIconVisible, Converter={StaticResource ReverseBooleanToVisibilityConverter}}" />
</Grid>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- Wino Navigation View Item -->
<Style TargetType="controls:WinoNavigationViewItem">
<Setter Property="ContentTransitions">
<Setter.Value>
<TransitionCollection>
<PopupThemeTransition />
</TransitionCollection>
</Setter.Value>
</Setter>
</Style>
<DataTemplate x:Key="NoneTemplate">
<Image Source="/Assets/FileTypes/type_none.png" />
</DataTemplate>
<DataTemplate x:Key="ExecutableTemplate">
<Image Source="/Assets/FileTypes/type_executable.png" />
</DataTemplate>
<DataTemplate x:Key="ImageTemplate">
<Image Source="/Assets/FileTypes/type_image.png" />
</DataTemplate>
<DataTemplate x:Key="VideoTemplate">
<Image Source="/Assets/FileTypes/type_video.png" />
</DataTemplate>
<DataTemplate x:Key="AudioTemplate">
<Image Source="/Assets/FileTypes/type_audio.png" />
</DataTemplate>
<DataTemplate x:Key="PDFTemplate">
<Image Source="/Assets/FileTypes/type_pdf.png" />
</DataTemplate>
<DataTemplate x:Key="HTMLTemplate">
<Image Source="/Assets/FileTypes/type_html.png" />
</DataTemplate>
<DataTemplate x:Key="RarTemplate">
<Image Source="/Assets/FileTypes/type_rar.png" />
</DataTemplate>
<DataTemplate x:Key="ArchiveTemplate">
<Image Source="/Assets/FileTypes/type_archive.png" />
</DataTemplate>
<DataTemplate x:Key="OtherTemplate">
<Image Source="/Assets/FileTypes/type_other.png" />
</DataTemplate>
<selectors:FileAttachmentTypeSelector
x:Key="FileTypeIconSelector"
Archive="{StaticResource ArchiveTemplate}"
Executable="{StaticResource ExecutableTemplate}"
HTML="{StaticResource HTMLTemplate}"
Image="{StaticResource ImageTemplate}"
None="{StaticResource NoneTemplate}"
Other="{StaticResource OtherTemplate}"
PDF="{StaticResource PDFTemplate}"
RarArchive="{StaticResource RarTemplate}"
Video="{StaticResource VideoTemplate}" />
</ResourceDictionary>
<XamlControlsResources xmlns="using:Microsoft.UI.Xaml.Controls" />
<!-- Define Global Styles here -->
<ResourceDictionary>
<Style TargetType="ScrollViewer">
<Setter Property="VerticalScrollBarVisibility" Value="Auto" />
</Style>
<!-- Remove border/backgroud of command bar -->
<SolidColorBrush x:Key="CommandBarBackground" Color="Transparent" />
<SolidColorBrush x:Key="CommandBarBackgroundOpen" Color="Transparent" />
<SolidColorBrush x:Key="CommandBarBorderBrushOpen" Color="Transparent" />
<Thickness x:Key="CommandBarBorderThicknessOpen">0</Thickness>
</ResourceDictionary>
<!-- Last item must always be the default theme. -->
<ResourceDictionary Source="/AppThemes/Mica.xaml" />
<!-- Other merged dictionaries here -->
</ResourceDictionary.MergedDictionaries>
<!-- Other app resources here -->
</ResourceDictionary>
</Application.Resources>
</Application>

View File

@@ -1,78 +1,50 @@
using System.Text;
using Microsoft.Extensions.DependencyInjection;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Runtime.InteropServices.WindowsRuntime;
using Microsoft.UI.Xaml;
using Microsoft.UI.Xaml.Controls;
using Microsoft.UI.Xaml.Controls.Primitives;
using Microsoft.UI.Xaml.Data;
using Microsoft.UI.Xaml.Input;
using Microsoft.UI.Xaml.Media;
using Windows.Storage;
using Wino.Core.Domain.Interfaces;
using Wino.Core.Services;
using Wino.Core.WinUI.Services;
using Wino.Views;
using WinUIEx;
namespace Wino
using Microsoft.UI.Xaml.Navigation;
using Microsoft.UI.Xaml.Shapes;
using Windows.ApplicationModel;
using Windows.ApplicationModel.Activation;
using Windows.Foundation;
using Windows.Foundation.Collections;
// To learn more about WinUI, the WinUI project structure,
// and more about our project templates, see: http://aka.ms/winui-project-info.
namespace Wino.Mail.WinUI
{
/// <summary>
/// Provides application-specific behavior to supplement the default Application class.
/// </summary>
public partial class App : Application
{
private WindowEx m_Window;
private Frame m_ShellFrame;
private readonly IApplicationConfiguration _applicationFolderConfiguration;
/// <summary>
/// Initializes the singleton application object. This is the first line of authored code
/// executed, and as such is the logical equivalent of main() or WinMain().
/// </summary>
public App()
{
if (WebAuthenticator.CheckOAuthRedirectionActivation()) return;
InitializeComponent();
Services = ConfigureServices();
_applicationFolderConfiguration = Services.GetService<IApplicationConfiguration>();
_logInitializer = Services.GetService<ILogInitializer>();
ConfigureLogger();
ConfigureAppCenter();
ConfigurePrelaunch();
ConfigureXbox();
// Make sure the paths are setup on app start.
_applicationFolderConfiguration.ApplicationDataFolderPath = ApplicationData.Current.LocalFolder.Path;
_applicationFolderConfiguration.PublisherSharedFolderPath = ApplicationData.Current.GetPublisherCacheFolder(ApplicationConfiguration.SharedFolderName).Path;
_themeService = Services.GetService<IThemeService>();
_databaseService = Services.GetService<IDatabaseService>();
_translationService = Services.GetService<ITranslationService>();
_appShellService = Services.GetService<IAppShellService>();
Encoding.RegisterProvider(CodePagesEncodingProvider.Instance);
this.InitializeComponent();
}
protected override async void OnLaunched(LaunchActivatedEventArgs args)
/// <summary>
/// Invoked when the application is launched.
/// </summary>
/// <param name="args">Details about the launch request and process.</param>
protected override void OnLaunched(Microsoft.UI.Xaml.LaunchActivatedEventArgs args)
{
ConfigureWindow();
_appShellService.AppWindow = m_Window;
foreach (var service in initializeServices)
{
await service.InitializeAsync();
}
m_ShellFrame.Navigate(typeof(AppShell));
m_Window.Activate();
m_window = new MainWindow();
m_window.Activate();
}
private void ConfigureWindow()
{
m_Window = new WindowEx
{
SystemBackdrop = new MicaBackdrop(),
ExtendsContentIntoTitleBar = true,
MinWidth = 420
};
m_ShellFrame = new Frame();
m_Window.Content = m_ShellFrame;
}
private Window m_window;
}
}

View File

@@ -1,47 +0,0 @@
<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:xaml="using:Microsoft.UI.Xaml">
<x:String x:Key="ThemeName">Custom</x:String>
<x:String x:Key="ThemeBackgroundImage">ms-appdata:///local/CustomWallpaper.jpg</x:String>
<x:Boolean x:Key="UseMica">False</x:Boolean>
<ImageBrush
x:Key="WinoApplicationBackgroundColor"
ImageSource="{StaticResource ThemeBackgroundImage}"
Stretch="UniformToFill" />
<!-- Navigation View Settings -->
<xaml:CornerRadius x:Key="NavigationViewContentGridCornerRadius">0,0,0,0</xaml:CornerRadius>
<xaml:CornerRadius x:Key="OverlayCornerRadius">0,1,0,0</xaml:CornerRadius>
<Thickness x:Key="NavigationViewContentMargin">0,0,0,0</Thickness>
<ResourceDictionary.ThemeDictionaries>
<ResourceDictionary x:Name="Light">
<!-- Reading Page Date/Name Group Header Background -->
<SolidColorBrush x:Key="MailListHeaderBackgroundColor">#ecf0f1</SolidColorBrush>
<Color x:Key="MainCustomThemeColor">#D9FFFFFF</Color>
<SolidColorBrush x:Key="AppBarBackgroundColor" Color="{StaticResource MainCustomThemeColor}" />
<SolidColorBrush x:Key="NavigationViewContentBackground" Color="Transparent" />
<SolidColorBrush x:Key="NavigationViewExpandedPaneBackground" Color="{StaticResource MainCustomThemeColor}" />
<SolidColorBrush x:Key="NavigationViewDefaultPaneBackground" Color="{StaticResource MainCustomThemeColor}" />
</ResourceDictionary>
<ResourceDictionary x:Name="Dark">
<!-- Reading Page Date/Name Group Header Background -->
<SolidColorBrush x:Key="MailListHeaderBackgroundColor">#1f1f1f</SolidColorBrush>
<Color x:Key="MainCustomThemeColor">#E61F1F1F</Color>
<!-- Reading Pane Background -->
<SolidColorBrush x:Key="ReadingPaneBackgroundColorBrush" Color="{StaticResource MainCustomThemeColor}" />
<SolidColorBrush x:Key="AppBarBackgroundColor" Color="{StaticResource MainCustomThemeColor}" />
<SolidColorBrush x:Key="NavigationViewContentBackground" Color="Transparent" />
<SolidColorBrush x:Key="NavigationViewExpandedPaneBackground" Color="{StaticResource MainCustomThemeColor}" />
<SolidColorBrush x:Key="NavigationViewDefaultPaneBackground" Color="{StaticResource MainCustomThemeColor}" />
</ResourceDictionary>
</ResourceDictionary.ThemeDictionaries>
</ResourceDictionary>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.4 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 732 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 732 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

After

Width:  |  Height:  |  Size: 637 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 583 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 916 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 283 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

View File

Before

Width:  |  Height:  |  Size: 456 B

After

Width:  |  Height:  |  Size: 456 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.0 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

View File

@@ -1,82 +0,0 @@
using System;
using System.Diagnostics;
using CommunityToolkit.Mvvm.Messaging;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.UI.Xaml;
using Microsoft.UI.Xaml.Controls;
using Microsoft.UI.Xaml.Navigation;
using Wino.Core.Messages.Shell;
using Wino.Mail.ViewModels;
namespace Wino
{
public class BasePage : Page, IRecipient<LanguageChanged>
{
public UIElement ShellContent
{
get { return (UIElement)GetValue(ShellContentProperty); }
set { SetValue(ShellContentProperty, value); }
}
public static readonly DependencyProperty ShellContentProperty = DependencyProperty.Register(nameof(ShellContent), typeof(UIElement), typeof(BasePage), new PropertyMetadata(null));
public void Receive(LanguageChanged message)
{
OnLanguageChanged();
}
public virtual void OnLanguageChanged() { }
}
public abstract class BasePage<T> : BasePage where T : BaseViewModel
{
public T ViewModel { get; } = App.Current.Services.GetService<T>();
protected BasePage()
{
// UWP and WinUI Dispatchers are different.
#if NET8_0
ViewModel.Dispatcher = new WinAppDispatcher(DispatcherQueue);
#else
ViewModel.Dispatcher = new UWPDispatcher(Dispatcher);
#endif
}
~BasePage()
{
Debug.WriteLine($"Disposed {this.GetType().Name}");
}
protected override void OnNavigatedTo(NavigationEventArgs e)
{
base.OnNavigatedTo(e);
var mode = GetNavigationMode(e.NavigationMode);
var parameter = e.Parameter;
WeakReferenceMessenger.Default.UnregisterAll(this);
WeakReferenceMessenger.Default.RegisterAll(this);
ViewModel.OnNavigatedTo(mode, parameter);
}
protected override void OnNavigatingFrom(NavigatingCancelEventArgs e)
{
base.OnNavigatingFrom(e);
var mode = GetNavigationMode(e.NavigationMode);
var parameter = e.Parameter;
WeakReferenceMessenger.Default.UnregisterAll(this);
ViewModel.OnNavigatedFrom(mode, parameter);
GC.Collect();
}
private Core.Domain.Models.Navigation.NavigationMode GetNavigationMode(NavigationMode mode)
{
return (Core.Domain.Models.Navigation.NavigationMode)mode;
}
}
}

View File

@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<Window
x:Class="Wino.Mail.WinUI.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:Wino.Mail.WinUI"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d">
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
<Button x:Name="myButton" Click="myButton_Click">Click Me</Button>
</StackPanel>
</Window>

View File

@@ -16,16 +16,21 @@ using Windows.Foundation.Collections;
// To learn more about WinUI, the WinUI project structure,
// and more about our project templates, see: http://aka.ms/winui-project-info.
namespace Wino.Views
namespace Wino.Mail.WinUI
{
/// <summary>
/// An empty page that can be used on its own or navigated to within a Frame.
/// An empty window that can be used on its own or navigated to within a Frame.
/// </summary>
public sealed partial class WelcomePage : Page
public sealed partial class MainWindow : Window
{
public WelcomePage()
public MainWindow()
{
this.InitializeComponent();
}
private void myButton_Click(object sender, RoutedEventArgs e)
{
myButton.Content = "Clicked";
}
}
}

View File

@@ -7,25 +7,16 @@
xmlns:rescap="http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities"
IgnorableNamespaces="uap rescap">
<!-- Publisher Cache Folders -->
<Extensions>
<Extension Category="windows.publisherCacheFolders">
<PublisherCacheFolders>
<Folder Name="WinoShared" />
</PublisherCacheFolders>
</Extension>
</Extensions>
<Identity
Name="8c9e5a8b-1203-4229-a3d1-18bca87c08a6"
Publisher="CN=bkaan"
Version="1.0.0.0" />
<Identity
Name="58272BurakKSE.WinoMailPreview"
Publisher="CN=51FBDAF3-E212-4149-89A2-A2636B3BC911"
Version="0.0.1.0" />
<mp:PhoneIdentity PhoneProductId="efeba1ea-0f3a-484d-8ac6-5f03a08ba6a9" PhonePublisherId="00000000-0000-0000-0000-000000000000"/>
<mp:PhoneIdentity PhoneProductId="8c9e5a8b-1203-4229-a3d1-18bca87c08a6" PhonePublisherId="00000000-0000-0000-0000-000000000000"/>
<Properties>
<DisplayName>Wino Mail (Preview)</DisplayName>
<PublisherDisplayName>Burak KÖSE</PublisherDisplayName>
<DisplayName>Wino.Mail.WinUI</DisplayName>
<PublisherDisplayName>bkaan</PublisherDisplayName>
<Logo>Assets\StoreLogo.png</Logo>
</Properties>
@@ -43,53 +34,14 @@
Executable="$targetnametoken$.exe"
EntryPoint="$targetentrypoint$">
<uap:VisualElements
DisplayName="Wino Mail WinUI"
Description="WinUI 3 for Wino Mail"
DisplayName="Wino.Mail.WinUI"
Description="Wino.Mail.WinUI"
BackgroundColor="transparent"
Square150x150Logo="Assets\Square150x150Logo.png"
Square44x44Logo="Assets\Square44x44Logo.png">
<uap:DefaultTile Wide310x150Logo="Assets\Wide310x150Logo.png" Square71x71Logo="Assets\SmallTile.png" Square310x310Logo="Assets\LargeTile.png"/>
<uap:DefaultTile Wide310x150Logo="Assets\Wide310x150Logo.png" />
<uap:SplashScreen Image="Assets\SplashScreen.png" />
</uap:VisualElements>
<Extensions>
<!-- Web Auth Broker -->
<uap:Extension Category="windows.protocol">
<uap:Protocol Name="winomail.app"/>
</uap:Extension>
<!-- App updated task. Notifies about new version after each Store update. -->
<Extension Category="windows.updateTask" EntryPoint="Wino.BackgroundTasks.AppUpdatedTask" />
<!-- Protocol activation: mailto -->
<uap:Extension Category="windows.protocol">
<uap:Protocol Name="mailto" />
</uap:Extension>
<!-- Protocol activation: Google oAuth -->
<uap:Extension Category="windows.protocol">
<uap:Protocol Name="google.pw.oauth2">
<uap:DisplayName>Google Auth Protocol</uap:DisplayName>
</uap:Protocol>
</uap:Extension>
<!-- SessionConnected task for background synchronization on startup. -->
<!--<Extension Category="windows.backgroundTasks" EntryPoint="Wino.BackgroundTasks.SessionConnectedTask">
<BackgroundTasks>
<Task Type="systemEvent" />
</BackgroundTasks>
</Extension>-->
<!-- File Assosication: EML -->
<uap:Extension Category="windows.fileTypeAssociation">
<uap:FileTypeAssociation Name="eml">
<uap:Logo>EML\eml.png</uap:Logo>
<uap:SupportedFileTypes>
<uap:FileType>.eml</uap:FileType>
</uap:SupportedFileTypes>
</uap:FileTypeAssociation>
</uap:Extension>
</Extensions>
</Application>
</Applications>

View File

@@ -1,8 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class AboutPageAbstract : BasePage<AboutPageViewModel>
{
}
}

View File

@@ -1,8 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class AccountDetailsPageAbstract : BasePage<AccountDetailsPageViewModel>
{
}
}

View File

@@ -1,9 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class AccountManagementPageAbstract : BasePage<AccountManagementViewModel>
{
}
}

View File

@@ -1,8 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class AppShellAbstract : BasePage<AppShellViewModel>
{
}
}

View File

@@ -1,8 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class ComposePageAbstract : BasePage<ComposePageViewModel>
{
}
}

View File

@@ -1,8 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class IdlePageAbstract : BasePage<IdlePageViewModel>
{
}
}

View File

@@ -1,6 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class LanguageTimePageAbstract : BasePage<LanguageTimePageViewModel> { }
}

View File

@@ -1,9 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public class MailListPageAbstract : BasePage<MailListPageViewModel>
{
}
}

View File

@@ -1,26 +0,0 @@
using Microsoft.UI.Xaml;
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class MailRenderingPageAbstract : BasePage<MailRenderingPageViewModel>
{
public bool IsDarkEditor
{
get { return (bool)GetValue(IsDarkEditorProperty); }
set { SetValue(IsDarkEditorProperty, value); }
}
public static readonly DependencyProperty IsDarkEditorProperty = DependencyProperty.Register(nameof(IsDarkEditor), typeof(bool), typeof(MailRenderingPageAbstract), new PropertyMetadata(false, OnIsComposerDarkModeChanged));
private static void OnIsComposerDarkModeChanged(DependencyObject obj, DependencyPropertyChangedEventArgs args)
{
if (obj is MailRenderingPageAbstract page)
{
page.OnEditorThemeChanged();
}
}
public virtual void OnEditorThemeChanged() { }
}
}

View File

@@ -1,8 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class MergedAccountDetailsPageAbstract : BasePage<MergedAccountDetailsPageViewModel>
{
}
}

View File

@@ -1,6 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class MessageListPageAbstract : BasePage<MessageListPageViewModel> { }
}

View File

@@ -1,8 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class NewAccountManagementPageAbstract : BasePage<NewAccountManagementPageViewModel>
{
}
}

View File

@@ -1,10 +0,0 @@
using Windows.UI.Xaml;
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class PersonalizationPageAbstract : SettingsPageBase<PersonalizationPageViewModel>
{
}
}

View File

@@ -1,6 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class ReadingPanePageAbstract : BasePage<ReadingPanePageViewModel> { }
}

View File

@@ -1,8 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class SettingOptionsPageAbstract : SettingsPageBase<SettingOptionsPageViewModel>
{
}
}

View File

@@ -1,6 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class SettingsPageAbstract : BasePage<SettingsPageViewModel> { }
}

View File

@@ -1,16 +0,0 @@
using Microsoft.UI.Xaml;
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public class SettingsPageBase<T> : BasePage<T> where T : BaseViewModel
{
public string Title
{
get { return (string)GetValue(TitleProperty); }
set { SetValue(TitleProperty, value); }
}
public static readonly DependencyProperty TitleProperty = DependencyProperty.Register(nameof(Title), typeof(string), typeof(SettingsPageBase<T>), new PropertyMetadata(string.Empty));
}
}

View File

@@ -1,6 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class SignatureManagementPageAbstract : BasePage<SignatureManagementPageViewModel> { }
}

View File

@@ -1,9 +0,0 @@
using Wino.Mail.ViewModels;
namespace Wino.Views.Abstract
{
public abstract class WelcomePageAbstract : BasePage<WelcomePageViewModel>
{
}
}

View File

@@ -1,15 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Page
x:Class="Wino.Views.WelcomePage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:Wino.Views"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
<Grid>
</Grid>
</Page>

View File

@@ -1,20 +0,0 @@
using System;
using System.Threading.Tasks;
using CommunityToolkit.WinUI;
using Microsoft.UI.Dispatching;
using Wino.Core.Domain.Interfaces;
namespace Wino
{
public class WinAppDispatcher : IDispatcher
{
private readonly DispatcherQueue _dispatcherQueue;
public WinAppDispatcher(DispatcherQueue dispatcherQueue)
{
_dispatcherQueue = dispatcherQueue;
}
public Task ExecuteOnUIThread(Action action) => _dispatcherQueue.EnqueueAsync(() => { action(); });
}
}

View File

@@ -1,9 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net8.0-windows10.0.19041.0</TargetFramework>
<TargetFramework>net8.0-windows10.0.22621.0</TargetFramework>
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
<RootNamespace>Wino</RootNamespace>
<RootNamespace>Wino.Mail.WinUI</RootNamespace>
<ApplicationManifest>app.manifest</ApplicationManifest>
<Platforms>x86;x64;ARM64</Platforms>
<RuntimeIdentifiers Condition="$([MSBuild]::GetTargetFrameworkVersion('$(TargetFramework)')) &gt;= 8">win-x86;win-x64;win-arm64</RuntimeIdentifiers>
@@ -11,197 +11,21 @@
<PublishProfile>win-$(Platform).pubxml</PublishProfile>
<UseWinUI>true</UseWinUI>
<EnableMsixTooling>true</EnableMsixTooling>
<WindowsSdkPackageVersion>10.0.19041.35-preview</WindowsSdkPackageVersion>
<GenerateTemporaryStoreCertificate>True</GenerateTemporaryStoreCertificate>
<GenerateAppInstallerFile>False</GenerateAppInstallerFile>
<GenerateAssemblyInfo>True</GenerateAssemblyInfo>
<AppxPackageSigningEnabled>False</AppxPackageSigningEnabled>
<AppxPackageSigningTimestampDigestAlgorithm>SHA256</AppxPackageSigningTimestampDigestAlgorithm>
<AppxAutoIncrementPackageRevision>False</AppxAutoIncrementPackageRevision>
<AppxPackageDir>C:\Users\bkaan\Desktop\Packages\WinUI\</AppxPackageDir>
<AppxSymbolPackageEnabled>True</AppxSymbolPackageEnabled>
<GenerateTestArtifacts>True</GenerateTestArtifacts>
<AppxBundle>Always</AppxBundle>
<AppxBundlePlatforms>x86|x64|arm64</AppxBundlePlatforms>
<HoursBetweenUpdateChecks>0</HoursBetweenUpdateChecks>
</PropertyGroup>
<ItemGroup>
<None Remove="AppThemes\Custom.xaml" />
<None Remove="Views\WelcomePage.xaml" />
</ItemGroup>
<ItemGroup>
<Page Remove="App.xaml" />
<Page Remove="AppThemes\Custom.xaml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\Wino.Mail\Activation\ActivationHandler.cs" Link="Activation\ActivationHandler.cs" />
<Compile Include="..\Wino.Mail\Activation\BackgroundActivationHandler.cs" Link="Activation\BackgroundActivationHandler.cs" />
<Compile Include="..\Wino.Mail\Activation\DefaultActivationHandler.cs" Link="Activation\DefaultActivationHandler.cs" />
<Compile Include="..\Wino.Mail\Activation\FileActivationHandler.cs" Link="Activation\FileActivationHandler.cs" />
<Compile Include="..\Wino.Mail\Activation\ProtocolActivationHandler.cs" Link="Activation\ProtocolActivationHandler.cs" />
<Compile Include="..\Wino.Mail\Activation\ToastNotificationActivationHandler.cs" Link="Activation\ToastNotificationActivationHandler.cs" />
<Compile Include="..\Wino.Mail\AppShell.xaml.cs" Link="AppShell.xaml.cs" />
<Compile Include="..\Wino.Mail\Behaviors\BindableCommandBarBehavior.cs" Link="Behaviors\BindableCommandBarBehavior.cs" />
<Compile Include="..\Wino.Mail\Behaviors\CreateMailNavigationItemBehavior.cs" Link="Behaviors\CreateMailNavigationItemBehavior.cs" />
<Compile Include="..\Wino.Mail\Controls\AccountNavigationItem.cs" Link="Controls\AccountNavigationItem.cs" />
<Compile Include="..\Wino.Mail\Controls\Advanced\WinoAppTitleBar.xaml.cs" Link="Controls\Advanced\WinoAppTitleBar.xaml.cs" />
<Compile Include="..\Wino.Mail\Controls\Advanced\WinoListView.cs" Link="Controls\Advanced\WinoListView.cs" />
<Compile Include="..\Wino.Mail\Controls\ControlConstants.cs" Link="Controls\ControlConstants.cs" />
<Compile Include="..\Wino.Mail\Controls\ImagePreviewControl.cs" Link="Controls\ImagePreviewControl.cs" />
<Compile Include="..\Wino.Mail\Controls\MailItemDisplayInformationControl.xaml.cs" Link="Controls\MailItemDisplayInformationControl.xaml.cs" />
<Compile Include="..\Wino.Mail\Controls\RendererCommandBar.cs" Link="Controls\RendererCommandBar.cs" />
<Compile Include="..\Wino.Mail\Controls\SettingsMenuItemControl.cs" Link="Controls\SettingsMenuItemControl.cs" />
<Compile Include="..\Wino.Mail\Controls\WinoFontIcon.cs" Link="Controls\WinoFontIcon.cs" />
<Compile Include="..\Wino.Mail\Controls\WinoFontIconSource.cs" Link="Controls\WinoFontIconSource.cs" />
<Compile Include="..\Wino.Mail\Controls\WinoInfoBar.cs" Link="Controls\WinoInfoBar.cs" />
<Compile Include="..\Wino.Mail\Controls\WinoNavigationViewItem.cs" Link="Controls\WinoNavigationViewItem.cs" />
<Compile Include="..\Wino.Mail\Controls\WinoPivotControl.xaml.cs" Link="Controls\WinoPivotControl.xaml.cs" />
<Compile Include="..\Wino.Mail\Controls\WinoSwipeControlItems.cs" Link="Controls\WinoSwipeControlItems.cs" />
<Compile Include="..\Wino.Mail\Converters\ReverseBooleanConverter.cs" Link="Converters\ReverseBooleanConverter.cs" />
<Compile Include="..\Wino.Mail\Converters\ReverseBooleanToVisibilityConverter.cs" Link="Converters\ReverseBooleanToVisibilityConverter.cs" />
<Compile Include="..\Wino.Mail\Dialogs\AccountCreationDialog.xaml.cs" Link="Dialogs\AccountCreationDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\AccountEditDialog.xaml.cs" Link="Dialogs\AccountEditDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\AccountPickerDialog.xaml.cs" Link="Dialogs\AccountPickerDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\AccountReorderDialog.xaml.cs" Link="Dialogs\AccountReorderDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\BaseAccountCreationDialog.cs" Link="Dialogs\BaseAccountCreationDialog.cs" />
<Compile Include="..\Wino.Mail\Dialogs\ConfirmationDialog.xaml.cs" Link="Dialogs\ConfirmationDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\CustomThemeBuilderDialog.xaml.cs" Link="Dialogs\CustomThemeBuilderDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\MoveMailDialog.xaml.cs" Link="Dialogs\MoveMailDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\NewAccountDialog.xaml.cs" Link="Dialogs\NewAccountDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\NewImapSetupDialog.xaml.cs" Link="Dialogs\NewImapSetupDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\SignatureEditorDialog.xaml.cs" Link="Dialogs\SignatureEditorDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\StoreRatingDialog.xaml.cs" Link="Dialogs\StoreRatingDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\SystemFolderConfigurationDialog.xaml.cs" Link="Dialogs\SystemFolderConfigurationDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\TextInputDialog.xaml.cs" Link="Dialogs\TextInputDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Dialogs\WinoMessageDialog.xaml.cs" Link="Dialogs\WinoMessageDialog.xaml.cs" />
<Compile Include="..\Wino.Mail\Extensions\AnimationExtensions.cs" Link="Extensions\AnimationExtensions.cs" />
<Compile Include="..\Wino.Mail\Extensions\CompositionEnums.cs" Link="Extensions\CompositionEnums.cs" />
<Compile Include="..\Wino.Mail\Extensions\CompositionExtensions.Implicit.cs" Link="Extensions\CompositionExtensions.Implicit.cs" />
<Compile Include="..\Wino.Mail\Extensions\CompositionExtensions.Size.cs" Link="Extensions\CompositionExtensions.Size.cs" />
<Compile Include="..\Wino.Mail\Extensions\EnumerableExtensions.cs" Link="Extensions\EnumerableExtensions.cs" />
<Compile Include="..\Wino.Mail\Extensions\MimeKitExtensions.cs" Link="Extensions\MimeKitExtensions.cs" />
<Compile Include="..\Wino.Mail\Extensions\UIExtensions.cs" Link="Extensions\UIExtensions.cs" />
<Compile Include="..\Wino.Mail\Extensions\UtilExtensions.cs" Link="Extensions\UtilExtensions.cs" />
<Compile Include="..\Wino.Mail\Helpers\SettingsStorageExtensions.cs" Link="Helpers\SettingsStorageExtensions.cs" />
<Compile Include="..\Wino.Mail\Helpers\WinoVisualTreeHelper.cs" Link="Helpers\WinoVisualTreeHelper.cs" />
<Compile Include="..\Wino.Mail\Helpers\XamlHelpers.cs" Link="Helpers\XamlHelpers.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\AccountSelectorFlyout.cs" Link="MenuFlyouts\AccountSelectorFlyout.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\FilterMenuFlyout.cs" Link="MenuFlyouts\FilterMenuFlyout.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\FolderOperationFlyout.cs" Link="MenuFlyouts\FolderOperationFlyout.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\FolderOperationMenuFlyoutItem.cs" Link="MenuFlyouts\FolderOperationMenuFlyoutItem.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\MailOperationFlyout.cs" Link="MenuFlyouts\MailOperationFlyout.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\MailOperationMenuFlyoutItem.cs" Link="MenuFlyouts\MailOperationMenuFlyoutItem.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\MoveButtonFlyout.cs" Link="MenuFlyouts\MoveButtonFlyout.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\RendererCommandBarItem.cs" Link="MenuFlyouts\RendererCommandBarItem.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\WinoOperationFlyout.cs" Link="MenuFlyouts\WinoOperationFlyout.cs" />
<Compile Include="..\Wino.Mail\MenuFlyouts\WinoOperationFlyoutItem.cs" Link="MenuFlyouts\WinoOperationFlyoutItem.cs" />
<Compile Include="..\Wino.Mail\PartialApp.cs" Link="PartialApp.cs" />
<Compile Include="..\Wino.Mail\Selectors\AccountProviderViewModelTemplateSelector.cs" Link="Selectors\AccountProviderViewModelTemplateSelector.cs" />
<Compile Include="..\Wino.Mail\Selectors\AccountReorderTemplateSelector.cs" Link="Selectors\AccountReorderTemplateSelector.cs" />
<Compile Include="..\Wino.Mail\Selectors\AppThemePreviewTemplateSelector.cs" Link="Selectors\AppThemePreviewTemplateSelector.cs" />
<Compile Include="..\Wino.Mail\Selectors\FileAttachmentTypeSelector.cs" Link="Selectors\FileAttachmentTypeSelector.cs" />
<Compile Include="..\Wino.Mail\Selectors\MailItemContainerStyleSelector.cs" Link="Selectors\MailItemContainerStyleSelector.cs" />
<Compile Include="..\Wino.Mail\Selectors\MailItemDisplayModePreviewTemplateSelector.cs" Link="Selectors\MailItemDisplayModePreviewTemplateSelector.cs" />
<Compile Include="..\Wino.Mail\Selectors\MailItemDisplaySelector.cs" Link="Selectors\MailItemDisplaySelector.cs" />
<Compile Include="..\Wino.Mail\Selectors\NavigationMenuTemplateSelector.cs" Link="Selectors\NavigationMenuTemplateSelector.cs" />
<Compile Include="..\Wino.Mail\Selectors\RendererCommandBarItemTemplateSelector.cs" Link="Selectors\RendererCommandBarItemTemplateSelector.cs" />
<Compile Include="..\Wino.Mail\Services\ApplicationResourceManager.cs" Link="Services\ApplicationResourceManager.cs" />
<Compile Include="..\Wino.Mail\Services\DialogService.cs" Link="Services\DialogService.cs" />
<Compile Include="..\Wino.Mail\Services\LaunchProtocolService.cs" Link="Services\LaunchProtocolService.cs" />
<Compile Include="..\Wino.Mail\Services\WinoNavigationService.cs" Link="Services\WinoNavigationService.cs" />
<Compile Include="..\Wino.Mail\Styles\CommandBarItems.xaml.cs" Link="Styles\CommandBarItems.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Account\AccountDetailsPage.xaml.cs" Link="Views\Account\AccountDetailsPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Account\AccountManagementPage.xaml.cs" Link="Views\Account\AccountManagementPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Account\MergedAccountDetailsPage.xaml.cs" Link="Views\Account\MergedAccountDetailsPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\ComposePage.xaml.cs" Link="Views\ComposePage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\IdlePage.xaml.cs" Link="Views\IdlePage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\ImapSetup\AdvancedImapSetupPage.xaml.cs" Link="Views\ImapSetup\AdvancedImapSetupPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\ImapSetup\ImapConnectionFailedPage.xaml.cs" Link="Views\ImapSetup\ImapConnectionFailedPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\ImapSetup\PreparingImapFoldersPage.xaml.cs" Link="Views\ImapSetup\PreparingImapFoldersPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\ImapSetup\TestingImapConnectionPage.xaml.cs" Link="Views\ImapSetup\TestingImapConnectionPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\ImapSetup\WelcomeImapSetupPage.xaml.cs" Link="Views\ImapSetup\WelcomeImapSetupPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\MailListPage.xaml.cs" Link="Views\MailListPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\MailRenderingPage.xaml.cs" Link="Views\MailRenderingPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\NewAccountManagementPage.xaml.cs" Link="Views\NewAccountManagementPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\SettingsPage.xaml.cs" Link="Views\SettingsPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Settings\AboutPage.xaml.cs" Link="Views\Settings\AboutPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Settings\LanguageTimePage.xaml.cs" Link="Views\Settings\LanguageTimePage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Settings\MessageListPage.xaml.cs" Link="Views\Settings\MessageListPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Settings\PersonalizationPage.xaml.cs" Link="Views\Settings\PersonalizationPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Settings\ReadingPanePage.xaml.cs" Link="Views\Settings\ReadingPanePage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Settings\SettingOptionsPage.xaml.cs" Link="Views\Settings\SettingOptionsPage.xaml.cs" />
<Compile Include="..\Wino.Mail\Views\Settings\SignatureManagementPage.xaml.cs" Link="Views\Settings\SignatureManagementPage.xaml.cs" />
</ItemGroup>
<ItemGroup>
<Content Include="..\Wino.Mail\Assets\EML\eml.png" Link="Assets\EML\eml.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_archive.png" Link="Assets\FileTypes\type_archive.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_audio.png" Link="Assets\FileTypes\type_audio.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_executable.png" Link="Assets\FileTypes\type_executable.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_html.png" Link="Assets\FileTypes\type_html.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_image.png" Link="Assets\FileTypes\type_image.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_none.png" Link="Assets\FileTypes\type_none.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_other.png" Link="Assets\FileTypes\type_other.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_pdf.png" Link="Assets\FileTypes\type_pdf.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_rar.png" Link="Assets\FileTypes\type_rar.png" />
<Content Include="..\Wino.Mail\Assets\FileTypes\type_video.png" Link="Assets\FileTypes\type_video.png" />
<Content Include="..\Wino.Mail\Assets\WinoIcons.ttf" Link="Assets\WinoIcons.ttf" />
<Content Include="..\Wino.Mail\Assets\NotificationIcons\delete.png" Link="Assets\NotificationIcons\delete.png" />
<Content Include="..\Wino.Mail\Assets\NotificationIcons\dismiss.png" Link="Assets\NotificationIcons\dismiss.png" />
<Content Include="..\Wino.Mail\Assets\NotificationIcons\markread.png" Link="Assets\NotificationIcons\markread.png" />
<Content Include="..\Wino.Mail\Assets\NotificationIcons\profile-dark.png" Link="Assets\NotificationIcons\profile-dark.png" />
<Content Include="..\Wino.Mail\Assets\NotificationIcons\profile-light.png" Link="Assets\NotificationIcons\profile-light.png" />
<Content Include="..\Wino.Mail\Assets\Providers\Gmail.png" Link="Assets\Providers\Gmail.png" />
<Content Include="..\Wino.Mail\Assets\Providers\IMAP4.png" Link="Assets\Providers\IMAP4.png" />
<Content Include="..\Wino.Mail\Assets\Providers\Office 365.png" Link="Assets\Providers\Office 365.png" />
<Content Include="..\Wino.Mail\Assets\Providers\Outlook.png" Link="Assets\Providers\Outlook.png" />
<Content Include="..\Wino.Mail\Assets\Providers\Yahoo.png" Link="Assets\Providers\Yahoo.png" />
<Content Include="..\Wino.Mail\Assets\Thumbnails\airbnb.com.png" Link="Assets\Thumbnails\airbnb.com.png" />
<Content Include="..\Wino.Mail\Assets\Thumbnails\apple.com.png" Link="Assets\Thumbnails\apple.com.png" />
<Content Include="..\Wino.Mail\Assets\Thumbnails\google.com.png" Link="Assets\Thumbnails\google.com.png" />
<Content Include="..\Wino.Mail\Assets\Thumbnails\microsoft.com.png" Link="Assets\Thumbnails\microsoft.com.png" />
<Content Include="..\Wino.Mail\Assets\Thumbnails\steampowered.com.png" Link="Assets\Thumbnails\steampowered.com.png" />
<Content Include="..\Wino.Mail\Assets\Thumbnails\uber.com.png" Link="Assets\Thumbnails\uber.com.png" />
<Content Include="..\Wino.Mail\Assets\Thumbnails\youtube.com.png" Link="Assets\Thumbnails\youtube.com.png" />
<Content Include="..\Wino.Mail\BackgroundImages\Acrylic.jpg" Link="BackgroundImages\Acrylic.jpg" />
<Content Include="..\Wino.Mail\BackgroundImages\Clouds.jpg" Link="BackgroundImages\Clouds.jpg" />
<Content Include="..\Wino.Mail\BackgroundImages\Forest.jpg" Link="BackgroundImages\Forest.jpg" />
<Content Include="..\Wino.Mail\BackgroundImages\Garden.jpg" Link="BackgroundImages\Garden.jpg" />
<Content Include="..\Wino.Mail\BackgroundImages\Mica.jpg" Link="BackgroundImages\Mica.jpg" />
<Content Include="..\Wino.Mail\BackgroundImages\Nighty.jpg" Link="BackgroundImages\Nighty.jpg" />
<Content Include="..\Wino.Mail\BackgroundImages\Snowflake.jpg" Link="BackgroundImages\Snowflake.jpg" />
<Content Include="..\Wino.Mail\JS\editor.html" Link="JS\editor.html" />
<Content Include="..\Wino.Mail\JS\global.css" Link="JS\global.css" />
<Content Include="..\Wino.Mail\JS\libs\jodit.min.css" Link="JS\libs\jodit.min.css" />
<Content Include="..\Wino.Mail\JS\reader.html" Link="JS\reader.html" />
<Content Include="AppThemes\Custom.xaml">
<Generator>MSBuild:Compile</Generator>
<CustomToolNamespace>XamlIntelliSenseFileGenerator</CustomToolNamespace>
</Content>
<Content Include="Assets\SplashScreen.scale-200.png" />
<Content Include="Assets\LockScreenLogo.scale-200.png" />
<Content Include="Assets\Square150x150Logo.scale-200.png" />
<Content Include="Assets\Square44x44Logo.scale-200.png" />
<Content Include="Assets\Square44x44Logo.targetsize-24_altform-unplated.png" />
<Content Include="Assets\StoreLogo.png" />
<Content Include="Assets\Wide310x150Logo.scale-200.png" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ColorHashSharp" Version="1.0.0" />
<PackageReference Include="CommunityToolkit.WinUI.Animations" Version="8.0.240109" />
<PackageReference Include="CommunityToolkit.WinUI.Controls.Primitives" Version="8.0.240109" />
<PackageReference Include="CommunityToolkit.WinUI.Controls.SettingsControls" Version="8.0.240109" />
<PackageReference Include="CommunityToolkit.WinUI.Controls.Sizers" Version="8.0.240109" />
<PackageReference Include="CommunityToolkit.WinUI.Controls.TokenizingTextBox" Version="8.0.240109" />
<PackageReference Include="CommunityToolkit.WinUI.Extensions" Version="8.0.240109" />
<PackageReference Include="EmailValidation" Version="1.2.0" />
<PackageReference Include="Microsoft.AppCenter.Analytics" Version="5.0.5" />
<PackageReference Include="Microsoft.AppCenter.Crashes" Version="5.0.5" />
<PackageReference Include="Microsoft.Windows.SDK.BuildTools" Version="10.0.26100.1" />
<PackageReference Include="Microsoft.WindowsAppSDK" Version="1.6.240701003-experimental2" />
<PackageReference Include="Microsoft.Xaml.Behaviors.WinUI.Managed" Version="2.0.9" />
<PackageReference Include="WinUIEx" Version="2.3.4" />
<PackageReference Include="Microsoft.WindowsAppSDK" Version="1.5.240627000" />
<Manifest Include="$(ApplicationManifest)" />
</ItemGroup>
@@ -213,217 +37,6 @@
<ItemGroup Condition="'$(DisableMsixProjectCapabilityAddedByProject)'!='true' and '$(EnableMsixTooling)'=='true'">
<ProjectCapability Include="Msix" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Wino.BackgroundTasks\Wino.BackgroundTasks.NET8.csproj" />
<ProjectReference Include="..\Wino.Core.Domain\Wino.Core.Domain.NET8.csproj" />
<ProjectReference Include="..\Wino.Core.UWP\Wino.Core.WinUI.csproj" />
<ProjectReference Include="..\Wino.Core\Wino.Core.NET8.csproj" />
<ProjectReference Include="..\Wino.Mail.ViewModels\Wino.Mail.ViewModels.NET8.csproj" />
</ItemGroup>
<ItemGroup>
<Folder Include="Activation\" />
<Folder Include="Assets\FileTypes\" />
<Folder Include="Assets\EML\" />
<Folder Include="Assets\Thumbnails\" />
<Folder Include="Assets\Providers\" />
<Folder Include="Assets\NotificationIcons\" />
<Folder Include="Controls\Advanced\" />
<Folder Include="Converters\" />
<Folder Include="Helpers\" />
<Folder Include="Extensions\" />
<Folder Include="BackgroundImages\" />
<Folder Include="Behaviors\" />
<Folder Include="JS\libs\" />
<Folder Include="MenuFlyouts\" />
<Folder Include="Dialogs\" />
<Folder Include="Services\" />
<Folder Include="Selectors\" />
<Folder Include="Styles\" />
<Folder Include="Views\ImapSetup\" />
<Folder Include="Views\Account\" />
<Folder Include="Views\Settings\" />
</ItemGroup>
<ItemGroup>
<Content Include="..\Wino.Mail\JS\editor.js" Link="JS\editor.js" />
<Content Include="..\Wino.Mail\JS\libs\darkreader.js" Link="JS\libs\darkreader.js" />
<Content Include="..\Wino.Mail\JS\libs\jodit.min.js" Link="JS\libs\jodit.min.js" />
</ItemGroup>
<ItemGroup>
<Page Include="..\Wino.Mail\AppShell.xaml" Link="AppShell.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Content Include="..\Wino.Mail\AppThemes\Clouds.xaml" Link="AppThemes\Clouds.xaml">
<Generator>MSBuild:Compile</Generator>
<CustomToolNamespace>XamlIntelliSenseFileGenerator</CustomToolNamespace>
</Content>
<Content Include="..\Wino.Mail\AppThemes\Forest.xaml" Link="AppThemes\Forest.xaml">
<Generator>MSBuild:Compile</Generator>
<CustomToolNamespace>XamlIntelliSenseFileGenerator</CustomToolNamespace>
</Content>
<Content Include="..\Wino.Mail\AppThemes\Garden.xaml" Link="AppThemes\Garden.xaml">
<Generator>MSBuild:Compile</Generator>
<CustomToolNamespace>XamlIntelliSenseFileGenerator</CustomToolNamespace>
</Content>
<Content Include="..\Wino.Mail\AppThemes\Mica.xaml" Link="AppThemes\Mica.xaml">
<Generator>MSBuild:Compile</Generator>
<CustomToolNamespace>XamlIntelliSenseFileGenerator</CustomToolNamespace>
</Content>
<Content Include="..\Wino.Mail\AppThemes\Nighty.xaml" Link="AppThemes\Nighty.xaml">
<Generator>MSBuild:Compile</Generator>
<CustomToolNamespace>XamlIntelliSenseFileGenerator</CustomToolNamespace>
</Content>
<Content Include="..\Wino.Mail\AppThemes\Snowflake.xaml" Link="AppThemes\Snowflake.xaml">
<Generator>MSBuild:Compile</Generator>
<CustomToolNamespace>XamlIntelliSenseFileGenerator</CustomToolNamespace>
</Content>
<Content Include="..\Wino.Mail\AppThemes\TestTheme.xaml" Link="AppThemes\TestTheme.xaml">
<Generator>MSBuild:Compile</Generator>
<CustomToolNamespace>XamlIntelliSenseFileGenerator</CustomToolNamespace>
</Content>
<Page Include="..\Wino.Mail\Controls\Advanced\WinoAppTitleBar.xaml" Link="Controls\Advanced\WinoAppTitleBar.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Controls\MailItemDisplayInformationControl.xaml" Link="Controls\MailItemDisplayInformationControl.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Controls\WinoPivotControl.xaml" Link="Controls\WinoPivotControl.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\AccountCreationDialog.xaml" Link="Dialogs\AccountCreationDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\AccountEditDialog.xaml" Link="Dialogs\AccountEditDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\AccountPickerDialog.xaml" Link="Dialogs\AccountPickerDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\AccountReorderDialog.xaml" Link="Dialogs\AccountReorderDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\ConfirmationDialog.xaml" Link="Dialogs\ConfirmationDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\CustomThemeBuilderDialog.xaml" Link="Dialogs\CustomThemeBuilderDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\MoveMailDialog.xaml" Link="Dialogs\MoveMailDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\NewAccountDialog.xaml" Link="Dialogs\NewAccountDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\NewImapSetupDialog.xaml" Link="Dialogs\NewImapSetupDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\SignatureEditorDialog.xaml" Link="Dialogs\SignatureEditorDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\StoreRatingDialog.xaml" Link="Dialogs\StoreRatingDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\SystemFolderConfigurationDialog.xaml" Link="Dialogs\SystemFolderConfigurationDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\TextInputDialog.xaml" Link="Dialogs\TextInputDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Dialogs\WinoMessageDialog.xaml" Link="Dialogs\WinoMessageDialog.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Styles\Colors.xaml" Link="Styles\Colors.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Styles\CommandBarItems.xaml" Link="Styles\CommandBarItems.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Styles\ContentPresenters.xaml" Link="Styles\ContentPresenters.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Styles\Converters.xaml" Link="Styles\Converters.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Styles\FontIcons.xaml" Link="Styles\FontIcons.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Styles\ImagePreviewControl.xaml" Link="Styles\ImagePreviewControl.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Styles\ItemContainerStyles.xaml" Link="Styles\ItemContainerStyles.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Styles\WinoInfoBar.xaml" Link="Styles\WinoInfoBar.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Account\AccountDetailsPage.xaml" Link="Views\Account\AccountDetailsPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Account\AccountManagementPage.xaml" Link="Views\Account\AccountManagementPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Account\MergedAccountDetailsPage.xaml" Link="Views\Account\MergedAccountDetailsPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\ComposePage.xaml" Link="Views\ComposePage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\IdlePage.xaml" Link="Views\IdlePage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\ImapSetup\AdvancedImapSetupPage.xaml" Link="Views\ImapSetup\AdvancedImapSetupPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\ImapSetup\ImapConnectionFailedPage.xaml" Link="Views\ImapSetup\ImapConnectionFailedPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\ImapSetup\PreparingImapFoldersPage.xaml" Link="Views\ImapSetup\PreparingImapFoldersPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\ImapSetup\TestingImapConnectionPage.xaml" Link="Views\ImapSetup\TestingImapConnectionPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\ImapSetup\WelcomeImapSetupPage.xaml" Link="Views\ImapSetup\WelcomeImapSetupPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\MailListPage.xaml" Link="Views\MailListPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\MailRenderingPage.xaml" Link="Views\MailRenderingPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\NewAccountManagementPage.xaml" Link="Views\NewAccountManagementPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\SettingsPage.xaml" Link="Views\SettingsPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Settings\AboutPage.xaml" Link="Views\Settings\AboutPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Settings\LanguageTimePage.xaml" Link="Views\Settings\LanguageTimePage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Settings\MessageListPage.xaml" Link="Views\Settings\MessageListPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Settings\PersonalizationPage.xaml" Link="Views\Settings\PersonalizationPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Settings\ReadingPanePage.xaml" Link="Views\Settings\ReadingPanePage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Settings\SettingOptionsPage.xaml" Link="Views\Settings\SettingOptionsPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="..\Wino.Mail\Views\Settings\SignatureManagementPage.xaml" Link="Views\Settings\SignatureManagementPage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
</ItemGroup>
<ItemGroup>
<Page Update="Views\WelcomePage.xaml">
<Generator>MSBuild:Compile</Generator>
</Page>
</ItemGroup>
<!--
Defining the "HasPackageAndPublishMenuAddedByProject" property here allows the Solution

View File

@@ -1,39 +0,0 @@
using System.Threading.Tasks;
namespace Wino.Activation
{
// For more information on understanding and extending activation flow see
// https://github.com/microsoft/TemplateStudio/blob/main/docs/UWP/activation.md
internal abstract class ActivationHandler
{
public abstract bool CanHandle(object args);
public abstract Task HandleAsync(object args);
}
// Extend this class to implement new ActivationHandlers
internal abstract class ActivationHandler<T> : ActivationHandler
where T : class
{
// Override this method to add the activation logic in your activation handler
protected abstract Task HandleInternalAsync(T args);
public override async Task HandleAsync(object args)
{
await HandleInternalAsync(args as T);
}
public override bool CanHandle(object args)
{
// CanHandle checks the args is of type you have configured
return args is T && CanHandleInternal(args as T);
}
// You can override this method to add extra validation on activation args
// to determine if your ActivationHandler should handle this activation args
protected virtual bool CanHandleInternal(T args)
{
return true;
}
}
}

View File

@@ -1,154 +0,0 @@
using System.Threading.Tasks;
using Serilog;
using Windows.ApplicationModel.Activation;
using Windows.ApplicationModel.Background;
using Windows.UI.Notifications;
using Wino.Core.Domain;
using Wino.Core.Domain.Enums;
using Wino.Core.Domain.Interfaces;
using Wino.Core.Domain.Models.MailItem;
using Wino.Core.UWP.Services;
#if NET8_0
using CommunityToolkit.WinUI.Notifications;
#else
using Microsoft.Toolkit.Uwp.Notifications;
#endif
namespace Wino.Activation
{
internal class BackgroundActivationHandler : ActivationHandler<BackgroundActivatedEventArgs>
{
private const string BackgroundExecutionLogTag = "[BackgroundExecution] ";
private readonly IWinoRequestDelegator _winoRequestDelegator;
private readonly INativeAppService _nativeAppService;
private readonly IWinoRequestProcessor _winoRequestProcessor;
private readonly IWinoServerConnectionManager _winoServerConnectionManager;
private readonly IMailService _mailService;
private ToastArguments _toastArguments;
BackgroundTaskDeferral _deferral;
public BackgroundActivationHandler(IWinoRequestDelegator winoRequestDelegator,
INativeAppService nativeAppService,
IWinoRequestProcessor winoRequestProcessor,
IWinoServerConnectionManager winoServerConnectionManager,
IMailService mailService)
{
_winoRequestDelegator = winoRequestDelegator;
_nativeAppService = nativeAppService;
_winoRequestProcessor = winoRequestProcessor;
_winoServerConnectionManager = winoServerConnectionManager;
_mailService = mailService;
}
protected override async Task HandleInternalAsync(BackgroundActivatedEventArgs args)
{
var instance = args.TaskInstance;
var taskName = instance.Task.Name;
instance.Canceled -= OnBackgroundExecutionCanceled;
instance.Canceled += OnBackgroundExecutionCanceled;
_deferral = instance.GetDeferral();
if (taskName == BackgroundTaskService.ToastActivationTaskEx)
{
if (instance.TriggerDetails is ToastNotificationActionTriggerDetail toastNotificationActionTriggerDetail)
_toastArguments = ToastArguments.Parse(toastNotificationActionTriggerDetail.Argument);
// All toast activation mail actions are handled here like mark as read or delete.
// This should not launch the application on the foreground.
// Get the action and mail item id.
// Prepare package and send to delegator.
if (_toastArguments.TryGetValue(Constants.ToastMailItemIdKey, out string mailItemId) &&
_toastArguments.TryGetValue(Constants.ToastActionKey, out MailOperation action) &&
_toastArguments.TryGetValue(Constants.ToastMailItemRemoteFolderIdKey, out string remoteFolderId))
{
var mailItem = await _mailService.GetSingleMailItemAsync(mailItemId, remoteFolderId);
if (mailItem == null) return;
if (_nativeAppService.IsAppRunning())
{
// Just send the package. We should reflect the UI changes as well.
var package = new MailOperationPreperationRequest(action, mailItem);
await _winoRequestDelegator.ExecuteAsync(package);
}
else
{
// We need to synchronize changes without reflection the UI changes.
// var synchronizer = _winoSynchronizerFactory.GetAccountSynchronizer(mailItem.AssignedAccount.Id);
var prepRequest = new MailOperationPreperationRequest(action, mailItem);
var requests = await _winoRequestProcessor.PrepareRequestsAsync(prepRequest);
foreach (var request in requests)
{
_winoServerConnectionManager.QueueRequest(request, mailItem.AssignedAccount.Id);
// synchronizer.QueueRequest(request);
}
//var options = new SynchronizationOptions()
//{
// Type = SynchronizationType.ExecuteRequests,
// AccountId = mailItem.AssignedAccount.Id
//};
//await synchronizer.SynchronizeAsync(options);
}
}
}
instance.Canceled -= OnBackgroundExecutionCanceled;
_deferral.Complete();
}
private void OnBackgroundExecutionCanceled(Windows.ApplicationModel.Background.IBackgroundTaskInstance sender, Windows.ApplicationModel.Background.BackgroundTaskCancellationReason reason)
{
Log.Error($"{BackgroundExecutionLogTag} ({sender.Task.Name}) Background task is canceled. Reason -> {reason}");
_deferral?.Complete();
}
protected override bool CanHandleInternal(BackgroundActivatedEventArgs args)
{
var instance = args.TaskInstance;
var taskName = instance.Task.Name;
if (taskName == BackgroundTaskService.ToastActivationTaskEx)
{
// User clicked Mark as Read or Delete in toast notification.
// MailId and Action must present in the arguments.
return true;
//if (instance.TriggerDetails is ToastNotificationActionTriggerDetail toastNotificationActionTriggerDetail)
//{
// _toastArguments = ToastArguments.Parse(toastNotificationActionTriggerDetail.Argument);
// return
// _toastArguments.Contains(Constants.ToastMailItemIdKey) &&
// _toastArguments.Contains(Constants.ToastActionKey);
//}
}
else if (taskName == BackgroundTaskService.BackgroundSynchronizationTimerTaskNameEx)
{
// This is timer based background synchronization.
return true;
}
return false;
}
}
}

View File

@@ -1,30 +0,0 @@
using System.Threading.Tasks;
using Windows.ApplicationModel.Activation;
using Wino.Views;
#if NET8_0
using Microsoft.UI.Xaml;
using Microsoft.UI.Xaml.Controls;
using Microsoft.UI.Xaml.Media.Animation;
#else
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using Windows.UI.Xaml.Media.Animation;
#endif
namespace Wino.Activation
{
internal class DefaultActivationHandler : ActivationHandler<IActivatedEventArgs>
{
protected override Task HandleInternalAsync(IActivatedEventArgs args)
{
(Window.Current.Content as Frame).Navigate(typeof(AppShell), null, new DrillInNavigationTransitionInfo());
return Task.CompletedTask;
}
// Only navigate if Frame content doesn't exist.
protected override bool CanHandleInternal(IActivatedEventArgs args)
=> (Window.Current?.Content as Frame)?.Content == null;
}
}

Some files were not shown because too many files have changed in this diff Show More