Skip to content

Commit

Permalink
GUIFormSpecMenu: Fix legacy sorting using std::stable_sort
Browse files Browse the repository at this point in the history
  • Loading branch information
SmallJoker committed Dec 14, 2019
1 parent 8e63d22 commit c3d0aab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/gui/guiFormSpecMenu.cpp
Expand Up @@ -3031,7 +3031,7 @@ void GUIFormSpecMenu::legacySortElements(core::list<IGUIElement *>::Iterator fro
elements.emplace_back(*it);

// 2: Sort the container
std::sort(elements.begin(), elements.end(),
std::stable_sort(elements.begin(), elements.end(),
[this] (const IGUIElement *a, const IGUIElement *b) -> bool {
const FieldSpec *spec_a = getSpecByID(a->getID());
const FieldSpec *spec_b = getSpecByID(b->getID());
Expand Down

0 comments on commit c3d0aab

Please sign in to comment.