Skip to content

Commit 84def6a

Browse files
committed
update for latest launchbox
1 parent 8140384 commit 84def6a

File tree

3 files changed

+19
-148
lines changed

3 files changed

+19
-148
lines changed
Lines changed: 15 additions & 108 deletions
Original file line numberDiff line numberDiff line change
@@ -1,116 +1,19 @@
1-
<?xml version="1.0" encoding="utf-8"?>
2-
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3-
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
1+
<Project Sdk="Microsoft.NET.Sdk">
42
<PropertyGroup>
5-
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
6-
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
7-
<ProjectGuid>{32D7987E-1A4E-48F6-97AF-7390AFEA7EF8}</ProjectGuid>
3+
<TargetFramework>net9.0-windows</TargetFramework>
84
<OutputType>Library</OutputType>
9-
<AppDesignerFolder>Properties</AppDesignerFolder>
10-
<RootNamespace>PegasusExportPlugin</RootNamespace>
11-
<AssemblyName>PegasusExportPlugin</AssemblyName>
12-
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
13-
<FileAlignment>512</FileAlignment>
14-
<Deterministic>true</Deterministic>
5+
<UseWindowsForms>true</UseWindowsForms>
6+
<ImportWindowsDesktopTargets>true</ImportWindowsDesktopTargets>
7+
<StartupObject />
158
</PropertyGroup>
169
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
17-
<DebugSymbols>true</DebugSymbols>
18-
<DebugType>full</DebugType>
19-
<Optimize>false</Optimize>
20-
<OutputPath>..\..\..\..\..\LaunchBox\Plugins\</OutputPath>
21-
<DefineConstants>DEBUG;TRACE</DefineConstants>
22-
<ErrorReport>prompt</ErrorReport>
23-
<WarningLevel>4</WarningLevel>
24-
</PropertyGroup>
25-
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
26-
<DebugType>pdbonly</DebugType>
27-
<Optimize>true</Optimize>
28-
<OutputPath>bin\Release\</OutputPath>
29-
<DefineConstants>TRACE</DefineConstants>
30-
<ErrorReport>prompt</ErrorReport>
31-
<WarningLevel>4</WarningLevel>
32-
</PropertyGroup>
33-
<PropertyGroup>
34-
<StartupObject />
10+
<OutputPath>..\..\..\..\LaunchBox\Plugins\</OutputPath>
3511
</PropertyGroup>
3612
<ItemGroup>
37-
<Reference Include="netstandard" />
38-
<Reference Include="System" />
39-
<Reference Include="System.Core" />
40-
<Reference Include="System.Drawing" />
41-
<Reference Include="System.Drawing.Common">
42-
<HintPath>..\..\..\..\LaunchBox\Metadata\System.Drawing.Common.dll</HintPath>
43-
</Reference>
44-
<Reference Include="System.Windows.Forms" />
45-
<Reference Include="System.Xml.Linq" />
46-
<Reference Include="System.Data.DataSetExtensions" />
47-
<Reference Include="Microsoft.CSharp" />
48-
<Reference Include="System.Data" />
49-
<Reference Include="System.Net.Http" />
50-
<Reference Include="System.Xml" />
51-
<Reference Include="Unbroken, Version=11.8.0.0, Culture=neutral, PublicKeyToken=97d6238f04304129, processorArchitecture=MSIL">
52-
<SpecificVersion>False</SpecificVersion>
53-
<HintPath>..\..\..\..\..\LaunchBox\Core\Unbroken.dll</HintPath>
54-
</Reference>
55-
<Reference Include="Unbroken.LaunchBox, Version=11.8.0.0, Culture=neutral, PublicKeyToken=97d6238f04304129, processorArchitecture=MSIL">
56-
<SpecificVersion>False</SpecificVersion>
57-
<HintPath>..\..\..\..\..\LaunchBox\Core\Unbroken.LaunchBox.dll</HintPath>
58-
</Reference>
59-
<Reference Include="Unbroken.LaunchBox.Plugins, Version=11.8.0.0, Culture=neutral, PublicKeyToken=558191e84f56affc, processorArchitecture=MSIL">
60-
<SpecificVersion>False</SpecificVersion>
61-
<HintPath>..\..\..\..\..\LaunchBox\Core\Unbroken.LaunchBox.Plugins.dll</HintPath>
62-
</Reference>
63-
</ItemGroup>
64-
<ItemGroup>
65-
<Compile Include="Controls\DataGridViewCheckBoxColumnHeaderCell.cs" />
66-
<Compile Include="Controls\DataGridViewCheckBoxColumnHeaderCellEventArgs.cs" />
67-
<Compile Include="Controls\DataGridViewHeaderCheckBoxColumn.cs" />
68-
<Compile Include="Controls\HeaderCheckBoxBehaviour.cs" />
69-
<Compile Include="Extensions\String.cs" />
70-
<Compile Include="frmPegasusExport.cs">
71-
<SubType>Form</SubType>
72-
</Compile>
73-
<Compile Include="frmPegasusExport.Designer.cs">
74-
<DependentUpon>frmPegasusExport.cs</DependentUpon>
75-
</Compile>
76-
<Compile Include="frmSettings.cs">
77-
<SubType>Form</SubType>
78-
</Compile>
79-
<Compile Include="frmSettings.Designer.cs">
80-
<DependentUpon>frmSettings.cs</DependentUpon>
81-
</Compile>
82-
<Compile Include="Launchbox\ImageDetail.cs" />
83-
<Compile Include="Launchbox\PlatformSetting.cs" />
84-
<Compile Include="Launchbox\PlaylistSetting.cs" />
85-
<Compile Include="ProgramEntry.cs" />
86-
<Compile Include="Pegasus\PegasusAssetType.cs" />
87-
<Compile Include="Program.cs" />
88-
<Compile Include="Properties\AssemblyInfo.cs" />
89-
<Compile Include="Properties\Resources.Designer.cs">
90-
<AutoGen>True</AutoGen>
91-
<DesignTime>True</DesignTime>
92-
<DependentUpon>Resources.resx</DependentUpon>
93-
</Compile>
94-
</ItemGroup>
95-
<ItemGroup>
96-
<EmbeddedResource Include="frmPegasusExport.resx">
97-
<DependentUpon>frmPegasusExport.cs</DependentUpon>
98-
</EmbeddedResource>
99-
<EmbeddedResource Include="frmSettings.resx">
100-
<DependentUpon>frmSettings.cs</DependentUpon>
101-
</EmbeddedResource>
102-
<EmbeddedResource Include="Properties\Resources.resx">
103-
<Generator>ResXFileCodeGenerator</Generator>
104-
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
105-
</EmbeddedResource>
106-
</ItemGroup>
107-
<ItemGroup>
108-
<None Include="Resources\favicon96.png" />
109-
</ItemGroup>
110-
<ItemGroup>
111-
<PackageReference Include="System.Drawing.Common">
112-
<Version>4.7.0</Version>
113-
</PackageReference>
13+
<PackageReference Include="Microsoft.CSharp" Version="4.7.0" />
14+
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
15+
<PackageReference Include="System.Drawing.Common" Version="9.0.10" />
16+
<PackageReference Include="System.Drawing.Common" Version="9.0.10" />
11417
</ItemGroup>
11518
<ItemGroup>
11619
<Content Include="img\img0.jpg" />
@@ -121,5 +24,9 @@
12124
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
12225
</Content>
12326
</ItemGroup>
124-
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
27+
<ItemGroup>
28+
<Reference Include="Unbroken.LaunchBox.Plugins">
29+
<HintPath>..\..\..\..\LaunchBox\Core\Unbroken.LaunchBox.Plugins.dll</HintPath>
30+
</Reference>
31+
</ItemGroup>
12532
</Project>

