Skip to content

Commit 80bbbd8

Browse files
committed
Initial commit
1 parent b444b46 commit 80bbbd8

13 files changed

+634
-24
lines changed

DotNetStringRepacker/App.config

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,30 @@
11
<?xml version="1.0" encoding="utf-8" ?>
22
<configuration>
3+
<configSections>
4+
<sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" >
5+
<section name="DotNetStringRepacker.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false" />
6+
</sectionGroup>
7+
</configSections>
38
<startup>
49
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" />
510
</startup>
11+
<userSettings>
12+
<DotNetStringRepacker.Properties.Settings>
13+
<setting name="InputFile" serializeAs="String">
14+
<value />
15+
</setting>
16+
<setting name="OutputFile" serializeAs="String">
17+
<value />
18+
</setting>
19+
<setting name="StringsFile" serializeAs="String">
20+
<value />
21+
</setting>
22+
<setting name="IldasmPath" serializeAs="String">
23+
<value>il\ildasm.exe</value>
24+
</setting>
25+
<setting name="IlasmPath" serializeAs="String">
26+
<value>il\ilasm.exe</value>
27+
</setting>
28+
</DotNetStringRepacker.Properties.Settings>
29+
</userSettings>
630
</configuration>

DotNetStringRepacker/DotNetStringRepacker.csproj

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
1414
<WarningLevel>4</WarningLevel>
1515
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
16+
<NuGetPackageImportStamp>
17+
</NuGetPackageImportStamp>
1618
</PropertyGroup>
1719
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
1820
<PlatformTarget>AnyCPU</PlatformTarget>
@@ -34,14 +36,22 @@
3436
<WarningLevel>4</WarningLevel>
3537
</PropertyGroup>
3638
<ItemGroup>
39+
<Reference Include="CsvHelper, Version=2.0.0.0, Culture=neutral, PublicKeyToken=8c4959082be5c823, processorArchitecture=MSIL">
40+
<HintPath>..\packages\CsvHelper.2.16.3.0\lib\net45\CsvHelper.dll</HintPath>
41+
</Reference>
42+
<Reference Include="Gravimage, Version=1.1.0.0, Culture=neutral, processorArchitecture=MSIL">
43+
<HintPath>..\packages\Gravimage.1.1.0\lib\Gravimage.dll</HintPath>
44+
</Reference>
3745
<Reference Include="System" />
46+
<Reference Include="System.Collections.Immutable, Version=1.2.2.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
47+
<HintPath>..\packages\System.Collections.Immutable.1.4.0\lib\netstandard2.0\System.Collections.Immutable.dll</HintPath>
48+
</Reference>
3849
<Reference Include="System.Data" />
3950
<Reference Include="System.Xml" />
4051
<Reference Include="Microsoft.CSharp" />
4152
<Reference Include="System.Core" />
4253
<Reference Include="System.Xml.Linq" />
4354
<Reference Include="System.Data.DataSetExtensions" />
44-
<Reference Include="System.Net.Http" />
4555
<Reference Include="System.Xaml">
4656
<RequiredTargetFramework>4.0</RequiredTargetFramework>
4757
</Reference>
@@ -85,6 +95,7 @@
8595
<Generator>ResXFileCodeGenerator</Generator>
8696
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
8797
</EmbeddedResource>
98+
<None Include="packages.config" />
8899
<None Include="Properties\Settings.settings">
89100
<Generator>SettingsSingleFileGenerator</Generator>
90101
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
@@ -93,5 +104,31 @@
93104
<ItemGroup>
94105
<None Include="App.config" />
95106
</ItemGroup>
107+
<ItemGroup>
108+
<Content Include="il\coreclr.dll">
109+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
110+
</Content>
111+
<Content Include="il\ilasm.exe">
112+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
113+
</Content>
114+
<Content Include="il\ildasm.exe">
115+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
116+
</Content>
117+
<Content Include="il\ildasmrc.dll">
118+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
119+
</Content>
120+
</ItemGroup>
96121
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
122+
<!--<Import Project="..\packages\ILAsm.4.5.1.1\build\net\ILAsm.targets" Condition="Exists('..\packages\ILAsm.4.5.1.1\build\net\ILAsm.targets')" />-->
123+
<!--<Target Name="CopyILAsmDasm" BeforeTargets="BeforeBuild">
124+
<ItemGroup>
125+
<ILAsmDasmFiles Include="$(ILAsm_PathToBin)\**\*"/>
126+
</ItemGroup>
127+
<Copy SourceFiles="@(ILAsmDasmFiles)" DestinationFolder="$(OutputPath)\il" SkipUnchangedFiles="True"/>
128+
</Target>-->
129+
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
130+
<PropertyGroup>
131+
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
132+
</PropertyGroup>
133+
</Target>
97134
</Project>

DotNetStringRepacker/MainWindow.xaml

