Mount network path as needed
This commit is contained in:
parent
c3d6498042
commit
8ace8d025a
3 changed files with 107 additions and 59 deletions
16
src/menu.rs
16
src/menu.rs
|
|
@ -198,7 +198,21 @@ pub fn context_menu<'a>(
|
|||
}
|
||||
}
|
||||
(_, Location::Network(_, _)) => {
|
||||
//TODO: networks context menu?
|
||||
if selected > 0 {
|
||||
if selected_dir == 1 && selected == 1 || selected_dir == 0 {
|
||||
children.push(menu_item(fl!("open"), Action::Open).into());
|
||||
}
|
||||
} else {
|
||||
if tab.mode.multiple() {
|
||||
children.push(menu_item(fl!("select-all"), Action::SelectAll).into());
|
||||
}
|
||||
if !children.is_empty() {
|
||||
children.push(divider::horizontal::light().into());
|
||||
}
|
||||
children.push(sort_item(fl!("sort-by-name"), HeadingOptions::Name));
|
||||
children.push(sort_item(fl!("sort-by-modified"), HeadingOptions::Modified));
|
||||
children.push(sort_item(fl!("sort-by-size"), HeadingOptions::Size));
|
||||
}
|
||||
}
|
||||
(_, Location::Trash) => {
|
||||
if tab.mode.multiple() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue