mirror of
https://github.com/processing/processing4.git
synced 2026-02-11 17:40:48 +01:00
Merge pull request #3540 from aengelke/patch-1
Fix bug with tab sorting when adding new tabs
This commit is contained in:
@@ -270,6 +270,13 @@ public class Sketch {
|
||||
SketchCode temp = code[who];
|
||||
code[who] = code[i];
|
||||
code[i] = temp;
|
||||
|
||||
// We also need to update the current tab
|
||||
if (currentIndex == i) {
|
||||
currentIndex = who;
|
||||
} else if (currentIndex == who) {
|
||||
currentIndex = i;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user