mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Add customized args
This commit is contained in:
parent
465146d36f
commit
5ba4e515f3
5 changed files with 16 additions and 4 deletions
|
|
@ -326,7 +326,7 @@ namespace Flow.Launcher.Plugin.Program.Programs
|
|||
{
|
||||
Main.StartProcess(Process.Start, new ProcessStartInfo(
|
||||
!string.IsNullOrEmpty(Main._settings.CustomizedExploere)?Main._settings.CustomizedExploere:"exploere"
|
||||
, Package.Location));
|
||||
, (Main._settings.CustomizedArgs + " " + ParentDirectory).Trim()));
|
||||
|
||||
return true;
|
||||
},
|
||||
|
|
|
|||
|
|
@ -142,7 +142,7 @@ namespace Flow.Launcher.Plugin.Program.Programs
|
|||
{
|
||||
Main.StartProcess(Process.Start, new ProcessStartInfo(
|
||||
!string.IsNullOrEmpty(Main._settings.CustomizedExploere)?Main._settings.CustomizedExploere:"exploere"
|
||||
, ParentDirectory));
|
||||
, (Main._settings.CustomizedArgs + " " + ParentDirectory).Trim()));
|
||||
return true;
|
||||
},
|
||||
IcoPath = "Images/folder.png"
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@ namespace Flow.Launcher.Plugin.Program
|
|||
|
||||
public bool EnableRegistrySource { get; set; } = true;
|
||||
public string CustomizedExploere { get; set; } = "exploere";
|
||||
public string CustomizedArgs { get; set; } = "";
|
||||
|
||||
internal const char SuffixSeperator = ';';
|
||||
|
||||
|
|
|
|||
|
|
@ -75,12 +75,17 @@
|
|||
<Button x:Name="btnAddProgramSource" Click="btnAddProgramSource_OnClick" Width="100" Margin="10" Content="{DynamicResource flowlauncher_plugin_program_add}"/>
|
||||
</StackPanel>
|
||||
</DockPanel>
|
||||
<TextBlock Text="Customized Explorer" HorizontalAlignment="Left" Margin="20,0,0,0" Grid.Row="3" VerticalAlignment="Center" FontSize="15"
|
||||
<StackPanel Grid.Row="3" Orientation="Horizontal" HorizontalAlignment="Stretch">
|
||||
<TextBlock Text="Customized Explorer" Margin="10,0,0,0" VerticalAlignment="Center" FontSize="15"
|
||||
ToolTip="You can customized the exploere for opening the container folder
|
||||
by inputing the Environmental Variable of the exploere you want to use.
|
||||
It will be useful to use CMD to test whether the Environmental Variable is avaliable."/>
|
||||
<TextBox HorizontalAlignment="Right" Margin="0,0,30,0" Grid.Row="3" Text="" TextWrapping="NoWrap" VerticalAlignment="Center" Width="250" Height="30" FontSize="15"
|
||||
<TextBox Margin="20,0,10,0" TextWrapping="NoWrap" VerticalAlignment="Center" Width="200" Height="30" FontSize="15"
|
||||
TextChanged="CustomizeExplorer" x:Name="CustomizeExplorerBox"/>
|
||||
<TextBlock Text="args" VerticalAlignment="Center" FontSize="15"
|
||||
ToolTip="Enter the customized args you want to add for customized exploere. Check the exploerer websites for detail."></TextBlock>
|
||||
<TextBox Margin="10,0,0,0" Width="80" Height="30" FontSize="15" x:Name="CustomizeArgsBox" TextChanged="CustomizeExplorerArgs"></TextBox>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</UserControl>
|
||||
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@ namespace Flow.Launcher.Plugin.Program.Views
|
|||
RegistryEnabled.IsChecked = _settings.EnableRegistrySource;
|
||||
|
||||
CustomizeExplorerBox.Text = _settings.CustomizedExploere;
|
||||
CustomizeArgsBox.Text = _settings.CustomizedArgs;
|
||||
|
||||
ViewRefresh();
|
||||
}
|
||||
|
|
@ -333,5 +334,10 @@ namespace Flow.Launcher.Plugin.Program.Views
|
|||
{
|
||||
_settings.CustomizedExploere = CustomizeExplorerBox.Text;
|
||||
}
|
||||
|
||||
private void CustomizeExplorerArgs(object sender, TextChangedEventArgs e)
|
||||
{
|
||||
_settings.CustomizedArgs = CustomizeArgsBox.Text;
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue