Remove, add next commit back in

This commit is contained in:
2024-05-22 11:05:36 +02:00
parent 88e0edcc76
commit 47d8a5996f
241 changed files with 0 additions and 12981 deletions

View File

@@ -1,3 +0,0 @@
{
"CurrentProjectSetting": null
}

View File

@@ -1,6 +0,0 @@
{
"ExpandedNodes": [
""
],
"PreviewInSolutionExplorer": false
}

Binary file not shown.

View File

@@ -1,69 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<configSections>
<sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" >
<section name="BeWoLauncher.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false" />
</sectionGroup>
</configSections>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="BeWoBasicEndpoint" closeTimeout="00:05:00" openTimeout="00:05:00" receiveTimeout="00:10:00" sendTimeout="00:05:00" allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" maxBufferPoolSize="524288" maxBufferSize="2147483647" maxReceivedMessageSize="2147483647" textEncoding="utf-8" transferMode="Buffered" useDefaultWebProxy="true" messageEncoding="Text">
<readerQuotas maxDepth="32" maxStringContentLength="2147483647" maxArrayLength="2147483647" maxBytesPerRead="4096" maxNameTableCharCount="16384" />
<security mode="None" />
<!-- mode="Transport" für echten Server und "None" sonst-->
</binding>
<binding name="BeWoBasicEndpointTransport" closeTimeout="00:05:00" openTimeout="00:05:00" receiveTimeout="00:10:00" sendTimeout="00:05:00" allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" maxBufferPoolSize="524288" maxBufferSize="2147483647" maxReceivedMessageSize="2147483647" textEncoding="utf-8" transferMode="Buffered" useDefaultWebProxy="true" messageEncoding="Text">
<readerQuotas maxDepth="32" maxStringContentLength="2147483647" maxArrayLength="2147483647" maxBytesPerRead="4096" maxNameTableCharCount="16384" />
<security mode="None" />
<!-- mode="Transport" für echten Server und "None" sonst-->
</binding>
</basicHttpBinding>
</bindings>
<client>
<endpoint binding="basicHttpBinding" bindingConfiguration="BeWoBasicEndpointTransport" contract="BeWoLauncher.ServiceProxy.ILauncherService" name="LauncherServiceEndpoint" />
<endpoint binding="basicHttpBinding" bindingConfiguration="BeWoBasicEndpointTransport" contract="BeWoLauncher.ServiceProxy.IEnumTranslationService" name="EnumTranslationEndpoint" />
<endpoint binding="basicHttpBinding" bindingConfiguration="BeWoBasicEndpoint" contract="BeWoLauncher.ServiceProxy.IDownloadBeWoService" name="DownloadBeWoEndpoint" />
</client>
<behaviors>
<endpointBehaviors>
<behavior name="BeWoServiceBehavior">
<dataContractSerializer maxItemsInObjectGraph="2147483647" />
</behavior>
</endpointBehaviors>
</behaviors>
</system.serviceModel>
<appSettings>
<add key="AutoLogin" value="false" />
<add key="ShowUpdateDelay" value="true" />
<add key="ForceUpdate" value="true" />
<add key="UseUpdater" value="true"/>
<add key="ClientSettingsProvider.ServiceUri" value="" />
<add key="SkipLock" value="true"/>
</appSettings>
<system.web>
<membership defaultProvider="ClientAuthenticationMembershipProvider">
<providers>
<add name="ClientAuthenticationMembershipProvider" type="System.Web.ClientServices.Providers.ClientFormsAuthenticationMembershipProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" />
</providers>
</membership>
<roleManager defaultProvider="ClientRoleProvider" enabled="true">
<providers>
<add name="ClientRoleProvider" type="System.Web.ClientServices.Providers.ClientRoleProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" cacheTimeout="86400" />
</providers>
</roleManager>
</system.web>
<userSettings>
<BeWoLauncher.Properties.Settings>
<setting name="InstallLocation" serializeAs="String">
<value />
</setting>
<setting name="FirstInstallationSuccess" serializeAs="String">
<value>False</value>
</setting>
</BeWoLauncher.Properties.Settings>
</userSettings>
</configuration>

View File

@@ -1,464 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" 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)' == '' ">AnyCPU</Platform>
<ProjectGuid>{E3BA193A-A64F-4CE6-91BE-F54E551797BE}</ProjectGuid>
<OutputType>WinExe</OutputType>
<RootNamespace>BeWoLauncher</RootNamespace>
<AssemblyName>BeWoLauncher</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<WarningLevel>4</WarningLevel>
<Deterministic>true</Deterministic>
<IsWebBootstrapper>false</IsWebBootstrapper>
<PublishUrl>D:\Test\Launcher\</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>
<AutorunEnabled>true</AutorunEnabled>
<ApplicationRevision>1</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust>
<PublishWizardCompleted>true</PublishWizardCompleted>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>x86</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>BeWoPlaner.ico</ApplicationIcon>
</PropertyGroup>
<PropertyGroup>
<ManifestCertificateThumbprint>F47E9EA636ECD1D899058A03A3946362A6DA6EE5</ManifestCertificateThumbprint>
</PropertyGroup>
<PropertyGroup>
<ManifestKeyFile>BeWoLauncher_1_TemporaryKey.pfx</ManifestKeyFile>
</PropertyGroup>
<PropertyGroup>
<GenerateManifests>true</GenerateManifests>
</PropertyGroup>
<PropertyGroup>
<SignManifests>false</SignManifests>
</PropertyGroup>
<ItemGroup>
<Reference Include="DevExpress.Mvvm.v17.1, Version=17.1.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
<Private>False</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />
<Reference Include="System.Configuration.Install" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.IO.Compression" />
<Reference Include="System.IO.Compression.FileSystem" />
<Reference Include="System.Runtime.Serialization" />
<Reference Include="System.ServiceModel" />
<Reference Include="System.Web.Extensions" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Net.Http" />
<Reference Include="System.Xaml">
<RequiredTargetFramework>4.0</RequiredTargetFramework>
</Reference>
<Reference Include="WindowsBase" />
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
</ItemGroup>
<ItemGroup>
<ApplicationDefinition Include="LauncherApp.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</ApplicationDefinition>
<Compile Include="Logic\Behavior\LaunchBehavior.cs" />
<Compile Include="Logic\Behavior\ViewSwitchBehavior.cs" />
<Compile Include="Logic\ViewBuilder.cs" />
<Compile Include="View\Components\ConfirmDemoDialog.xaml.cs">
<DependentUpon>ConfirmDemoDialog.xaml</DependentUpon>
</Compile>
<Compile Include="View\Components\MessageDialog.xaml.cs">
<DependentUpon>MessageDialog.xaml</DependentUpon>
</Compile>
<Compile Include="Logic\Converter\BoolNullCheckConverter.cs" />
<Compile Include="Logic\Converter\BoolReverseConverter.cs" />
<Compile Include="Logic\Converter\BoolVisibilityConverter.cs" />
<Compile Include="Logic\Converter\BoolVisibilityHiddenConverter.cs" />
<Compile Include="Logic\Converter\BoolVisibilityMultiConverter.cs" />
<Compile Include="Logic\Converter\CollectionCountToBoolConverter.cs" />
<Compile Include="Logic\Converter\CollectionCountToVisibilityConverter.cs" />
<Compile Include="Logic\Converter\DataContract2StringConverter.cs" />
<Compile Include="Logic\Converter\Date2CalendarWeekStringConverter.cs" />
<Compile Include="Logic\Converter\DateConverter.cs" />
<Compile Include="Logic\Converter\DateNullValueToEmptyStringConverter.cs" />
<Compile Include="Logic\Converter\DecimalConverter.cs" />
<Compile Include="Logic\Converter\EnumToDescriptionConverter.cs" />
<Compile Include="Logic\Converter\IListT2DataTableConverter.cs" />
<Compile Include="Logic\Converter\IndexBoolConverter.cs" />
<Compile Include="Logic\Converter\Int2DecimalConverter.cs" />
<Compile Include="Logic\Converter\NullableBoolToBoolConverter.cs" />
<Compile Include="Logic\Converter\ObjectBoolConverter.cs" />
<Compile Include="Logic\Converter\ObjectVisibilityConverter.cs" />
<Compile Include="Logic\Converter\OneWayToSourceSwitch.cs" />
<Compile Include="Logic\Converter\ReverseValueEqualsParamVisibilityConverter.cs" />
<Compile Include="Logic\Converter\StringBrushConverter.cs" />
<Compile Include="Logic\Converter\StringFormatConverter.cs" />
<Compile Include="Logic\Converter\StringFormatMulitConverter.cs" />
<Compile Include="Logic\Converter\StringLengthVisibilityConverter.cs" />
<Compile Include="Logic\Converter\StringLengthVisibilityMultiConverter.cs" />
<Compile Include="Logic\Converter\ValueEqualsParamVisibilityConverter.cs" />
<Compile Include="Logic\Controller\DownloadController.cs" />
<Compile Include="Logic\Controller\ProcessController.cs" />
<Compile Include="Logic\Controller\ViewController.cs" />
<Compile Include="View\Frames\FrameBase.cs" />
<Compile Include="View\Frames\InfoFrame.xaml.cs">
<DependentUpon>InfoFrame.xaml</DependentUpon>
</Compile>
<Compile Include="View\Frames\LoadingFrame.xaml.cs">
<DependentUpon>LoadingFrame.xaml</DependentUpon>
</Compile>
<Compile Include="View\Frames\ProgressFrame.xaml.cs">
<DependentUpon>ProgressFrame.xaml</DependentUpon>
</Compile>
<Compile Include="View\FrameView.xaml.cs">
<DependentUpon>FrameView.xaml</DependentUpon>
</Compile>
<Compile Include="View\Frames\InstallInfoFrame.xaml.cs">
<DependentUpon>InstallInfoFrame.xaml</DependentUpon>
</Compile>
<Compile Include="View\Frames\UpdateInfoFrame.xaml.cs">
<DependentUpon>UpdateInfoFrame.xaml</DependentUpon>
</Compile>
<Compile Include="View\Frames\UninstallInfoFrame.xaml.cs">
<DependentUpon>UninstallInfoFrame.xaml</DependentUpon>
</Compile>
<Compile Include="Logic\Utils\LauncherAppdataConfig.cs" />
<Compile Include="Logic\Utils\LauncherPaths.cs" />
<Compile Include="Logic\Utils\Download\DownloadManager.cs" />
<Compile Include="View\Components\PasswortAenderungsView.xaml.cs">
<DependentUpon>PasswortAenderungsView.xaml</DependentUpon>
</Compile>
<Compile Include="Models\ConnectionProfile.cs" />
<Compile Include="View\Windows\PopUpWindow.xaml.cs">
<DependentUpon>PopUpWindow.xaml</DependentUpon>
</Compile>
<Page Include="View\Components\ConfirmDemoDialog.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="View\Components\EnterTenantDialog.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="View\Components\MessageDialog.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="View\Components\ProfileEditView.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="View\Components\ExceptionMessageBox.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="View\Components\PasswortAenderungsView.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="View\LoginView.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="View\Components\ProxyLoginView.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="View\Components\PwVergessenView.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="View\Components\WaitLayer2.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="View\Frames\InfoFrame.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="View\Frames\ProgressFrame.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="View\Frames\LoadingFrame.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="Styles\OrangeBlack.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="View\FrameView.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="View\Frames\InstallInfoFrame.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="View\Frames\UpdateInfoFrame.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="View\Frames\UninstallInfoFrame.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="LauncherWindow.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Compile Include="LauncherApp.xaml.cs">
<DependentUpon>LauncherApp.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>
<Compile Include="Logic\Utils\LauncherUtils.cs" />
<Compile Include="View\Components\EnterTenantDialog.xaml.cs">
<DependentUpon>EnterTenantDialog.xaml</DependentUpon>
</Compile>
<Compile Include="View\Components\ProfileEditView.xaml.cs">
<DependentUpon>ProfileEditView.xaml</DependentUpon>
</Compile>
<Compile Include="Logic\Multitenancy\MultitenancyEndpointBehavior.cs" />
<Compile Include="Logic\Multitenancy\MultitenancyHeader.cs" />
<Compile Include="Logic\Multitenancy\MultitenancyInterceptor.cs" />
<Compile Include="Logic\Security\LauncherSecurityHeader.cs" />
<Compile Include="Logic\Security\LauncherSecurityHeaderEndpointBehavior.cs" />
<Compile Include="Logic\Security\LauncherSecurityHeaderInterceptor.cs" />
<Compile Include="Logic\ServiceProxy\LauncherGenerated.cs" />
<Compile Include="Logic\ServiceProxy\LauncherServiceFacade.cs" />
<Compile Include="View\Components\ExceptionMessageBox.xaml.cs">
<DependentUpon>ExceptionMessageBox.xaml</DependentUpon>
</Compile>
<Compile Include="View\LoginView.xaml.cs">
<DependentUpon>LoginView.xaml</DependentUpon>
</Compile>
<Compile Include="View\Components\ProxyLoginView.xaml.cs">
<DependentUpon>ProxyLoginView.xaml</DependentUpon>
</Compile>
<Compile Include="View\Components\PwVergessenView.xaml.cs">
<DependentUpon>PwVergessenView.xaml</DependentUpon>
</Compile>
<Compile Include="View\Components\WaitLayer2.xaml.cs">
<DependentUpon>WaitLayer2.xaml</DependentUpon>
</Compile>
<Compile Include="LauncherWindow.xaml.cs">
<DependentUpon>LauncherWindow.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>
<Page Include="View\Windows\PopUpWindow.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
</ItemGroup>
<ItemGroup>
<Compile Include="Properties\AssemblyInfo.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<EmbeddedResource Include="Properties\licenses.licx" />
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
<None Include="LauncherServiceReferences.bat" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
</ItemGroup>
<ItemGroup>
<None Include="App.config">
<SubType>Designer</SubType>
</None>
</ItemGroup>
<ItemGroup>
<Resource Include="View\Icons\16_bulleted_list.png" />
<Resource Include="View\Icons\16_employee.png" />
<Resource Include="View\Icons\16_euro.png" />
<Resource Include="View\Icons\16_female.png" />
<Resource Include="View\Icons\16_male.png" />
<Resource Include="View\Icons\16_report.png" />
<Resource Include="View\Icons\Add24.png" />
<Resource Include="View\Icons\adobe-pdf-icon.png" />
<Resource Include="View\Icons\Alarm.png" />
<Resource Include="View\Icons\AlertsDisabled.png" />
<Resource Include="View\Icons\AnonymousUserDisabled.png" />
<Resource Include="View\Icons\Archiv.png" />
<Resource Include="View\Icons\ArrowLeft.png" />
<Resource Include="View\Icons\ArrowRight.png" />
<Resource Include="View\Icons\bewologo_big.gif" />
<Resource Include="View\Icons\bewoplaner_logo_big.png" />
<Resource Include="View\Icons\bewoplaner_logo_small.png" />
<Resource Include="View\Icons\bslogo.gif" />
<Resource Include="View\Icons\Calendar 1.png" />
<Resource Include="View\Icons\Calendar1Day24.png" />
<Resource Include="View\Icons\Calendar31Day24.png" />
<Resource Include="View\Icons\Calendar5Day24.png" />
<Resource Include="View\Icons\Calendar7Day24.png" />
<Resource Include="View\Icons\CalendarDisabled.png" />
<Resource Include="View\Icons\CashStackDisabled.png" />
<Resource Include="View\Icons\ChartBarDisabled.png" />
<Resource Include="View\Icons\ChartLineDisabled.png" />
<Resource Include="View\Icons\ClipboardDisabled.png" />
<Resource Include="View\Icons\CoinsDisabled.png" />
<Resource Include="View\Icons\ConfigurationDisabled.png" />
<Resource Include="View\Icons\ConfigurationToolsDisabled.png" />
<Resource Include="View\Icons\ContactCardDisabled.png" />
<Resource Include="View\Icons\ContactCardWebDisabled.png" />
<Resource Include="View\Icons\Copy.png" />
<Resource Include="View\Icons\Cut.png" />
<Resource Include="View\Icons\delete.png" />
<Resource Include="View\Icons\Delete24.png" />
<Resource Include="View\Icons\Document48.png" />
<Resource Include="View\Icons\DocumentWithAdd.png" />
<Resource Include="View\Icons\DocumentWithAdd2.png" />
<Resource Include="View\Icons\edit.png" />
<Resource Include="View\Icons\Email.png" />
<Resource Include="View\Icons\excel.png" />
<Resource Include="View\Icons\Favorites16.png" />
<Resource Include="View\Icons\Favorites32.png" />
<Resource Include="View\Icons\FavoritesDisabled32.png" />
<Resource Include="View\Icons\Folder.png" />
<Resource Include="View\Icons\glucklicher.png" />
<Resource Include="View\Icons\Haeckchen.png" />
<Resource Include="View\Icons\Help.png" />
<Resource Include="View\Icons\HelpDisabled.png" />
<Resource Include="View\Icons\History24.png" />
<Resource Include="View\Icons\HistoryDisabled - Kopie.png" />
<Resource Include="View\Icons\HistoryDisabled.png" />
<Resource Include="View\Icons\Home.png" />
<Resource Include="View\Icons\HomeDisabled - Kopie.png" />
<Resource Include="View\Icons\HomeDisabled.png" />
<Resource Include="View\Icons\IDBadgeDisabled - Kopie.png" />
<Resource Include="View\Icons\IDBadgeDisabled.png" />
<Resource Include="View\Icons\InternetDisabled - Kopie.png" />
<Resource Include="View\Icons\InternetDisabled.png" />
<Resource Include="View\Icons\Keywords.png" />
<Resource Include="View\Icons\KeywordsDisabled.png" />
<Resource Include="View\Icons\klient-avatar.png" />
<Resource Include="View\Icons\Light Bulb.png" />
<Resource Include="View\Icons\Logout - Kopie.png" />
<Resource Include="View\Icons\Logout.png" />
<Resource Include="View\Icons\LogoutDisabled.png" />
<Resource Include="View\Icons\ManufacturingDisabled - Kopie.png" />
<Resource Include="View\Icons\ManufacturingDisabled.png" />
<Resource Include="View\Icons\massnahme.png" />
<Resource Include="View\Icons\MenuDisabled.png" />
<Resource Include="View\Icons\mitarbeiter-avatar.png" />
<Resource Include="View\Icons\mitarbeiter-team-avatar.png" />
<Resource Include="View\Icons\new.png" />
<Resource Include="View\Icons\Newspaper.png" />
<Resource Include="View\Icons\ObjectsDisabled.png" />
<Resource Include="View\Icons\OfficeBulidingBlackDisabled.png" />
<Resource Include="View\Icons\Paste.png" />
<Resource Include="View\Icons\Paste24.png" />
<Resource Include="View\Icons\Redo - Kopie.png" />
<Resource Include="View\Icons\Redo.png" />
<Resource Include="View\Icons\Rename24 - Kopie.png" />
<Resource Include="View\Icons\Rename24.png" />
<Resource Include="View\Icons\RSS Newsfeed - Kopie.png" />
<Resource Include="View\Icons\RSS Newsfeed.png" />
<Resource Include="View\Icons\Save - Kopie.png" />
<Resource Include="View\Icons\Save.png" />
<Resource Include="View\Icons\Search - Kopie.png" />
<Resource Include="View\Icons\Search.png" />
<Resource Include="View\Icons\SMS24_2.png" />
<Resource Include="View\Icons\sortiert.png" />
<Resource Include="View\Icons\Symbol Delete.png" />
<Resource Include="View\Icons\Symbol Edit.png" />
<Resource Include="View\Icons\Symbol Help.png" />
<Resource Include="View\Icons\SymbolRefresh32.png" />
<Resource Include="View\Icons\SymbolRefresh32Disabled - Kopie.png" />
<Resource Include="View\Icons\SymbolRefresh32Disabled.png" />
<Resource Include="View\Icons\TechSupportWhiteDisabled.png" />
<Resource Include="View\Icons\trauriges-smiley.png" />
<Resource Include="View\Icons\Undo - Kopie.png" />
<Resource Include="View\Icons\Undo.png" />
<Resource Include="View\Icons\unsortiert.png" />
<Resource Include="View\Icons\User Business Male.png" />
<Resource Include="View\Icons\User Home Boy.png" />
<Resource Include="View\Icons\User Home Girl.png" />
<Resource Include="View\Icons\UserBusinessMaleDisabled - Kopie.png" />
<Resource Include="View\Icons\UserBusinessMaleDisabled.png" />
<Resource Include="View\Icons\UserGroupBusinessDisabled - Kopie.png" />
<Resource Include="View\Icons\UserGroupBusinessDisabled.png" />
<Resource Include="View\Icons\UserGroupDisabled - Kopie.png" />
<Resource Include="View\Icons\UserGroupDisabled.png" />
<Resource Include="View\Icons\UserGroupHome24bw.png" />
<Resource Include="View\Icons\UserHomeBoyDisabled.png" />
<Resource Include="View\Icons\UserHomeMaleDisabled.png" />
<Resource Include="View\Icons\UserHomeMaleDisabled32.png" />
<Resource Include="View\Icons\UserMaleBlackDisabled.png" />
<Resource Include="View\Icons\warning-16x16.png" />
<Resource Include="View\Icons\WeitereNachrichtLaden.png" />
<Resource Include="View\Icons\word.png" />
<Resource Include="View\Icons\ziel.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="BeWoPlaner.ico" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\SharedLauncher\SharedLauncher.csproj">
<Project>{efe05c79-e0dd-4311-8b90-a8da7ebdf36f}</Project>
<Name>SharedLauncher</Name>
<Private>True</Private>
</ProjectReference>
</ItemGroup>
<ItemGroup />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>

View File

@@ -1,17 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<PublishUrlHistory>D:\Test\Launcher\|publish\</PublishUrlHistory>
<InstallUrlHistory />
<SupportUrlHistory />
<UpdateUrlHistory />
<BootstrapperUrlHistory />
<ErrorReportUrlHistory />
<FallbackCulture>de-DE</FallbackCulture>
<VerifyUploadedFiles>false</VerifyUploadedFiles>
<ProjectView>ProjectFiles</ProjectView>
</PropertyGroup>
<PropertyGroup>
<EnableSecurityDebugging>false</EnableSecurityDebugging>
</PropertyGroup>
</Project>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

View File

@@ -1,14 +0,0 @@
<Application x:Class="BeWoLauncher.LauncherApp"
x:ClassModifier="public"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:BeWoLauncher"
Exit="Application_Exit">
<Application.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="Styles/OrangeBlack.xaml" />
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</Application.Resources>
</Application>

View File

@@ -1,97 +0,0 @@
using BeWoLauncher.Components;
using BeWoLauncher.Logic;
using BeWoLauncher.Logic.Controller;
using BeWoLauncher.ServiceProxy;
using BeWoLauncher.WindowImp;
using BS.SharedLauncher;
using BS.SharedLauncher.Information;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Configuration;
using System.Data;
using System.Diagnostics;
using System.Globalization;
using System.IO;
using System.IO.Pipes;
using System.Linq;
using System.Reflection;
using System.Security.Policy;
using System.Threading;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
using System.Windows.Markup;
using System.Windows.Threading;
using System.Xml;
namespace BeWoLauncher
{
/// <summary>
/// Interaktionslogik für "App.xaml"
/// </summary>
public partial class LauncherApp : Application
{
public static string ShortVersion => "3";
public static string Version => "Version 3.0";
public LauncherApp()
{
}
protected override void OnStartup(StartupEventArgs e)
{
MainWindow = new LauncherWindow();
MainWindow.Show();
base.OnStartup(e);
ProcessController.StartLauncher();
Dispatcher.UnhandledException += (s, ex)
=>
{
if (ex.Exception == null || String.IsNullOrEmpty(ex.Exception.Message) ||
(!ex.Exception.ToString().Contains("DevExpress.Xpf.Bars.Customization.CustomizationControl.OnLoaded")
&& !ex.Exception.ToString().Contains("DevExpress.Xpf.Grid.Native.SelectionStrategyCellBase.IsCellSelected")))
{
ShowError("Unbehandelter Fehler", ex.Exception, true);
}
ex.Handled = true;
};
FrameworkElement.LanguageProperty.OverrideMetadata(typeof(FrameworkElement), new FrameworkPropertyMetadata(XmlLanguage.GetLanguage(CultureInfo.CurrentCulture.IetfLanguageTag)));
}
private void Application_Exit(object sender, ExitEventArgs e)
{
ProcessController.KillPlanerProcess();
}
#region ShowError
public static void ShowError(Exception ex) => ShowError(null, ex, true);
public static void ShowError(string message, Exception ex, bool showDetails)
{
ShowError(message, ex.ToString(), showDetails);
}
public static void ShowError(string message, string ex, bool showDetails)
{
if (ViewController.CurrentWindow is null)
{
MessageBox.Show(ex, message);
}
else
{
ViewController.CurrentWindow.Dispatcher.BeginInvoke(DispatcherPriority.Normal, (Action)(() =>
ViewController.CurrentWindow.ShowControlAsModalPopUp(new ExceptionMessageBox(message, ex, showDetails))));
}
}
#endregion
}
}

View File

