Console Binary file preview
This commit is contained in:
@@ -4,4 +4,6 @@ public class ConsoleApplicationConfiguration
|
||||
{
|
||||
public string? ConsoleDriver { get; set; }
|
||||
public bool DisableUtf8 { get; set; }
|
||||
public string? ClipboardSingleIcon { get; set; }
|
||||
public string? ClipboardMultipleIcon { get; set; }
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
using System.Collections.ObjectModel;
|
||||
using FileTime.App.Core.ViewModels;
|
||||
using FileTime.ConsoleUI.App.Preview;
|
||||
|
||||
namespace FileTime.ConsoleUI.App;
|
||||
|
||||
@@ -7,4 +8,5 @@ public interface IConsoleAppState : IAppState
|
||||
{
|
||||
string ErrorText { get; set; }
|
||||
ObservableCollection<string> PopupTexts { get; }
|
||||
ItemPreviewType? PreviewType { get; set; }
|
||||
}
|
||||
@@ -22,5 +22,6 @@ public interface IRootViewModel
|
||||
IDeclarativeProperty<VolumeSizeInfo?> VolumeSizeInfo { get; }
|
||||
IFrequencyNavigationViewModel FrequencyNavigation { get; }
|
||||
IItemPreviewService ItemPreviewService { get; }
|
||||
IClipboardService ClipboardService { get; }
|
||||
event Action<IInputElement>? FocusReadInputElement;
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace FileTime.ConsoleUI.App.Preview;
|
||||
|
||||
public enum ItemPreviewType
|
||||
{
|
||||
Text,
|
||||
Binary
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using FileTime.App.Core.UserCommand;
|
||||
|
||||
namespace FileTime.ConsoleUI.App.UserCommand;
|
||||
|
||||
public class NextPreviewUserCommand : IIdentifiableUserCommand
|
||||
{
|
||||
public const string CommandId = "console_next_preview";
|
||||
|
||||
public static NextPreviewUserCommand Instance = new();
|
||||
|
||||
private NextPreviewUserCommand()
|
||||
{
|
||||
}
|
||||
|
||||
public string UserCommandID => CommandId;
|
||||
public string Title => "Next preview";
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using FileTime.App.Core.UserCommand;
|
||||
|
||||
namespace FileTime.ConsoleUI.App.UserCommand;
|
||||
|
||||
public class PreviousPreviewUserCommand : IIdentifiableUserCommand
|
||||
{
|
||||
public const string CommandId = "console_previous_preview";
|
||||
|
||||
public static PreviousPreviewUserCommand Instance = new();
|
||||
|
||||
private PreviousPreviewUserCommand()
|
||||
{
|
||||
}
|
||||
|
||||
public string UserCommandID => CommandId;
|
||||
public string Title => "Previous preview";
|
||||
}
|
||||
Reference in New Issue
Block a user