Skip to content

Commit

Permalink
6.6 updates
Browse files Browse the repository at this point in the history
  • Loading branch information
kyle-ciq committed Mar 11, 2022
1 parent ce79423 commit 02783a3
Show file tree
Hide file tree
Showing 29 changed files with 111 additions and 66 deletions.
31 changes: 29 additions & 2 deletions AuthenticationExample/AuthenticationExample.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,21 @@
<WarningLevel>4</WarningLevel>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<TargetFrameworkProfile />
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>0</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<IsWebBootstrapper>false</IsWebBootstrapper>
<UseApplicationTrust>false</UseApplicationTrust>
<BootstrapperEnabled>true</BootstrapperEnabled>
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
</PropertyGroup>
Expand Down Expand Up @@ -57,8 +72,8 @@
<Reference Include="EventHook, Version=1.4.105.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\EventHook.1.4.105\lib\net45\EventHook.dll</HintPath>
</Reference>
<Reference Include="Finsemble, Version=6.5.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.5.0\lib\net452\Finsemble.dll</HintPath>
<Reference Include="Finsemble, Version=6.6.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.6.0\lib\net452\Finsemble.dll</HintPath>
</Reference>
<Reference Include="Microsoft.IdentityModel.Logging, Version=6.12.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.IdentityModel.Logging.6.12.1\lib\net45\Microsoft.IdentityModel.Logging.dll</HintPath>
Expand Down Expand Up @@ -162,6 +177,18 @@
<ItemGroup>
<None Include="App.config" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.5.2">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.5.2 %28x86 and x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="..\packages\Microsoft.Bcl.Build.1.0.21\build\Microsoft.Bcl.Build.targets" Condition="Exists('..\packages\Microsoft.Bcl.Build.1.0.21\build\Microsoft.Bcl.Build.targets')" />
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
Expand Down
4 changes: 2 additions & 2 deletions AuthenticationExample/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,5 @@
// 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("6.5.0.0")]
[assembly: AssemblyFileVersion("6.5.0.0")]
[assembly: AssemblyVersion("6.6.0.0")]
[assembly: AssemblyFileVersion("6.6.0.0")]
2 changes: 1 addition & 1 deletion AuthenticationExample/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<package id="DotNetZip" version="1.13.7" targetFramework="net452" />
<package id="EngineIoClientDotNet" version="1.0.7" targetFramework="net452" />
<package id="EventHook" version="1.4.105" targetFramework="net452" />
<package id="Finsemble" version="6.5.0" targetFramework="net452" />
<package id="Finsemble" version="6.6.0" targetFramework="net452" />
<package id="Microsoft.Bcl" version="1.1.10" targetFramework="net452" />
<package id="Microsoft.Bcl.Async" version="1.0.168" targetFramework="net452" />
<package id="Microsoft.Bcl.Build" version="1.0.21" targetFramework="net452" />
Expand Down
4 changes: 2 additions & 2 deletions FDC3WPFExample/FDC3WPFExample.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@
<Reference Include="EventHook, Version=1.4.105.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\EventHook.1.4.105\lib\net45\EventHook.dll</HintPath>
</Reference>
<Reference Include="Finsemble, Version=6.5.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.5.0\lib\net452\Finsemble.dll</HintPath>
<Reference Include="Finsemble, Version=6.6.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.6.0\lib\net452\Finsemble.dll</HintPath>
</Reference>
<Reference Include="Microsoft.IdentityModel.Logging, Version=6.12.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.IdentityModel.Logging.6.12.1\lib\net45\Microsoft.IdentityModel.Logging.dll</HintPath>
Expand Down
4 changes: 2 additions & 2 deletions FDC3WPFExample/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@
// 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("6.5.0.0")]
[assembly: AssemblyFileVersion("6.5.0.0")]
[assembly: AssemblyVersion("6.6.0.0")]
[assembly: AssemblyFileVersion("6.6.0.0")]
2 changes: 1 addition & 1 deletion FDC3WPFExample/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<package id="DotNetZip" version="1.13.7" targetFramework="net452" />
<package id="EngineIoClientDotNet" version="1.0.7" targetFramework="net452" />
<package id="EventHook" version="1.4.105" targetFramework="net452" />
<package id="Finsemble" version="6.5.0" targetFramework="net452" />
<package id="Finsemble" version="6.6.0" targetFramework="net452" />
<package id="Microsoft.Bcl" version="1.1.10" targetFramework="net452" />
<package id="Microsoft.Bcl.Async" version="1.0.168" targetFramework="net452" />
<package id="Microsoft.Bcl.Build" version="1.0.21" targetFramework="net452" />
Expand Down
6 changes: 3 additions & 3 deletions FreestandingWPFExample/FreestandingWPFExample.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
<TargetFramework>net5.0-windows</TargetFramework>
<UseWPF>true</UseWPF>
<Platforms>AnyCPU;x64</Platforms>
<AssemblyVersion>6.5.0.0</AssemblyVersion>
<FileVersion>6.5.0.0</FileVersion>
<Version>6.5.0</Version>
<AssemblyVersion>6.6.0.0</AssemblyVersion>
<FileVersion>6.6.0.0</FileVersion>
<Version>6.6.0</Version>
</PropertyGroup>

<ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions MultiWindowExample/MultiWindowExample.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@
<Reference Include="EventHook, Version=1.4.105.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\EventHook.1.4.105\lib\net45\EventHook.dll</HintPath>
</Reference>
<Reference Include="Finsemble, Version=6.5.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.5.0\lib\net452\Finsemble.dll</HintPath>
<Reference Include="Finsemble, Version=6.6.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.6.0\lib\net452\Finsemble.dll</HintPath>
</Reference>
<Reference Include="Microsoft.IdentityModel.Logging, Version=6.12.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.IdentityModel.Logging.6.12.1\lib\net45\Microsoft.IdentityModel.Logging.dll</HintPath>
Expand Down
4 changes: 2 additions & 2 deletions MultiWindowExample/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,5 @@
// 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("6.5.0.0")]
[assembly: AssemblyFileVersion("6.5.0.0")]
[assembly: AssemblyVersion("6.6.0.0")]
[assembly: AssemblyFileVersion("6.6.0.0")]
2 changes: 1 addition & 1 deletion MultiWindowExample/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<package id="DotNetZip" version="1.13.7" targetFramework="net452" />
<package id="EngineIoClientDotNet" version="1.0.7" targetFramework="net452" />
<package id="EventHook" version="1.4.105" targetFramework="net452" />
<package id="Finsemble" version="6.5.0" targetFramework="net452" />
<package id="Finsemble" version="6.6.0" targetFramework="net452" />
<package id="Microsoft.Bcl" version="1.1.10" targetFramework="net452" />
<package id="Microsoft.Bcl.Async" version="1.0.168" targetFramework="net452" />
<package id="Microsoft.Bcl.Build" version="1.0.21" targetFramework="net452" />
Expand Down
4 changes: 2 additions & 2 deletions WPFExample/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@
// 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("6.5.0.0")]
[assembly: AssemblyFileVersion("6.5.0.0")]
[assembly: AssemblyVersion("6.6.0.0")]
[assembly: AssemblyFileVersion("6.6.0.0")]
4 changes: 2 additions & 2 deletions WPFExample/WPFExample.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@
<Reference Include="EventHook, Version=1.4.105.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\EventHook.1.4.105\lib\net45\EventHook.dll</HintPath>
</Reference>
<Reference Include="Finsemble, Version=6.5.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.5.0\lib\net452\Finsemble.dll</HintPath>
<Reference Include="Finsemble, Version=6.6.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.6.0\lib\net452\Finsemble.dll</HintPath>
</Reference>
<Reference Include="Microsoft.IdentityModel.Logging, Version=6.12.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.IdentityModel.Logging.6.12.1\lib\net45\Microsoft.IdentityModel.Logging.dll</HintPath>
Expand Down
2 changes: 1 addition & 1 deletion WPFExample/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<package id="DotNetZip" version="1.13.7" targetFramework="net452" />
<package id="EngineIoClientDotNet" version="1.0.7" targetFramework="net452" />
<package id="EventHook" version="1.4.105" targetFramework="net452" />
<package id="Finsemble" version="6.5.0" targetFramework="net452" />
<package id="Finsemble" version="6.6.0" targetFramework="net452" />
<package id="Microsoft.Bcl" version="1.1.10" targetFramework="net452" />
<package id="Microsoft.Bcl.Async" version="1.0.168" targetFramework="net452" />
<package id="Microsoft.Bcl.Build" version="1.0.21" targetFramework="net452" />
Expand Down
4 changes: 2 additions & 2 deletions WPFExampleCore/WPFExampleCore.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
<TargetFramework>net5.0-windows</TargetFramework>
<UseWPF>true</UseWPF>
<Platforms>AnyCPU;x64</Platforms>
<Version>6.5.0</Version>
<Version>6.6.0</Version>
</PropertyGroup>

<ItemGroup>
<None Remove="Assets\ic_WPFLogo.png" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="Finsemble.WPF.Core" Version="6.5.0" />
<PackageReference Include="Finsemble.WPF.Core" Version="6.6.0" />
</ItemGroup>

<ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions WPFMultiWindowExampleCore/WPFMultiWindowExampleCore.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
<UseWPF>true</UseWPF>
<StartupObject>WPFMultiWindowExampleCore.AppStartup</StartupObject>
<Platforms>AnyCPU;x64</Platforms>
<Version>6.5.0</Version>
<Version>6.6.0</Version>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Finsemble.WPF.Core" Version="6.5.0" />
<PackageReference Include="Finsemble.WPF.Core" Version="6.6.0" />
</ItemGroup>

