GUI: new pattern cursor logic, part 17

fix some more annoyances
This commit is contained in:
tildearrow 2025-07-05 04:32:28 -05:00
parent 853111b99d
commit 55e00cf538

View file

@ -359,6 +359,13 @@ void FurnaceGUI::drawOrders() {
if (orderEditMode==0) {
handleUnimportant;
}
if (cursor.xCoarse==selStart.xCoarse && cursor.xFine==selStart.xFine && cursor.y==selStart.y && cursor.order==selStart.order &&
cursor.xCoarse==selEnd.xCoarse && cursor.xFine==selEnd.xFine && cursor.y==selEnd.y && cursor.order==selEnd.order) {
cursor.order=curOrder;
selStart=cursor;
selEnd=cursor;
}
}
ImGui::PopStyleColor();
for (int j=0; j<e->getTotalChannelCount(); j++) {
@ -398,6 +405,14 @@ void FurnaceGUI::drawOrders() {
orderCursor=j;
curNibble=false;
}
// i wonder whether this is necessary
if (cursor.xCoarse==selStart.xCoarse && cursor.xFine==selStart.xFine && cursor.y==selStart.y && cursor.order==selStart.order &&
cursor.xCoarse==selEnd.xCoarse && cursor.xFine==selEnd.xFine && cursor.y==selEnd.y && cursor.order==selEnd.order) {
cursor.order=curOrder;
selStart=cursor;
selEnd=cursor;
}
}
if (orderEditMode==0) {
@ -439,6 +454,13 @@ void FurnaceGUI::drawOrders() {
orderCursor=j;
curNibble=false;
}
if (cursor.xCoarse==selStart.xCoarse && cursor.xFine==selStart.xFine && cursor.y==selStart.y && cursor.order==selStart.order &&
cursor.xCoarse==selEnd.xCoarse && cursor.xFine==selEnd.xFine && cursor.y==selEnd.y && cursor.order==selEnd.order) {
cursor.order=curOrder;
selStart=cursor;
selEnd=cursor;
}
}
}
}