mirror of
https://github.com/veeso/termscp.git
synced 2025-12-07 09:36:00 -08:00
Added options to explorer, in order to define sorting modes and other options. Added bitflags to dependencies; Moved Explorer to Fs module
This commit is contained in:
@@ -24,6 +24,7 @@ use super::{
|
||||
Color, ConfigClient, FileTransferActivity, InputField, InputMode, LogLevel, LogRecord,
|
||||
PopupType,
|
||||
};
|
||||
use crate::fs::explorer::{builder::FileExplorerBuilder, FileExplorer};
|
||||
use crate::system::environment;
|
||||
use crate::system::sshkey_storage::SshKeyStorage;
|
||||
// Ext
|
||||
@@ -125,6 +126,17 @@ impl FileTransferActivity {
|
||||
}
|
||||
}
|
||||
|
||||
/// ### build_explorer
|
||||
///
|
||||
/// Build explorer reading configuration from `ConfigClient`
|
||||
pub(super) fn build_explorer(cli: Option<&ConfigClient>) -> FileExplorer {
|
||||
FileExplorerBuilder::new()
|
||||
.sort_by_name()
|
||||
.with_dirs_first()
|
||||
.with_stack_size(16)
|
||||
.build()
|
||||
}
|
||||
|
||||
/// ### setup_text_editor
|
||||
///
|
||||
/// Set text editor to use
|
||||
|
||||
Reference in New Issue
Block a user