</Project>
4 changes: 2 additions & 2 deletions WindowlessExample.Core/WindowlessExample.Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
<OutputType>WinExe</OutputType>
<TargetFramework>net5.0</TargetFramework>
<Platforms>AnyCPU;x64</Platforms>
<Version>6.5.0</Version>
<Version>6.6.0</Version>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Finsemble.Core" Version="6.5.0" />
<PackageReference Include="Finsemble.Core" Version="6.6.0" />
</ItemGroup>

</Project>
4 changes: 2 additions & 2 deletions WindowlessExample/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,5 @@
// 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("6.5.0.0")]
[assembly: AssemblyFileVersion("6.5.0.0")]
[assembly: AssemblyVersion("6.6.0.0")]
[assembly: AssemblyFileVersion("6.6.0.0")]
4 changes: 2 additions & 2 deletions WindowlessExample/WindowlessExample.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@
<Reference Include="EventHook, Version=1.4.105.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\EventHook.1.4.105\lib\net45\EventHook.dll</HintPath>
</Reference>
<Reference Include="Finsemble, Version=6.5.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.5.0\lib\net452\Finsemble.dll</HintPath>
<Reference Include="Finsemble, Version=6.6.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.6.0\lib\net452\Finsemble.dll</HintPath>
</Reference>
<Reference Include="Microsoft.CSharp" />
<Reference Include="Microsoft.IdentityModel.Logging, Version=6.12.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
Expand Down
2 changes: 1 addition & 1 deletion WindowlessExample/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<package id="DotNetZip" version="1.13.7" targetFramework="net452" />
<package id="EngineIoClientDotNet" version="1.0.7" targetFramework="net452" />
<package id="EventHook" version="1.4.105" targetFramework="net452" />
<package id="Finsemble" version="6.5.0" targetFramework="net452" />
<package id="Finsemble" version="6.6.0" targetFramework="net452" />
<package id="Microsoft.Bcl" version="1.1.10" targetFramework="net452" />
<package id="Microsoft.Bcl.Async" version="1.0.168" targetFramework="net452" />
<package id="Microsoft.Bcl.Build" version="1.0.21" targetFramework="net452" />
Expand Down
32 changes: 19 additions & 13 deletions WinformExample/FormExample.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
using System.Windows.Threading;
using ChartIQ.Finsemble.DragAndDrop;
using ChartIQ.Finsemble.Router;
using Newtonsoft.Json.Bson;
using WinformExample.Controls;
using Color = System.Drawing.Color;
using ChartIQ.Finsemble.FDC3.Types;
Expand Down Expand Up @@ -146,6 +145,13 @@ private async void FinsembleConnected(object sender, EventArgs e)
FSBL.ConfigClient.GetValue(new JObject { ["field"] = "finsemble.components" }, HandleComponentsList);

SetInitialWindowGrouping(FSBL.WindowClient.GetWindowGroups());
SetInitialAlwaysOnTop();
}

private async void SetInitialAlwaysOnTop()
{
var isAlwaysOnTop = (await FSBL.FinsembleWindow.IsAlwaysOnTop(new JObject()))?["data"]?.ToObject<bool>() == true;
UpdateAlwaysOnTopButton(isAlwaysOnTop);
}

private void HandleContext(Context context)
Expand Down Expand Up @@ -605,14 +611,9 @@ private void LinkerButton_Click(object sender, EventArgs e)
}
}

private async void AlwaysOnTopButton_Click(object sender, EventArgs e)
private void UpdateAlwaysOnTopButton(bool isAlwaysOnTop)
{
var isAlwaysOnTop = await FSBL.WindowClient.IsAlwaysOnTop();

var newAlwaysOnTop = !isAlwaysOnTop;
await FSBL.WindowClient.SetAlwaysOnTop(newAlwaysOnTop);

if (newAlwaysOnTop)
if (isAlwaysOnTop)
{
AlwaysOnTopButton.ButtonColor = Color.FromArgb(3, 155, 255);
AlwaysOnTopButton.OnHoverButtonColor = Color.FromArgb(3, 155, 255);
Expand All @@ -624,6 +625,16 @@ private async void AlwaysOnTopButton_Click(object sender, EventArgs e)
}
}

private async void AlwaysOnTopButton_Click(object sender, EventArgs e)
{
var isAlwaysOnTop = await FSBL.WindowClient.IsAlwaysOnTop();

var newAlwaysOnTop = !isAlwaysOnTop;
await FSBL.WindowClient.SetAlwaysOnTop(newAlwaysOnTop);

UpdateAlwaysOnTopButton(newAlwaysOnTop);
}

private void DockingButton_Click(object sender, EventArgs e)
{
var currentWindowName = FSBL.WindowClient.GetWindowIdentifier()["windowName"].ToString();
Expand Down Expand Up @@ -670,11 +681,6 @@ private void DragNDropEmittingButton_MouseDown(object sender, MouseEventArgs e)
FSBL.DragAndDropClient.DragStartWithData(sender);
}

private void DragNDropEmittingButton_Click(object sender, EventArgs e)
{

}

protected override void OnFormClosing(FormClosingEventArgs e)
{
//Dispose of the FSSBL object when the form is closed so that Finsemble is aware we've closed
Expand Down
4 changes: 2 additions & 2 deletions WinformExample/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,5 @@
// 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("6.5.0.0")]
[assembly: AssemblyFileVersion("6.5.0.0")]
[assembly: AssemblyVersion("6.6.0.0")]
[assembly: AssemblyFileVersion("6.6.0.0")]
4 changes: 2 additions & 2 deletions WinformExample/WinformExample.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@
<Reference Include="EventHook, Version=1.4.105.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\EventHook.1.4.105\lib\net45\EventHook.dll</HintPath>
</Reference>
<Reference Include="Finsemble, Version=6.5.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.5.0\lib\net452\Finsemble.dll</HintPath>
<Reference Include="Finsemble, Version=6.6.0.0, Culture=neutral, PublicKeyToken=9df516fcbc4ebe73, processorArchitecture=MSIL">
<HintPath>..\packages\Finsemble.6.6.0\lib\net452\Finsemble.dll</HintPath>
</Reference>
<Reference Include="Microsoft.IdentityModel.Logging, Version=6.12.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.IdentityModel.Logging.6.12.1\lib\net45\Microsoft.IdentityModel.Logging.dll</HintPath>
Expand Down
2 changes: 1 addition & 1 deletion WinformExample/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<package id="DotNetZip" version="1.13.7" targetFramework="net452" />
<package id="EngineIoClientDotNet" version="1.0.7" targetFramework="net452" />
<package id="EventHook" version="1.4.105" targetFramework="net452" />
<package id="Finsemble" version="6.5.0" targetFramework="net452" />
<package id="Finsemble" version="6.6.0" targetFramework="net452" />
<package id="Microsoft.Bcl" version="1.1.10" targetFramework="net461" />
<package id="Microsoft.Bcl.Async" version="1.0.168" targetFramework="net461" />
<package id="Microsoft.Bcl.Build" version="1.0.21" targetFramework="net461" />
Expand Down
22 changes: 17 additions & 5 deletions WinformExampleCore/MainForm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -111,9 +111,16 @@ private async void Finsemble_Connected(object sender, EventArgs e)

SetInitialWindowGrouping(_bridge.Clients.WindowClient.GetWindowGroups());
LoadAndSetButtonsFont();
SetInitialAlwaysOnTop();
this.Visible = true;
}

private async void SetInitialAlwaysOnTop()
{
var isAlwaysOnTop = (await _bridge.Clients.FinsembleWindow.IsAlwaysOnTop(new JObject())).response?["data"]?.ToObject<bool>() == true;
UpdateAlwaysOnTopButton(isAlwaysOnTop);
}

private void SetInitialWindowGrouping(JArray groupdWindowBelongsTo)
{
this.Invoke(new Action(() =>
Expand Down Expand Up @@ -469,12 +476,9 @@ private void SendButton_Click(object sender, EventArgs e)
_bridge.Clients.Fdc3Client.DesktopAgentClient.Broadcast(new Context(param));
}

private async void AlwaysOnTopButton_Click(object sender, EventArgs e)
private void UpdateAlwaysOnTopButton(bool isAlwaysOnTop)
{
var newAlwaysOnTop = !await _bridge.Clients.WindowClient.IsAlwaysOnTop();
await _bridge.Clients.WindowClient.SetAlwaysOnTop(newAlwaysOnTop);

if (newAlwaysOnTop)
if (isAlwaysOnTop)
{
AlwaysOnTopButton.ButtonColor = Color.FromArgb(3, 155, 255);
AlwaysOnTopButton.OnHoverButtonColor = Color.FromArgb(3, 155, 255);
Expand All @@ -486,6 +490,14 @@ private async void AlwaysOnTopButton_Click(object sender, EventArgs e)
}
}

private async void AlwaysOnTopButton_Click(object sender, EventArgs e)
{
var newAlwaysOnTop = !await _bridge.Clients.WindowClient.IsAlwaysOnTop();
await _bridge.Clients.WindowClient.SetAlwaysOnTop(newAlwaysOnTop);

UpdateAlwaysOnTopButton(newAlwaysOnTop);
}


private void DockingButton_Click(object sender, EventArgs args)
{
Expand Down
Loading

0 comments on commit 02783a3

Please sign in to comment.