fix: allow context menu when shift is being pressed
This commit is contained in:
parent
8fd99ec40e
commit
e053db3bf9
1 changed files with 7 additions and 9 deletions
16
src/tab.rs
16
src/tab.rs
|
|
@ -3312,16 +3312,14 @@ impl Tab {
|
|||
}
|
||||
Message::ContextMenu(point_opt, _) => {
|
||||
self.edit_location = None;
|
||||
if point_opt.is_none() || !mod_shift {
|
||||
self.context_menu = point_opt;
|
||||
self.location_context_menu_index = None;
|
||||
self.context_menu = point_opt;
|
||||
self.location_context_menu_index = None;
|
||||
|
||||
//TODO: hack for clearing selecting when right clicking empty space
|
||||
if self.context_menu.is_some() && self.last_right_click.take().is_none() {
|
||||
if let Some(ref mut items) = self.items_opt {
|
||||
for item in items.iter_mut() {
|
||||
item.selected = false;
|
||||
}
|
||||
//TODO: hack for clearing selecting when right clicking empty space
|
||||
if self.context_menu.is_some() && self.last_right_click.take().is_none() {
|
||||
if let Some(ref mut items) = self.items_opt {
|
||||
for item in items.iter_mut() {
|
||||
item.selected = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue