Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/veler/DevToys into main
Browse files Browse the repository at this point in the history
  • Loading branch information
veler committed Oct 10, 2021
2 parents d31e66f + 9947810 commit 937d13c
Show file tree
Hide file tree
Showing 78 changed files with 347 additions and 160 deletions.
Binary file added assets/logo/1080x1080-Prev.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/logo/300x300-Prev.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/logo/Icon-with-shade-400px-Prev.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/logo/Icon-without-shade-400px-Prev.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified assets/logo/logo-figma.fig
Binary file not shown.
24 changes: 22 additions & 2 deletions ci/azure-pipelines-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,16 @@ jobs:
$xmlDoc.Save('$(Build.SourcesDirectory)\src\dev\shared\Package.appxmanifest')
failOnStderr: true

- task: PowerShell@2
displayName: 'Use Release Logo'
inputs:
targetType: 'inline'
script: |
gci $(Build.SourcesDirectory)\src -Include *.csproj, *.appxmanifest, *.wapproj -recurse | ForEach -Process {
(Get-Content $_ -Raw | ForEach -Process {$_ -replace "Assets\\Logo-Prev", "Assets\Logo"}) | Set-Content $_ -NoNewline
}
failOnStderr: true

- task: DownloadSecureFile@1
displayName: 'Download certificate'
name: signingCert
Expand All @@ -45,7 +55,7 @@ jobs:

# Run the init.ps1, which mostly restores dependencies
- task: PowerShell@2
displayName: 'Restore nuget packages'
displayName: 'Restore nuget packages & Monaco editor'
inputs:
filePath: 'init.ps1'
failOnStderr: true
Expand Down Expand Up @@ -92,9 +102,19 @@ jobs:
$xmlDoc.Save('$(Build.SourcesDirectory)\src\dev\shared\Package.appxmanifest')
failOnStderr: true

- task: PowerShell@2
displayName: 'Use Release Logo'
inputs:
targetType: 'inline'
script: |
gci $(Build.SourcesDirectory)\src -Include *.csproj, *.appxmanifest, *.wapproj -recurse | ForEach -Process {
(Get-Content $_ -Raw | ForEach -Process {$_ -replace "Assets\\Logo-Prev", "Assets\Logo"}) | Set-Content $_ -NoNewline
}
failOnStderr: true

