mirror of
https://github.com/tildearrow/furnace.git
synced 2024-12-31 20:11:29 +00:00
GUI: better instrument value input
This commit is contained in:
parent
651db5784e
commit
b26ef5ac82
1 changed files with 4 additions and 1 deletions
|
@ -2411,7 +2411,10 @@ void FurnaceGUI::keyDown(SDL_Event& ev) {
|
|||
pat->data[cursor.y][cursor.xFine+1]=((pat->data[cursor.y][cursor.xFine+1]<<4)|num)&0xff;
|
||||
if (cursor.xFine==1) { // instrument
|
||||
if (pat->data[cursor.y][cursor.xFine+1]>=(int)e->song.ins.size()) {
|
||||
pat->data[cursor.y][cursor.xFine+1]=(int)e->song.ins.size()-1;
|
||||
pat->data[cursor.y][cursor.xFine+1]&=0x0f;
|
||||
if (pat->data[cursor.y][cursor.xFine+1]>=(int)e->song.ins.size()) {
|
||||
pat->data[cursor.y][cursor.xFine+1]=(int)e->song.ins.size()-1;
|
||||
}
|
||||
}
|
||||
makeUndo(GUI_ACTION_PATTERN_EDIT);
|
||||
if (e->song.ins.size()<16) {
|
||||
|
|
Loading…
Reference in a new issue