Skip to content

Commit 34ae62a

Browse files
authored
Merge pull request #36 from AmusementClub/patch/hardcode-stripCommonPathComponents
Revert configurable stripCommonPathComponents
2 parents d5d0bba + d6604d1 commit 34ae62a

File tree

3 files changed

+4
-16
lines changed

3 files changed

+4
-16
lines changed

OKEGui/OKEGui/Gui/ConfigPanel.xaml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
xmlns:local="clr-namespace:OKEGui"
77
DataContext="{Binding RelativeSource={RelativeSource Self}}"
88
mc:Ignorable="d"
9-
Title="设置" Height="370" Width="500">
9+
Title="设置" Height="300" Width="500">
1010
<Window.Resources>
1111
<Style TargetType="DataGridCell">
1212
<Setter Property="HorizontalContentAlignment" Value="Left" />
@@ -16,7 +16,7 @@
1616
<Grid>
1717
<Grid.RowDefinitions>
1818
<RowDefinition Height="70"/>
19-
<RowDefinition Height="187"/>
19+
<RowDefinition Height="105"/>
2020
<RowDefinition/>
2121
</Grid.RowDefinitions>
2222
<Grid Grid.Row="0" Height="70" VerticalAlignment="Top">
@@ -60,8 +60,6 @@
6060
<CheckBox HorizontalAlignment="Center" VerticalAlignment="Center" Grid.Row="1" Grid.Column="1" IsChecked="{Binding Config.singleNuma}"/>
6161
<TextBlock Margin="10,9" Height="30" Grid.Row="2" Grid.Column="0" Text="开启AVX512烤鸡模式"/>
6262
<CheckBox HorizontalAlignment="Center" VerticalAlignment="Center" Grid.Row="2" Grid.Column="1" IsChecked="{Binding Config.avx512}"/>
63-
<TextBlock Margin="10,44,10,-39" Height="30" Grid.Row="2" Grid.Column="0" Text="删除工作/输出目录路径中的以下目录层次(使用 / 分割)"/>
64-
<TextBox Grid.Row="2" Text="{Binding Config.stripCommonPathCompnents}" Margin="10,74,13,-80" Grid.ColumnSpan="2"/>
6563
</Grid>
6664
<Grid Grid.Row="2">
6765
<Grid.ColumnDefinitions>

OKEGui/OKEGui/Gui/WizardWindow.xaml.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,8 @@ private void WizardFinish(object sender, RoutedEventArgs e)
249249
inputFile + "\"" + inputTemplate[3];
250250

251251
string inputSuffixPath = inputFile.Replace(':', '_');
252-
string[] strippedComponents = Initializer.Config.stripCommonPathCompnents.Split(new char[] { '/', '\\' }, StringSplitOptions.RemoveEmptyEntries);
252+
const string stripCommonPathComponents = "BDBOX/BDROM/BD/BDMV/STREAM/BD_VIDEO"; // FIXME: do not hardcode this.
253+
string[] strippedComponents = stripCommonPathComponents.Split(new char[] { '/', '\\' }, StringSplitOptions.RemoveEmptyEntries);
253254
foreach (var comp in strippedComponents)
254255
{
255256
inputSuffixPath = Regex.Replace(inputSuffixPath, @"[/\\]" + Regex.Escape(comp) + @"[/\\]", "\\");

OKEGui/OKEGui/Utils/Initializer.cs

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -104,17 +104,6 @@ public int memoryTotal
104104
NotifyPropertyChanged();
105105
}
106106
}
107-
108-
private string _stripCommonPathCompnents = "BDBOX/BDROM/BD/BDMV/STREAM/BD_VIDEO";
109-
public string stripCommonPathCompnents
110-
{
111-
get => _stripCommonPathCompnents;
112-
set
113-
{
114-
_stripCommonPathCompnents = value;
115-
NotifyPropertyChanged();
116-
}
117-
}
118107
}
119108

120109
static class Initializer

0 commit comments

Comments
 (0)