Skip to content

Commit

Permalink
Fix autoscroll bug in navigator (#908)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamkewley committed Sep 13, 2024
1 parent 3e8c365 commit 8d1eaeb
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/OpenSimCreator/UI/Shared/NavigatorPanel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,12 @@ class osc::NavigatorPanel::Impl final : public StandardPanelImpl {
}

// cache the previous selection path, so we can observe when it has changed (#908)
m_PreviousSelectionPath = std::move(selectedPath);
if (rv.type == ResponseType::SelectionChanged) {
m_PreviousSelectionPath = GetAbsolutePathOrEmpty(rv.ptr);
}
else {
m_PreviousSelectionPath = std::move(selectedPath);
}
}

std::shared_ptr<IModelStatePair> m_Model;
Expand Down

0 comments on commit 8d1eaeb

Please sign in to comment.