# Run the init.ps1, which mostly restores dependencies
- task: PowerShell@2
displayName: 'Restore nuget packages'
displayName: 'Restore nuget packages & Monaco editor'
inputs:
filePath: 'init.ps1'
failOnStderr: true
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/dev/DevToys.Startup/Assets/Logo/StoreLogo.scale-100.png
Binary file modified src/dev/DevToys.Startup/Assets/Logo/StoreLogo.scale-125.png
Binary file modified src/dev/DevToys.Startup/Assets/Logo/StoreLogo.scale-150.png
Binary file modified src/dev/DevToys.Startup/Assets/Logo/StoreLogo.scale-200.png
Binary file modified src/dev/DevToys.Startup/Assets/Logo/StoreLogo.scale-400.png
100 changes: 50 additions & 50 deletions src/dev/DevToys.Startup/DevToys.Startup.wapproj
Original file line number Diff line number Diff line change
Expand Up @@ -53,56 +53,56 @@
<ProjectReference Include="..\impl\DevToys\DevToys.csproj" />
</ItemGroup>
<ItemGroup>
<Content Include="Assets\Logo\LargeTile.scale-100.png" />
<Content Include="Assets\Logo\LargeTile.scale-125.png" />
<Content Include="Assets\Logo\LargeTile.scale-150.png" />
<Content Include="Assets\Logo\LargeTile.scale-200.png" />
<Content Include="Assets\Logo\LargeTile.scale-400.png" />
<Content Include="Assets\Logo\SmallTile.scale-100.png" />
<Content Include="Assets\Logo\SmallTile.scale-125.png" />
<Content Include="Assets\Logo\SmallTile.scale-150.png" />
<Content Include="Assets\Logo\SmallTile.scale-200.png" />
<Content Include="Assets\Logo\SmallTile.scale-400.png" />
<Content Include="Assets\Logo\SplashScreen.scale-100.png" />
<Content Include="Assets\Logo\SplashScreen.scale-125.png" />
<Content Include="Assets\Logo\SplashScreen.scale-150.png" />
<Content Include="Assets\Logo\SplashScreen.scale-200.png" />
<Content Include="Assets\Logo\SplashScreen.scale-400.png" />
<Content Include="Assets\Logo\Square150x150Logo.scale-100.png" />
<Content Include="Assets\Logo\Square150x150Logo.scale-125.png" />
<Content Include="Assets\Logo\Square150x150Logo.scale-150.png" />
<Content Include="Assets\Logo\Square150x150Logo.scale-200.png" />
<Content Include="Assets\Logo\Square150x150Logo.scale-400.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-lightunplated_targetsize-16.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-lightunplated_targetsize-24.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-lightunplated_targetsize-256.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-lightunplated_targetsize-32.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-lightunplated_targetsize-48.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-unplated_targetsize-16.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-unplated_targetsize-24.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-unplated_targetsize-256.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-unplated_targetsize-32.png" />
<Content Include="Assets\Logo\Square44x44Logo.altform-unplated_targetsize-48.png" />
<Content Include="Assets\Logo\Square44x44Logo.scale-100.png" />
<Content Include="Assets\Logo\Square44x44Logo.scale-125.png" />
<Content Include="Assets\Logo\Square44x44Logo.scale-150.png" />
<Content Include="Assets\Logo\Square44x44Logo.scale-200.png" />
<Content Include="Assets\Logo\Square44x44Logo.scale-400.png" />
<Content Include="Assets\Logo\Square44x44Logo.targetsize-16.png" />
<Content Include="Assets\Logo\Square44x44Logo.targetsize-24.png" />
<Content Include="Assets\Logo\Square44x44Logo.targetsize-256.png" />
<Content Include="Assets\Logo\Square44x44Logo.targetsize-32.png" />
<Content Include="Assets\Logo\Square44x44Logo.targetsize-48.png" />
<Content Include="Assets\Logo\StoreLogo.scale-100.png" />
<Content Include="Assets\Logo\StoreLogo.scale-125.png" />
<Content Include="Assets\Logo\StoreLogo.scale-150.png" />
<Content Include="Assets\Logo\StoreLogo.scale-200.png" />
<Content Include="Assets\Logo\StoreLogo.scale-400.png" />
<Content Include="Assets\Logo\Wide310x150Logo.scale-100.png" />
<Content Include="Assets\Logo\Wide310x150Logo.scale-125.png" />
<Content Include="Assets\Logo\Wide310x150Logo.scale-150.png" />
<Content Include="Assets\Logo\Wide310x150Logo.scale-200.png" />
<Content Include="Assets\Logo\Wide310x150Logo.scale-400.png" />
<Content Include="Assets\Logo-Prev\LargeTile.scale-100.png" />
<Content Include="Assets\Logo-Prev\LargeTile.scale-125.png" />
<Content Include="Assets\Logo-Prev\LargeTile.scale-150.png" />
<Content Include="Assets\Logo-Prev\LargeTile.scale-200.png" />
<Content Include="Assets\Logo-Prev\LargeTile.scale-400.png" />
<Content Include="Assets\Logo-Prev\SmallTile.scale-100.png" />
<Content Include="Assets\Logo-Prev\SmallTile.scale-125.png" />
<Content Include="Assets\Logo-Prev\SmallTile.scale-150.png" />
<Content Include="Assets\Logo-Prev\SmallTile.scale-200.png" />
<Content Include="Assets\Logo-Prev\SmallTile.scale-400.png" />
<Content Include="Assets\Logo-Prev\SplashScreen.scale-100.png" />
<Content Include="Assets\Logo-Prev\SplashScreen.scale-125.png" />
<Content Include="Assets\Logo-Prev\SplashScreen.scale-150.png" />
<Content Include="Assets\Logo-Prev\SplashScreen.scale-200.png" />
<Content Include="Assets\Logo-Prev\SplashScreen.scale-400.png" />
<Content Include="Assets\Logo-Prev\Square150x150Logo.scale-100.png" />
<Content Include="Assets\Logo-Prev\Square150x150Logo.scale-125.png" />
<Content Include="Assets\Logo-Prev\Square150x150Logo.scale-150.png" />
<Content Include="Assets\Logo-Prev\Square150x150Logo.scale-200.png" />
<Content Include="Assets\Logo-Prev\Square150x150Logo.scale-400.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-lightunplated_targetsize-16.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-lightunplated_targetsize-24.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-lightunplated_targetsize-256.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-lightunplated_targetsize-32.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-lightunplated_targetsize-48.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-unplated_targetsize-16.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-unplated_targetsize-24.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-unplated_targetsize-256.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-unplated_targetsize-32.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.altform-unplated_targetsize-48.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.scale-100.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.scale-125.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.scale-150.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.scale-200.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.scale-400.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.targetsize-16.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.targetsize-24.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.targetsize-256.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.targetsize-32.png" />
<Content Include="Assets\Logo-Prev\Square44x44Logo.targetsize-48.png" />
<Content Include="Assets\Logo-Prev\StoreLogo.scale-100.png" />
<Content Include="Assets\Logo-Prev\StoreLogo.scale-125.png" />
<Content Include="Assets\Logo-Prev\StoreLogo.scale-150.png" />
<Content Include="Assets\Logo-Prev\StoreLogo.scale-200.png" />
<Content Include="Assets\Logo-Prev\StoreLogo.scale-400.png" />
<Content Include="Assets\Logo-Prev\Wide310x150Logo.scale-100.png" />
<Content Include="Assets\Logo-Prev\Wide310x150Logo.scale-125.png" />
<Content Include="Assets\Logo-Prev\Wide310x150Logo.scale-150.png" />
<Content Include="Assets\Logo-Prev\Wide310x150Logo.scale-200.png" />
<Content Include="Assets\Logo-Prev\Wide310x150Logo.scale-400.png" />
</ItemGroup>
<ItemGroup>
<AppxManifest Include="..\shared\Package.appxmanifest">
Expand Down
7 changes: 7 additions & 0 deletions src/dev/impl/DevToys/Api/Core/Settings/SettingDefinition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,13 @@ namespace DevToys.Api.Core.Settings
/// <param name="defaultValue">The default value of the setting.</param>
public SettingDefinition(string name, bool isRoaming, T defaultValue)
{
if (string.IsNullOrEmpty(name) || name.Length > 255)
{
// For both LocalSettings and RoamingSettings, the name of each setting can be 255 characters in length at most.
// see https://docs.microsoft.com/en-us/uwp/api/windows.storage.applicationdata.localsettings?view=winrt-22000#remarks
throw new ArgumentOutOfRangeException(nameof(name));
}

IsRoaming = isRoaming;
Name = name;
DefaultValue = defaultValue;
Expand Down
12 changes: 12 additions & 0 deletions src/dev/impl/DevToys/App.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,18 @@ private void OnSuspending(object sender, SuspendingEventArgs e)
{
var deferral = e.SuspendingOperation.GetDeferral();
//TODO: Save application state and stop any background activity

try
{
// Bug #22: Here we flush the Clipboard to make sure content in clipboard to remain available
// after the application shuts down.
Windows.ApplicationModel.DataTransfer.Clipboard.Flush();
}
catch (Exception)
{
// ignore
}

deferral.Complete();
}

Expand Down
Loading

0 comments on commit 937d13c

Please sign in to comment.