mirror of
https://github.com/tildearrow/furnace.git
synced 2025-01-03 06:01:29 +00:00
remove delta mode
it's unnecessary in my opinion unless I am missing something
This commit is contained in:
parent
3f14625361
commit
c473f94f0d
2 changed files with 20 additions and 38 deletions
|
@ -864,13 +864,13 @@ struct FurnaceGUIMacroDesc {
|
|||
float height;
|
||||
const char* displayName;
|
||||
const char** bitfieldBits;
|
||||
const char** modeName;
|
||||
const char* modeName;
|
||||
ImVec4 color;
|
||||
unsigned int bitOffset;
|
||||
bool isBitfield, blockMode, useMacroMode;
|
||||
bool isBitfield, blockMode;
|
||||
String (*hoverFunc)(int,float);
|
||||
|
||||
FurnaceGUIMacroDesc(const char* name, DivInstrumentMacro* m, int macroMin, int macroMax, float macroHeight, ImVec4 col=ImVec4(1.0f,1.0f,1.0f,1.0f), bool block=false, bool mMode=false, const char** mName={NULL}, String (*hf)(int,float)=NULL, bool bitfield=false, const char** bfVal=NULL, unsigned int bitOff=0):
|
||||
FurnaceGUIMacroDesc(const char* name, DivInstrumentMacro* m, int macroMin, int macroMax, float macroHeight, ImVec4 col=ImVec4(1.0f,1.0f,1.0f,1.0f), bool block=false, const char* mName=NULL, String (*hf)(int,float)=NULL, bool bitfield=false, const char** bfVal=NULL, unsigned int bitOff=0):
|
||||
macro(m),
|
||||
height(macroHeight),
|
||||
displayName(name),
|
||||
|
@ -880,7 +880,6 @@ struct FurnaceGUIMacroDesc {
|
|||
bitOffset(bitOff),
|
||||
isBitfield(bitfield),
|
||||
blockMode(block),
|
||||
useMacroMode(mMode),
|
||||
hoverFunc(hf) {
|
||||
// MSVC -> hell
|
||||
this->min=macroMin;
|
||||
|
|
|
@ -305,34 +305,15 @@ const char* gbHWSeqCmdTypes[6]={
|
|||
"Loop until Release"
|
||||
};
|
||||
|
||||
const char* macroAbsoluteMode[3]={
|
||||
"Relative",
|
||||
"Absolute",
|
||||
NULL
|
||||
};
|
||||
|
||||
const char* macroRelativeMode[3]={
|
||||
"Absolute",
|
||||
"Relative",
|
||||
NULL
|
||||
};
|
||||
|
||||
const char* macroQSoundMode[3]={
|
||||
"Independent",
|
||||
"QSound",
|
||||
NULL
|
||||
};
|
||||
|
||||
const char* macroDummyMode[1]={
|
||||
NULL
|
||||
};
|
||||
|
||||
const char* macroFilterMode[4]={
|
||||
"Relative",
|
||||
"Absolute",
|
||||
"Delta",
|
||||
NULL
|
||||
};
|
||||
// do not change these!
|
||||
// anything other than a checkbox will look ugly!
|
||||
//
|
||||
// if you really need to, and have a good rationale (and by good I mean a VERY
|
||||
// good one), please tell me and we'll sort it out.
|
||||
const char* macroAbsoluteMode="Fixed";
|
||||
const char* macroRelativeMode="Relative";
|
||||
const char* macroQSoundMode="QSound";
|
||||
const char* macroDummyMode="Bug";
|
||||
|
||||
String macroHoverNote(int id, float val) {
|
||||
if (val<-60 || val>=120) return "???";
|
||||
|
@ -1259,12 +1240,14 @@ void FurnaceGUI::drawMacros(std::vector<FurnaceGUIMacroDesc>& macros) {
|
|||
if (ImGui::InputScalar("##IMacroLen",ImGuiDataType_U8,&i.macro->len,&_ONE,&_THREE)) { MARK_MODIFIED
|
||||
if (i.macro->len>128) i.macro->len=128;
|
||||
}
|
||||
if (i.useMacroMode && i.modeName[0]!=NULL) {
|
||||
for (int m=0; i.modeName[m]!=NULL; m++) {
|
||||
String modeName=fmt::sprintf("%s##IMacroMode%d",i.modeName[m],m);
|
||||
if (ImGui::RadioButton(modeName.c_str(),(int)i.macro->mode==m)) {
|
||||
i.macro->mode=m;
|
||||
}
|
||||
// do not change this!
|
||||
// anything other than a checkbox will look ugly!
|
||||
// if you really need more than two macro modes please tell me.
|
||||
if (i.modeName!=NULL) {
|
||||
bool modeVal=i.macro->mode;
|
||||
String modeName=fmt::sprintf("%s##IMacroMode",i.modeName);
|
||||
if (ImGui::Checkbox(modeName.c_str(),&modeVal)) {
|
||||
i.macro->mode=modeVal;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue