list nav: fix deadlock in goby() horizontal case
This commit is contained in:
parent
b220d264e4
commit
fc9ac6cac7
1 changed files with 9 additions and 4 deletions
|
@ -249,10 +249,15 @@ impl TreeNav for ListEditor {
|
||||||
// nested
|
// nested
|
||||||
|
|
||||||
if cur.tree_addr[0] < self.data.len() as isize {
|
if cur.tree_addr[0] < self.data.len() as isize {
|
||||||
match self.data
|
|
||||||
.get_mut(cur.tree_addr[0] as usize)
|
let cur_item = self.data
|
||||||
.write().unwrap()
|
.get_mut(cur.tree_addr[0] as usize);
|
||||||
.goby(direction)
|
|
||||||
|
let result = cur_item.write().unwrap().goby(direction);
|
||||||
|
|
||||||
|
drop(cur_item);
|
||||||
|
|
||||||
|
match result
|
||||||
{
|
{
|
||||||
TreeNavResult::Exit => {
|
TreeNavResult::Exit => {
|
||||||
if direction.y < 0 {
|
if direction.y < 0 {
|
||||||
|
|
Loading…
Reference in a new issue