PegasusExportPlugin/Properties/AssemblyInfo.cs

Lines changed: 0 additions & 36 deletions
This file was deleted.

PegasusExportPlugin/frmPegasusExport.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,10 @@
1313
using PegasusExportPlugin.Controls;
1414
using PegasusExportPlugin.Launchbox;
1515
using PegasusExportPlugin.Pegasus;
16-
using Unbroken;
1716
using Unbroken.LaunchBox.Plugins;
1817
using Unbroken.LaunchBox.Plugins.Data;
1918
using PegasusExportPlugin.Extensions;
20-
using Unbroken.LaunchBox;
19+
using MethodInvoker = System.Windows.Forms.MethodInvoker;
2120

2221
namespace PegasusExportPlugin
2322
{
@@ -135,11 +134,12 @@ await Task.Run(() =>
135134
}
136135
}
137136
}
138-
137+
var invalidChars = new HashSet<char>(Path.GetInvalidPathChars());
138+
139139
Parallel.ForEach(gamesByPlatform, gamePlatform =>
140140
{
141141
var platform = gamePlatform.Key.Platform;
142-
var platformFolderName = Unbroken.LaunchBox.NamingHelper.CoerceValidFileName(platform);
142+
var platformFolderName = new string(platform.Where(c => !invalidChars.Contains(c)).ToArray());
143143
var platformPath = Path.Combine(selectedFolder, platformFolderName);
144144
Directory.CreateDirectory(platformPath);
145145
var metadataBuilder = new StringBuilder();

0 commit comments

Comments
 (0)