-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changes from dev 2.0 branch
- Loading branch information
Showing
58 changed files
with
3,599 additions
and
757 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,26 +12,30 @@ jobs: | |
- name: Set version number | ||
shell: pwsh | ||
run: | | ||
$version = "0.1.0" | ||
echo $version | ||
echo "VERSION_NUMBER=$version" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append | ||
$versionNumber = "2.0.0" | ||
$versionSuffix = "beta.1" | ||
$infoVersion = "$versionNumber-$versionSuffix" | ||
echo $infoVersion | ||
echo "VERSION_NUMBER=$versionNumber" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append | ||
echo "VERSION_SUFFIX=$versionSuffix" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append | ||
echo "INFO_VERSION=$infoVersion" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append | ||
- uses: actions/checkout@v4 | ||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
dotnet-version: 7.0.x | ||
- name: Publish for win-x64 | ||
run: dotnet publish KaddaOK.AvaloniaApp.Windows/KaddaOK.AvaloniaApp.Windows.csproj /p:Version=${{ env.VERSION_NUMBER }}.0 /p:Configuration=Release /p:RuntimeIdentifier=win-x64 /p:PublishSingleFile=true /p:PublishDir=${{ github.workspace }}/publish | ||
run: dotnet publish KaddaOK.AvaloniaApp.Windows/KaddaOK.AvaloniaApp.Windows.csproj /p:VersionPrefix=${{ env.VERSION_NUMBER }} /p:VersionSuffix=${{ env.VERSION_SUFFIX }} /p:Configuration=Release /p:RuntimeIdentifier=win-x64 /p:PublishSingleFile=true /p:PublishDir=${{ github.workspace }}/publish | ||
- name: Zip for win-x64 | ||
shell: pwsh | ||
run: Compress-Archive -Path ${{ github.workspace }}/publish/* -DestinationPath KaddaOKTools_win-x64_${{ env.VERSION_NUMBER }}.zip | ||
run: Compress-Archive -Path ${{ github.workspace }}/publish/* -DestinationPath KaddaOKTools_win-x64_${{ env.INFO_VERSION }}.zip | ||
- name: Upload win-x64 Artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: KaddaOKTools_win-x64_${{ env.VERSION_NUMBER }} | ||
path: KaddaOKTools_win-x64_${{ env.VERSION_NUMBER }}.zip | ||
name: KaddaOKTools_win-x64_${{ env.INFO_VERSION }} | ||
path: KaddaOKTools_win-x64_${{ env.INFO_VERSION }}.zip | ||
- name: Create Release | ||
uses: ncipollo/[email protected] | ||
with: | ||
artifacts: "KaddaOKTools_win-x64_${{ env.VERSION_NUMBER }}.zip" | ||
tag: ${{ env.VERSION_NUMBER }} | ||
artifacts: "KaddaOKTools_win-x64_${{ env.INFO_VERSION }}.zip" | ||
tag: ${{ env.INFO_VERSION }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
59 changes: 59 additions & 0 deletions
59
KaddaOK.AvaloniaApp/Controls/Dialogs/NudgeTimingsDialog.axaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
<UserControl xmlns="https://github.com/avaloniaui" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
xmlns:dialogs="clr-namespace:KaddaOK.AvaloniaApp.Controls.Dialogs" | ||
xmlns:dialogHost="clr-namespace:DialogHostAvalonia;assembly=DialogHost.Avalonia" | ||
xmlns:library="clr-namespace:KaddaOK.Library;assembly=KaddaOK.Library" | ||
xmlns:viewModels="clr-namespace:KaddaOK.AvaloniaApp.ViewModels" | ||
mc:Ignorable="d" d:DesignWidth="500" d:DesignHeight="350" | ||
x:Class="KaddaOK.AvaloniaApp.Controls.Dialogs.NudgeTimingsDialog" | ||
x:DataType="viewModels:NudgeTimingsViewModel"> | ||
<dialogs:ModalDialogChrome Title="Nudge All Timings"> | ||
<Grid RowDefinitions="170,30,100" MaxWidth="500"> | ||
<StackPanel> | ||
<TextBlock TextWrapping="Wrap" Margin="2"> | ||
Shift all the starts and stops in the entire song by an offset value in seconds. | ||
</TextBlock> | ||
<TextBlock TextWrapping="Wrap" Margin="2"> | ||
Positive values will move everything later relative to the music, and should | ||
be applied if the scroll is happening too early. | ||
</TextBlock> | ||
<TextBlock TextWrapping="Wrap" Margin="2"> | ||
Negative values will move everything earlier relative to the music, and should | ||
be applied if the scroll isn't happening early enough. | ||
</TextBlock> | ||
<TextBlock TextWrapping="Wrap" Margin="2"> | ||
For instance, to move everything 100ms earlier in the song to give singers more | ||
time to react, enter -0.1 in the input below. | ||
</TextBlock> | ||
</StackPanel> | ||
<Grid Grid.Row="1" ColumnDefinitions="*, 30"> | ||
|
||
<NumericUpDown | ||
Increment="0.01" | ||
FormatString="{}{0:#,0.00}" | ||
Value="{Binding NudgeBy}"/> | ||
<TextBlock Grid.Column="1" Text="s" Margin="5"/> | ||
</Grid> | ||
|
||
<StackPanel | ||
Grid.Row="2" | ||
Orientation="Horizontal" | ||
HorizontalAlignment="Right" | ||
Margin="0,10,0,0"> | ||
<Button | ||
Content="Apply" | ||
Classes="accent" | ||
Command="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType=dialogHost:DialogHost}, Path=CloseDialogCommand}" | ||
CommandParameter="{Binding}" /> | ||
|
||
<Button | ||
Content="Cancel" | ||
Command="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType=dialogHost:DialogHost}, Path=CloseDialogCommand}" /> | ||
</StackPanel> | ||
|
||
</Grid> | ||
|
||
</dialogs:ModalDialogChrome> | ||
</UserControl> |
36 changes: 36 additions & 0 deletions
36
KaddaOK.AvaloniaApp/Controls/Dialogs/NudgeTimingsDialog.axaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
using Avalonia.Controls; | ||
using Avalonia.Input; | ||
using Avalonia.VisualTree; | ||
using DialogHostAvalonia; | ||
|
||
namespace KaddaOK.AvaloniaApp.Controls.Dialogs | ||
{ | ||
public partial class NudgeTimingsDialog : UserControl | ||
{ | ||
private DialogHost? dialogHost; | ||
|
||
public NudgeTimingsDialog() | ||
{ | ||
InitializeComponent(); | ||
} | ||
|
||
private void TextBox_AttachedToVisualTree(object? sender, Avalonia.VisualTreeAttachmentEventArgs e) | ||
{ | ||
(sender as TextBox)?.Focus(); | ||
dialogHost = this.FindAncestorOfType<DialogHost>(); | ||
} | ||
|
||
private void TextBox_KeyDown(object? sender, Avalonia.Input.KeyEventArgs e) | ||
{ | ||
if (e.Key == Key.Enter) | ||
{ | ||
dialogHost?.CloseDialogCommand.Execute(((TextBox)sender).Text); | ||
Check warning on line 27 in KaddaOK.AvaloniaApp/Controls/Dialogs/NudgeTimingsDialog.axaml.cs GitHub Actions / build
|
||
} | ||
|
||
if (e.Key == Key.Escape) | ||
{ | ||
dialogHost?.CloseDialogCommand.Execute(null); | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,130 @@ | ||
<UserControl xmlns="https://github.com/avaloniaui" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
xmlns:local="clr-namespace:KaddaOK.AvaloniaApp.Controls" | ||
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450" | ||
x:Class="KaddaOK.AvaloniaApp.Controls.InitialSyncOption" | ||
x:DataType="local:InitialSyncOption"> | ||
<UserControl.Styles> | ||
<Style Selector="Image.sourceMethodIconImage"> | ||
<Setter Property="Width" Value="32" /> | ||
</Style> | ||
<Style Selector="ScrollViewer.gettingFile"> | ||
<Setter | ||
Property="Cursor" | ||
Value="Wait" /> | ||
</Style> | ||
<Style Selector="ScrollViewer.gettingFile StackPanel"> | ||
<Setter | ||
Property="IsEnabled" | ||
Value="False" /> | ||
</Style> | ||
<Style Selector="Label.waveformLabel"> | ||
<Setter | ||
Property="Margin" | ||
Value="0,10,0,0" /> | ||
</Style> | ||
<Style Selector="Border.outerWaveformBorder"> | ||
<Setter | ||
Property="Margin" | ||
Value="0,2,0,5" /> | ||
<Setter | ||
Property="Background" | ||
Value="#FF061424" /> | ||
<Setter | ||
Property="BorderBrush" | ||
Value="Gray" /> | ||
<Setter | ||
Property="BorderThickness" | ||
Value="1" /> | ||
<Setter | ||
Property="CornerRadius" | ||
Value="5" /> | ||
</Style> | ||
<Style Selector="Border.innerWaveformBorder"> | ||
<Setter | ||
Property="Margin" | ||
Value="0,5" /> | ||
<Setter | ||
Property="MinHeight" | ||
Value="50" /> | ||
</Style> | ||
|
||
<Style Selector="TextBlock.introText"> | ||
<Setter | ||
Property="Margin" | ||
Value="0,0,0,10" /> | ||
<Setter | ||
Property="TextWrapping" | ||
Value="Wrap" /> | ||
</Style> | ||
<Style Selector="Border.initialOptionBorder"> | ||
<Setter Property="Background"> | ||
<Setter.Value> | ||
<LinearGradientBrush StartPoint="50%,0%" EndPoint="50%,100%"> | ||
<GradientStop Color="#FF385371" Offset="0" /> | ||
<GradientStop Color="#FF1E3851" Offset="0.5" /> | ||
<GradientStop Color="#FF112132" Offset="1" /> | ||
</LinearGradientBrush> | ||
</Setter.Value> | ||
</Setter> | ||
<Setter Property="BorderBrush" Value="#FF5A6A83" /> | ||
<Setter Property="BorderThickness" Value="0,1,0,0" /> | ||
<Setter Property="Padding" Value="25, 12" /> | ||
<Setter Property="CornerRadius" Value="30" /> | ||
<Setter Property="Margin" Value="0,20,0,0" /> | ||
</Style> | ||
<Style Selector="StackPanel.optionMainLineStackPanel"> | ||
<Setter Property="VerticalAlignment" Value="Center" /> | ||
</Style> | ||
<Style Selector="StackPanel.optionMainLineStackPanel TextBlock"> | ||
<Setter Property="VerticalAlignment" Value="Center" /> | ||
<Setter Property="Margin" Value="10,0" /> | ||
</Style> | ||
<Style Selector="StackPanel.optionMainLineStackPanel Button"> | ||
<Setter Property="Padding" Value="15,10" /> | ||
<Setter Property="VerticalAlignment" Value="Center" /> | ||
</Style> | ||
<Style Selector="StackPanel.moreInfoStackPanel"> | ||
<Setter Property="Margin" Value="5" /> | ||
</Style> | ||
<Style Selector="TextBlock.linkButtonText"> | ||
<Setter Property="FontFamily" Value="Arial" /> | ||
<Setter Property="FontStyle" Value="Italic" /> | ||
</Style> | ||
<Style Selector="TextBlock.summarySentence"> | ||
<Setter Property="Margin" Value="5,10,0,5" /> | ||
</Style> | ||
</UserControl.Styles> | ||
<Border Classes="initialOptionBorder"> | ||
<StackPanel> | ||
<Grid ColumnDefinitions="50,*,60"> | ||
<Image VerticalAlignment="Center" Classes="sourceMethodIconImage" Source="{Binding $parent[local:InitialSyncOption].IconDrawing}" /> | ||
<TextBlock VerticalAlignment="Center" Margin="10,0" FontWeight="Bold" Grid.Column="1" Text="{Binding $parent[local:InitialSyncOption].OptionTitle}" /> | ||
<Button VerticalAlignment="Center" Content="GO ->" | ||
Command="{Binding $parent[local:InitialSyncOption].ChooseCommand}" | ||
Grid.Column="2" /> | ||
</Grid> | ||
<StackPanel Orientation="Horizontal" Classes="optionMainLineStackPanel"> | ||
<TextBlock Classes="summarySentence"> | ||
<Run Text="{Binding $parent[local:InitialSyncOption].OptionSummary}"/> <InlineUIContainer> | ||
<Button Margin="0" Padding="0" Background="Transparent" | ||
Command="{Binding $parent[local:InitialSyncOption].ShowMoreInfoCommand}" | ||
IsVisible="{Binding !$parent[local:InitialSyncOption].MoreInfoVisible}"> | ||
<TextBlock Classes="linkButtonText">(more info)</TextBlock> | ||
</Button> | ||
</InlineUIContainer> | ||
</TextBlock> | ||
</StackPanel> | ||
<StackPanel IsVisible="{Binding $parent[local:InitialSyncOption].MoreInfoVisible}" | ||
Classes="moreInfoStackPanel"> | ||
<ItemsControl ItemsSource="{Binding $parent[local:InitialSyncOption].MoreInfoContent}" /> | ||
<Button Margin="0" Padding="0" Background="Transparent" | ||
Command="{Binding $parent[local:InitialSyncOption].HideMoreInfo}"> | ||
<TextBlock Classes="linkButtonText">(less info)</TextBlock> | ||
</Button> | ||
</StackPanel> | ||
</StackPanel> | ||
</Border> | ||
</UserControl> |
Oops, something went wrong.