mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Remove files tip button
This commit is contained in:
parent
6ce2cf9cac
commit
5578daaa3e
3 changed files with 5 additions and 57 deletions
|
|
@ -366,9 +366,7 @@
|
|||
|
||||
<!-- FileManager Setting Dialog -->
|
||||
<system:String x:Key="fileManagerWindow">Select File Manager</system:String>
|
||||
<system:String x:Key="fileManager_files_btn">Do you use Files?</system:String>
|
||||
<system:String x:Key="fileManager_learnMore">Learn more</system:String>
|
||||
<system:String x:Key="fileManager_files_tips">Depending on the version, Files may use either "Files" or "Files-stable" as its path. (This can vary depending on which version you're using.) For more details, see:</system:String>
|
||||
<system:String x:Key="fileManager_tips">Please specify the file location of the file manager you using and add arguments as required. The "%d" represents the directory path to open for, used by the Arg for Folder field and for commands opening specific directories. The "%f" represents the file path to open for, used by the Arg for File field and for commands opening specific files.</system:String>
|
||||
<system:String x:Key="fileManager_tips2">For example, if the file manager uses a command such as "totalcmd.exe /A c:\windows" to open the c:\windows directory, the File Manager Path will be totalcmd.exe, and the Arg For Folder will be /A "%d". Certain file managers like QTTabBar may just require a path to be supplied, in this instance use "%d" as the File Manager Path and leave the rest of the fileds blank.</system:String>
|
||||
<system:String x:Key="fileManager_name">File Manager</system:String>
|
||||
|
|
|
|||
|
|
@ -74,20 +74,11 @@
|
|||
<TextBlock Margin="0 14 0 0" FontSize="14">
|
||||
<TextBlock Text="{DynamicResource fileManager_tips2}" TextWrapping="WrapWithOverflow" />
|
||||
</TextBlock>
|
||||
<StackPanel Margin="0 14 0 0" Orientation="Horizontal">
|
||||
<Button
|
||||
x:Name="btnTips"
|
||||
Margin="0 7 0 7"
|
||||
HorizontalAlignment="Left"
|
||||
Command="{Binding OpenFilesTipsCommand}"
|
||||
CommandParameter="{Binding RelativeSource={RelativeSource Self}}"
|
||||
Content="{DynamicResource fileManager_files_btn}" />
|
||||
<TextBlock Margin="10 4 0 4" VerticalAlignment="Center">
|
||||
<Hyperlink NavigateUri="https://www.flowlauncher.com/docs/#/filemanager" RequestNavigate="Hyperlink_RequestNavigate">
|
||||
<TextBlock FontSize="14" Text="{DynamicResource fileManager_learnMore}" />
|
||||
</Hyperlink>
|
||||
</TextBlock>
|
||||
</StackPanel>
|
||||
<TextBlock Margin="0 14 0 0" VerticalAlignment="Center">
|
||||
<Hyperlink NavigateUri="https://www.flowlauncher.com/docs/#/filemanager" RequestNavigate="Hyperlink_RequestNavigate">
|
||||
<TextBlock FontSize="14" Text="{DynamicResource fileManager_learnMore}" />
|
||||
</Hyperlink>
|
||||
</TextBlock>
|
||||
</StackPanel>
|
||||
<Rectangle
|
||||
Height="1"
|
||||
|
|
|
|||
|
|
@ -102,47 +102,6 @@ public partial class SelectFileManagerViewModel : BaseModel
|
|||
}
|
||||
}
|
||||
|
||||
[RelayCommand]
|
||||
private async Task OpenFilesTipsAsync(Button button)
|
||||
{
|
||||
var tipText = App.API.GetTranslation("fileManager_files_tips");
|
||||
var url = "https://files.community/docs/contributing/updates";
|
||||
|
||||
var textBlock = new TextBlock
|
||||
{
|
||||
FontSize = 14,
|
||||
TextWrapping = TextWrapping.Wrap,
|
||||
Margin = new Thickness(0, 0, 0, 0)
|
||||
};
|
||||
|
||||
textBlock.Inlines.Add(tipText);
|
||||
|
||||
var hyperlink = new Hyperlink
|
||||
{
|
||||
NavigateUri = new Uri(url)
|
||||
};
|
||||
hyperlink.Inlines.Add(url);
|
||||
hyperlink.RequestNavigate += (s, args) =>
|
||||
{
|
||||
App.API.OpenUrl(args.Uri.AbsoluteUri);
|
||||
args.Handled = true;
|
||||
};
|
||||
|
||||
textBlock.Inlines.Add(hyperlink);
|
||||
|
||||
var tipsDialog = new ContentDialog()
|
||||
{
|
||||
Owner = Window.GetWindow(button),
|
||||
Title = (string)Application.Current.Resources["fileManager_files_btn"],
|
||||
Content = textBlock,
|
||||
PrimaryButtonText = (string)Application.Current.Resources["commonOK"],
|
||||
CornerRadius = new CornerRadius(8),
|
||||
Style = (Style)Application.Current.Resources["ContentDialog"]
|
||||
};
|
||||
|
||||
await tipsDialog.ShowAsync();
|
||||
}
|
||||
|
||||
[RelayCommand]
|
||||
private void Add()
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue