mirror of
https://github.com/tildearrow/furnace.git
synced 2025-01-05 23:21:22 +00:00
parent
36eaea0fa7
commit
585efbec13
1 changed files with 6 additions and 6 deletions
|
@ -609,7 +609,7 @@ void FurnaceGUI::drawEditControls() {
|
||||||
ImGui::Text("Octave");
|
ImGui::Text("Octave");
|
||||||
ImGui::SameLine();
|
ImGui::SameLine();
|
||||||
if (ImGui::InputInt("##Octave",&curOctave,1,1)) {
|
if (ImGui::InputInt("##Octave",&curOctave,1,1)) {
|
||||||
if (curOctave>6) curOctave=6;
|
if (curOctave>7) curOctave=7;
|
||||||
if (curOctave<-5) curOctave=-5;
|
if (curOctave<-5) curOctave=-5;
|
||||||
for (size_t i=0; i<activeNotes.size(); i++) {
|
for (size_t i=0; i<activeNotes.size(); i++) {
|
||||||
e->noteOff(activeNotes[i].chan);
|
e->noteOff(activeNotes[i].chan);
|
||||||
|
@ -699,7 +699,7 @@ void FurnaceGUI::drawEditControls() {
|
||||||
ImGui::SameLine();
|
ImGui::SameLine();
|
||||||
ImGui::SetNextItemWidth(96.0f*dpiScale);
|
ImGui::SetNextItemWidth(96.0f*dpiScale);
|
||||||
if (ImGui::InputInt("##Octave",&curOctave,1,1)) {
|
if (ImGui::InputInt("##Octave",&curOctave,1,1)) {
|
||||||
if (curOctave>6) curOctave=6;
|
if (curOctave>7) curOctave=7;
|
||||||
if (curOctave<-5) curOctave=-5;
|
if (curOctave<-5) curOctave=-5;
|
||||||
for (size_t i=0; i<activeNotes.size(); i++) {
|
for (size_t i=0; i<activeNotes.size(); i++) {
|
||||||
e->noteOff(activeNotes[i].chan);
|
e->noteOff(activeNotes[i].chan);
|
||||||
|
@ -762,7 +762,7 @@ void FurnaceGUI::drawEditControls() {
|
||||||
float avail=ImGui::GetContentRegionAvail().x;
|
float avail=ImGui::GetContentRegionAvail().x;
|
||||||
ImGui::SetNextItemWidth(avail);
|
ImGui::SetNextItemWidth(avail);
|
||||||
if (ImGui::InputInt("##Octave",&curOctave,0,0)) {
|
if (ImGui::InputInt("##Octave",&curOctave,0,0)) {
|
||||||
if (curOctave>6) curOctave=6;
|
if (curOctave>7) curOctave=7;
|
||||||
if (curOctave<-5) curOctave=-5;
|
if (curOctave<-5) curOctave=-5;
|
||||||
for (size_t i=0; i<activeNotes.size(); i++) {
|
for (size_t i=0; i<activeNotes.size(); i++) {
|
||||||
e->noteOff(activeNotes[i].chan);
|
e->noteOff(activeNotes[i].chan);
|
||||||
|
@ -846,7 +846,7 @@ void FurnaceGUI::drawEditControls() {
|
||||||
float avail=ImGui::GetContentRegionAvail().x;
|
float avail=ImGui::GetContentRegionAvail().x;
|
||||||
ImGui::SetNextItemWidth(avail);
|
ImGui::SetNextItemWidth(avail);
|
||||||
if (ImGui::InputInt("##Octave",&curOctave,1,1)) {
|
if (ImGui::InputInt("##Octave",&curOctave,1,1)) {
|
||||||
if (curOctave>6) curOctave=6;
|
if (curOctave>7) curOctave=7;
|
||||||
if (curOctave<-5) curOctave=-5;
|
if (curOctave<-5) curOctave=-5;
|
||||||
for (size_t i=0; i<activeNotes.size(); i++) {
|
for (size_t i=0; i<activeNotes.size(); i++) {
|
||||||
e->noteOff(activeNotes[i].chan);
|
e->noteOff(activeNotes[i].chan);
|
||||||
|
@ -4213,8 +4213,8 @@ void FurnaceGUI::doAction(int what) {
|
||||||
e->stepOne(cursor.y);
|
e->stepOne(cursor.y);
|
||||||
break;
|
break;
|
||||||
case GUI_ACTION_OCTAVE_UP:
|
case GUI_ACTION_OCTAVE_UP:
|
||||||
if (++curOctave>6) {
|
if (++curOctave>7) {
|
||||||
curOctave=6;
|
curOctave=7;
|
||||||
} else {
|
} else {
|
||||||
for (size_t i=0; i<activeNotes.size(); i++) {
|
for (size_t i=0; i<activeNotes.size(); i++) {
|
||||||
e->noteOff(activeNotes[i].chan);
|
e->noteOff(activeNotes[i].chan);
|
||||||
|
|
Loading…
Reference in a new issue