Lines changed: 98 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,102 @@
55
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
66
xmlns:local="clr-namespace:DotNetStringRepacker"
77
mc:Ignorable="d"
8-
Title="MainWindow" Height="350" Width="525">
9-
<Grid>
10-
11-
</Grid>
8+
Title="DotNet String Repacker" Height="500" Width="700" MinHeight="350" MinWidth="500" Closed="Window_Closed">
9+
<TabControl>
10+
<TabItem x:Name="MainTab" Padding="0" >
11+
<TabItem.Header>
12+
<TextBlock Padding="5,0" Margin="0">Main</TextBlock>
13+
</TabItem.Header>
14+
<TabItem.Content>
15+
<DockPanel LastChildFill="True">
16+
<StackPanel Orientation="Vertical" DockPanel.Dock="Top">
17+
<Label Content="Input file (valid .NET Assembly &quot;.exe&quot; or &quot;.dll&quot; file):" HorizontalAlignment="Left" Margin="10,0,0,0" VerticalAlignment="Top"/>
18+
<TextBox Height="23" TextWrapping="NoWrap" Margin="10,0,10,0" x:Name="InputTextBox" Drop="TextBox_Drop" AllowDrop="True" PreviewDragOver="TextBox_PreviewDragOver" />
19+
<Label Content="Output file (file with replaced strings will be written here):" HorizontalAlignment="Left" Margin="10,0,0,0" VerticalAlignment="Top"/>
20+
<TextBox Height="23" TextWrapping="NoWrap" Margin="10,0,10,0" x:Name="OutputTextBox" Drop="TextBox_Drop" AllowDrop="True" PreviewDragOver="TextBox_PreviewDragOver" />
21+
<Label Content="Strings file (&quot;.csv&quot; file to/from strings will be exported/loaded):" HorizontalAlignment="Left" Margin="10,0,0,0" VerticalAlignment="Top"/>
22+
<TextBox Height="23" TextWrapping="NoWrap" Margin="10,0,10,0" x:Name="StringsFileTextBox" Drop="TextBox_Drop" AllowDrop="True" PreviewDragOver="TextBox_PreviewDragOver" />
23+
<DockPanel Margin="10">
24+
<StackPanel Orientation="Horizontal" DockPanel.Dock="Right" HorizontalAlignment="Right" >
25+
<Button Content="Cancel" Margin="0,0,10,0" Padding="5,2" x:Name="CancelButtton" Click="CancelButtton_Click" IsCancel="True" IsEnabled="False"/>
26+
<Button Content="Extract strings" Margin="0,0,10,0" Padding="5,2" x:Name="ExtractButtton" Click="ExtractButtton_Click"/>
27+
<Button Content="Repack application" Padding="5,2" x:Name="RepackButtton" Click="RepackButtton_Click" />
28+
</StackPanel>
29+
<!--<Button DockPanel.Dock="Left" Content="About" Margin="0,0,10,0" Padding="5,2" x:Name="AboutButton" Click="CancelButtton_Click" IsCancel="True" IsEnabled="False"/>-->
30+
<ProgressBar Margin="0,0,10,0" x:Name="ProgressBar"/>
31+
</DockPanel>
32+
</StackPanel>
33+
<TextBox TextWrapping="NoWrap" Margin="10,0,10,10" x:Name="LogTextBox" IsUndoEnabled="False" IsReadOnly="True" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" />
34+
35+
</DockPanel>
36+
</TabItem.Content>
37+
38+
</TabItem>
39+
<TabItem x:Name="AboutTab" Padding="0" >
40+
<TabItem.Header>
41+
<TextBlock Padding="5,0" Margin="0">About</TextBlock>
42+
</TabItem.Header>
43+
<TabItem.Content>
44+
<StackPanel Margin="5">
45+
<Label Content="DotNet String Repacker" FontWeight="Bold" FontSize="14" />
46+
<Label>
47+
<TextBlock TextWrapping="WrapWithOverflow">
48+
This program allows extract and replace strings in .NET application.
49+
</TextBlock>
50+
</Label>
51+
52+
<StackPanel Orientation="Horizontal">
53+
<Label Content="Version:" FontWeight="Bold" />
54+
<Label x:Name="VersionLabel" Content=""/>
55+
</StackPanel>
56+
57+
<Label x:Name="ProjectWebsiteLabel">
58+
<TextBlock TextWrapping="WrapWithOverflow">
59+
<TextBlock FontWeight="Bold">Project website: </TextBlock>
60+
<Hyperlink NavigateUri="https://github.com/VoronFX/DotNet-String-Repacker" >https://github.com/VoronFX/DotNet-String-Repacker</Hyperlink>
61+
</TextBlock>
62+
</Label>
63+
64+
<!--<Label x:Name="CopyrightLabel">
65+
<TextBlock TextWrapping="WrapWithOverflow">
66+
<TextBlock FontWeight="Bold">Copyright: </TextBlock>
67+
@ 2015 Voron.exe<LineBreak/> All rights reserved.
68+
</TextBlock>
69+
</Label>-->
70+
71+
<GroupBox Margin="5">
72+
<GroupBox.Header>
73+
<TextBlock FontWeight="Bold" FontSize="14">Author</TextBlock>
74+
</GroupBox.Header>
75+
<StackPanel Orientation="Horizontal">
76+
<Image x:Name="AuthorGravatar" Margin="10,5,10,5" Loaded="AuthorGravatar_Loaded" />
77+
<StackPanel>
78+
<Label Content="Igor Voronin" FontWeight="Bold" />
79+
80+
<StackPanel Orientation="Horizontal">
81+
<Label Content="GitHub:" FontWeight="Bold" />
82+
<Label>
83+
<Hyperlink NavigateUri="https://github.com/VoronFX" >VoronFX</Hyperlink>
84+
</Label>
85+
</StackPanel>
86+
<StackPanel Orientation="Horizontal">
87+
<Label Content="Email:" FontWeight="Bold" />
88+
<Label>
89+
<Hyperlink NavigateUri="mailto:[email protected]" >[email protected]</Hyperlink>
90+
</Label>
91+
</StackPanel>
92+
<StackPanel Orientation="Horizontal">
93+
<Label Content="Skype:" FontWeight="Bold" />
94+
<Label>
95+
<Hyperlink NavigateUri="skype:Voron.exe?chat:Voron.exe">Voron.exe</Hyperlink>
96+
</Label>
97+
</StackPanel>
98+
</StackPanel>
99+
</StackPanel>
100+
</GroupBox>
101+
</StackPanel>
102+
</TabItem.Content>
103+
</TabItem>
104+
</TabControl>
105+
12106
</Window>

0 commit comments

Comments
 (0)