update projects (versions, nuget, references)
This commit is contained in:
@@ -40,14 +40,16 @@
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
|
||||
<IncrementVersionOnBuild>1.yyyy.Mdd.Hmm</IncrementVersionOnBuild>
|
||||
<Version>1.2023.914.854</Version>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.VisualBasic" Version="10.3.0" />
|
||||
<PackageReference Include="Pilz.IO" Version="1.0.0" />
|
||||
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
|
||||
<PackageReference Include="System.Net.Http" Version="4.3.4" />
|
||||
<PackageReference Include="ui.for.winforms.allcontrols.net60" Version="2022.2.510" />
|
||||
<PackageReference Include="UI.for.WinForms.AllControls.Net60">
|
||||
<Version>2022.3.1109</Version>
|
||||
<Version>2023.1.117</Version>
|
||||
</PackageReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
@@ -97,11 +99,6 @@
|
||||
<DependentUpon>Settings.settings</DependentUpon>
|
||||
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||
</Compile>
|
||||
<Compile Update="UpdatingClientGuiLangRes.de.Designer.cs">
|
||||
<DependentUpon>UpdatingClientGuiLangRes.de.resx</DependentUpon>
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
</Compile>
|
||||
<Compile Update="UpdatingClientGuiLangRes.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
@@ -133,8 +130,7 @@
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Update="UpdatingClientGuiLangRes.de.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>UpdatingClientGuiLangRes.de.Designer.cs</LastGenOutput>
|
||||
<Generator></Generator>
|
||||
<CustomToolNamespace>Pilz.Updating.Client.GUI</CustomToolNamespace>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Update="UpdatingClientGuiLangRes.resx">
|
||||
@@ -160,10 +156,9 @@
|
||||
<ProjectReference Include="..\Pilz.Updating\Pilz.Updating.csproj" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="HtmlRenderer.Core" Version="1.5.0.6" />
|
||||
<PackageReference Include="HtmlRenderer.WinForms" Version="1.5.0.6" />
|
||||
<PackageReference Include="Markdig" Version="0.30.2" />
|
||||
<PackageReference Include="Markdig" Version="0.33.0" />
|
||||
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="6.0.0" />
|
||||
<PackageReference Include="Westermo.HtmlRenderer.WinForms" Version="1.6.0" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Remove="obj\RelMono\TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs" />
|
||||
|
||||
@@ -12,66 +12,20 @@ namespace Pilz.Updating.Client.GUI
|
||||
|
||||
public void SetCurrentState(UpdateStatus curAction)
|
||||
{
|
||||
SetCurrentStateInternal(curAction, -1);
|
||||
}
|
||||
|
||||
public void SetCurrentState(UpdateStatus curAction, int progress)
|
||||
{
|
||||
SetCurrentStateInternal(curAction, progress);
|
||||
}
|
||||
|
||||
private void SetCurrentStateInternal(UpdateStatus curAction, int progress)
|
||||
{
|
||||
var progressText = string.Empty;
|
||||
|
||||
switch (curAction)
|
||||
string progressText = curAction switch
|
||||
{
|
||||
case UpdateStatus.Waiting:
|
||||
{
|
||||
progressText = UpdatingClientGuiLangRes.SimpleActions_Waiting;
|
||||
break;
|
||||
}
|
||||
UpdateStatus.Waiting => UpdatingClientGuiLangRes.SimpleActions_Waiting,
|
||||
UpdateStatus.Searching => UpdatingClientGuiLangRes.SimpleActions_Searching,
|
||||
UpdateStatus.DownloadingPackage => UpdatingClientGuiLangRes.SimpleActions_DownloadingPackage,
|
||||
UpdateStatus.DownloadingInstaller => UpdatingClientGuiLangRes.SimpleActions_DownloadingInstaller,
|
||||
UpdateStatus.StartingInstaller => UpdatingClientGuiLangRes.SimpleActions_StartingInstaller,
|
||||
_ => string.Empty,
|
||||
};
|
||||
|
||||
case UpdateStatus.Searching:
|
||||
{
|
||||
progressText = UpdatingClientGuiLangRes.SimpleActions_Searching;
|
||||
break;
|
||||
}
|
||||
|
||||
case UpdateStatus.DownloadingInstaller:
|
||||
{
|
||||
progressText = UpdatingClientGuiLangRes.SimpleActions_DownloadingInstaller;
|
||||
break;
|
||||
}
|
||||
|
||||
case UpdateStatus.DownloadingPackage:
|
||||
{
|
||||
progressText = UpdatingClientGuiLangRes.SimpleActions_DownloadingPackage;
|
||||
break;
|
||||
}
|
||||
|
||||
case UpdateStatus.StartingInstaller:
|
||||
{
|
||||
progressText = UpdatingClientGuiLangRes.SimpleActions_DownloadingInstaller;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (progress == -1)
|
||||
{
|
||||
radProgressBar1.Visible = false;
|
||||
radWaitingBar1.Text = progressText;
|
||||
radWaitingBar1.BringToFront();
|
||||
radWaitingBar1.StartWaiting();
|
||||
}
|
||||
else
|
||||
{
|
||||
radWaitingBar1.StopWaiting();
|
||||
radProgressBar1.Text = progressText + $" ({progress}%)";
|
||||
radProgressBar1.Value1 = progress;
|
||||
radProgressBar1.BringToFront();
|
||||
radProgressBar1.Visible = true;
|
||||
}
|
||||
radProgressBar1.Visible = false;
|
||||
radWaitingBar1.Text = progressText;
|
||||
radWaitingBar1.BringToFront();
|
||||
radWaitingBar1.StartWaiting();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,6 +7,7 @@ using Microsoft.VisualBasic.CompilerServices;
|
||||
using global::Pilz.Updating.Client.GUI.My.Resources;
|
||||
using System;
|
||||
using Telerik.WinControls;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Pilz.Updating.Client.GUI
|
||||
{
|
||||
@@ -59,13 +60,7 @@ namespace Pilz.Updating.Client.GUI
|
||||
|
||||
public bool UseHiddenSearch { get; set; } = false;
|
||||
|
||||
private Image MyAppIcon
|
||||
{
|
||||
get
|
||||
{
|
||||
return Icon.ExtractAssociatedIcon(Assembly.GetEntryAssembly().Location).ToBitmap();
|
||||
}
|
||||
}
|
||||
private static Image MyAppIcon => Icon.ExtractAssociatedIcon(IO.Extensions.GetExecutablePath()).ToBitmap();
|
||||
|
||||
// C o n s t r u c t o r s
|
||||
|
||||
@@ -76,10 +71,10 @@ namespace Pilz.Updating.Client.GUI
|
||||
|
||||
// F e a t u r e s
|
||||
|
||||
public void UpdateInteractive(Form parentForm)
|
||||
public async Task UpdateInteractive(Form parentForm)
|
||||
{
|
||||
this.parentForm = parentForm;
|
||||
UpdateClient.UpdateInteractiveAsync();
|
||||
await UpdateClient.UpdateInteractive();
|
||||
}
|
||||
|
||||
private void EndUpdating()
|
||||
@@ -88,7 +83,7 @@ namespace Pilz.Updating.Client.GUI
|
||||
UpdateClient = null;
|
||||
}
|
||||
|
||||
private void MyUpdateClient_UpdateStatusChanged(UpdateStatus newStatus, int progress)
|
||||
private void MyUpdateClient_UpdateStatusChanged(UpdateStatus newStatus)
|
||||
{
|
||||
bool useGui = false;
|
||||
if (!(newStatus == UpdateStatus.Searching && UseHiddenSearch))
|
||||
@@ -106,7 +101,7 @@ namespace Pilz.Updating.Client.GUI
|
||||
}));
|
||||
}
|
||||
|
||||
curProgressDialog?.Invoke(new Action(() => curProgressDialog.SetCurrentState(newStatus, progress)));
|
||||
curProgressDialog?.Invoke(new Action(() => curProgressDialog.SetCurrentState(newStatus)));
|
||||
}
|
||||
|
||||
private void MyUpdateClient_DownloadingUpdate(UpdatePackageInfo pkg, CancelEventArgs e)
|
||||
|
||||
@@ -105,6 +105,15 @@ namespace Pilz.Updating.Client.GUI {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die Starting Installer ... ähnelt.
|
||||
/// </summary>
|
||||
internal static string SimpleActions_StartingInstaller {
|
||||
get {
|
||||
return ResourceManager.GetString("SimpleActions_StartingInstaller", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die Waiting ... ähnelt.
|
||||
/// </summary>
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
@@ -132,6 +132,9 @@
|
||||
<data name="SimpleActions_Searching" xml:space="preserve">
|
||||
<value>Nach Updates suchen ...</value>
|
||||
</data>
|
||||
<data name="SimpleActions_StartingInstaller" xml:space="preserve">
|
||||
<value>Starte Installer ...</value>
|
||||
</data>
|
||||
<data name="SimpleActions_Waiting" xml:space="preserve">
|
||||
<value>Warten ...</value>
|
||||
</data>
|
||||
|
||||
@@ -132,6 +132,9 @@
|
||||
<data name="SimpleActions_Searching" xml:space="preserve">
|
||||
<value>Searching for Updates ...</value>
|
||||
</data>
|
||||
<data name="SimpleActions_StartingInstaller" xml:space="preserve">
|
||||
<value>Starting Installer ...</value>
|
||||
</data>
|
||||
<data name="SimpleActions_Waiting" xml:space="preserve">
|
||||
<value>Waiting ...</value>
|
||||
</data>
|
||||
|
||||
Reference in New Issue
Block a user