mirror of
https://github.com/veeso/termscp.git
synced 2025-12-07 09:36:00 -08:00
Ctx before string in input cb
This commit is contained in:
@@ -57,7 +57,7 @@ use unicode_width::UnicodeWidthStr;
|
|||||||
|
|
||||||
// Types
|
// Types
|
||||||
type DialogCallback = fn(&mut FileTransferActivity, &mut Context);
|
type DialogCallback = fn(&mut FileTransferActivity, &mut Context);
|
||||||
type OnInputSubmitCallback = fn(&mut FileTransferActivity, String, &mut Context);
|
type OnInputSubmitCallback = fn(&mut FileTransferActivity, &mut Context, String);
|
||||||
|
|
||||||
/// ### FileTransferParams
|
/// ### FileTransferParams
|
||||||
///
|
///
|
||||||
@@ -607,7 +607,7 @@ impl FileTransferActivity {
|
|||||||
// Set mode back to explorer BEFORE CALLBACKS!!! Callback can then overwrite this, clever uh?
|
// Set mode back to explorer BEFORE CALLBACKS!!! Callback can then overwrite this, clever uh?
|
||||||
self.input_mode = InputMode::Explorer;
|
self.input_mode = InputMode::Explorer;
|
||||||
// Call cb
|
// Call cb
|
||||||
cb(self, input_text, ctx);
|
cb(self, ctx, input_text);
|
||||||
}
|
}
|
||||||
KeyCode::Char(ch) => self.input_txt.push(ch),
|
KeyCode::Char(ch) => self.input_txt.push(ch),
|
||||||
KeyCode::Backspace => {
|
KeyCode::Backspace => {
|
||||||
|
|||||||
Reference in New Issue
Block a user