@@ -1 +0,0 @@
svcutil.exe /noConfig /edb /n:*,BeWoLauncher.ServiceProxy /out:ServiceProxy\LauncherGenerated.cs /ct:System.Collections.Generic.List`1 /r:..\SharedLauncher\bin\Debug\BS.SharedLauncher.dll http://localhost:3778/LauncherService.svc?wsdl http://localhost:3778/EnumTranslationService.svc?wsdl http://localhost:3778/DownloadBeWoService.svc?wsdl

View File

@@ -1,15 +0,0 @@
<Window x:Class="BeWoLauncher.LauncherWindow"
x:ClassModifier="public"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
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:BeWoLauncher"
mc:Ignorable="d"
Title="BeWoLauncher" Height="1080" Width="1920" WindowStartupLocation="CenterScreen" WindowState="Maximized" BorderThickness="1" Closing="MainWindow_OnClosing"
Background="{StaticResource LoginBackground}" KeyDown="Window_KeyDown" KeyUp="Window_KeyUp">
<Grid x:Name="rootGrid2" Margin="0,0,0,0">
<Grid x:Name="rootGrid" SizeChanged="RootGrid_SizeChanged" Margin="0,0,0,0">
</Grid>
</Grid>
</Window>

View File

@@ -1,156 +0,0 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;
using System.Windows.Threading;
using BeWoLauncher.Components;
using BeWoLauncher.Logic.Controller;
namespace BeWoLauncher
{
public partial class LauncherWindow : Window
{
private readonly Stack<Control> _ModalPopUpControls;
private Control _CurrentModalPopUp;
private Grid _ModalPopUpBackGround;
private WaitLayer2 _WaitLayer;
public LauncherWindow()
{
InitializeComponent();
_ModalPopUpControls = new Stack<Control>();
ViewController.InitWindow(this);
ViewController.StartView();
}
private void MainWindow_OnClosing(object s, CancelEventArgs e)
{
ProcessController.StartLauncherShutdown();
}
private void RootGrid_SizeChanged(object sender, SizeChangedEventArgs e)
{
double top = (rootGrid.ActualHeight - 400) / 3;
rootGrid.Margin = new Thickness(0, top, 0, 0);
}
private void ShowModalBackground()
{
_ModalPopUpBackGround = new Grid();
_ModalPopUpBackGround.IsHitTestVisible = true;
_ModalPopUpBackGround.Background = Brushes.White;
_ModalPopUpBackGround.Opacity = .5;
Grid.SetColumnSpan(_ModalPopUpBackGround, 3);
Grid.SetRowSpan(_ModalPopUpBackGround, 3);
rootGrid.Children.Add(_ModalPopUpBackGround);
Panel.SetZIndex(_ModalPopUpBackGround, int.MaxValue - 1);
}
public void ShowControlAsModalPopUp(Control control)
{
ShowControlAsModalPopUp(control, HorizontalAlignment.Center, VerticalAlignment.Center);
}
public void ShowControlAsModalPopUp(Control control, HorizontalAlignment ha, VerticalAlignment va)
{
Dispatcher.BeginInvoke(DispatcherPriority.Normal,
(Action)delegate
{
if (_CurrentModalPopUp != null)
{
rootGrid.Children.Remove(_CurrentModalPopUp);
_ModalPopUpControls.Push(_CurrentModalPopUp);
}
else
{
this.ShowModalBackground();
}
_CurrentModalPopUp = control;
control.HorizontalAlignment = ha;
control.VerticalAlignment = va;
Grid.SetColumnSpan(control, 3);
Grid.SetRowSpan(control, 3);
this.rootGrid.Children.Add(control);
Panel.SetZIndex(control, int.MaxValue);
});
}
public void CloseCurrentPopUp()
{
if (_ModalPopUpBackGround != null)
{
Dispatcher.BeginInvoke(DispatcherPriority.Normal,
(Action)delegate
{
rootGrid.Children.Remove(_CurrentModalPopUp);
_CurrentModalPopUp = null;
if (_ModalPopUpControls.Count == 0)
{
rootGrid.Children.Remove(_ModalPopUpBackGround);
_ModalPopUpBackGround = null;
}
else
{
var control = this._ModalPopUpControls.Pop();
_CurrentModalPopUp = control;
rootGrid.Children.Add(control);
Panel.SetZIndex(control, int.MaxValue);
}
});
}
}
public void StartWaiting()
{
Dispatcher.BeginInvoke(DispatcherPriority.Normal,
(Action)delegate
{
if (_WaitLayer == null)
{
_WaitLayer = new WaitLayer2();
_WaitLayer.HorizontalAlignment = HorizontalAlignment.Center;
_WaitLayer.VerticalAlignment = VerticalAlignment.Center;
rootGrid2.Children.Add(_WaitLayer);
Panel.SetZIndex(_WaitLayer, int.MaxValue);
_WaitLayer.Dispatcher.Invoke(DispatcherPriority.Render, (Action)delegate () { });
}
});
}
public void EndWaiting()
{
Dispatcher.BeginInvoke(
DispatcherPriority.Normal,
(Action)delegate
{
if (_WaitLayer != null)
{
rootGrid2.Children.Remove(_WaitLayer);
_WaitLayer = null;
}
});
}
public void SetMainContent(UserControl main)
{
rootGrid.Children.Clear();
rootGrid.Children.Add(main);
}
private void Window_KeyDown(object sender, System.Windows.Input.KeyEventArgs e)
{
if (e.Key == System.Windows.Input.Key.Delete)
{
ViewController.LaunchBehavior.UninstallMode = true;
}
}
private void Window_KeyUp(object sender, System.Windows.Input.KeyEventArgs e)
{
if (e.Key == System.Windows.Input.Key.Delete)
{
ViewController.LaunchBehavior.UninstallMode = false;
}
}
}
}

View File

@@ -1,88 +0,0 @@
using BeWoLauncher.Components;
using BeWoLauncher.Logic.Controller;
using BeWoLauncher.Logic.Utils;
using BS.SharedLauncher.Extensions;
using BS.SharedLauncher.Information;
using System;
using System.Threading.Tasks;
using static BeWoLauncher.Logic.Controller.ViewController;
namespace BeWoLauncher.Logic.Behavior
{
public class LaunchBehavior
{
public bool UninstallMode { get; set; }
public LaunchBehavior()
{
}
public void LoginSuccessful()
{
#region confirm demo
#if DEBUG
//if (ConnectionInformation.Tenant == "demo")
//{
// var dlg = new ConfirmDemoDialog();
// dlg.ShowDialog();
//}
#else
if (ConnectionInformation.Tenant == "demo")
{
var dlg = new ConfirmDemoDialog();
dlg.ShowDialog();
}
#endif
#endregion
var path = LauncherPaths.GetInstallLocationFromSetting();
LauncherPaths.ActualPlanerLocation = path;
if (path is string && !string.IsNullOrWhiteSpace(path) && !CheckForPermissions(path))
{
ViewBehavior.ShowFrame(FrameType.NoPermissionInfo);
EndWaiting();
}
else
{
if (UninstallMode)
ViewBehavior.ShowUninstallInfo();
else
Task.Run(() =>
{
try
{
DownloadController.Start();
DownloadController.Manager.GetUpdatePlan();
if (!DownloadController.Manager.UpdatePlanResponse.Successful)
throw DownloadController.Manager.UpdatePlanResponse.Exception;
if (DownloadController.Manager.UpdatePlanResponse.HasToDo())
{
ViewBehavior.ShowInfo();
}
else
{
ViewBehavior.ShowLoading();
}
}
catch(Exception ex)
{
ViewBehavior.ShowError(ex);
}
EndWaiting();
});
}
}
public void LaunchPlaner()
{
Task.Run(() => ProcessController.StartPlanerProcess());
}
}
}

View File

@@ -1,168 +0,0 @@
using BeWoLauncher.Logic.Controller;
using BeWoLauncher.Logic.Utils;
using BeWoLauncher.View;
using BeWoLauncher.View.Frames;
using BS.SharedLauncher.Enums;
using System;
using System.IO;
using System.Threading.Tasks;
using System.Windows.Controls;
using System.Windows.Threading;
using static BeWoLauncher.Logic.Controller.ViewController;
namespace BeWoLauncher.Logic.Behavior
{
public class ViewSwitchBehavior
{
private UserControl _currentView;
private FrameBase _currentFrame;
private LauncherMode _currentLauncherMode;
private UserControl CurrentView
{
get => _currentView;
set
{
_currentView = value;
CurrentWindow.Dispatcher.BeginInvoke(DispatcherPriority.Render,
(Action)delegate
{
CurrentWindow.SetMainContent(value);
});
}
}
private FrameBase CurrentFrame
{
get => _currentFrame;
set
{
_currentFrame = value;
if (CurrentView is FrameView frameview)
CurrentWindow.Dispatcher.BeginInvoke(DispatcherPriority.Render,
(Action)delegate
{
frameview.SetFrame(value);
});
else
CurrentView = new FrameView(value);
}
}
public ViewSwitchBehavior()
{
}
public void ShowView(ViewType vt)
{
CurrentView = ViewController.ViewBuilder.GetNewView(vt);
}
public void ShowFrame(FrameType ft)
{
CurrentFrame = ViewController.ViewBuilder.GetNewFrame(ft);
}
public void ShowInfo()
{
ViewController.Dispatcher.BeginInvoke(DispatcherPriority.Normal, new Action(() =>
{
if (LauncherAppdataConfig.GetFirstInstallationSuccess() &&
File.Exists(LauncherPaths.GetPlanerExePath()))
{
ShowFrame(FrameType.UpdateInfo);
}
else
{
ShowFrame(FrameType.InstallInfo);
}
}));
}
public void ShowError(Exception exception)
{
ViewController.Dispatcher.BeginInvoke(DispatcherPriority.Normal, new Action(() =>
{
Error = exception;
ShowFrame(FrameType.GenericFail);
}));
}
public void ShowUninstallInfo()
{
ViewController.Dispatcher.BeginInvoke(DispatcherPriority.Normal, new Action(() =>
{
ShowFrame(FrameType.UninstallInfo);
}));
}
public void ShowLoading()
{
ViewController.Dispatcher.BeginInvoke(DispatcherPriority.Render, new Action(() =>
{
ShowFrame(FrameType.LoadingScreen);
}));
}
public void BackToLogin(object sender, EventArgs e)
{
ShowView(ViewType.LoginView);
}
public void LoginSuccessful(object sender, EventArgs e)
{
ViewController.LaunchBehavior.LoginSuccessful();
}
public void InstallInfoAccept(object sender, EventArgs e)
{
var install = sender as InstallInfoFrame;
if (CheckForPermissions(install.InstallLocation))
{
LauncherPaths.SetAndSaveInstallLocation(install.InstallLocation);
LauncherAppdataConfig.SetFirstInstallationSuccess(true);
ShowFrame(FrameType.InstallProgress);
}
else
{
ShowFrame(FrameType.NoPermissionInfo);
}
}
public void InstallSuccesss(object sender, EventArgs e)
{
LauncherAppdataConfig.SetFirstInstallationSuccess(true);
ShowFrame(FrameType.LoadingScreen);
}
public void InstallFailed(object sender, EventArgs e)
{
ShowFrame(FrameType.InstallFailed);
}
public void UpdateFailed(object sender, EventArgs e)
{
ShowFrame(FrameType.UpdateFailed);
}
public void UninstallFailed(object sender, EventArgs e)
{
ShowFrame(FrameType.UninstallFailed);
}
public void UpdateStarting(object sender, EventArgs e)
{
ShowFrame(FrameType.UpdateProgress);
}
public void UpdateSuccess(object sender, EventArgs e)
{
ShowFrame(FrameType.LoadingScreen);
}
public void UninstallStarting(object sender, EventArgs e)
{
ShowFrame(FrameType.UninstallProgress);
}
public void UninstallSuccess(object sender, EventArgs e)
{
ShowFrame(FrameType.UninstallSuccessful);
}
}
}

View File

@@ -1,35 +0,0 @@
using BeWoLauncher.Logic.Utils;
using BeWoLauncher.Logic.Utils.Download;
using BS.SharedLauncher.Information;
using BS.SharedLauncher.Utils;
using System.IO;
namespace BeWoLauncher.Logic.Controller
{
public static class DownloadController
{
public static DownloadManager Manager { get; set; }
public static long FreeSpace { get; set; }
public static long NeededSpace => Manager.UpdatePlanResponse.DownloadSize;
public static void Start()
{
Manager = new DownloadManager();
DownloadLogger.Init(LauncherPaths.GetLoggerPath());
}
public static string UpdateDiskSpace(string path)
{
FileInfo f = new FileInfo(path);
string drive = System.IO.Path.GetPathRoot(f.FullName);
FreeSpace = NonspecificTools.GetTotalFreeSpace(drive);
if (FreeSpace >= 0)
return NonspecificTools.SizeSuffix((ulong)FreeSpace);
else
return "error";
}
}
}

View File

@@ -1,162 +0,0 @@
using BeWoLauncher.Logic.Utils;
using BeWoLauncher.ServiceProxy;
using BS.SharedLauncher.Information;
using System;
using System.Diagnostics;
using System.IO;
using System.IO.Pipes;
using System.Threading;
using System.Windows;
using System.Windows.Threading;
namespace BeWoLauncher.Logic.Controller
{
public static class ProcessController
{
private static Process PlanerProcess { get; set; }
public static Application Current => Application.Current;
public static LauncherApp CurrentLauncher => Current as LauncherApp;
private static bool PlanerRunning
{
get
{
if (PlanerProcess is null)
return false;
PlanerProcess.Refresh();
return !PlanerProcess.HasExited;
}
}
internal static void CheckForOtherInstance()
{
string procName = Process.GetCurrentProcess().ProcessName;
Process[] processes = Process.GetProcessesByName(procName);
if (processes.Length > 1)
{
MessageBox.Show("BeWo Prozess läuft bereits");
StartLauncherShutdown();
}
Process[] processes2 = Process.GetProcessesByName("BeWoPlaner");
if (processes2.Length > 0)
{
MessageBox.Show("BeWo Prozess läuft bereits");
StartLauncherShutdown();
}
}
internal static void StartLauncher()
{
CheckForOtherInstance();
// Update Server Adresses
//ConnectionInformation.DownloadServerAddress = ConnectionInformation.DownloadServerAddressExact.ToString();
//ConnectionInformation.CoreServerAddress = ConnectionInformation.CoreServerAddress.ToString();
LauncherServiceFacade.UpdateServerAddresses();
}
internal static void StartLauncherShutdown()
{
Current.Shutdown();
}
internal static void StartPlanerProcess()
{
// based on https://docs.microsoft.com/en-us/dotnet/standard/io/how-to-use-anonymous-pipes-for-local-interprocess-communication?redirectedfrom=MSDN
PlanerProcess = new Process();
PlanerProcess.StartInfo.FileName = LauncherPaths.GetPlanerExePath();
PlanerProcess.EnableRaisingEvents = true;
PlanerProcess.Exited += PlanerProcess_Exit;
using (AnonymousPipeServerStream pipeServer = new AnonymousPipeServerStream(PipeDirection.Out, HandleInheritability.Inheritable))
{
PlanerProcess.StartInfo.Arguments = pipeServer.GetClientHandleAsString();
PlanerProcess.StartInfo.UseShellExecute = false;
PlanerProcess.StartInfo.CreateNoWindow = false;
PlanerProcess.StartInfo.RedirectStandardOutput = true;
PlanerProcess.OutputDataReceived += MessageFromPlanerClient;
PlanerProcess.Start();
DownloadLogger.Post2($"Launcher Start: {PlanerProcess.StartInfo.FileName}");
PlanerProcess.BeginOutputReadLine();
pipeServer.DisposeLocalCopyOfClientHandle();
try
{
using (StreamWriter sw = new StreamWriter(pipeServer))
{
var signal = new string[] { "C-137", "C-131" };
sw.AutoFlush = true;
SendInfo(sw, signal[0], pipeServer);
SessionInformation.Connection.ToList().ForEach(info => SendInfo(sw, info, pipeServer));
SessionInformation.Login.ToList().ForEach(info => SendInfo(sw, info, pipeServer));
SessionInformation.Session.ToList().ForEach(info => SendInfo(sw, info, pipeServer));
SendInfo(sw, signal[1], pipeServer);
}
}
catch (IOException ex)
{
}
}
}
internal static void SendInfo(StreamWriter sw, string info, AnonymousPipeServerStream pipe)
{
sw.WriteLine(info);
pipe.WaitForPipeDrain();
}
internal static void KillPlanerProcess()
{
foreach (var process in Process.GetProcesses())
{
if (process.ProcessName.Contains("BeWoPlaner"))
{
process.Kill();
}
}
}
internal static void PlanerProcess_Exit(object sender, EventArgs e)
{
// ExitCode Übersicht:
// 100 - Nutzer hat Logout in Core gedrückt
// 0 - Nutzer hat Fenster geschlossen
// 1 - Proess über TaskManager gekillt
if (PlanerProcess.ExitCode == 100)
{
CurrentLauncher.Dispatcher.BeginInvoke(DispatcherPriority.Render, (Action)delegate
{
Thread.Sleep(500);
ViewController.RestartView();
});
return;
}
CurrentLauncher.Dispatcher.BeginInvoke(DispatcherPriority.Normal, (Action)StartLauncherShutdown);
}
private static void MessageFromPlanerClient(object sender, DataReceivedEventArgs args)
{
var data = args.Data;
if (data == "GUI geladen")
{
ViewController.CurrentWindow.Dispatcher.BeginInvoke(DispatcherPriority.Render, (Action)(() => ViewController.CurrentWindow.Hide()));
}
}
}
}

View File

@@ -1,90 +0,0 @@
using BeWoLauncher.Logic.Behavior;
using BeWoLauncher.Logic.Utils;
using BeWoLauncher.View;
using BeWoLauncher.View.Frames;
using BS.SharedLauncher.Logic;
using System;
using System.Configuration;
using System.IO;
using System.Threading.Tasks;
using System.Windows.Controls;
using System.Windows.Threading;
namespace BeWoLauncher.Logic.Controller
{
public enum ViewType
{
LoginView,
FrameView
}
public enum FrameType
{
InstallInfo,
InstallProgress,
InstallFailed,
UpdateInfo,
UpdateProgress,
UpdateFailed,
UninstallInfo,
UninstallProgress,
UninstallFailed,
UninstallSuccessful,
LoadingScreen,
NoPermissionInfo,
GenericFail
}
public static class ViewController
{
public static Exception Error{ get; set; }
public static LauncherWindow CurrentWindow { get; private set; }
public static Dispatcher Dispatcher => CurrentWindow.Dispatcher;
public static ViewSwitchBehavior ViewBehavior { get; set; }
public static LaunchBehavior LaunchBehavior { get; set; }
public static ViewBuilder ViewBuilder { get; set; }
static ViewController()
{
LaunchBehavior = new LaunchBehavior();
ViewBehavior = new ViewSwitchBehavior();
ViewBuilder = new ViewBuilder();
}
public static void InitWindow(LauncherWindow window)
{
if (CurrentWindow is null)
CurrentWindow = window;
}
public static void StartView()
{
ViewBehavior.ShowView(ViewType.LoginView);
}
public static void RestartView()
{
ViewBehavior.ShowView(ViewType.LoginView);
CurrentWindow.Show();
CurrentWindow.Activate();
}
public static void StartWaiting() => CurrentWindow.StartWaiting();
public static void EndWaiting() => CurrentWindow.EndWaiting();
public static bool CheckForPermissions(string path)
{
return FileController.IsDirectoryWritable(path, false);
}
public static void CheckForAutoLogin(object sender, EventArgs e)
{
var autologin = bool.TryParse(ConfigurationManager.AppSettings.Get("AutoLogin"), out bool c) && c;
if (autologin)
if (sender is LoginView loginPage)
loginPage.ClickLogin();
}
}
}

View File

@@ -1,19 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class BoolNullCheckConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
return value != null;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,24 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class BoolReverseConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value is bool buhl)
{
return !buhl;
}
return false;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,36 +0,0 @@
using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class BoolVisibilityConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value == null)
{
return Visibility.Visible;
}
var lMode = true;
if (parameter is string s)
{
bool.TryParse(s, out lMode);
}
if (lMode)
{
return !(bool)value ? Visibility.Collapsed : Visibility.Visible;
}
return (bool)value ? Visibility.Collapsed : Visibility.Visible;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,36 +0,0 @@
using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class BoolVisibilityHiddenConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value == null)
{
return Visibility.Visible;
}
bool lMode = true;
if (parameter is string)
{
bool.TryParse((string)parameter, out lMode);
}
if (lMode)
{
return (!(bool)value) ? Visibility.Hidden : Visibility.Visible;
}
return ((bool)value) ? Visibility.Hidden : Visibility.Visible;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,21 +0,0 @@
using System;
using System.Globalization;
using System.Linq;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class BoolVisibilityMultiConverter : IMultiValueConverter
{
public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
{
return values.OfType<bool>().All(b => b) ? Visibility.Visible : Visibility.Collapsed;
}
public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,27 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class CollectionCountToBoolConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
try
{
var count = (int) value;
return count > 0;
}
catch (Exception)
{
return false;
}
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,28 +0,0 @@
using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class CollectionCountToVisibilityConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
try
{
var count = (int)value;
return count > 0 ? Visibility.Visible : Visibility.Collapsed;
}
catch (Exception)
{
return Visibility.Collapsed;
}
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,24 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class DataContract2StringConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value == null || ((String)value) == string.Empty)
{
return "nicht angegeben";
}
return value.ToString();
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,34 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class Date2CalendarWeekStringConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (!(value is DateTime))
{
return null;
}
var lDate = (DateTime)value;
var lCal = DateTimeFormatInfo.CurrentInfo.Calendar;
// TODO Wochenbuchung wegmachen :-)
return "Leistungen gleicher Zeit und Dauer in dieser Woche buchen";
// return "Leistungen gleicher Zeit und Dauer in dieser Woche buchen ("
// + lDate.GetLast(DayOfWeek.Monday).ToShortDateString()
// + " - "
// + lDate.GetNext(DayOfWeek.Sunday).ToShortDateString()
// + ")";
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,36 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
[ValueConversion(typeof(DateTime?), typeof(string))]
public class DateConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
string s = string.Empty;
DateTime? lDateTime = (DateTime?)value;
if (lDateTime.HasValue)
{
s = lDateTime.Value.ToShortDateString();
}
return s;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
DateTime temp;
DateTime.TryParse((string)value, out temp);
if (temp != DateTime.MinValue)
{
return temp;
}
else
{
return null;
}
}
}
}

View File

@@ -1,38 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
[ValueConversion(typeof(DateTime?), typeof(string))]
public class DateNullValueToEmptyStringConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
DateTime? dt = System.Convert.ToDateTime(value);
return (dt == null || dt.Value.Millisecond == 123) ? string.Empty : value;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
[ValueConversion(typeof(decimal?), typeof(string))]
public class DecimalNullValueToEmptyStringConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
decimal? dec = System.Convert.ToDecimal(value);
bool empty = value == null || dec == null || dec.Value == (decimal)0.00123;
return empty ? string.Empty : value;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,48 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class DecimalConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value != null)
{
if (string.IsNullOrEmpty(parameter as string))
{
string v = value.ToString();
// nachfolgende nullen entfernen
while (v.Length > 1 && v[v.Length - 1] == '0')
{
v = v.Substring(0, v.Length - 1);
}
if (v.Length > 1 && v[v.Length - 1] == ',')
{
v = v.Substring(0, v.Length - 1);
}
return v;
}
return string.Format((string)parameter, value);
}
return string.Empty;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
if (!string.IsNullOrEmpty((string)value))
{
var t = decimal.Parse((string)value);
return t;
}
return null;
}
}
}

View File

@@ -1,29 +0,0 @@
using System;
using System.ComponentModel;
using System.Globalization;
using System.Linq;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class EnumToDescriptionConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value == null)
return null;
throw new Exception("Hier muss noch was getestet werden");
//var EnVal = value as DevExpress.Xpf.Core.EnumHelper. EnumItem;
//var fi2 = EnVal.Id.GetType().GetField(EnVal.Id.ToString());
//var attrs = (DescriptionAttribute[])fi2.GetCustomAttributes(typeof(DescriptionAttribute), true);
//return !attrs.Any() ? value : attrs[0].Description;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
return value;
}
}
}

View File

@@ -1,63 +0,0 @@
using System;
using System.Collections;
using System.Data;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class IListT2DataTableConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value is IList && value.GetType().IsGenericType)
{
DataTable lResult = new DataTable();
Type lGenericType = value.GetType().GetGenericArguments()[0];
lResult.TableName = lGenericType.FullName;
lResult.Columns.Add("item");
foreach (var iProp in lGenericType.GetProperties())
{
lResult.Columns.Add(iProp.Name);
}
Hashtable lRows2Objects = new Hashtable();
foreach (var iItem in value as IList)
{
var iRow = lResult.NewRow();
iRow["item"] = iItem;
lRows2Objects.Add(iRow, iItem);
foreach (var iProp in lGenericType.GetProperties())
{
iRow[iProp.Name] = iProp.GetValue(iItem, null);
}
lResult.Rows.Add(iRow);
}
lResult.RowChanged += (s, e) =>
{
foreach (var iProp in lGenericType.GetProperties())
{
iProp.SetValue(lRows2Objects[e.Row], e.Row[iProp.Name], null);
}
};
return lResult;
}
return null;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,26 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
[ValueConversion(typeof(int), typeof(bool))]
public class IndexBoolConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
int lIndex = -1;
if (parameter != null && parameter is string)
{
Int32.TryParse(parameter as string, out lIndex);
}
return ((int)value) != lIndex;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,25 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
using System.Windows.Markup;
namespace BeWoLauncher.Converter
{
public class Int2DecimalConverter : IValueConverter
{
#region IValueConverter Members
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
{
return System.Convert.ToDecimal(value);
}
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
{
return System.Convert.ToInt32(value);
}
#endregion
}
}

View File

@@ -1,22 +0,0 @@
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BeWoLauncher.Converter
{
public class NullableBoolToBoolConverter : System.Windows.Data.IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
return false;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,43 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class ObjectBoolConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
bool lFalseIfNull = true;
if (parameter != null || parameter is string)
{
bool.TryParse((string)parameter, out lFalseIfNull);
}
if (value is string)
{
if (lFalseIfNull)
{
return !string.IsNullOrEmpty((string)value);
}
else
{
return string.IsNullOrEmpty((string)value);
}
}
if (lFalseIfNull)
{
return value != null;
}
return value == null;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,44 +0,0 @@
using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class ObjectVisibilityConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
bool lVisibleIfNull = false;
if (parameter != null || parameter is string)
{
bool.TryParse((string)parameter, out lVisibleIfNull);
}
if (value is string)
{
if (lVisibleIfNull)
{
return !string.IsNullOrEmpty((string)value) ? Visibility.Collapsed : Visibility.Visible;
}
else
{
return string.IsNullOrEmpty((string)value) ? Visibility.Collapsed : Visibility.Visible;
}
}
if (lVisibleIfNull)
{
return value != null ? Visibility.Collapsed : Visibility.Visible;
}
return value == null ? Visibility.Collapsed : Visibility.Visible;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,20 +0,0 @@
using System;
using System.Globalization;
using System.Linq;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class OneWayToSourceSwitch : IMultiValueConverter
{
public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture)
{
return targetTypes.Select(t => value).ToArray();
}
}
}

View File

@@ -1,30 +0,0 @@
using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class ReverseValueEqualsParamVisibilityConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (parameter == null || value == null)
{
return Visibility.Visible;
}
if (parameter.Equals(value))
{
return Visibility.Collapsed;
}
return Visibility.Visible;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,22 +0,0 @@
using System;
using System.Globalization;
using System.Windows.Data;
using System.Windows.Media;
namespace BeWoLauncher.Converter
{
public class StringBrushConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
var lColor = value as string;
return lColor == null ? null : new SolidColorBrush((Color) ColorConverter.ConvertFromString(lColor));
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,34 +0,0 @@
using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class StringFormatConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
Object val = String.Empty;
if (value != null && value != DependencyProperty.UnsetValue)
{
val = value;
}
if (parameter is string)
{
return string.Format(parameter as string, value);
}
return value;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,33 +0,0 @@
using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class StringFormatMulitConverter : IMultiValueConverter
{
public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
{
for (int i = 0; i < values.Length; i++)
{
if (values[i] == null || values[i] == DependencyProperty.UnsetValue)
{
values[i] = string.Empty;
}
}
if (parameter is string)
{
return string.Format(parameter as string, values);
}
return values;
}
public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,22 +0,0 @@
using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class StringLengthVisibilityConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if(value == null || value.GetType() != typeof(string) || string.IsNullOrWhiteSpace(value.ToString()))
{
return Visibility.Collapsed;
}
return Visibility.Visible;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) => throw new NotImplementedException();
}
}

View File

@@ -1,23 +0,0 @@
using System;
using System.Globalization;
using System.Linq;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class StringLengthVisibilityMultiConverter : IMultiValueConverter
{
public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
{
if(values == null || values.Length < 2 || values.Any(a => string.IsNullOrWhiteSpace(a?.ToString())))
{
return Visibility.Collapsed;
}
return Visibility.Visible;
}
public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture) => throw new NotImplementedException();
}
}

View File

@@ -1,30 +0,0 @@
using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
namespace BeWoLauncher.Converter
{
public class ValueEqualsParamVisibilityConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (parameter == null || value == null)
{
return Visibility.Collapsed;
}
if (parameter.Equals(value))
{
return Visibility.Visible;
}
return Visibility.Collapsed;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotImplementedException();
}
}
}

View File

@@ -1,28 +0,0 @@
using System;
using System.ServiceModel.Channels;
using System.ServiceModel.Description;
using System.ServiceModel.Dispatcher;
namespace BeWoLauncher.Multitenancy
{
public class MultitenancyEndpointBehavior : IEndpointBehavior
{
public void AddBindingParameters(ServiceEndpoint endpoint, BindingParameterCollection bindingParameters)
{
}
public void ApplyClientBehavior(ServiceEndpoint endpoint, ClientRuntime clientRuntime)
{
clientRuntime.MessageInspectors.Add(new MultitenancyInterceptor());
}
public void ApplyDispatchBehavior(ServiceEndpoint endpoint, EndpointDispatcher endpointDispatcher)
{
throw new NotImplementedException("This is a client behavior only");
}
public void Validate(ServiceEndpoint endpoint)
{
}
}
}

View File

@@ -1,39 +0,0 @@
using System.ServiceModel.Channels;
using System.Xml;
namespace BeWoLauncher.Multitenancy
{
public class MultitenancyHeader : MessageHeader
{
public override bool MustUnderstand
{
get
{
return false;
}
}
public override string Name
{
get
{
return "Multitenancy";
}
}
public override string Namespace
{
get
{
return "http://beyondsoft.de/Multitenancy.xsd";
}
}
public string Tenant { get; set; }
protected override void OnWriteHeaderContents(XmlDictionaryWriter writer, MessageVersion messageVersion)
{
writer.WriteElementString("Tenant", this.Tenant);
}
}
}

View File

@@ -1,21 +0,0 @@
using BS.SharedLauncher;
using BS.SharedLauncher.Information;
using System.ServiceModel;
using System.ServiceModel.Channels;
using System.ServiceModel.Dispatcher;
namespace BeWoLauncher.Multitenancy
{
public class MultitenancyInterceptor : IClientMessageInspector
{
public void AfterReceiveReply(ref Message reply, object correlationState)
{
}
public object BeforeSendRequest(ref Message request, IClientChannel channel)
{
request.Headers.Add(new MultitenancyHeader { Tenant = SessionInformation.Login.Tenant });
return null;
}
}
}

View File

@@ -1,75 +0,0 @@
using System.ServiceModel.Channels;
using System.Xml;
namespace BeWoLauncher.Security
{
// TODO: Make it namespace-conform (type Attributes, prefixes, etc)
// ns:
public class LauncherSecurityHeader : MessageHeader
{
private string mPassword;
private string mUsername;
public override bool MustUnderstand
{
get
{
return false;
}
}
public override string Name
{
get
{
return "Security";
}
}
public override string Namespace
{
get
{
return "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd";
}
}
public string Password
{
get
{
return this.mPassword;
}
set
{
this.mPassword = value;
}
}
public string Username
{
get
{
return this.mUsername;
}
set
{
this.mUsername = value;
}
}
protected override void OnWriteHeaderContents(XmlDictionaryWriter writer, MessageVersion messageVersion)
{
writer.WriteStartElement("UsernameToken");
writer.WriteElementString("Username", this.mUsername);
writer.WriteStartElement("Password");
writer.WriteAttributeString("Type", "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText");
writer.WriteValue(this.mPassword);
writer.WriteEndElement();
writer.WriteEndElement();
}
}
}

View File

@@ -1,28 +0,0 @@
using System;
using System.ServiceModel.Channels;
using System.ServiceModel.Description;
using System.ServiceModel.Dispatcher;
namespace BeWoLauncher.Security
{
public class LauncherSecurityHeaderEndpointBehavior : IEndpointBehavior
{
public void AddBindingParameters(ServiceEndpoint endpoint, BindingParameterCollection bindingParameters)
{
}
public void ApplyClientBehavior(ServiceEndpoint endpoint, ClientRuntime clientRuntime)
{
clientRuntime.MessageInspectors.Add(new LauncherSecurityHeaderInterceptor());
}
public void ApplyDispatchBehavior(ServiceEndpoint endpoint, EndpointDispatcher endpointDispatcher)
{
throw new NotImplementedException("This is a client behavior only");
}
public void Validate(ServiceEndpoint endpoint)
{
}
}
}

View File

@@ -1,22 +0,0 @@
using BeWoLauncher;
using BS.SharedLauncher;
using BS.SharedLauncher.Information;
using System.ServiceModel;
using System.ServiceModel.Channels;
using System.ServiceModel.Dispatcher;
namespace BeWoLauncher.Security
{
public class LauncherSecurityHeaderInterceptor : IClientMessageInspector
{
public void AfterReceiveReply(ref Message reply, object correlationState)
{
}
public object BeforeSendRequest(ref Message request, IClientChannel channel)
{
request.Headers.Add(new LauncherSecurityHeader { Username = SessionInformation.Login.Username, Password = SessionInformation.Login.Password });
return null;
}
}
}

View File

@@ -1,403 +0,0 @@
//------------------------------------------------------------------------------
// <auto-generated>
// Dieser Code wurde von einem Tool generiert.
// Laufzeitversion:4.0.30319.42000
//
// Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
// der Code erneut generiert wird.
// </auto-generated>
//------------------------------------------------------------------------------
namespace BeWoLauncher.ServiceProxy
{
using System.Runtime.Serialization;
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
[System.Runtime.Serialization.DataContractAttribute(Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
public partial class BeWoFault : object, System.Runtime.Serialization.IExtensibleDataObject, System.ComponentModel.INotifyPropertyChanged
{
private System.Runtime.Serialization.ExtensionDataObject extensionDataField;
private BeWoLauncher.ServiceProxy.BeWoFaultType FaultTypeField;
private string InnerExceptionMessageField;
private string InnerExceptionStackTraceField;
private string MessageField;
private string StackTraceField;
public System.Runtime.Serialization.ExtensionDataObject ExtensionData
{
get
{
return this.extensionDataField;
}
set
{
this.extensionDataField = value;
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public BeWoLauncher.ServiceProxy.BeWoFaultType FaultType
{
get
{
return this.FaultTypeField;
}
set
{
if ((this.FaultTypeField.Equals(value) != true))
{
this.FaultTypeField = value;
this.RaisePropertyChanged("FaultType");
}
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public string InnerExceptionMessage
{
get
{
return this.InnerExceptionMessageField;
}
set
{
if ((object.ReferenceEquals(this.InnerExceptionMessageField, value) != true))
{
this.InnerExceptionMessageField = value;
this.RaisePropertyChanged("InnerExceptionMessage");
}
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public string InnerExceptionStackTrace
{
get
{
return this.InnerExceptionStackTraceField;
}
set
{
if ((object.ReferenceEquals(this.InnerExceptionStackTraceField, value) != true))
{
this.InnerExceptionStackTraceField = value;
this.RaisePropertyChanged("InnerExceptionStackTrace");
}
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public string Message
{
get
{
return this.MessageField;
}
set
{
if ((object.ReferenceEquals(this.MessageField, value) != true))
{
this.MessageField = value;
this.RaisePropertyChanged("Message");
}
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public string StackTrace
{
get
{
return this.StackTraceField;
}
set
{
if ((object.ReferenceEquals(this.StackTraceField, value) != true))
{
this.StackTraceField = value;
this.RaisePropertyChanged("StackTrace");
}
}
}
public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;
protected void RaisePropertyChanged(string propertyName)
{
System.ComponentModel.PropertyChangedEventHandler propertyChanged = this.PropertyChanged;
if ((propertyChanged != null))
{
propertyChanged(this, new System.ComponentModel.PropertyChangedEventArgs(propertyName));
}
}
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
[System.Runtime.Serialization.DataContractAttribute(Name = "BeWoFaultType", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
public enum BeWoFaultType : int
{
[System.Runtime.Serialization.EnumMemberAttribute()]
Unknown = 0,
[System.Runtime.Serialization.EnumMemberAttribute()]
Concurrency = 1,
[System.Runtime.Serialization.EnumMemberAttribute()]
DeleteNotPossible = 2,
[System.Runtime.Serialization.EnumMemberAttribute()]
LoginNameTaken = 3,
[System.Runtime.Serialization.EnumMemberAttribute()]
CustomWithoutDetails = 4,
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
[System.ServiceModel.ServiceContractAttribute(ConfigurationName = "BeWoLauncher.ServiceProxy.ILauncherService")]
public interface ILauncherService
{
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/ILauncherService/IsUserValid", ReplyAction = "http://tempuri.org/ILauncherService/IsUserValidResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/ILauncherService/IsUserValidBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.Enums.UserValidationResult IsUserValid(string pUserName, string pPassword, string pPIN, string clientId, bool checkTenant);
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/ILauncherService/ResetTenant", ReplyAction = "http://tempuri.org/ILauncherService/ResetTenantResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/ILauncherService/ResetTenantBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
void ResetTenant(string tenant);
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/ILauncherService/ResetAllTenant", ReplyAction = "http://tempuri.org/ILauncherService/ResetAllTenantResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/ILauncherService/ResetAllTenantBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
void ResetAllTenant();
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/ILauncherService/GetEmailForUserName", ReplyAction = "http://tempuri.org/ILauncherService/GetEmailForUserNameResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/ILauncherService/GetEmailForUserNameBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
bool GetEmailForUserName(out string email, string pUserName, System.Uri serverName);
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/ILauncherService/CheckPassword", ReplyAction = "http://tempuri.org/ILauncherService/CheckPasswordResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/ILauncherService/CheckPasswordBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.Enums.PasswordValidationResult CheckPassword(long userOid, string pOldPassword, string pNewPassword);
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/ILauncherService/CheckPassword2", ReplyAction = "http://tempuri.org/ILauncherService/CheckPassword2Response")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/ILauncherService/CheckPassword2BeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.Enums.PasswordValidationResult CheckPassword2(string username, string pOldPassword, string pNewPassword);
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/ILauncherService/ChangePassword", ReplyAction = "http://tempuri.org/ILauncherService/ChangePasswordResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/ILauncherService/ChangePasswordBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
long ChangePassword(string pUserName, string pOldPassword, string pNewPassword);
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/ILauncherService/ResetPasswordInfo", ReplyAction = "http://tempuri.org/ILauncherService/ResetPasswordInfoResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/ILauncherService/ResetPasswordInfoBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
void ResetPasswordInfo(string pUserName, string pPassword);
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public interface ILauncherServiceChannel : BeWoLauncher.ServiceProxy.ILauncherService, System.ServiceModel.IClientChannel
{
}
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public partial class LauncherServiceClient : System.ServiceModel.ClientBase<BeWoLauncher.ServiceProxy.ILauncherService>, BeWoLauncher.ServiceProxy.ILauncherService
{
public LauncherServiceClient()
{
}
public LauncherServiceClient(string endpointConfigurationName) :
base(endpointConfigurationName)
{
}
public LauncherServiceClient(string endpointConfigurationName, string remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public LauncherServiceClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public LauncherServiceClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) :
base(binding, remoteAddress)
{
}
public BS.SharedLauncher.Enums.UserValidationResult IsUserValid(string pUserName, string pPassword, string pPIN, string clientId, bool checkTenant)
{
return base.Channel.IsUserValid(pUserName, pPassword, pPIN, clientId, checkTenant);
}
public void ResetTenant(string tenant)
{
base.Channel.ResetTenant(tenant);
}
public void ResetAllTenant()
{
base.Channel.ResetAllTenant();
}
public bool GetEmailForUserName(out string email, string pUserName, System.Uri serverName)
{
return base.Channel.GetEmailForUserName(out email, pUserName, serverName);
}
public BS.SharedLauncher.Enums.PasswordValidationResult CheckPassword(long userOid, string pOldPassword, string pNewPassword)
{
return base.Channel.CheckPassword(userOid, pOldPassword, pNewPassword);
}
public BS.SharedLauncher.Enums.PasswordValidationResult CheckPassword2(string username, string pOldPassword, string pNewPassword)
{
return base.Channel.CheckPassword2(username, pOldPassword, pNewPassword);
}
public long ChangePassword(string pUserName, string pOldPassword, string pNewPassword)
{
return base.Channel.ChangePassword(pUserName, pOldPassword, pNewPassword);
}
public void ResetPasswordInfo(string pUserName, string pPassword)
{
base.Channel.ResetPasswordInfo(pUserName, pPassword);
}
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
[System.ServiceModel.ServiceContractAttribute(ConfigurationName = "BeWoLauncher.ServiceProxy.IEnumTranslationService")]
public interface IEnumTranslationService
{
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/IEnumTranslationService/GetTranslation", ReplyAction = "http://tempuri.org/IEnumTranslationService/GetTranslationResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/IEnumTranslationService/GetTranslationBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
string GetTranslation(string e, short value);
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public interface IEnumTranslationServiceChannel : BeWoLauncher.ServiceProxy.IEnumTranslationService, System.ServiceModel.IClientChannel
{
}
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public partial class EnumTranslationServiceClient : System.ServiceModel.ClientBase<BeWoLauncher.ServiceProxy.IEnumTranslationService>, BeWoLauncher.ServiceProxy.IEnumTranslationService
{
public EnumTranslationServiceClient()
{
}
public EnumTranslationServiceClient(string endpointConfigurationName) :
base(endpointConfigurationName)
{
}
public EnumTranslationServiceClient(string endpointConfigurationName, string remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public EnumTranslationServiceClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public EnumTranslationServiceClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) :
base(binding, remoteAddress)
{
}
public string GetTranslation(string e, short value)
{
return base.Channel.GetTranslation(e, value);
}
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
[System.ServiceModel.ServiceContractAttribute(ConfigurationName = "BeWoLauncher.ServiceProxy.IDownloadBeWoService")]
public interface IDownloadBeWoService
{
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/IDownloadBeWoService/Download2", ReplyAction = "http://tempuri.org/IDownloadBeWoService/Download2Response")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/IDownloadBeWoService/Download2BeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.DataContract.UpdateFileResponse Download2(BS.SharedLauncher.DataContract.UpdatePlanRequest request);
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/IDownloadBeWoService/DownloadInfo", ReplyAction = "http://tempuri.org/IDownloadBeWoService/DownloadInfoResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/IDownloadBeWoService/DownloadInfoBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.DataContract.UpdatePlanResponse DownloadInfo(BS.SharedLauncher.DataContract.UpdatePlanRequest request);
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/IDownloadBeWoService/GetUpdatePlan", ReplyAction = "http://tempuri.org/IDownloadBeWoService/GetUpdatePlanResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/IDownloadBeWoService/GetUpdatePlanBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.DataContract.UpdatePlanResponse GetUpdatePlan(BS.SharedLauncher.DataContract.UpdatePlanRequest request);
[System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/IDownloadBeWoService/GetUpdateFile", ReplyAction = "http://tempuri.org/IDownloadBeWoService/GetUpdateFileResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action = "http://tempuri.org/IDownloadBeWoService/GetUpdateFileBeWoFaultFault", Name = "BeWoFault", Namespace = "http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.DataContract.UpdateFileResponse GetUpdateFile(BS.SharedLauncher.DataContract.UpdateFileRequest request);
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public interface IDownloadBeWoServiceChannel : BeWoLauncher.ServiceProxy.IDownloadBeWoService, System.ServiceModel.IClientChannel
{
}
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public partial class DownloadBeWoServiceClient : System.ServiceModel.ClientBase<BeWoLauncher.ServiceProxy.IDownloadBeWoService>, BeWoLauncher.ServiceProxy.IDownloadBeWoService
{
public DownloadBeWoServiceClient()
{
}
public DownloadBeWoServiceClient(string endpointConfigurationName) :
base(endpointConfigurationName)
{
}
public DownloadBeWoServiceClient(string endpointConfigurationName, string remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public DownloadBeWoServiceClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public DownloadBeWoServiceClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) :
base(binding, remoteAddress)
{
}
public BS.SharedLauncher.DataContract.UpdateFileResponse Download2(BS.SharedLauncher.DataContract.UpdatePlanRequest request)
{
return base.Channel.Download2(request);
}
public BS.SharedLauncher.DataContract.UpdatePlanResponse DownloadInfo(BS.SharedLauncher.DataContract.UpdatePlanRequest request)
{
return base.Channel.DownloadInfo(request);
}
public BS.SharedLauncher.DataContract.UpdatePlanResponse GetUpdatePlan(BS.SharedLauncher.DataContract.UpdatePlanRequest request)
{
return base.Channel.GetUpdatePlan(request);
}
public BS.SharedLauncher.DataContract.UpdateFileResponse GetUpdateFile(BS.SharedLauncher.DataContract.UpdateFileRequest request)
{
return base.Channel.GetUpdateFile(request);
}
}
}

View File

@@ -1,500 +0,0 @@
using BeWoLauncher.Multitenancy;
using BeWoLauncher.Security;
using BS.SharedLauncher.Information;
using System;
using System.Collections.Generic;
using System.ServiceModel;
using System.Threading;
using System.Windows;
namespace BeWoLauncher.ServiceProxy
{
public static class LauncherServiceFacade
{
public static object _Lock = string.Empty;
private static Dictionary<Type, EndpointAddress> _EndpointAddresses;
private static readonly Dictionary<Type, object> _ProxyCache;
private static readonly int _RunningAsyncs;
public static void UpdateServerAddresses()
{
var download = SessionInformation.Connection.DownloadServerAddressExact;
var core = SessionInformation.Connection.CoreServerAddressExact;
if (download.Substring(download.Length - 1, 1) != "/")
download += "/";
if (core.Substring(core.Length - 1, 1) != "/")
core += "/";
_EndpointAddresses = new Dictionary<Type, EndpointAddress>
{
{ typeof(ILauncherService), new EndpointAddress(core + "LauncherService.svc") },
{ typeof(IEnumTranslationService), new EndpointAddress(core + "EnumTranslationService.svc") },
{ typeof(IDownloadBeWoService), new EndpointAddress(download + "DownloadBeWoService.svc") }
};
}
static LauncherServiceFacade()
{
_ProxyCache = new Dictionary<Type, object>();
}
#region Launcher
public static void DoLauncherServiceSync(Action<ILauncherService> pAction)
{
try
{
pAction.Invoke(GetInstance<LauncherServiceClient, ILauncherService>());
}
catch (Exception e)
{
// if (HandleServiceProxyException(e))
// throw e;
ShowErrorMessage(e);
}
}
public static T DoLauncherServiceSync<T>(Func<ILauncherService, T> pFunc)
{
try
{
return pFunc.Invoke(GetInstance<LauncherServiceClient, ILauncherService>());
}
catch (Exception e)
{
ShowErrorMessage(e);
}
return default(T);
}
public static void DoLauncherServiceAsync<T>(Func<ILauncherService, T> pFunc, Action<T> pCallBack)
{
DoAsync<LauncherServiceClient, ILauncherService, T>(pFunc, pCallBack, true);
}
public static void DoLauncherServiceAsync<T>(Func<ILauncherService, T> pFunc, Action<T> pCallBack, bool showWaitDialog)
{
DoAsync<LauncherServiceClient, ILauncherService, T>(pFunc, pCallBack, showWaitDialog);
}
public static void DoLauncherServiceAsync(Action<ILauncherService> pAction)
{
DoAsync<LauncherServiceClient, ILauncherService>(pAction, true);
}
public static void DoLauncherServiceAsync(Action<ILauncherService> pAction, Action pCallBack)
{
DoAsync<LauncherServiceClient, ILauncherService>(pAction, pCallBack, true);
}
public static void DoMultipleLauncherServicesAsync(List<Action<ILauncherService>> pActions, Action pAllDoneCallBack)
{
DoMulitpleAsync<LauncherServiceClient, ILauncherService>(pActions, pAllDoneCallBack, true);
}
public static void DoMultipleLauncherServicesSync(List<Action<ILauncherService>> pActions)
{
DoMulitpleSync<LauncherServiceClient, ILauncherService>(pActions, true);
}
#endregion
#region EnumTranslation
public static void DoEnumTranslationServiceSync(Action<IEnumTranslationService> pAction)
{
try
{
pAction.Invoke(GetInstance<EnumTranslationServiceClient, IEnumTranslationService>());
}
catch (Exception e)
{
// if (HandleServiceProxyException(e))
// throw e;
ShowErrorMessage(e);
}
}
public static T DoEnumTranslationServiceSync<T>(Func<IEnumTranslationService, T> pFunc)
{
try
{
return pFunc.Invoke(GetInstance<EnumTranslationServiceClient, IEnumTranslationService>());
}
catch (Exception e)
{
ShowErrorMessage(e);
}
return default(T);
}
public static void DoEnumTranslationServiceAsync<T>(Func<IEnumTranslationService, T> pFunc, Action<T> pCallBack)
{
DoAsync<EnumTranslationServiceClient, IEnumTranslationService, T>(pFunc, pCallBack, true);
}
public static void DoEnumTranslationServiceAsync<T>(Func<IEnumTranslationService, T> pFunc, Action<T> pCallBack, bool showWaitDialog)
{
DoAsync<EnumTranslationServiceClient, IEnumTranslationService, T>(pFunc, pCallBack, showWaitDialog);
}
public static void DoEnumTranslationServiceAsync(Action<IEnumTranslationService> pAction)
{
DoAsync<EnumTranslationServiceClient, IEnumTranslationService>(pAction, true);
}
public static void DoEnumTranslationServiceAsync(Action<IEnumTranslationService> pAction, Action pCallBack)
{
DoAsync<EnumTranslationServiceClient, IEnumTranslationService>(pAction, pCallBack, true);
}
public static void DoMultipleEnumTranslationServicesAsync(List<Action<IEnumTranslationService>> pActions, Action pAllDoneCallBack)
{
DoMulitpleAsync<EnumTranslationServiceClient, IEnumTranslationService>(pActions, pAllDoneCallBack, true);
}
public static void DoMultipleEnumTranslationServicesSync(List<Action<IEnumTranslationService>> pActions)
{
DoMulitpleSync<EnumTranslationServiceClient, IEnumTranslationService>(pActions, true);
}
#endregion
#region DownloadBeWo
public static void DoDownloadBeWoServiceSync(Action<IDownloadBeWoService> pAction)
{
try
{
pAction.Invoke(GetInstance<DownloadBeWoServiceClient, IDownloadBeWoService>());
}
catch (Exception e)
{
// if (HandleServiceProxyException(e))
// throw e;
ShowErrorMessage(e);
}
}
public static T DoDownloadBeWoServiceSyncWithException<T>(Func<IDownloadBeWoService, T> pFunc)
{
try
{
return pFunc.Invoke(GetInstance<DownloadBeWoServiceClient, IDownloadBeWoService>());
}
catch (Exception e)
{
throw e;
}
return default(T);
}
public static T DoDownloadBeWoServiceSync<T>(Func<IDownloadBeWoService, T> pFunc)
{
try
{
return pFunc.Invoke(GetInstance<DownloadBeWoServiceClient, IDownloadBeWoService>());
}
catch (Exception e)
{
ShowErrorMessage(e);
}
return default(T);
}
public static void DoDownloadBeWoServiceAsync<T>(Func<IDownloadBeWoService, T> pFunc, Action<T> pCallBack)
{
DoAsync<DownloadBeWoServiceClient, IDownloadBeWoService, T>(pFunc, pCallBack, true);
}
public static void DoDownloadBeWoServiceAsync<T>(Func<IDownloadBeWoService, T> pFunc, Action<T> pCallBack, bool showWaitDialog)
{
DoAsync<DownloadBeWoServiceClient, IDownloadBeWoService, T>(pFunc, pCallBack, showWaitDialog);
}
public static void DoDownloadBeWoServiceAsync(Action<IDownloadBeWoService> pAction)
{
DoAsync<DownloadBeWoServiceClient, IDownloadBeWoService>(pAction, true);
}
public static void DoDownloadBeWoServiceAsync(Action<IDownloadBeWoService> pAction, Action pCallBack)
{
DoAsync<DownloadBeWoServiceClient, IDownloadBeWoService>(pAction, pCallBack, true);
}
#endregion
private static void DoAsync<TClient, TInterface, T>(Func<TInterface, T> pFunc, Action<T> pCallback, bool showWaitDialog)
where TClient : ClientBase<TInterface>, TInterface, new()
where TInterface : class
{
DoAsync<TClient, TInterface, T>(pFunc, pCallback, null, showWaitDialog);
}
private static void DoAsync<TClient, TInterface, T>(Func<TInterface, T> pFunc, Action<T> pCallback, Action pErrorCallback, bool showWaitDialog)
where TClient : ClientBase<TInterface>, TInterface, new()
where TInterface : class
{
try
{
if (showWaitDialog)
{
StartWaiting();
}
pFunc.BeginInvoke(
GetInstance<TClient, TInterface>(),
cb =>
{
try
{
T lResult = pFunc.EndInvoke(cb);
if (pCallback != null)
{
pCallback(lResult);
}
if (showWaitDialog)
{
EndWaiting();
}
}
catch (Exception e)
{
// bool lThrow = ShowErrorMessage(e);
// if (showWaitDialog) EndWaiting();
// if (lThrow)
// throw e;
if (showWaitDialog)
{
EndWaiting();
}
ShowErrorMessage(e);
if (pErrorCallback != null)
{
pErrorCallback();
}
}
},
null);
}
catch (Exception e)
{
// bool lThrow = ShowErrorMessage(e);
// if (showWaitDialog) EndWaiting();
// if (lThrow)
// throw e;
if (showWaitDialog)
{
EndWaiting();
}
ShowErrorMessage(e);
}
}
private static void DoAsync<TClient, TInterface>(Action<TInterface> pAction, bool showWaitDialog)
where TClient : ClientBase<TInterface>, TInterface, new()
where TInterface : class
{
DoAsync<TClient, TInterface>(pAction, null, showWaitDialog);
}
private static void DoAsync<TClient, TInterface>(Action<TInterface> pAction, Action pCallback, bool showWaitDialog)
where TClient : ClientBase<TInterface>, TInterface, new()
where TInterface : class
{
try
{
if (showWaitDialog)
{
StartWaiting();
}
pAction.BeginInvoke(
GetInstance<TClient, TInterface>(),
cb =>
{
try
{
pAction.EndInvoke(cb);
if (pCallback != null)
{
pCallback();
}
if (showWaitDialog)
{
EndWaiting();
}
}
catch (Exception e)
{
// bool lThrow = ShowErrorMessage(e);
// if (showWaitDialog) EndWaiting();
// if (lThrow)
// throw e;
if (showWaitDialog)
{
EndWaiting();
}
ShowErrorMessage(e);
}
},
null);
}
catch (Exception e)
{
// bool lThrow = ShowErrorMessage(e);
// if (showWaitDialog) EndWaiting();
// if (lThrow)
// throw e;
if (showWaitDialog)
{
EndWaiting();
}
ShowErrorMessage(e);
}
}
private static void DoMulitpleSync<TClient, TInterface>(List<Action<TInterface>> pActions, bool showWaitDialog)
where TClient : ClientBase<TInterface>, TInterface, new()
where TInterface : class
{
int lCount = pActions.Count;
if (showWaitDialog)
{
StartWaiting();
}
foreach (var iAction in pActions)
{
iAction.Invoke(GetInstance<TClient, TInterface>());
}
if (showWaitDialog)
{
EndWaiting();
}
}
private static void DoMulitpleAsync<TClient, TInterface>(List<Action<TInterface>> pActions, Action pAllDoneCallBack, bool showWaitDialog)
where TClient : ClientBase<TInterface>, TInterface, new()
where TInterface : class
{
int lCount = pActions.Count;
if (lCount == 0)
{
pAllDoneCallBack();
}
foreach (var iAction in pActions)
{
DoAsync<TClient, TInterface>(
iAction,
delegate
{
Monitor.Enter(_Lock);
lCount--;
Monitor.Exit(_Lock);
if (lCount == 0)
{
pAllDoneCallBack();
}
},
showWaitDialog);
}
}
private static TInterface GetInstance<TClient, TInterface>()
where TClient : ClientBase<TInterface>, TInterface, new()
where TInterface : class
{
TClient lClient = null;
if (_ProxyCache.ContainsKey(typeof(TClient)))
{
lClient = (TClient)_ProxyCache[typeof(TClient)];
if (lClient.State == CommunicationState.Closing || lClient.State == CommunicationState.Closed || lClient.State == CommunicationState.Faulted)
{
if (lClient.State == CommunicationState.Faulted)
{
lClient.Abort();
}
lClient = null;
_ProxyCache.Remove(typeof(TClient));
}
}
if (lClient != null)
{// EndpointAddresses aktualisieren
if (!lClient.Endpoint.Address.Equals(_EndpointAddresses[typeof(TInterface)]))
{
if (lClient.State == CommunicationState.Opened)
lClient.Close();
if (_ProxyCache.ContainsKey(typeof(TClient)))
_ProxyCache.Remove(typeof(TClient));
lClient = null;
}
}
if (lClient == null)
{
lClient = new TClient();
if (!_ProxyCache.ContainsKey(lClient.GetType()))
{
_ProxyCache.Add(typeof(TClient), lClient);
}
lClient.Endpoint.Behaviors.Add(new LauncherSecurityHeaderEndpointBehavior());
lClient.Endpoint.Behaviors.Add(new MultitenancyEndpointBehavior());
lClient.Endpoint.Address = _EndpointAddresses[typeof(TInterface)];
}
return lClient;
}
private static void ShowErrorMessage(Exception e)
{
if (e is FaultException<BeWoFault>)
{
var lBeWoFault = (e as FaultException<BeWoFault>).Detail;
String rowUpdated = "Der Datensatz wurde in der Zwischenzeit von einem anderen Benutzer geändert. Ihre Änderungen konnten leider NICHT gespeichert werden. Das Problem tritt auf, wenn mehrere Benutzer gleichzeitig den gleichen Datensatz bearbeiten.\n\nSie müssen den Datensatz schließen und erneut öffnen, um die Änderungen vornehmen zu können.";
switch (lBeWoFault.FaultType)
{
case BeWoFaultType.Concurrency:
LauncherApp.ShowError(rowUpdated, e, false);
break;
case BeWoFaultType.DeleteNotPossible:
MessageBox.Show(lBeWoFault.Message, "Fehler", MessageBoxButton.OK, MessageBoxImage.Asterisk);
break;
case BeWoFaultType.LoginNameTaken:
MessageBox.Show(lBeWoFault.Message, "Warnung", MessageBoxButton.OK, MessageBoxImage.Asterisk);
return;
case BeWoFaultType.CustomWithoutDetails:
LauncherApp.ShowError(lBeWoFault.Message, e, false);
break;
default:
if (!string.IsNullOrEmpty(e.Message) && e.Message.IndexOf("Row was updated or deleted by another transaction") >= 0)
{
LauncherApp.ShowError(rowUpdated, e, false);
}
else
{
if (!string.IsNullOrEmpty(lBeWoFault.Message))
{
LauncherApp.ShowError(lBeWoFault.Message, e, true);
}
else
{
LauncherApp.ShowError(null, e, true);
}
}
break;
}
}
else
{
LauncherApp.ShowError(null, e, true);
}
}
private static void StartWaiting()
{
//Monitor.Enter(_Lock);
//if ((++_RunningAsyncs) == 1)
//{
// LauncherApp.Window.StartWaiting();
//}
//Monitor.Exit(_Lock);
}
private static void EndWaiting()
{
//Monitor.Enter(_Lock);
//if ((--_RunningAsyncs) == 0)
//{
// LauncherApp.Window.EndWaiting();
//}
//Monitor.Exit(_Lock);
}
}
}

View File

@@ -1,212 +0,0 @@
using BeWoLauncher.ServiceProxy;
using BS.SharedLauncher;
using BS.SharedLauncher.DataContract;
using BS.SharedLauncher.Enums;
using BS.SharedLauncher.Exceptions;
using BS.SharedLauncher.Extensions;
using BS.SharedLauncher.Information;
using BS.SharedLauncher.Logic;
using BS.SharedLauncher.Update;
using BS.SharedLauncher.Utils;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.IO;
using System.IO.Compression;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows;
using System.Xml.Serialization;
namespace BeWoLauncher.Logic.Utils.Download
{
public class DownloadManager
{
public UpdatePlanRequest UpdatePlanRequest { get; set; }
public UpdatePlanResponse UpdatePlanResponse { get; set; }
public string RootFolder => LauncherPaths.GetRootPath();
public string DownloadFolder => LauncherPaths.GetDownloadPath();
public string ApplyFolder => LauncherPaths.GetApplyPath();
public bool SkipLock { get; set; }
public Action<int, object> Feedback { get; set; }
public int FilesToDownloadCount => UpdatePlanResponse.FilesToRequest?.Count ?? 0;
public int FilesToApplyCount => FilesToDownloadCount + (UpdatePlanResponse.FilesToApply?.Count ?? 0);
public int FilesToDeleteInApplyCount => UpdatePlanResponse.FilesToDeleteInApply?.Count ?? 0;
public int FilesToProcessTotal => FilesToDownloadCount + FilesToApplyCount + FilesToDeleteInApplyCount;
public DownloadManager()
{
}
public void GetUpdatePlan()
{
CreateUpdatePlanRequest();
GetUpdatePlanResponse();
SessionInformation.Session.Version = UpdatePlanResponse.CurrentPackage.Version;
}
public void StartProcess(BackgroundWorker worker)
{
var report = new Action<LauncherProgress, int>((progress, waitms) =>
{
worker.ReportProgress((int)progress);
Thread.Sleep(waitms);
});
report(LauncherProgress.ProgressStart, 1000);
if (FilesToDownloadCount > 0)
{
report(LauncherProgress.DownloadStart, 500);
Download();
report(LauncherProgress.DownloadFinish, 1000);
}
if (FilesToApplyCount > 0)
{
report(LauncherProgress.ApplyStart, 500);
Apply();
report(LauncherProgress.ApplyFinished, 1000);
}
if (FilesToDeleteInApplyCount > 0)
{
report(LauncherProgress.DeleteStart, 500);
Delete();
report(LauncherProgress.DeleteFinished, 1000);
}
report(LauncherProgress.CleanupStart, 500);
Cleanup();
report(LauncherProgress.CleanupFinished, 1000);
// report(LauncherProgress.ProgressEnd, 500);
}
public void Download()
{
DownloadFolder.CreateFolder();
DownloadFolder.Lock(SkipLock);
DownloadFolder.SaveCurrentInfo("current");
UpdateFileRequest req = new UpdateFileRequest(UpdatePlanResponse.CurrentPackage.Version);
foreach (var file2request in UpdatePlanResponse.FilesToRequest)
{
req.UpdateFile = file2request;
var res = AskForFile(req);
var download_path = DownloadFolder.Combine(file2request.RelativePath);
Path.GetDirectoryName(download_path).CreateFolder();
download_path.SaveFile(res.FileData);
var size = NonspecificTools.SizeSuffix((ulong)res.FileData.Length);
Feedback((int)LauncherProgress.DownloadUpdate, new DownloadProgressEventArgs(size, file2request));
}
DownloadFolder.Unlock();
}
public void Apply()
{
ApplyFolder.CreateFolder();
ApplyFolder.Lock(SkipLock);
if (UpdatePlanResponse.FilesToApply is object)
UpdatePlanResponse.FilesToApply.ForEach(ApplyFile);
if (UpdatePlanResponse.FilesToRequest is object)
UpdatePlanResponse.FilesToRequest.ForEach(ApplyFile);
ApplyFolder.SaveCurrentInfo("current");
}
public void ApplyFile(UpdateFileDC file2apply)
{
var apply_path = ApplyFolder.Combine(file2apply.RelativePath);
var download_path = DownloadFolder.Combine(file2apply.RelativePath);
Path.GetDirectoryName(apply_path).CreateFolder();
download_path.CopyFileTo(apply_path);
Feedback((int)LauncherProgress.ApplyUpdate, new ApplyFileEventArgs(file2apply.RelativePath));
}
public void Delete()
{
foreach (var file2delete in UpdatePlanResponse.FilesToDeleteInApply)
{
var delete_path = ApplyFolder.Combine(file2delete.RelativePath);
delete_path.DeleteFile();
Feedback((int)LauncherProgress.DeleteUpdate, file2delete.RelativePath);
}
}
public void Cleanup()
{
ApplyFolder.DeleteEmptyDirectories();
DownloadFolder.ClearFolder();
ApplyFolder.Unlock();
}
private void CreateUpdatePlanRequest()
{
UpdatePlanRequest = new UpdatePlanRequest();
if (UpdatePlanRequest.PlanerRootFolderExists = LauncherPaths.ActualPlanerLocation.Exists())
{
if (UpdatePlanRequest.DownloadFolderExists = DownloadFolder.Exists())
if (!(UpdatePlanRequest.DownloadFolderIsEmpty = DownloadFolder.IsFolderEmpty()))
UpdatePlanRequest.DownloadedFiles = FileController.GetDownloadedFiles(DownloadFolder);
if (UpdatePlanRequest.ApplyFolderExists = ApplyFolder.Exists())
if (!(UpdatePlanRequest.ApplyFolderIsEmpty = ApplyFolder.IsFolderEmpty()))
UpdatePlanRequest.ApplyPackage = FileController.GetApplyPackage(ApplyFolder);
}
UpdatePlanRequest.Login = new LoginDC()
{
Username = SessionInformation.Login.Username,
Password = SessionInformation.Login.Password,
CoreServerAddress = SessionInformation.Connection.CoreServerAddress,
Pin = SessionInformation.Login.Pin,
ClientID = SessionInformation.Login.ClientId,
CheckTenant = true,
TempUsername = SessionInformation.Login.TempUsername,
};
}
private UpdateFileResponse AskForFile(UpdateFileRequest request)
{
return LauncherServiceFacade.DoDownloadBeWoServiceSyncWithException(x => x.GetUpdateFile(request));
}
private void GetUpdatePlanResponse()
{
UpdatePlanResponse = LauncherServiceFacade.DoDownloadBeWoServiceSyncWithException(x => x.GetUpdatePlan(UpdatePlanRequest));
// UpdatePlanResponse.FilesToApply.AddRange(UpdatePlanResponse.FilesToRequest);
}
}
}

View File

@@ -1,33 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BeWoLauncher.Logic.Utils
{
public static class LauncherAppdataConfig
{
public static string GetInstallLocation()
{
return Properties.Settings.Default.InstallLocation;
}
public static void SetInstallLocation(string path)
{
Properties.Settings.Default.InstallLocation = path;
Properties.Settings.Default.Save();
}
public static bool GetFirstInstallationSuccess()
{
return Properties.Settings.Default.FirstInstallationSuccess;
}
public static void SetFirstInstallationSuccess(bool b)
{
Properties.Settings.Default.FirstInstallationSuccess = b;
Properties.Settings.Default.Save();
}
}
}

View File

@@ -1,127 +0,0 @@
using BeWoLauncher.Logic.Controller;
using BS.SharedLauncher.Extensions;
using BS.SharedLauncher.Information;
using BS.SharedLauncher.Logic;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
namespace BeWoLauncher.Logic.Utils
{
public static class LauncherPaths
{
private static readonly string planerExeName = "BeWoPlaner.exe";
//private static readonly string versionXml = "bewo.version";
public static string LoginSelectionPlanerLocation { get; set; }
public static string ActualPlanerLocation { get; set; }
/// <summary>
/// Holt den Install Ort aus den Properties Settings.
/// Sollte dieser nicht verfügbar sein, wird als default - "CurrentBaseDir"/BeWoPlaner - verwendet
/// </summary>
/// <returns></returns>
public static string GetInstallLocationFromSettingOrDefault()
{
var installLocation = GetInstallLocationFromSetting();
if (string.IsNullOrWhiteSpace(installLocation))
{
installLocation = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, BeWoPathFileConfig.SubDirectory);
}
return installLocation;
}
public static string GetInstallLocationFromSetting()
{
return LauncherAppdataConfig.GetInstallLocation();
}
/// <summary>
///
/// </summary>
/// <param name="newLocation"></param>
/// <returns>Gibt true aus, wenn der Path sich verändert hat.</returns>
public static bool ChangePath(string newLocation)
{
var info = new DirectoryInfo(newLocation);
if (LoginSelectionPlanerLocation == newLocation)
{
return false;
}
//if (newLocation.Exists() && (info.GetDirectories().Any() || info.GetFiles().Any()))
//{
// MessageBox.Show($"Ordner muss leer sein! Es sind {info.GetDirectories().Count()} Ordner und {info.GetFiles().Count()} Datei(en) enthalten");
// return false;
//}
// Annahme: Ordner ist leer und neuer Ort
LoginSelectionPlanerLocation = newLocation;
return true;
}
public static void SetAndSaveInstallLocation(string path)
{
ActualPlanerLocation = path;
LauncherAppdataConfig.SetInstallLocation(path);
}
public static string GetRootPath()
{
return ActualPlanerLocation;
}
public static string GetLoggerPath()
{
return Path.Combine(new string[] { GetRootPath(), "log" });
}
public static string GetDownloadPath()
{
return Path.Combine(new string[] { GetRootPath(), "download" });
}
public static string GetApplyPath()
{
return Path.Combine(new string[] { GetRootPath(), "apply" });
}
public static string GetPlanerExeName() => planerExeName;
public static string GetPlanerExePath()
{
return Path.Combine(GetApplyPath(), GetPlanerExeName());
}
public static void SaveCurrentInfo(this string path, string file)
{
FileController.SaveInfo(path.Combine(file), DownloadController.Manager.UpdatePlanResponse.CurrentPackage);
}
public static void SaveFile(this string path, byte[] data)
{
FileController.SaveFile(path, data);
}
public static void CopyFileTo(this string source, string destination)
{
FileController.CopyFile(source, destination);
}
public static void DeleteFile(this string file)
{
FileController.DeleteFile(file);
}
public static void DeleteEmptyDirectories(this string dir)
{
FileController.DeleteEmptyDirectories(dir);
}
}
}

View File

@@ -1,81 +0,0 @@
using BeWoLauncher.ServiceProxy;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Reflection;
using System.ServiceModel;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Windows;
namespace BeWoLauncher.Logic.Utils
{
public static class LauncherUtils
{
public static Dictionary<string, string> ParseQuery(string query)
{
try
{
if (query.IndexOf('?') >= 0)
{
query = query.Split('?')[1];
var valueArray = Regex.Split(query, @"[\&]{0,1}[A-Za-z0-9]+[\=]{1}");
var paramArray = Regex.Split(query, @"[\=][A-Za-z0-9;]+");
valueArray = valueArray.Where(t => !string.IsNullOrWhiteSpace(t)).ToArray();
paramArray = paramArray.Where(t => !string.IsNullOrWhiteSpace(t)).ToArray();
var queryDictionary = new Dictionary<string, string>();
int ixg = 0;
foreach (var item in paramArray)
{
queryDictionary.Add(item.Contains("&") ? Regex.Split(item, @"[\?]|[\&]")[1] : item,
valueArray[ixg]);
ixg++;
if (ixg >= valueArray.Length)
break;
}
return queryDictionary;
}
return new Dictionary<string, string>();
}
catch (Exception ex)
{
throw new Exception(String.Format("Error while parsing query '{0}'\n{1}", query, ex.Message), ex);
}
}
public static string GetAndCreateUserAppDataPath()
{
try
{
string localAppData = Environment.GetFolderPath(
Environment.SpecialFolder.LocalApplicationData);
string companyFilePath
= Path.Combine(localAppData, "beyondSoft");
if (!Directory.Exists(companyFilePath))
Directory.CreateDirectory(companyFilePath);
string bewoFilePath
= Path.Combine(companyFilePath, "BeWoPlaner");
if (!Directory.Exists(bewoFilePath))
Directory.CreateDirectory(bewoFilePath);
return bewoFilePath;
}
catch (Exception ex)
{
MessageBox.Show(
"Fehler beim Anlegen des Anwendungsordners. Sie besitzen nicht die erforderlichen Rechte, bitte wenden Sie sich an Ihren Systemadministrator.\n" +
ex.Message, "BeWoPlaner", MessageBoxButton.OK, MessageBoxImage.Exclamation);
}
return Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
}
}
}

View File

@@ -1,218 +0,0 @@
using BeWoLauncher.Logic.Behavior;
using BeWoLauncher.Logic.Controller;
using BeWoLauncher.View;
using BeWoLauncher.View.Frames;
using BS.SharedLauncher.Enums;
using System;
using System.Threading.Tasks;
using System.Windows.Controls;
using static BeWoLauncher.Logic.Controller.ViewController;
namespace BeWoLauncher.Logic
{
public class ViewBuilder
{
public ViewBuilder()
{
}
public UserControl GetNewView(ViewType type)
{
switch (type)
{
case ViewType.LoginView:
return getLoginView();
}
throw new NotImplementedException("ViewBuilder: View nicht implementiert");
}
public FrameBase GetNewFrame(FrameType type)
{
switch (type)
{
case FrameType.GenericFail:
return getGenericFailedFrame();
case FrameType.InstallInfo:
return getInstallInfoFrame();
case FrameType.InstallProgress:
return getInstallProgressFrame();
case FrameType.InstallFailed:
return getInstallFailedFrame();
case FrameType.UpdateInfo:
return getUpdateInfoFrame();
case FrameType.UpdateProgress:
return getUpdateProgressFrame();
case FrameType.UpdateFailed:
return getUpdateFailedFrame();
case FrameType.UninstallInfo:
return getUninstallInfoFrame();
case FrameType.UninstallProgress:
return getUninstallProgressFrame();
case FrameType.UninstallFailed:
return getUninstallFailedFrame();
case FrameType.UninstallSuccessful:
return getUninstallSuccessfulFrame();
case FrameType.LoadingScreen:
return getLoadingScreenFrame();
case FrameType.NoPermissionInfo:
return getNoPermissionInfoFrame();
}
throw new NotImplementedException("ViewBuilder: Frame nicht implementiert");
}
private UserControl getLoginView()
{
var login = new LoginView();
login.Loaded += CheckForAutoLogin;
login.LoginSuccessful += ViewBehavior.LoginSuccessful;
return login;
}
private FrameBase getNoPermissionInfoFrame()
{
var noper = new InfoFrame();
noper.Title = "Keine Rechte auf Speicherort!";
noper.Text = "Es liegt eine neue Version. Sie besitzen aber nicht die benötigten Rechte, um diese anzuwenden. Bitte wenden Sie sich an Ihren System-Administrator!";
noper.Button1Click += ViewBehavior.BackToLogin;
return noper;
}
private FrameBase getLoadingScreenFrame()
{
var loading = new LoadingScreen();
loading.Loaded += (s,e)=> ViewController.LaunchBehavior.LaunchPlaner();
return loading;
}
private FrameBase getUninstallSuccessfulFrame()
{
var uninstallSuccessful = new InfoFrame();
uninstallSuccessful.Title = "Deinstallation erfolgreich!";
uninstallSuccessful.Text = "Kehre zum Login zurück...";
uninstallSuccessful.CollapseCopyButton();
uninstallSuccessful.Button1Click += ViewBehavior.BackToLogin;
return uninstallSuccessful;
}
private FrameBase getUninstallFailedFrame()
{
var uninstallFailed = new InfoFrame();
uninstallFailed.Title = "Deinstallation fehlgeschlagen!";
uninstallFailed.Text = Error.ToString();
uninstallFailed.Button1Click += ViewBehavior.BackToLogin;
return uninstallFailed;
}
private FrameBase getUninstallProgressFrame()
{
var progress = new ProgressFrame(LauncherMode.Update);
progress.Successful += ViewBehavior.UninstallSuccess;
progress.Exception += ViewBehavior.UninstallFailed;
return progress;
}
private FrameBase getUninstallInfoFrame()
{
var uninstall = new UninstallInfoFrame();
uninstall.Accept += ViewBehavior.UninstallStarting;
uninstall.Abort += ViewBehavior.BackToLogin;
return uninstall;
}
private FrameBase getUpdateFailedFrame()
{
var updateError = new InfoFrame();
updateError.Title = "Update fehlgeschlagen!";
updateError.Text = Error.ToString();
updateError.Button1Click += ViewBehavior.BackToLogin;
return updateError;
}
private FrameBase getUpdateProgressFrame()
{
var progress = new ProgressFrame(LauncherMode.Update);
progress.Successful += ViewBehavior.UpdateSuccess;
progress.Exception += ViewBehavior.UpdateFailed;
return progress;
}
private FrameBase getUpdateInfoFrame()
{
var update = new UpdateInfoFrame();
update.Accept += ViewBehavior.UpdateStarting;
update.Abort += ViewBehavior.BackToLogin;
return update;
}
private FrameBase getInstallFailedFrame()
{
var installError = new InfoFrame();
installError.Title = "Installation fehlgeschlagen!";
installError.Text = Error.ToString();
installError.Button1Click += ViewBehavior.BackToLogin;
return installError;
}
private FrameBase getGenericFailedFrame()
{
var genError = new InfoFrame();
genError.Title = "Loader fehlgeschlagen!";
genError.Text = Error.ToString();
genError.Button1Click += ViewBehavior.BackToLogin;
return genError;
}
private FrameBase getInstallProgressFrame()
{
var progress = new ProgressFrame(LauncherMode.Install);
progress.Successful += ViewBehavior.InstallSuccesss;
progress.Exception += ViewBehavior.InstallFailed;
return progress;
}
private FrameBase getInstallInfoFrame()
{
var install = new InstallInfoFrame();
install.Accept += ViewBehavior.InstallInfoAccept;
install.Abort += ViewBehavior.BackToLogin;
return install;
}
}
}

View File

@@ -1,48 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BeWoLauncher.Models
{
public class ConnectionProfile
{
public string Name { get; set; }
public string Server { get; set; }
public string Tenant { get; set; }
public ConnectionProfile(string pname, string pserver, string ptenant)
{
Name = pname;
Server = pserver;
Tenant = ptenant;
if (Name == null)
Name = String.Empty;
}
public override string ToString()
{
return Name;
}
// Mistery Bug:
//public override int GetHashCode()
//{
// String key = String.Format("{0}_{1}_{2}", Name, Server, Tenant);
// return key.GetHashCode();
//}
//public override bool Equals(object obj)
//{
// var profile = obj as ConnectionProfile;
// if (profile == null)
// {
// return false;
// }
// String key1 = String.Format("{0}_{1}_{2}", Name, Server, Tenant);
// String key2 = String.Format("{0}_{1}_{2}", profile.Name, profile.Server, profile.Tenant);
// return key1.Equals(key2);
//}
}
}

View File

@@ -1,55 +0,0 @@
using System.Reflection;
using System.Resources;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Windows;
// Allgemeine Informationen über eine Assembly werden über die folgenden
// Attribute gesteuert. Ändern Sie diese Attributwerte, um die Informationen zu ändern,
// die einer Assembly zugeordnet sind.
[assembly: AssemblyTitle("BeWoLauncher")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("beyondSoft GmbH")]
[assembly: AssemblyProduct("BeWoPlaner")]
[assembly: AssemblyCopyright("Copyright © 2013 beyondSoft GmbH")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Durch Festlegen von ComVisible auf FALSE werden die Typen in dieser Assembly
// für COM-Komponenten unsichtbar. Wenn Sie auf einen Typ in dieser Assembly von
// COM aus zugreifen müssen, sollten Sie das ComVisible-Attribut für diesen Typ auf "True" festlegen.
[assembly: ComVisible(false)]
//Um mit dem Erstellen lokalisierbarer Anwendungen zu beginnen, legen Sie
//<UICulture>ImCodeVerwendeteKultur</UICulture> in der .csproj-Datei
//in einer <PropertyGroup> fest. Wenn Sie in den Quelldateien beispielsweise Deutsch
//(Deutschland) verwenden, legen Sie <UICulture> auf \"de-DE\" fest. Heben Sie dann die Auskommentierung
//des nachstehenden NeutralResourceLanguage-Attributs auf. Aktualisieren Sie "en-US" in der nachstehenden Zeile,
//sodass es mit der UICulture-Einstellung in der Projektdatei übereinstimmt.
//[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)]
[assembly: ThemeInfo(
ResourceDictionaryLocation.None, //Speicherort der designspezifischen Ressourcenwörterbücher
//(wird verwendet, wenn eine Ressource auf der Seite nicht gefunden wird,
// oder in den Anwendungsressourcen-Wörterbüchern nicht gefunden werden kann.)
ResourceDictionaryLocation.SourceAssembly //Speicherort des generischen Ressourcenwörterbuchs
//(wird verwendet, wenn eine Ressource auf der Seite nicht gefunden wird,
// designspezifischen Ressourcenwörterbuch nicht gefunden werden kann.)
)]
// Versionsinformationen für eine Assembly bestehen aus den folgenden vier Werten:
//
// Hauptversion
// Nebenversion
// Buildnummer
// Revision
//
// Sie können alle Werte angeben oder Standardwerte für die Build- und Revisionsnummern verwenden,
// übernehmen, indem Sie "*" eingeben:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.0.0.0")]
[assembly: AssemblyFileVersion("2.0.0.0")]

View File

@@ -1,71 +0,0 @@
//------------------------------------------------------------------------------
// <auto-generated>
// Dieser Code wurde von einem Tool generiert.
// Laufzeitversion: 4.0.30319.42000
//
// Änderungen an dieser Datei können fehlerhaftes Verhalten verursachen und gehen verloren, wenn
// der Code neu generiert wird.
// </auto-generated>
//------------------------------------------------------------------------------
namespace BeWoLauncher.Properties
{
/// <summary>
/// Eine stark typisierte Ressourcenklasse zum Suchen von lokalisierten Zeichenfolgen usw.
/// </summary>
// Diese Klasse wurde von der StronglyTypedResourceBuilder-Klasse
// über ein Tool wie ResGen oder Visual Studio automatisch generiert.
// Um einen Member hinzuzufügen oder zu entfernen, bearbeiten Sie die .ResX-Datei und führen dann ResGen
// mit der Option /str erneut aus, oder erstellen Sie Ihr VS-Projekt neu.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources
{
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources()
{
}
/// <summary>
/// Gibt die zwischengespeicherte ResourceManager-Instanz zurück, die von dieser Klasse verwendet wird.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager
{
get
{
if ((resourceMan == null))
{
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("BeWoLauncher.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Überschreibt die CurrentUICulture-Eigenschaft des aktuellen Threads für alle
/// Ressourcenlookups, die diese stark typisierte Ressourcenklasse verwenden.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture
{
get
{
return resourceCulture;
}
set
{
resourceCulture = value;
}
}
}
}

View File

@@ -1,117 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -1,50 +0,0 @@
//------------------------------------------------------------------------------
// <auto-generated>
// Dieser Code wurde von einem Tool generiert.
// Laufzeitversion:4.0.30319.42000
//
// Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
// der Code erneut generiert wird.
// </auto-generated>
//------------------------------------------------------------------------------
namespace BeWoLauncher.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.9.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
public static Settings Default {
get {
return defaultInstance;
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("")]
public string InstallLocation {
get {
return ((string)(this["InstallLocation"]));
}
set {
this["InstallLocation"] = value;
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("False")]
public bool FirstInstallationSuccess {
get {
return ((bool)(this["FirstInstallationSuccess"]));
}
set {
this["FirstInstallationSuccess"] = value;
}
}
}
}

View File

@@ -1,12 +0,0 @@
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" GeneratedClassNamespace="BeWoLauncher.Properties" GeneratedClassName="Settings">
<Profiles />
<Settings>
<Setting Name="InstallLocation" Type="System.String" Scope="User">
<Value Profile="(Default)" />
</Setting>
<Setting Name="FirstInstallationSuccess" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">False</Value>
</Setting>
</Settings>
</SettingsFile>

View File

@@ -1,403 +0,0 @@
//------------------------------------------------------------------------------
// <auto-generated>
// Dieser Code wurde von einem Tool generiert.
// Laufzeitversion:4.0.30319.42000
//
// Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
// der Code erneut generiert wird.
// </auto-generated>
//------------------------------------------------------------------------------
namespace BeWoLauncher.ServiceProxy
{
using System.Runtime.Serialization;
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
[System.Runtime.Serialization.DataContractAttribute(Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
public partial class BeWoFault : object, System.Runtime.Serialization.IExtensibleDataObject, System.ComponentModel.INotifyPropertyChanged
{
private System.Runtime.Serialization.ExtensionDataObject extensionDataField;
private BeWoLauncher.ServiceProxy.BeWoFaultType FaultTypeField;
private string InnerExceptionMessageField;
private string InnerExceptionStackTraceField;
private string MessageField;
private string StackTraceField;
public System.Runtime.Serialization.ExtensionDataObject ExtensionData
{
get
{
return this.extensionDataField;
}
set
{
this.extensionDataField = value;
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public BeWoLauncher.ServiceProxy.BeWoFaultType FaultType
{
get
{
return this.FaultTypeField;
}
set
{
if ((this.FaultTypeField.Equals(value) != true))
{
this.FaultTypeField = value;
this.RaisePropertyChanged("FaultType");
}
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public string InnerExceptionMessage
{
get
{
return this.InnerExceptionMessageField;
}
set
{
if ((object.ReferenceEquals(this.InnerExceptionMessageField, value) != true))
{
this.InnerExceptionMessageField = value;
this.RaisePropertyChanged("InnerExceptionMessage");
}
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public string InnerExceptionStackTrace
{
get
{
return this.InnerExceptionStackTraceField;
}
set
{
if ((object.ReferenceEquals(this.InnerExceptionStackTraceField, value) != true))
{
this.InnerExceptionStackTraceField = value;
this.RaisePropertyChanged("InnerExceptionStackTrace");
}
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public string Message
{
get
{
return this.MessageField;
}
set
{
if ((object.ReferenceEquals(this.MessageField, value) != true))
{
this.MessageField = value;
this.RaisePropertyChanged("Message");
}
}
}
[System.Runtime.Serialization.DataMemberAttribute()]
public string StackTrace
{
get
{
return this.StackTraceField;
}
set
{
if ((object.ReferenceEquals(this.StackTraceField, value) != true))
{
this.StackTraceField = value;
this.RaisePropertyChanged("StackTrace");
}
}
}
public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;
protected void RaisePropertyChanged(string propertyName)
{
System.ComponentModel.PropertyChangedEventHandler propertyChanged = this.PropertyChanged;
if ((propertyChanged != null))
{
propertyChanged(this, new System.ComponentModel.PropertyChangedEventArgs(propertyName));
}
}
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
[System.Runtime.Serialization.DataContractAttribute(Name="BeWoFaultType", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
public enum BeWoFaultType : int
{
[System.Runtime.Serialization.EnumMemberAttribute()]
Unknown = 0,
[System.Runtime.Serialization.EnumMemberAttribute()]
Concurrency = 1,
[System.Runtime.Serialization.EnumMemberAttribute()]
DeleteNotPossible = 2,
[System.Runtime.Serialization.EnumMemberAttribute()]
LoginNameTaken = 3,
[System.Runtime.Serialization.EnumMemberAttribute()]
CustomWithoutDetails = 4,
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
[System.ServiceModel.ServiceContractAttribute(ConfigurationName="BeWoLauncher.ServiceProxy.ILauncherService")]
public interface ILauncherService
{
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ILauncherService/IsUserValid", ReplyAction="http://tempuri.org/ILauncherService/IsUserValidResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/ILauncherService/IsUserValidBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.Enums.UserValidationResult IsUserValid(string pUserName, string pPassword, string pPIN, string clientId, bool checkTenant);
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ILauncherService/ResetTenant", ReplyAction="http://tempuri.org/ILauncherService/ResetTenantResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/ILauncherService/ResetTenantBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
void ResetTenant(string tenant);
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ILauncherService/ResetAllTenant", ReplyAction="http://tempuri.org/ILauncherService/ResetAllTenantResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/ILauncherService/ResetAllTenantBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
void ResetAllTenant();
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ILauncherService/GetEmailForUserName", ReplyAction="http://tempuri.org/ILauncherService/GetEmailForUserNameResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/ILauncherService/GetEmailForUserNameBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
bool GetEmailForUserName(out string email, string pUserName, System.Uri serverName);
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ILauncherService/CheckPassword", ReplyAction="http://tempuri.org/ILauncherService/CheckPasswordResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/ILauncherService/CheckPasswordBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.Enums.PasswordValidationResult CheckPassword(long userOid, string pOldPassword, string pNewPassword);
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ILauncherService/CheckPassword2", ReplyAction="http://tempuri.org/ILauncherService/CheckPassword2Response")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/ILauncherService/CheckPassword2BeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.Enums.PasswordValidationResult CheckPassword2(string username, string pOldPassword, string pNewPassword);
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ILauncherService/ChangePassword", ReplyAction="http://tempuri.org/ILauncherService/ChangePasswordResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/ILauncherService/ChangePasswordBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
long ChangePassword(string pUserName, string pOldPassword, string pNewPassword);
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ILauncherService/ResetPasswordInfo", ReplyAction="http://tempuri.org/ILauncherService/ResetPasswordInfoResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/ILauncherService/ResetPasswordInfoBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
void ResetPasswordInfo(string pUserName, string pPassword);
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public interface ILauncherServiceChannel : BeWoLauncher.ServiceProxy.ILauncherService, System.ServiceModel.IClientChannel
{
}
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public partial class LauncherServiceClient : System.ServiceModel.ClientBase<BeWoLauncher.ServiceProxy.ILauncherService>, BeWoLauncher.ServiceProxy.ILauncherService
{
public LauncherServiceClient()
{
}
public LauncherServiceClient(string endpointConfigurationName) :
base(endpointConfigurationName)
{
}
public LauncherServiceClient(string endpointConfigurationName, string remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public LauncherServiceClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public LauncherServiceClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) :
base(binding, remoteAddress)
{
}
public BS.SharedLauncher.Enums.UserValidationResult IsUserValid(string pUserName, string pPassword, string pPIN, string clientId, bool checkTenant)
{
return base.Channel.IsUserValid(pUserName, pPassword, pPIN, clientId, checkTenant);
}
public void ResetTenant(string tenant)
{
base.Channel.ResetTenant(tenant);
}
public void ResetAllTenant()
{
base.Channel.ResetAllTenant();
}
public bool GetEmailForUserName(out string email, string pUserName, System.Uri serverName)
{
return base.Channel.GetEmailForUserName(out email, pUserName, serverName);
}
public BS.SharedLauncher.Enums.PasswordValidationResult CheckPassword(long userOid, string pOldPassword, string pNewPassword)
{
return base.Channel.CheckPassword(userOid, pOldPassword, pNewPassword);
}
public BS.SharedLauncher.Enums.PasswordValidationResult CheckPassword2(string username, string pOldPassword, string pNewPassword)
{
return base.Channel.CheckPassword2(username, pOldPassword, pNewPassword);
}
public long ChangePassword(string pUserName, string pOldPassword, string pNewPassword)
{
return base.Channel.ChangePassword(pUserName, pOldPassword, pNewPassword);
}
public void ResetPasswordInfo(string pUserName, string pPassword)
{
base.Channel.ResetPasswordInfo(pUserName, pPassword);
}
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
[System.ServiceModel.ServiceContractAttribute(ConfigurationName="BeWoLauncher.ServiceProxy.IEnumTranslationService")]
public interface IEnumTranslationService
{
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IEnumTranslationService/GetTranslation", ReplyAction="http://tempuri.org/IEnumTranslationService/GetTranslationResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/IEnumTranslationService/GetTranslationBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
string GetTranslation(string e, short value);
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public interface IEnumTranslationServiceChannel : BeWoLauncher.ServiceProxy.IEnumTranslationService, System.ServiceModel.IClientChannel
{
}
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public partial class EnumTranslationServiceClient : System.ServiceModel.ClientBase<BeWoLauncher.ServiceProxy.IEnumTranslationService>, BeWoLauncher.ServiceProxy.IEnumTranslationService
{
public EnumTranslationServiceClient()
{
}
public EnumTranslationServiceClient(string endpointConfigurationName) :
base(endpointConfigurationName)
{
}
public EnumTranslationServiceClient(string endpointConfigurationName, string remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public EnumTranslationServiceClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public EnumTranslationServiceClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) :
base(binding, remoteAddress)
{
}
public string GetTranslation(string e, short value)
{
return base.Channel.GetTranslation(e, value);
}
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
[System.ServiceModel.ServiceContractAttribute(ConfigurationName="BeWoLauncher.ServiceProxy.IDownloadBeWoService")]
public interface IDownloadBeWoService
{
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IDownloadBeWoService/Download2", ReplyAction="http://tempuri.org/IDownloadBeWoService/Download2Response")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/IDownloadBeWoService/Download2BeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.DataContract.UpdateFileResponse Download2(BS.SharedLauncher.DataContract.UpdateRequest request);
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IDownloadBeWoService/DownloadInfo", ReplyAction="http://tempuri.org/IDownloadBeWoService/DownloadInfoResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/IDownloadBeWoService/DownloadInfoBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.DataContract.UpdateResponse DownloadInfo(BS.SharedLauncher.DataContract.UpdateRequest request);
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IDownloadBeWoService/GetUpdatePlan", ReplyAction="http://tempuri.org/IDownloadBeWoService/GetUpdatePlanResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/IDownloadBeWoService/GetUpdatePlanBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.DataContract.UpdateResponse GetUpdatePlan(BS.SharedLauncher.DataContract.UpdateRequest request);
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IDownloadBeWoService/GetUpdateFile", ReplyAction="http://tempuri.org/IDownloadBeWoService/GetUpdateFileResponse")]
[System.ServiceModel.FaultContractAttribute(typeof(BeWoLauncher.ServiceProxy.BeWoFault), Action="http://tempuri.org/IDownloadBeWoService/GetUpdateFileBeWoFaultFault", Name="BeWoFault", Namespace="http://schemas.datacontract.org/2004/07/BeWo.Service.ServiceContracts")]
BS.SharedLauncher.DataContract.UpdateFileResponse GetUpdateFile(BS.SharedLauncher.DataContract.UpdateFileRequest request);
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public interface IDownloadBeWoServiceChannel : BeWoLauncher.ServiceProxy.IDownloadBeWoService, System.ServiceModel.IClientChannel
{
}
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public partial class DownloadBeWoServiceClient : System.ServiceModel.ClientBase<BeWoLauncher.ServiceProxy.IDownloadBeWoService>, BeWoLauncher.ServiceProxy.IDownloadBeWoService
{
public DownloadBeWoServiceClient()
{
}
public DownloadBeWoServiceClient(string endpointConfigurationName) :
base(endpointConfigurationName)
{
}
public DownloadBeWoServiceClient(string endpointConfigurationName, string remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public DownloadBeWoServiceClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress) :
base(endpointConfigurationName, remoteAddress)
{
}
public DownloadBeWoServiceClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) :
base(binding, remoteAddress)
{
}
public BS.SharedLauncher.DataContract.UpdateFileResponse Download2(BS.SharedLauncher.DataContract.UpdateRequest request)
{
return base.Channel.Download2(request);
}
public BS.SharedLauncher.DataContract.UpdateResponse DownloadInfo(BS.SharedLauncher.DataContract.UpdateRequest request)
{
return base.Channel.DownloadInfo(request);
}
public BS.SharedLauncher.DataContract.UpdateResponse GetUpdatePlan(BS.SharedLauncher.DataContract.UpdateRequest request)
{
return base.Channel.GetUpdatePlan(request);
}
public BS.SharedLauncher.DataContract.UpdateFileResponse GetUpdateFile(BS.SharedLauncher.DataContract.UpdateFileRequest request)
{
return base.Channel.GetUpdateFile(request);
}
}
}

File diff suppressed because it is too large Load Diff

Binary file not shown.

View File

@@ -1,43 +0,0 @@
<Window x:Class="BeWoLauncher.Components.ConfirmDemoDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="BeWoPlaner" Height="240" Width="360" WindowStartupLocation="CenterScreen" WindowStyle="None" ResizeMode="NoResize" >
<Grid Background="{x:Null}" Margin="0,0,0,0">
<Border BorderThickness="1" Padding="5,5,5,5" BorderBrush="Black" Background="{DynamicResource LoginBackgroundColor}">
<Grid Opacity="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="80" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Image Grid.Row="0" HorizontalAlignment="Left" VerticalAlignment="Top" Source="BeWoLauncher/View/Icons/bewoplaner_logo_big.png" Height="45" Margin="7,7,0,0"/>
<Grid Grid.Row="1" Margin="0,10,0,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*" ></RowDefinition>
<RowDefinition Height="Auto" ></RowDefinition>
</Grid.RowDefinitions>
<TextBlock TextWrapping="Wrap" Margin="3" FontSize="14">WICHTIG! Bitte tragen Sie keine echten Daten bei Ihren Tests ein, da es sich um einen öffentlichen Testzugang handelt, auf den jeder Zugriff hat!</TextBlock>
<Button x:Name="CountButton" Grid.Row="2" Grid.Column="1" Width="120" Margin="3,25,3,3" IsDefault="True" HorizontalAlignment="Right" Click="ButtonBase_OnClick">OK</Button>
<!--<Button Grid.Row="2" Grid.Column ="2" Width="100" Margin="3" IsCancel="True" IsEnabled="False" HorizontalAlignment="Right">Abbrechen</Button>-->
</Grid>
</Grid>
</Border>
<Line Grid.ColumnSpan="4" Stroke="#FFADADAD" X1="14" Y1="70" X2="585" Y2="70" StrokeThickness="1"></Line>
<Line x:Name="linkLine" Stroke="#FFADADAD" X1="14" Y1="340" X2="585" Y2="340" StrokeThickness="1" Margin="0,30,0,-30"></Line>
</Grid>
</Window>

View File

@@ -1,51 +0,0 @@
using System;
using System.Windows;
using System.Windows.Threading;
namespace BeWoLauncher.Components
{
/// <summary>
/// Interaktionslogik für ConfirmDemoDialog.xaml
/// </summary>
public partial class ConfirmDemoDialog : Window
{
public ConfirmDemoDialog()
{
InitializeComponent();
CountButton.Content = "Bitte warten (10 sek.)";
CountButton.IsEnabled = false;
this.Loaded += new RoutedEventHandler(ConfirmDemoDialog_Loaded);
}
void ConfirmDemoDialog_Loaded(object sender, RoutedEventArgs e)
{
int count = 9;
new DispatcherTimer(
TimeSpan.FromMilliseconds(1000),
DispatcherPriority.Background,
(s1, e1) =>
{
CountButton.Content = String.Format("Bitte warten ({0} sek.)", count);
if (count-- == 0)
{
CountButton.Content = "OK";
CountButton.IsEnabled = true;
((DispatcherTimer) s1).Stop();
}
},
this.Dispatcher).Start();
}
private void ButtonBase_OnClick(object sender, RoutedEventArgs e)
{
//DialogResult = true;
Close();
}
}
}

View File

@@ -1,48 +0,0 @@
<Window x:Class="BeWoLauncher.Components.EnterTenantDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
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:BeWoLauncher.Components"
mc:Ignorable="d"
Title="BeWoPlaner" Height="240" Width="320" WindowStartupLocation="CenterScreen" WindowStyle="ToolWindow">
<Grid Background="{x:Null}" Margin="0,0,0,0">
<Border BorderThickness="0" Padding="5,5,5,5" Background="{DynamicResource LoginBackgroundColor}">
<Grid Opacity="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="80" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Image Grid.Row="0" HorizontalAlignment="Left" VerticalAlignment="Top" Source="pack://application:,,,/View/Icons/bewoplaner_logo_big.png" Height="45" Margin="7,7,0,0"/>
<Grid Grid.Row="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" ></RowDefinition>
<RowDefinition Height="Auto" ></RowDefinition>
<RowDefinition Height="Auto" ></RowDefinition>
<RowDefinition Height="Auto" ></RowDefinition>
</Grid.RowDefinitions>
<TextBlock Grid.ColumnSpan="3" TextWrapping="Wrap" Margin="3">Bitte geben Sie Ihre 10-stellige Kundennummer ein:</TextBlock>
<TextBox x:Name="txtTenant" Grid.ColumnSpan="3" Grid.Row="1" Margin="3"></TextBox>
<Button Grid.Row="2" Grid.Column ="1" Width="100" Margin="3" IsDefault="True" Click="ButtonBase_OnClick">OK</Button>
<Button Grid.Row="2" Grid.Column ="2" Width="100" Margin="3" IsCancel="True" >Abbrechen</Button>
<CheckBox Grid.ColumnSpan="3" Grid.Row="3" Margin="3" Checked="ToggleButton_OnChecked" Unchecked="ToggleButton_OnUnchecked">Demo Zugang nutzen</CheckBox>
</Grid>
</Grid>
</Border>
<Line Grid.ColumnSpan="4" Stroke="#FFADADAD" X1="14" Y1="70" X2="585" Y2="70" StrokeThickness="1"></Line>
<Line x:Name="linkLine" Stroke="#FFADADAD" X1="14" Y1="340" X2="585" Y2="340" StrokeThickness="1" Margin="0,30,0,-30"></Line>
</Grid>
</Window>

View File

@@ -1,58 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;
namespace BeWoLauncher.Components
{
/// <summary>
/// Interaktionslogik für EnterTenantDialog.xaml
/// </summary>
public partial class EnterTenantDialog : Window
{
public EnterTenantDialog()
{
InitializeComponent();
}
private String oldTenant = String.Empty;
public String Tenant
{
get { return txtTenant.Text; }
set
{
txtTenant.Text = value;
txtTenant.Focus();
txtTenant.SelectAll();
}
}
private void ButtonBase_OnClick(object sender, RoutedEventArgs e)
{
DialogResult = true;
}
private void ToggleButton_OnChecked(object sender, RoutedEventArgs e)
{
oldTenant = txtTenant.Text;
txtTenant.Text = "demo";
txtTenant.IsEnabled = false;
}
private void ToggleButton_OnUnchecked(object sender, RoutedEventArgs e)
{
txtTenant.Text = oldTenant;
txtTenant.IsEnabled = true;
}
}
}

View File

@@ -1,40 +0,0 @@
<UserControl xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
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"
mc:Ignorable="d"
x:Class="BeWoLauncher.Components.ExceptionMessageBox"
x:Name="UserControl"
Width="400" Height="300">
<Grid x:Name="LayoutRoot">
<Border BorderBrush="Black" BorderThickness="1" CornerRadius="10">
<Border.Background>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#FF152043" Offset="0" />
<GradientStop Color="#FF464674" Offset="1" />
<GradientStop Color="White" Offset="0.293" />
</LinearGradientBrush>
</Border.Background>
</Border>
<Border BorderBrush="Black" BorderThickness="1" CornerRadius="2,2,10,10" Margin="3,25,3,3" Background="White">
<Grid Margin="5,5,5,45">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<TextBlock x:Name="lblError" Grid.Row="1" Text="Fehlerdetails:" d:LayoutOverrides="Height" TextDecorations="Underline" />
<ScrollViewer x:Name="contentError" Grid.Row="2" Margin="10" HorizontalScrollBarVisibility="Disabled" VerticalScrollBarVisibility="Auto">
<TextBox IsReadOnly="True" TextWrapping="Wrap" Name="tb_stack" FontStyle="Italic"></TextBox>
</ScrollViewer>
<TextBlock TextWrapping="Wrap" Name="tb_message" FontWeight="Bold" FontSize="13.333" Margin="0,10" />
</Grid>
</Border>
<Border BorderBrush="Black" BorderThickness="1" CornerRadius="0,0,10,10" Background="#FFEFE8E8" Height="40" VerticalAlignment="Bottom" Margin="3,0,3,3">
<Button HorizontalAlignment="Right" Click="Button_Click" Height="23" Content="OK" VerticalAlignment="Center" Width="100" Margin="0,0,7,0" />
</Border>
<TextBlock Margin="10,5,0,0" VerticalAlignment="Top" Width="332.826666666667" Text="Es ist ein Fehler aufgetreten." Foreground="#FFEFE8E8" HorizontalAlignment="Left" FontSize="13.333" />
</Grid>
</UserControl>

View File

@@ -1,51 +0,0 @@
using BeWoLauncher.Logic;
using BeWoLauncher.Logic.Controller;
using System;
using System.Windows;
using System.Windows.Controls;
namespace BeWoLauncher.Components
{
public partial class ExceptionMessageBox : UserControl
{
public ExceptionMessageBox(string message, Exception ex, bool showDetails) : this(message, ex?.ToString(), showDetails) { }
public ExceptionMessageBox(string message, string submessage, bool showDetails)
{
InitializeComponent();
if (!String.IsNullOrEmpty(message) && !showDetails)
tb_message.Text = message;
else
{
tb_message.Text =
"Es ist leider ein unbekannter Fehler aufgetreten. Prüfen Sie Ihre Internetverbindung oder versuchen Sie es später erneut. Wir sind stets bemüht das Programm zu verbessern, daher freuen wir uns auch, wenn Sie die Fehlerdetails unten in einer Mail an support@bewoplaner.de senden.";
}
if (!showDetails)
{
lblError.Visibility = Visibility.Collapsed;
contentError.Visibility = Visibility.Collapsed;
}
else
{
tb_stack.Text = String.Empty;
if (!String.IsNullOrEmpty(message))
{
tb_stack.Text = message + System.Environment.NewLine + System.Environment.NewLine + tb_stack.Text;
}
tb_stack.Text += submessage ?? string.Empty;
lblError.Visibility = Visibility.Visible;
contentError.Visibility = Visibility.Visible;
}
}
private void Button_Click(object sender, RoutedEventArgs e)
{
if(ViewController.CurrentWindow != null)
{
ViewController.CurrentWindow.CloseCurrentPopUp();
}
}
}
}

View File

@@ -1,79 +0,0 @@
<Window x:Class="BeWoLauncher.Components.MessageDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:converter="clr-namespace:BeWoLauncher.Converter"
Title="BeWoPlaner" Height="400" Width="500" WindowStartupLocation="CenterScreen" WindowStyle="None" ResizeMode="NoResize" >
<Window.Resources>
<converter:BoolVisibilityConverter x:Key="BoolVisibilityConverter" />
</Window.Resources>
<Grid Background="{x:Null}" Margin="0,0,0,0">
<Border BorderThickness="1" Padding="5,5,5,5" BorderBrush="Black" Background="{DynamicResource LoginBackgroundColor}">
<Grid Opacity="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="80" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Image Grid.Row="0" HorizontalAlignment="Left" VerticalAlignment="Top" Source="pack://application:,,,/View/Icons/bewoplaner_logo_big.png" Height="45" Margin="7,7,0,0"/>
<Grid Grid.Row="1" Margin="0,10,0,0" x:Name="rootGrid">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*"></RowDefinition>
<RowDefinition Height="Auto"></RowDefinition>
<RowDefinition Height="Auto"></RowDefinition>
<RowDefinition Height="Auto"></RowDefinition>
</Grid.RowDefinitions>
<TextBox Background="Transparent"
BorderThickness="0" IsReadOnly="True"
x:Name="txtMessage" TextWrapping="Wrap" Margin="3" FontSize="14"></TextBox>
<Grid Grid.Row="1" HorizontalAlignment="Center" Visibility="{Binding Path=IsInConfirmationWithPasswordMode, Converter={StaticResource BoolVisibilityConverter}}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Label Grid.Row="0" Grid.Column="0" VerticalAlignment="Center" HorizontalAlignment="Left" Content="Passwort:" />
<PasswordBox Grid.Row="0" Grid.Column="1" Height="24" x:Name="PasswordBox" VerticalContentAlignment="Center" Width="185" VerticalAlignment="Center" HorizontalAlignment="Stretch"></PasswordBox>
</Grid>
<!--<Grid >
<Grid.RowDefinitions>
<RowDefinition Height="*" ></RowDefinition>
<RowDefinition Height="Auto" ></RowDefinition>
</Grid.RowDefinitions>
<TextBox Background="Transparent"
BorderThickness="0" IsReadOnly="True"
TextWrapping="Wrap" Margin="3" FontSize="14">
Am 17./18.11.2017 wird ein BeWoPlaner-Update erscheinen, welches auf die Microsoft Komponente .NET 4.5 angewiesen ist. Bitte installieren Sie .NET 4.5. Sobald Sie die Installation durchgeführt haben, startet der BeWoPlaner ohne diese Meldung.
Sie finden die Installation unter folgendem Link:
</TextBox>
<TextBlock Grid.Row="1" Margin="3" FontSize="14">
<Hyperlink NavigateUri="https://www.microsoft.com/de-de/download/details.aspx?id=42642" Command="{Binding Test}">
https://www.microsoft.com/de-de/download/details.aspx?id=42642
</Hyperlink>
</TextBlock>
</Grid>-->
<!--<Button Grid.Row="2" Grid.Column ="2" Width="100" Margin="3" IsCancel="True" IsEnabled="False" HorizontalAlignment="Right">Abbrechen</Button>-->
</Grid>
</Grid>
</Border>
<Line Grid.ColumnSpan="4" Stroke="#FFADADAD" X1="14" Y1="70" X2="486" Y2="70" StrokeThickness="1"></Line>
<Line x:Name="linkLine" Stroke="#FFADADAD" X1="14" Y1="320" X2="486" Y2="320" StrokeThickness="1" Margin="0,30,0,-30"></Line>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
<Button x:Name="OkayButton" Width="120" Margin="3,3,15,10" VerticalAlignment="Bottom" Click="OkayButton_OnClick">OK</Button>
<Button x:Name="CountButton" Width="120" Margin="3,3,15,10" IsDefault="True" VerticalAlignment="Bottom" Click="ButtonBase_OnClick">Schließen</Button>
</StackPanel>
</Grid>
</Window>

View File

@@ -1,122 +0,0 @@
using BeWoLauncher.ServiceProxy;
using BS.SharedLauncher;
using BS.SharedLauncher.Enums;
using BS.SharedLauncher.Information;
using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Threading;
using System.Xaml;
using XamlReader = System.Windows.Markup.XamlReader;
namespace BeWoLauncher.Components
{
public partial class MessageDialog
{
public MessageDialog()
{
InitializeComponent();
DataContext = this;
OkayButton.Visibility = Visibility.Collapsed;
}
public MessageDialog(Action pAfterPasswordConfirmationCallBack)
{
IsInConfirmationWithPasswordMode = true;
AfterPasswordConfirmationCallBack = pAfterPasswordConfirmationCallBack;
InitializeComponent();
DataContext = this;
OkayButton.IsDefault = true;
CountButton.IsDefault = false;
}
public Action AfterPasswordConfirmationCallBack { get; set; }
public bool IsInConfirmationWithPasswordMode { get; set; }
private ICommand _OpenBrowserCommand;
public ICommand OpenBrowserCommand => _OpenBrowserCommand ?? (_OpenBrowserCommand = new OpenBrowserCommandImpl());
public class OpenBrowserCommandImpl : ICommand
{
public bool CanExecute(object parameter)
{
return true;
}
public event EventHandler CanExecuteChanged;
public void Execute(object parameter)
{
if (parameter != null)
{
System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo(parameter.ToString()));
}
}
}
public void SetXaml(string xamlCode)
{
try
{
if(XamlReader.Parse(xamlCode) is UIElement element)
{
txtMessage.Visibility = Visibility.Collapsed;
rootGrid.Children.Add(element);
}
}
catch(Exception e)
{
//ignore
}
}
public string Message
{
get => txtMessage.Text;
set => txtMessage.Text = value;
}
private void ButtonBase_OnClick(object sender, RoutedEventArgs e)
{
//DialogResult = true;
Close();
}
private void OpenBrowserCommand_Executed(object sender, ExecutedRoutedEventArgs e)
{
if (e.OriginalSource is Hyperlink)
{
System.Diagnostics.Process.Start(
new System.Diagnostics.ProcessStartInfo((e.OriginalSource as Hyperlink).NavigateUri.ToString()));
}
}
private void OpenBrowserCommand_CanExecute(object sender, CanExecuteRoutedEventArgs e)
{
e.CanExecute = true;
e.Handled = true;
}
private void OkayButton_OnClick(object sender, RoutedEventArgs e)
{
LauncherServiceFacade.DoLauncherServiceAsync(u => u.IsUserValid(SessionInformation.Login.Username, PasswordBox.Password, null, null, false), result =>
{
if(result == UserValidationResult.UserValid)
{
AfterPasswordConfirmationCallBack?.Invoke();
Dispatcher.BeginInvoke(DispatcherPriority.Normal, (Action)Close);
}
else
{
MessageBox.Show("Anmeldeinformationen nicht bekannt. Bitte überprüfen Sie den Benutzernamen und das Passwort!", "Fehler bei der Anmeldung", MessageBoxButton.OK, MessageBoxImage.Exclamation);
}
}, true);
}
}
}

View File

@@ -1,45 +0,0 @@
<UserControl x:Class="BeWoLauncher.Components.PasswortAenderungsView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:BeWoLauncher.Components"
mc:Ignorable="d"
d:DesignHeight="230" d:DesignWidth="340">
<Grid>
<GroupBox Header="Passwort ändern" x:Name="rootGroupBox" Style="{DynamicResource MainContentGroupBoxWithoutMaximizeBtnStyle}" MouseLeftButtonDown="RootGroupBox_OnMouseLeftButtonDown">
<Grid Background="{DynamicResource ObjectEditBackgroundBrush}">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<TextBlock x:Name="textblock_editFailures" Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="2" Height="30" Foreground="Red" FontSize="12" TextWrapping="Wrap" Margin="3" VerticalAlignment="Center" HorizontalAlignment="Center" />
<Label Grid.Row="1" Grid.Column="0" Content="Altes Passwort" Margin="3" />
<PasswordBox x:Name="AltesPwBox" Grid.Row="1" Grid.Column="1" Margin="3" VerticalContentAlignment="Center" PasswordChanged="AltesPWgeaendert" />
<Label Grid.Row="2" Grid.Column="0" Content="Neues Passwort" Margin="3" />
<PasswordBox x:Name="NeuesPwBox" Grid.Row="2" Grid.Column="1" Margin="3" VerticalContentAlignment="Center" PasswordChanged="NeuesPwBox_OnPasswordChanged" />
<Label Grid.Row="3" Grid.Column="0" Content="Passwort bestätigen" Margin="3" />
<PasswordBox x:Name="NeuesPwBox2" Grid.Row="3" Grid.Column="1" Margin="3" VerticalContentAlignment="Center" />
<Label Content="Passwort zu kurz" Grid.Row="4" Grid.ColumnSpan="2" Foreground="Red" x:Name="passwortprüfer" Visibility="Hidden" />
<StackPanel Grid.Row="5" Grid.Column="0" Grid.ColumnSpan="2" Orientation="Horizontal" HorizontalAlignment="Right" Margin="0,10,0,0">
<Button Margin="3" Content="OK" Width="100" Click="AendernClick" IsDefault="True" />
<Button Margin="3" x:Name="AbbrechenButton" Content="Abbrechen" Width="100" Command="Close" />
</StackPanel>
</Grid>
</GroupBox>
</Grid>
</UserControl>

View File

@@ -1,120 +0,0 @@
using BeWoLauncher.ServiceProxy;
using BeWoLauncher.WindowImp;
using BS.SharedLauncher;
using BS.SharedLauncher.Enums;
using BS.SharedLauncher.Information;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using System.Windows.Threading;
namespace BeWoLauncher.Components
{
/// <summary>
/// Interaktionslogik für UserControl1.xaml
/// </summary>
public partial class PasswortAenderungsView : UserControl
{
public PopUpWindow PopUp { get; set; }
public PasswortAenderungsView(PopUpWindow pop)
{
InitializeComponent();
PopUp = pop;
}
private void RootGroupBox_OnMouseLeftButtonDown(object sender, MouseButtonEventArgs e)
{
try
{
PopUp.DragMove();
}
catch (Exception) { }
}
private void AendernClick(object sender, RoutedEventArgs e)
{
textblock_editFailures.Foreground = new SolidColorBrush(Colors.Red);
//if (ViewModel.CheckOldPassword(AltesPwBox.Password))
//{
// textblock_editFailures.Text = "Das alte Passwort ist nicht korrekt!";
// MessageBox.Show("Das alte Passwort ist nicht korrekt!", "Ändern des Passworts fehlgeschlagen", MessageBoxButton.OK, MessageBoxImage.Information);
// return;
//}
if (string.IsNullOrEmpty(NeuesPwBox.Password))
{
textblock_editFailures.Text = "Bitte geben Sie ein neues Passwort ein!";
MessageBox.Show("Bitte geben Sie ein neues Passwort ein!", "Ändern des Passworts fehlgeschlagen", MessageBoxButton.OK, MessageBoxImage.Information);
return;
}
if (NeuesPwBox.Password != NeuesPwBox2.Password)
{
textblock_editFailures.Text = "Die Passwörter stimmen nicht überein!";
MessageBox.Show("Die Passwörter stimmen nicht überein!", "Ändern des Passworts fehlgeschlagen", MessageBoxButton.OK, MessageBoxImage.Information);
return;
}
var lOld = AltesPwBox.Password;
var lNew = NeuesPwBox.Password;
LauncherServiceFacade.DoLauncherServiceAsync(x => x.CheckPassword2(SessionInformation.Login.Username, lOld, lNew),
result => CheckPasswordResult(result, lOld, lNew), true);
}
private void CheckPasswordResult(PasswordValidationResult result, String oldPassword, String newPassword)
{
if (result == PasswordValidationResult.Succesful)
{
LauncherServiceFacade.DoLauncherServiceSync(x => x.ChangePassword(SessionInformation.Login.Username, oldPassword, newPassword));
SessionInformation.Login.Password = newPassword;
Dispatcher.BeginInvoke(DispatcherPriority.Normal, (Action)PopUp.Close);
}
else
{
var trans = LauncherServiceFacade.DoEnumTranslationServiceSync(x => x.GetTranslation(nameof(PasswordValidationResult), (short)result));
LauncherApp.ShowError("Ändern des Passworts fehlgeschlagen", trans, true);
}
}
private void AltesPWgeaendert(object sender, RoutedEventArgs e)
{
//textblock_editFailures.Text = string.Empty;
}
//PasswortSicherheit pwS = new PasswortSicherheit();
private void NeuesPwBox_OnPasswordChanged(object sender, RoutedEventArgs e)
{
//passwortprüfer = pwS.ErmittleUndZeigePasswortStaerke(NeuesPwBox.Password, passwortprüfer);
//var fehlermeldung = string.Empty;
//textblock_editFailures.Foreground = new SolidColorBrush(Color.FromRgb(255, 72, 0));
//if (!(NeuesPwBox.Password.Any(x => sonderzeichen.Contains(x)) && NeuesPwBox.Password.Any(x => zahlen.Contains(x)) && NeuesPwBox.Password.Any(x => grossBuchstaben.Contains(x)) && NeuesPwBox.Password.Any(x => kleinBuchstaben.Contains(x))))
// fehlermeldung = "Das Passwort sollte Sonderzeichen, Zahlen, Groß- und Kleinbuchstaben enthalten";
//if (NeuesPwBox.Password.Length < 8)
// fehlermeldung = "Das Passwort sollte mindestens 8 Zeichen lang sein";
//textblock_editFailures.Text = fehlermeldung;
}
}
}

View File

@@ -1,76 +0,0 @@
<UserControl x:Class="BeWoLauncher.Components.ProfileEditView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:view="clr-namespace:BeWoLauncher.Components"
Height="300" Width="500">
<Grid Background="{StaticResource ObjectEditBackgroundBrush}">
<GroupBox Style="{StaticResource PopUpWindowStyle}">
<GroupBox.Header>
<StackPanel Orientation="Horizontal" VerticalAlignment="Center" Margin="0">
<Image Source="pack://application:,,,/View/Icons/ContactCardWebDisabled.png" RenderTransformOrigin="0.5,0.5" Width="Auto" Height="28" Margin="0,0,0,0">
<Image.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="0" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Image.RenderTransform>
</Image>
<TextBox Text="Profile verwalten" Margin="10,4,0,0" Background="{x:Null}" Foreground="{DynamicResource MainGroupBoxForegroundBrush}" FontSize="20" BorderBrush="{x:Null}" VerticalAlignment="Stretch" BorderThickness="0,0,0,0" Padding="0,0,0,0" />
</StackPanel>
</GroupBox.Header>
<Grid Margin="0,3,0,0" Background="{StaticResource ObjectEditBackgroundBrush}">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid x:Name="rootGrid" Grid.Row="1" >
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid Grid.Row="0" Margin="5,10,5,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<DockPanel Margin="0" Grid.Column="1" Grid.Row="3" Grid.ColumnSpan="1">
<Button Margin="0,0,0,0" HorizontalAlignment="Right" Click="ProfileDeleteClick" Width="25" >-</Button>
<Button Margin="0,0,0,0" HorizontalAlignment="Right" Click="ProfileAddClick" Width="25" >+</Button>
</DockPanel>
</Grid>
<DataGrid x:Name="profileControl" Grid.Row="1" Margin="5"
SelectionMode="Single" AutoGenerateColumns="False" CanUserResizeRows="False" CanUserSortColumns="False" CellEditEnding="ProfileControl_CellEditEnding" >
<DataGrid.Columns>
<DataGridTextColumn Header="Profilname" Binding="{Binding Name}" Width="70"/>
<DataGridTextColumn Header="Kundennummer" Binding="{Binding Tenant}" Width="100"/>
<DataGridTextColumn Header="Server" Binding="{Binding Server}" Width="*"/>
</DataGrid.Columns>
</DataGrid>
<Border Grid.Row="2" Grid.ColumnSpan="3" Height="40" Margin="0,10,0,0" VerticalAlignment="Stretch" Background="#FF000000">
<Border.OpacityMask>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#19000000" Offset="0" />
<GradientStop Color="#33FFFFFF" Offset="1" />
</LinearGradientBrush>
</Border.OpacityMask>
</Border>
<StackPanel Grid.ColumnSpan="3" Grid.Row="2" Orientation="Horizontal" VerticalAlignment="Center" Height="Auto" Margin="5,10,0,0" HorizontalAlignment="Right">
<Button x:Name="btnSave" Content="Speichern und schließen" Margin="0,0,3,0" Command="ApplicationCommands.Save" Height="25" />
<Button x:Name="btnClose" Content="Abbrechen" Margin="0,0,3,0" Command="ApplicationCommands.Close" Height="25" />
</StackPanel>
</Grid>
</Grid>
</GroupBox>
</Grid>
</UserControl>

View File

@@ -1,68 +0,0 @@
using BeWoLauncher.Logic;
using BeWoLauncher.Models;
using BS.SharedLauncher;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;
namespace BeWoLauncher.Components
{
/// <summary>
/// Interaktionslogik für ProfileEditView.xaml
/// </summary>
public partial class ProfileEditView : UserControl
{
private ObservableCollection<ConnectionProfile> _Profiles;
public ObservableCollection<ConnectionProfile> Profiles
{
get { return _Profiles; }
set
{
_Profiles = value;
profileControl.ItemsSource = value;
}
}
public ProfileEditView()
{
InitializeComponent();
Profiles = new ObservableCollection<ConnectionProfile>();
}
private void ProfileAddClick(object sender, RoutedEventArgs e)
{
var bp = new ConnectionProfile("<Neuer Eintrag>", string.Empty, string.Empty);
if (Profiles.Contains(bp))
return;
Profiles.Add(bp);
}
private void ProfileDeleteClick(object sender, RoutedEventArgs e)
{
if (Profiles.Count == 1)
{
MessageBox.Show("Es muss mindestens ein Profil vorhanden sein.\nLöschen nicht möglich",
"Löschen nicht möglich", MessageBoxButton.OK, MessageBoxImage.Warning);
return;
}
if(profileControl.SelectedItem is null)
{
MessageBox.Show("Wählen Sie ein Profil aus",
"Löschen nicht möglich", MessageBoxButton.OK);
return;
}
Profiles.Remove(profileControl.SelectedItem as ConnectionProfile);
}
private void ProfileControl_CellEditEnding(object sender, DataGridCellEditEndingEventArgs e)
{
}
}
}

View File

@@ -1,20 +0,0 @@
<Window x:Class="BeWoLauncher.Components.ProxyLoginView"
x:ClassModifier="internal"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="Proxy Einstellungen" Height="200" Width="300">
<Grid>
<Button x:Name="proxyOK" Content="OK" HorizontalAlignment="Left" Margin="75,120,0,0" VerticalAlignment="Top" Width="100" Click="proxyOK_Click"/>
<Button x:Name="proxyAbbr" Content="Abbrechen" HorizontalAlignment="Left" Margin="180,120,0,0" VerticalAlignment="Top" Width="100" Click="proxyAbbr_Click"/>
<Label Content="Proxyname:" HorizontalAlignment="Left" Margin="10,15,0,0" VerticalAlignment="Top" Width="100"/>
<Label Content="Benutzername:" HorizontalAlignment="Left" Margin="10,45,0,0" VerticalAlignment="Top" Width="100"/>
<Label Content="Passwort:" HorizontalAlignment="Left" Margin="10,75,0,0" VerticalAlignment="Top" Width="100"/>
<TextBox x:Name="proxynametxt" HorizontalAlignment="Left" Height="23" Margin="120,15,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="160" SelectionOpacity="0.5" />
<TextBox x:Name="proxybenutzer" HorizontalAlignment="Left" Height="23" Margin="120,45,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="160" SelectionOpacity="0.5"/>
<PasswordBox x:Name="proxypasswort" HorizontalAlignment="Left" Height="23" Margin="120,75,0,0" VerticalAlignment="Top" Width="160" SelectionOpacity="0.5"/>
</Grid>
</Window>

View File

@@ -1,120 +0,0 @@
using BeWoLauncher.Logic.Utils;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Security.Cryptography;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;
namespace BeWoLauncher.Components
{
/// <summary>
/// Interaktionslogik für ProxyLoginView.xaml
/// </summary>
internal partial class ProxyLoginView : Window
{
public ProxyLoginView()
{
InitializeComponent();
überprüfe();
}
private void überprüfe() {
if (proxynametxt.Text.Equals("") && proxybenutzer.Text.Equals("") && proxypasswort.Password.Equals("")) {
int counter = 0;
string line;
string[] datai= new string[3];
try
{
var filePath = System.IO.Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location) + "\\proxy.dat";
if (!File.Exists(filePath))
{
filePath = System.IO.Path.Combine(LauncherUtils.GetAndCreateUserAppDataPath(), "proxy.dat");
}
var file = new System.IO.StreamReader(filePath);
while ((line = file.ReadLine()) != null)
{
byte[] decbuff = Convert.FromBase64String(line);
var x= System.Text.Encoding.UTF8.GetString(decbuff);
datai[counter] = x;
counter++;
}
file.Close();
proxynametxt.Text = datai[0];
proxybenutzer.Text = datai[1];
proxypasswort.Password = datai[2];
}catch(IOException){
//Fehlermeldung
}
}
}
private void proxyOK_Click(object sender, RoutedEventArgs e)
{
string ptname = proxynametxt.Text;
string ptbenutzer = proxybenutzer.Text;
string ptpasswd = proxypasswort.Password;
string[] lines = { ptname, ptbenutzer, ptpasswd };
try
{
var filePath = System.IO.Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location) + "\\proxy.dat";
if (!File.Exists(filePath))
{
filePath = System.IO.Path.Combine(LauncherUtils.GetAndCreateUserAppDataPath(), "proxy.dat");
}
using (System.IO.StreamWriter file =
new System.IO.StreamWriter(filePath))
{
foreach (string line in lines)
{
byte[] encData_byte = new byte[line.Length];
encData_byte = System.Text.Encoding.UTF8.GetBytes(line);
string encodedData = Convert.ToBase64String(encData_byte);
file.WriteLine(encodedData);
}
}
ptname = "";
ptbenutzer = "";
ptpasswd = "";
this.Close();
}catch(IOException){
//Fehlermeldung
}
}
private void proxyAbbr_Click(object sender, RoutedEventArgs e)
{
this.Close();
}
}
}

View File

@@ -1,31 +0,0 @@
<Window x:Class="BeWoLauncher.Components.PwVergessenView"
x:ClassModifier="internal"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="PwVergessenView" Height="135" Width="322" WindowStartupLocation="CenterScreen" WindowStyle="None"
AllowsTransparency="True"
Background="Transparent"
ResizeMode="NoResize">
<Grid>
<GroupBox Header="Passwort anfordern" Style="{DynamicResource MainContentGroupBoxWithoutMaximizeBtnStyle}" MouseLeftButtonDown="RootGroupBox_OnMouseLeftButtonDown">
<Grid Background="{StaticResource ObjectEditBackgroundBrush}">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<TextBlock Grid.Column="0" Grid.Row="0" Grid.ColumnSpan="2" Height="20" VerticalAlignment="Center" HorizontalAlignment="Center" Foreground="Red" Margin="3,8,3,3"/>
<Label Grid.Row="1" Grid.Column="0" Margin="3" Content="Benutzername" />
<TextBox x:Name="BenutzernamenTextBox" Grid.Row="1" Grid.Column="1" MaxLines="1" Margin="3" />
<StackPanel Grid.Row="2" Grid.Column="0" Grid.ColumnSpan="2" Orientation="Horizontal" HorizontalAlignment="Stretch">
<Button Margin="3" Content="Neues Passwort anfordern" Width="150" Click="AnfordernClick" IsDefault="True" VerticalContentAlignment="Center" />
<Button Margin="3" Content="Abbrechen" Width="150" Command="Close" />
</StackPanel>
</Grid>
</GroupBox>
</Grid>
</Window>

View File

@@ -1,49 +0,0 @@
using System;
using System.Windows;
using System.Windows.Input;
namespace BeWoLauncher.Components
{
internal partial class PwVergessenView
{
private string email = "";
public PwVergessenView()
{
InitializeComponent();
CommandBindings.Add(new CommandBinding(ApplicationCommands.Close, (s, e) => Close()));
}
private void RootGroupBox_OnMouseLeftButtonDown(object sender, MouseButtonEventArgs e)
{
try
{
DragMove();
}
catch (Exception) { }
}
private void AnfordernClick(object sender, RoutedEventArgs e)
{
var benutzername = BenutzernamenTextBox.Text;
if (benutzername.Equals(""))
{
MessageBox.Show("Bitte geben Sie einen Benutzernamen an", "Passwort anfordern fehlgeschlagen", MessageBoxButton.OK, MessageBoxImage.Information);
return;
}
//ServiceFacade.DoUserServiceAsync(s => s.GetEmailForUserName(out email, benutzername, ConnectionInformation.CoreServerAddressOrigin), CallBack, true);
}
private void CallBack(bool hatEmail)
{
if(email.Equals("") || !hatEmail)
{
MessageBox.Show("Es konnte kein Benutzer mit diesem Namen gefunden werden oder der Benutzer hat keine E-Mail Adresse hinterlegt\nBitte wenden Sie sich an Ihren Systemadministrator", "Passwort anfordern fehlgeschlagen", MessageBoxButton.OK, MessageBoxImage.Information);
return;
}
MessageBox.Show("Es wurde eine E-Mail an " + email + " gesendet");
this.Dispatcher.BeginInvoke(System.Windows.Threading.DispatcherPriority.Normal, (Action)Close);
}
}
}

View File

@@ -1,162 +0,0 @@
<UserControl x:Class="BeWoLauncher.Components.WaitLayer2"
x:ClassModifier="internal"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
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"
mc:Ignorable="d"
Foreground="{DynamicResource BSOrangeBrush}">
<UserControl.Resources>
<Style TargetType="{x:Type Rectangle}">
<Setter Property="Fill" Value="{Binding Path=Foreground, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type UserControl}}}" />
<Setter Property="Width" Value="12" />
<Setter Property="Height" Value="40" />
</Style>
<Storyboard x:Key="OnLoaded1" RepeatBehavior="Forever">
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00.1" Storyboard.TargetName="bSLogoControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" >
<LinearDoubleKeyFrame KeyTime="0:0:0" Value="45" />
</DoubleAnimationUsingKeyFrames>
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00.2" Storyboard.TargetName="bSLogoControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" >
<LinearDoubleKeyFrame KeyTime="0:0:0" Value="90" />
</DoubleAnimationUsingKeyFrames>
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00.3" Storyboard.TargetName="bSLogoControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" >
<LinearDoubleKeyFrame KeyTime="0:0:0" Value="135" />
</DoubleAnimationUsingKeyFrames>
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00.4" Storyboard.TargetName="bSLogoControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" >
<LinearDoubleKeyFrame KeyTime="0:0:0" Value="180" />
</DoubleAnimationUsingKeyFrames>
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00.5" Storyboard.TargetName="bSLogoControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" >
<LinearDoubleKeyFrame KeyTime="0:0:0" Value="225" />
</DoubleAnimationUsingKeyFrames>
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00.6" Storyboard.TargetName="bSLogoControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" >
<LinearDoubleKeyFrame KeyTime="0:0:0" Value="270" />
</DoubleAnimationUsingKeyFrames>
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00.7" Storyboard.TargetName="bSLogoControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" >
<LinearDoubleKeyFrame KeyTime="0:0:0" Value="315" />
</DoubleAnimationUsingKeyFrames>
<DoubleAnimationUsingKeyFrames BeginTime="00:00:00.8" Storyboard.TargetName="bSLogoControl" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" >
<LinearDoubleKeyFrame KeyTime="0:0:0" Value="360" />
</DoubleAnimationUsingKeyFrames>
</Storyboard>
</UserControl.Resources>
<UserControl.Triggers>
<EventTrigger RoutedEvent="FrameworkElement.Loaded">
<BeginStoryboard Storyboard="{StaticResource OnLoaded1}" />
</EventTrigger>
</UserControl.Triggers>
<Grid>
<Grid Background="White" Opacity="0.01" />
<Border CornerRadius="5,5,5,5" Opacity="0.92" BorderThickness="1,1,1,1" Padding="5,5,5,5" BorderBrush="#FF606060" VerticalAlignment="Center" Width="250" Height="100" Background="#FFFFFFFF">
<Border.OpacityMask>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#F3FFFFFF" Offset="0.027" />
<GradientStop Color="#D7FFFFFF" Offset="1" />
</LinearGradientBrush>
</Border.OpacityMask>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*" />
<RowDefinition Height="2*" />
</Grid.RowDefinitions>
<Label Content="Daten werden übertragen. Bitte warten..." Foreground="#FF000000" FontSize="12" FontFamily="Microsoft Sans Serif" FontWeight="Normal" HorizontalAlignment="Center" VerticalAlignment="Center" />
<Grid Grid.Row="1" HorizontalAlignment="Center" VerticalAlignment="Center" Width="40" Height="40" x:Name="bSLogoControl" RenderTransformOrigin="0.5,0.5" Background="#00000000" >
<Grid.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="0" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Grid.RenderTransform>
<Viewbox StretchDirection="Both" Stretch="Fill"
MaxWidth="{Binding Path=ActualWidth, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type UserControl}}}"
MaxHeight="{Binding Path=ActualHeight, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type UserControl}}}">
<Canvas Width="100" Height="100">
<Canvas Width="100" Height="100" Canvas.Left="0" Canvas.Top="0">
<Rectangle Canvas.Left="44" Canvas.Top="0" RadiusX="6" RadiusY="6"/>
</Canvas>
<Canvas Width="100" Height="100" Canvas.Left="0" Canvas.Top="0" RenderTransformOrigin="0.5,0.5">
<Canvas.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="45" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Canvas.RenderTransform>
<Rectangle Canvas.Left="44" Canvas.Top="0" RadiusX="6" RadiusY="6" Opacity="0.875"/>
</Canvas>
<Canvas Width="100" Height="100" Canvas.Left="0" Canvas.Top="0" RenderTransformOrigin="0.5,0.5">
<Canvas.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="90" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Canvas.RenderTransform>
<Rectangle Canvas.Left="44" Canvas.Top="0" RadiusX="6" RadiusY="6" Opacity="0.75"/>
</Canvas>
<Canvas Width="100" Height="100" Canvas.Left="0" Canvas.Top="0" RenderTransformOrigin="0.5,0.5">
<Canvas.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="135" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Canvas.RenderTransform>
<Rectangle Canvas.Left="44" Canvas.Top="0" RadiusX="6" RadiusY="6" Opacity="0.625"/>
</Canvas>
<Canvas Width="100" Height="100" Canvas.Left="0" Canvas.Top="0" RenderTransformOrigin="0.5,0.5">
<Canvas.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="180" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Canvas.RenderTransform>
<Rectangle Canvas.Left="44" Canvas.Top="0" RadiusX="6" RadiusY="6" Opacity="0.5"/>
</Canvas>
<Canvas Width="100" Height="100" Canvas.Left="0" Canvas.Top="0" RenderTransformOrigin="0.5,0.5">
<Canvas.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="225" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Canvas.RenderTransform>
<Rectangle Canvas.Left="44" Canvas.Top="0" RadiusX="6" RadiusY="6" Opacity="0.375"/>
</Canvas>
<Canvas Width="100" Height="100" Canvas.Left="0" Canvas.Top="0" RenderTransformOrigin="0.5,0.5">
<Canvas.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="270" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Canvas.RenderTransform>
<Rectangle Canvas.Left="44" Canvas.Top="0" RadiusX="6" RadiusY="6" Opacity="0.25"/>
</Canvas>
<Canvas Width="100" Height="100" Canvas.Left="0" Canvas.Top="0" RenderTransformOrigin="0.5,0.5">
<Canvas.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="315" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Canvas.RenderTransform>
<Rectangle Canvas.Left="44" Canvas.Top="0" RadiusX="6" RadiusY="6" Opacity="0.125"/>
</Canvas>
</Canvas>
</Viewbox>
</Grid>
</Grid>
</Border>
</Grid>
</UserControl>

View File

@@ -1,16 +0,0 @@
using System.Windows;
using System.Windows.Controls;
namespace BeWoLauncher.Components
{
/// <summary>
/// Interaction logic for WaitLayer.xaml
/// </summary>
internal partial class WaitLayer2 : UserControl
{
public WaitLayer2()
{
this.InitializeComponent();
}
}
}

View File

@@ -1,79 +0,0 @@
<UserControl x:Class="BeWoLauncher.View.FrameView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
d:DesignHeight="400" d:DesignWidth="600"
Width="Auto">
<Grid Name="grid_root" >
<StackPanel HorizontalAlignment="Center" >
<Grid Background="{x:Null}" Height="400" Width="600" Visibility="Visible" x:Name="gridLogin" RenderTransformOrigin="0.5,0.5" Margin="0,0,0,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="7*"/>
<ColumnDefinition Width="93*"/>
</Grid.ColumnDefinitions>
<Grid.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="0" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Grid.RenderTransform>
<Border CornerRadius="7,7,7,7" BorderThickness="2,2,2,2" Padding="5,5,5,5" BorderBrush="#FF606060" Background="{DynamicResource LoginBackgroundColor}" Grid.ColumnSpan="2">
<Grid Opacity="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="100" />
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="170" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="70" />
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Image Grid.Row="0" Grid.ColumnSpan="4" HorizontalAlignment="Left" VerticalAlignment="Top" Source="pack://application:,,,/View/Icons/bewoplaner_logo_big.png" Height="45" Margin="7,7,0,0"/>
<Label VerticalAlignment="Top" HorizontalAlignment="Right" Content="Version x.x.x" Foreground="#FF818181" Margin="5,7,3,0" Grid.Row="0" Grid.ColumnSpan="4"
Grid.Column="0" FontSize="10" x:Name="lblVersion" />
<Button Grid.Row="7" Grid.Column="2" Visibility="Hidden">Debug</Button>
<Grid x:Name="contentGrid" Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="4" Margin="3" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" >
</Grid>
<TextBlock x:Name="txtCopyright" Grid.Row="2" Grid.Column="0" Grid.ColumnSpan="3" HorizontalAlignment="Left" VerticalAlignment="Bottom" FontSize="10" Margin="10,5,0,5" Text="Copyright 2017 | beyondSoft GmbH" Foreground="#FF818181"/>
<TextBlock Grid.Row="2" Grid.Column="3" HorizontalAlignment="Right" VerticalAlignment="Bottom" FontSize="10" Margin="0,5,12,5">
<Hyperlink x:Name="hyperlink" TargetName="newWindow" Foreground="#FF818181" NavigateUri="http://www.beyondsoft.de" RequestNavigate="Hyperlink_OnRequestNavigate">www.beyondsoft.de</Hyperlink>
</TextBlock>
</Grid>
</Border>
<Line Grid.ColumnSpan="2" Stroke="#FFADADAD" X1="14" Y1="70" X2="585" Y2="70" StrokeThickness="1"></Line>
<Line x:Name="linkLine" Stroke="#FFADADAD" X1="14" Y1="340" X2="585" Y2="340" StrokeThickness="1" Margin="0,30,0,-30" Grid.ColumnSpan="2"></Line>
</Grid>
<Rectangle Width="600" Height="400" RenderTransformOrigin="0.5,0.5">
<Rectangle.OpacityMask>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0.418">
<GradientStop Color="#00000000" Offset="0" />
<GradientStop Color="#4CFFFFFF" Offset="1" />
</LinearGradientBrush>
</Rectangle.OpacityMask>
<Rectangle.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="-1" />
<SkewTransform AngleX="0" AngleY="0" />
<RotateTransform Angle="0" />
<TranslateTransform X="0" Y="0" />
</TransformGroup>
</Rectangle.RenderTransform>
<Rectangle.Fill>
<VisualBrush Visual="{Binding ElementName=gridLogin}" />
</Rectangle.Fill>
</Rectangle>
</StackPanel>
</Grid>
</UserControl>

View File

@@ -1,66 +0,0 @@
using BeWoLauncher.Logic;
using BeWoLauncher.Logic.Controller;
using BeWoLauncher.View.Frames;
using BeWoLauncher.WindowImp;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace BeWoLauncher.View
{
/// <summary>
/// Interaktionslogik für BeWoLoginBorder.xaml
/// </summary>
public partial class FrameView : UserControl
{
public FrameView()
{
InitializeComponent();
DateTime dt = new DateTime(2017, 1, 1);
if (DateTime.Now > dt)
dt = DateTime.Now;
txtCopyright.Text = String.Format("Copyright {0:yyyy} | beyondSoft GmbH", dt);
lblVersion.Content = LauncherApp.Version;
}
public FrameView(FrameBase frame) : this()
{
SetFrame(frame);
}
private void Hyperlink_OnRequestNavigate(object sender, RequestNavigateEventArgs e)
{
System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo((sender as Hyperlink).NavigateUri.ToString()));
}
public FrameBase GetFrame()
{
return contentGrid.Children?[0] as FrameBase;
}
public void SetFrame(FrameBase uc)
{
ClearFrame();
contentGrid.Children.Add(uc);
}
public void ClearFrame()
{
contentGrid.Children.Clear();
}
}
}

View File

@@ -1,13 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Controls;
namespace BeWoLauncher.View.Frames
{
public class FrameBase : UserControl
{
}
}

View File

@@ -1,21 +0,0 @@
<local:FrameBase x:Class="BeWoLauncher.View.Frames.InfoFrame"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:BeWoLauncher.View.Frames"
mc:Ignorable="d"
d:DesignHeight="400" d:DesignWidth="600">
<Grid x:Name="root" >
<DockPanel Margin="5">
<Label DockPanel.Dock="Top" FontWeight="Bold" FontSize="15" x:Name="lblTitle">Fehler in der Installation aufgetreten!</Label>
<StackPanel DockPanel.Dock="Bottom" VerticalAlignment="Bottom" HorizontalAlignment="Center" Orientation="Horizontal" Margin="0,10,0,0">
<Button x:Name="btnCopy" Width="70" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="0,0,5,0" Click="Button_Click">Kopieren</Button>
<Button Width="200" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="0" Click="Button_Click_1">Zurück zum Login</Button>
</StackPanel>
<TextBox x:Name="txtField2" DockPanel.Dock="Top" BorderThickness="0" Background="Transparent" Margin="3" TextWrapping="Wrap" VerticalScrollBarVisibility="Auto">
Hier könnte ihre Fehlermeldung stehen!
</TextBox>
</DockPanel>
</Grid>
</local:FrameBase>

View File

@@ -1,54 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace BeWoLauncher.View.Frames
{
/// <summary>
/// Interaktionslogik für ErrorScreen.xaml
/// </summary>
public partial class InfoFrame : FrameBase
{
public event EventHandler Button1Click;
public InfoFrame()
{
InitializeComponent();
}
public string Title
{
get => lblTitle.Content as string;
set => lblTitle.Content = value;
}
public string Text
{
get => txtField2.Text;
set => txtField2.Text = value;
}
public void CollapseCopyButton() => btnCopy.Visibility = Visibility.Collapsed;
private void Button_Click(object sender, RoutedEventArgs e)
{
System.Windows.Clipboard.SetText(Text);
}
private void Button_Click_1(object sender, RoutedEventArgs e)
{
Button1Click.Invoke(this, new EventArgs());
}
}
}

View File

@@ -1,63 +0,0 @@
<local:FrameBase
x:Class="BeWoLauncher.View.Frames.InstallInfoFrame"
xmlns:local="clr-namespace:BeWoLauncher.View.Frames"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
d:DesignHeight="400" d:DesignWidth="600" >
<Grid x:Name="root" >
<DockPanel Margin="5">
<Label DockPanel.Dock="Top" FontWeight="Bold">Sie sind dabei BeWoPlaner zu installieren.</Label>
<!--<StackPanel Orientation="Vertical" Margin="6">
<CheckBox>Desktopverknüpfung erstellen</CheckBox>
<CheckBox>Startmenüverknüpfung erstellen</CheckBox>
</StackPanel>-->
<Grid DockPanel.Dock="Top" Margin="10,5,0,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="30"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition/>
<RowDefinition Height="3"/>
<RowDefinition/>
<RowDefinition/>
<RowDefinition Height="3"/>
<RowDefinition/>
<RowDefinition/>
</Grid.RowDefinitions>
<Label Grid.Column="0" Grid.Row="0">Version:</Label>
<Label Grid.Column="2" Grid.Row="0" x:Name="lblversion" Margin="10,0,0,0">1.0.0.0 t</Label>
<Label Grid.Column="0" Grid.Row="2" Margin="0,0,0,0" >Erforderlicher Festplattenspeicher:</Label>
<Label Grid.Column="2" Grid.Row="2" x:Name="lblErforderlich" HorizontalAlignment="Right">10.9t</Label>
<Label Grid.Column="3" Grid.Row="2" x:Name="lblErforderlichSize" HorizontalAlignment="Left">GB</Label>
<Label Grid.Column="0" Grid.Row="3" Margin="0,-5,0,0">Verfügbarer Festplattenspeicher:</Label>
<Label Grid.Column="2" Grid.Row="3" Margin="0,-5,0,0" x:Name="lblVerfuegbar" HorizontalAlignment="Right">20.0t</Label>
<Label Grid.Column="3" Grid.Row="3" Margin="0,-5,0,0" x:Name="lblVerfuegbarSize" HorizontalAlignment="Left">GB</Label>
</Grid>
<StackPanel DockPanel.Dock="Bottom" VerticalAlignment="Bottom" HorizontalAlignment="Center" Orientation="Horizontal" Margin="0,10,0,0">
<Button Width="70" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="0" Click="Button_Click">Abbrechen</Button>
<Button Width="100" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="5,0,0,0" Click="Button_Click_1">Installieren</Button>
</StackPanel>
<GroupBox DockPanel.Dock="Bottom" VerticalAlignment="Bottom" Header="Installationsordner" BorderBrush="#FFADADAD" >
<DockPanel LastChildFill="True">
<Button Click="button_installLoc_Click" DockPanel.Dock="Right" Margin="0,0,0,0" Height="23" ToolTip="Sie müssen einen leeren Ordner auswählen, auf welchen Sie schreibrechte besitzen.">Auswählen</Button>
<TextBox x:Name="txtLoc" Height="23" DockPanel.Dock="Left" Width="Auto" Margin="3,0,3,0" IsReadOnly="True" VerticalContentAlignment="Center" IsEnabled="False"></TextBox>
</DockPanel>
</GroupBox>
</DockPanel>
</Grid>
</local:FrameBase>

View File

@@ -1,105 +0,0 @@
using BeWoLauncher.Logic.Controller;
using BeWoLauncher.Logic.Utils;
using BS.SharedLauncher.Information;
using BS.SharedLauncher.Utils;
using System;
using System.IO;
using System.Windows;
using Path = System.IO.Path;
namespace BeWoLauncher.View.Frames
{
/// <summary>
/// Interaktionslogik für UpdateInfo1.xaml
/// </summary>
public partial class InstallInfoFrame : FrameBase
{
public event EventHandler Accept;
public event EventHandler Abort;
public InstallInfoFrame()
{
InitializeComponent();
InstallLocation = LauncherPaths.GetInstallLocationFromSettingOrDefault();
var size = NonspecificTools.SizeSuffix((ulong)DownloadController.Manager.UpdatePlanResponse.DownloadSize).Split(' ');
lblErforderlich.Content = size[0];
lblErforderlichSize.Content = size[1];
lblversion.Content = DownloadController.Manager.UpdatePlanResponse.CurrentPackage.Version;
}
public string InstallLocation
{
get
{
return LauncherPaths.LoginSelectionPlanerLocation;
}
set
{
if (!endPathWithSubDir(value))
value = Path.Combine(value, BeWoPathFileConfig.SubDirectory);
if (LauncherPaths.ChangePath(value))
{
txtLoc.Text = value;
var size2 = DownloadController.UpdateDiskSpace(LauncherPaths.LoginSelectionPlanerLocation).Split(' ');
if (size2.Length > 1)
{
lblVerfuegbar.Content = size2[0];
lblVerfuegbarSize.Content = size2[1];
}
else
{
lblVerfuegbar.Content = size2[0] ?? "error#87";
lblVerfuegbarSize.Content = string.Empty;
}
}
}
}
private void button_installLoc_Click(object sender, RoutedEventArgs rea)
{
// https://stackoverflow.com/questions/11624298/how-to-use-openfiledialog-to-select-a-folder
using (var fbd = new System.Windows.Forms.FolderBrowserDialog())
{
fbd.SelectedPath = getPathWithoutSubDir(InstallLocation);
System.Windows.Forms.DialogResult result = fbd.ShowDialog();
if (result == System.Windows.Forms.DialogResult.OK && !string.IsNullOrWhiteSpace(fbd.SelectedPath))
{
InstallLocation = fbd.SelectedPath;
}
}
}
private bool endPathWithSubDir(string path)
{
var dirName = new DirectoryInfo(path).Name;
return (dirName == BeWoPathFileConfig.SubDirectory);
}
private string getPathWithoutSubDir(string path)
{
if (endPathWithSubDir(path))
return Directory.GetParent(path).FullName;
return path;
}
private void Button_Click(object sender, RoutedEventArgs e)
{
Abort.Invoke(this, new EventArgs());
}
private void Button_Click_1(object sender, RoutedEventArgs e)
{
Accept.Invoke(this, new EventArgs());
}
}
}

View File

@@ -1,15 +0,0 @@
<local:FrameBase x:Class="BeWoLauncher.View.Frames.LoadingScreen"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:BeWoLauncher.View.Frames"
mc:Ignorable="d"
d:DesignHeight="450" d:DesignWidth="800" Loaded="UserControl_Loaded">
<Grid>
<DockPanel Margin="5">
<Label FontSize="15" FontWeight="Bold" DockPanel.Dock="Top" HorizontalAlignment="Left" Margin="50,30,0,0">Starte BeWoPlaner</Label>
<ProgressBar DockPanel.Dock="Top" Height="30" IsIndeterminate="True" Margin="10" ></ProgressBar>
</DockPanel>
</Grid>
</local:FrameBase>

View File

@@ -1,33 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace BeWoLauncher.View.Frames
{
/// <summary>
/// Interaktionslogik für LoadingScreen.xaml
/// </summary>
public partial class LoadingScreen : FrameBase
{
public LoadingScreen()
{
InitializeComponent();
}
private void UserControl_Loaded(object sender, RoutedEventArgs e)
{
}
}
}

View File

@@ -1,22 +0,0 @@
<frames:FrameBase
x:Class="BeWoLauncher.View.Frames.ProgressFrame"
xmlns:frames="clr-namespace:BeWoLauncher.View.Frames"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
d:DesignHeight="400" d:DesignWidth="600">
<Grid Opacity="1">
<DockPanel Margin="5">
<StackPanel DockPanel.Dock="Top" Margin="0,0,0,0" Orientation="Vertical">
<Label x:Name="lblMessage" Content="t - bewoplaner wird aktualisiert..." Foreground="#FF000000" FontSize="12" FontWeight="Bold" Margin="0,0,0,0" />
<Label x:Name="lblSubmessage" Content="t - Update wird installiert" Foreground="#FF000000" FontSize="12" />
</StackPanel>
<StackPanel DockPanel.Dock="Top" Margin="0,0,0,0" Orientation="Vertical" VerticalAlignment="Center">
<ProgressBar DockPanel.Dock="Top" x:Name="proBar1" Width="500" Height="15" Minimum="0" Maximum="100" IsIndeterminate="True" Margin="5"/>
<ProgressBar DockPanel.Dock="Top" x:Name="proBar2" Width="500" Height="20" Minimum="0" Maximum="100" IsIndeterminate="True"/>
</StackPanel>
</DockPanel>
</Grid>
</frames:FrameBase>

View File

@@ -1,237 +0,0 @@
using BeWoLauncher.Logic.Controller;
using BS.SharedLauncher.Enums;
using BS.SharedLauncher.Update;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Configuration;
using System.Threading;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media.Animation;
namespace BeWoLauncher.View.Frames
{
/// <summary>
/// Interaktionslogik für UpdateView.xaml
/// </summary>
public partial class ProgressFrame : FrameBase
{
private static TimeSpan duration = TimeSpan.FromSeconds(1);
private int lastStep = -1;
private string[][] keywords = new string[][]
{
new string[]{"Installation", "Ungebrauchte Datei(en) gefunden." },
new string[]{"Update", "Ungebrauchte Datei(en) gefunden."},
new string[]{"Deinstallation", "Deinstallation startet..."},
};
private int keyword_mode;
public readonly BackgroundWorker Worker = new BackgroundWorker();
public event EventHandler Successful;
public event EventHandler Exception;
public LauncherMode LauncherMode { get; set; }
public ProgressFrame(LauncherMode mode)
{
InitializeComponent();
proBar1.IsIndeterminate = false;
proBar1.Minimum = 0;
proBar1.Maximum = 100;
proBar2.IsIndeterminate = false;
proBar2.Minimum = 0;
proBar2.Maximum = DownloadController.Manager.FilesToProcessTotal;
LauncherMode = mode;
keyword_mode = (int)mode;
Loaded += (s, e) => Start();
}
private string getKeyword(int pos) => keywords[keyword_mode][pos];
public string Message
{
get { return lblMessage.Content as string; }
set { lblMessage.Content = value; }
}
public string SubMessage
{
get { return lblSubmessage.Content as string; }
set { lblSubmessage.Content = value; }
}
public void Start()
{
var skipLock = bool.TryParse(ConfigurationManager.AppSettings.Get("SkipLock"), out bool c) && c;
Worker.DoWork += worker_DoWork;
Worker.ProgressChanged += worker_ProgressChanged;
Worker.RunWorkerCompleted += worker_completed;
Worker.WorkerReportsProgress = true;
Worker.RunWorkerAsync(skipLock);
}
void worker_DoWork(object sender, DoWorkEventArgs e)
{
var skipLock = (bool)e.Argument;
var worker = sender as BackgroundWorker;
DownloadController.Manager.SkipLock = skipLock;
DownloadController.Manager.Feedback = worker.ReportProgress;
DownloadController.Manager.StartProcess(worker);
}
private void worker_completed(object sender, RunWorkerCompletedEventArgs e)
{
if (e.Error != null)
{
ViewController.Error = e.Error;
Exception.Invoke(this, new EventArgs());
}
else
{
Successful.Invoke(this, new EventArgs());
}
}
private void worker_ProgressChanged(object sender, ProgressChangedEventArgs e)
{
var progress = (LauncherProgress)e.ProgressPercentage;
var obj = e.UserState;
switch (progress)
{
case LauncherProgress.ProgressStart:
Message = $"{getKeyword(0)} wird vorbereitet...";
SubMessage = "";
Bar2Activate();
break;
case LauncherProgress.DownloadStart:
Message = "Download startet...";
SubMessage = "";
Bar1Show();
Bar1Activate();
Bar1Reset();
Bar1SetLimit(DownloadController.Manager.FilesToDownloadCount);
break;
case LauncherProgress.DownloadUpdate:
var args = obj as DownloadProgressEventArgs;
Message = "Download wird ausgeführt...";
SubMessage = $"{args.File.RelativePath} ({args.Size})\n wurde heruntergeladen...";
Bar1MakeStep();
Bar2MakeStep();
break;
case LauncherProgress.DownloadFinish:
Message = "Download abgeschlossen!";
SubMessage = "";
Bar1Hide();
break;
case LauncherProgress.ApplyStart:
Message = "Füge Pakete hinzu...";
SubMessage = "";
Bar1Show();
Bar1Activate();
Bar1Reset();
Bar1SetLimit(DownloadController.Manager.FilesToApplyCount);
break;
case LauncherProgress.ApplyUpdate:
var args2 = obj as ApplyFileEventArgs;
SubMessage = $"{args2.RelativePath}\n wurde installiert...";
Bar1MakeStep();
Bar2MakeStep();
break;
case LauncherProgress.ApplyFinished:
Message = "Hinzufügen abgeschlossen!";
SubMessage = "";
Bar1Hide();
break;
case LauncherProgress.DeleteStart:
Message = getKeyword(1);
SubMessage = "";
Bar1Show();
Bar1Activate();
Bar1Reset();
Bar1SetLimit(DownloadController.Manager.FilesToDeleteInApplyCount);
break;
case LauncherProgress.DeleteUpdate:
var args3 = obj as string;
SubMessage = $"{args3}\n wurde entfernt!";
Bar1MakeStep();
Bar2MakeStep();
break;
case LauncherProgress.DeleteFinished:
Message = "Säuberung abgeschlossen!";
SubMessage = "";
Bar1Hide();
break;
case LauncherProgress.CleanupStart:
Message = "Räume hier noch eben auf...";
SubMessage = "";
Bar1Show();
Bar1Deactivate();
break;
case LauncherProgress.CleanupUpdate:
break;
case LauncherProgress.CleanupFinished:
Message = "Blitze blank...";
SubMessage = "";
break;
case LauncherProgress.ProgressEnd:
Message = $"{getKeyword(0)} abgeschlossen!";
SubMessage = "";
Bar2Fill();
break;
default:
break;
}
}
#region a
public void Bar1Activate() => proBar1.IsIndeterminate = false;
public void Bar1Deactivate() => proBar1.IsIndeterminate = true;
public void Bar1SetLimit(int max) => proBar1.Maximum = max;
public void Bar1Reset() => proBar1.Value = 0;
public void Bar1MakeStep() => proBar1.Value++;
public void Bar1Hide() => proBar1.Visibility = Visibility.Hidden;
public void Bar1Show() => proBar1.Visibility = Visibility.Visible;
public void Bar2Activate() => proBar2.IsIndeterminate = false;
public void Bar2Deactivate() => proBar2.IsIndeterminate = true;
public void Bar2SetLimit(int max) => proBar2.Maximum = max;
public void Bar2MakeStep() => proBar2.Value++;
public void Bar2MakeStep(int val) => proBar2.Value += val;
public void Bar2Fill() => proBar2.Value = proBar2.Maximum;
public void Bar2Hide() => proBar2.Visibility = Visibility.Hidden;
public void Bar2Show() => proBar2.Visibility = Visibility.Visible;
public void Bar2SetPercent(double percentage)
{
DoubleAnimation animation = new DoubleAnimation(percentage, duration);
proBar2.BeginAnimation(ProgressBar.ValueProperty, animation);
}
#endregion
}
}

View File

@@ -1,20 +0,0 @@
<local:FrameBase x:Class="BeWoLauncher.View.Frames.UninstallInfoFrame"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:BeWoLauncher.View.Frames"
mc:Ignorable="d"
d:DesignHeight="400" d:DesignWidth="600" >
<Grid>
<DockPanel Margin="5">
<Label DockPanel.Dock="Top">Sie sind dabei BeWoPlaner zu deinstallieren.</Label>
<Label DockPanel.Dock="Top">Wie möchten Sie fortfahren?</Label>
<StackPanel DockPanel.Dock="Bottom" VerticalAlignment="Bottom" HorizontalAlignment="Center" Orientation="Horizontal" Margin="0,10,0,0">
<Button Width="70" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="0,0,0,0" Click="Button_Click">Abbrechen</Button>
<Button Width="100" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="5,0,0,0" Click="Button_Click_1">Deinstallieren</Button>
</StackPanel>
</DockPanel>
</Grid>
</local:FrameBase>

View File

@@ -1,41 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace BeWoLauncher.View.Frames
{
/// <summary>
/// Interaktionslogik für UpdateInfo3.xaml
/// </summary>
public partial class UninstallInfoFrame : FrameBase
{
public event EventHandler Accept;
public event EventHandler Abort;
public UninstallInfoFrame()
{
InitializeComponent();
}
private void Button_Click(object sender, RoutedEventArgs e)
{
Abort.Invoke(this, new EventArgs());
}
private void Button_Click_1(object sender, RoutedEventArgs e)
{
Accept.Invoke(this, new EventArgs());
}
}
}

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