downgrade .dmf to export status
This commit is contained in:
parent
bf6d98d3c1
commit
b253bd862b
|
|
@ -251,6 +251,33 @@ void FurnaceGUI::drawExportCommand(bool onWindow) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void FurnaceGUI::drawExportDMF(bool onWindow) {
|
||||||
|
exitDisabledTimer=1;
|
||||||
|
|
||||||
|
ImGui::Text(
|
||||||
|
"export in DefleMask module format.\n"
|
||||||
|
"only do it if you really, really need to, or are downgrading an existing .dmf."
|
||||||
|
);
|
||||||
|
|
||||||
|
ImGui::Text("format version:");
|
||||||
|
ImGui::RadioButton("1.1.3 and higher",&dmfExportVersion,0);
|
||||||
|
ImGui::RadioButton("1.0/legacy (0.12)",&dmfExportVersion,1);
|
||||||
|
|
||||||
|
if (onWindow) {
|
||||||
|
ImGui::Separator();
|
||||||
|
if (ImGui::Button("Cancel",ImVec2(200.0f*dpiScale,0))) ImGui::CloseCurrentPopup();
|
||||||
|
ImGui::SameLine();
|
||||||
|
}
|
||||||
|
if (ImGui::Button("Export",ImVec2(200.0f*dpiScale,0))) {
|
||||||
|
if (dmfExportVersion==1) {
|
||||||
|
openFileDialog(GUI_FILE_SAVE_DMF_LEGACY);
|
||||||
|
} else {
|
||||||
|
openFileDialog(GUI_FILE_SAVE_DMF);
|
||||||
|
}
|
||||||
|
ImGui::CloseCurrentPopup();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void FurnaceGUI::drawExport() {
|
void FurnaceGUI::drawExport() {
|
||||||
if (settings.exportOptionsLayout==1 || curExportType==GUI_EXPORT_NONE) {
|
if (settings.exportOptionsLayout==1 || curExportType==GUI_EXPORT_NONE) {
|
||||||
if (ImGui::BeginTabBar("ExportTypes")) {
|
if (ImGui::BeginTabBar("ExportTypes")) {
|
||||||
|
|
@ -290,6 +317,10 @@ void FurnaceGUI::drawExport() {
|
||||||
drawExportCommand(true);
|
drawExportCommand(true);
|
||||||
ImGui::EndTabItem();
|
ImGui::EndTabItem();
|
||||||
}
|
}
|
||||||
|
if (ImGui::BeginTabItem("DMF")) {
|
||||||
|
drawExportDMF(true);
|
||||||
|
ImGui::EndTabItem();
|
||||||
|
}
|
||||||
ImGui::EndTabBar();
|
ImGui::EndTabBar();
|
||||||
}
|
}
|
||||||
} else switch (curExportType) {
|
} else switch (curExportType) {
|
||||||
|
|
@ -311,6 +342,9 @@ void FurnaceGUI::drawExport() {
|
||||||
case GUI_EXPORT_CMD_STREAM:
|
case GUI_EXPORT_CMD_STREAM:
|
||||||
drawExportCommand(true);
|
drawExportCommand(true);
|
||||||
break;
|
break;
|
||||||
|
case GUI_EXPORT_DMF:
|
||||||
|
drawExportDMF(true);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
ImGui::Text("congratulations! you've unlocked a secret panel.");
|
ImGui::Text("congratulations! you've unlocked a secret panel.");
|
||||||
if (ImGui::Button("Toggle hidden systems")) {
|
if (ImGui::Button("Toggle hidden systems")) {
|
||||||
|
|
|
||||||
|
|
@ -4156,12 +4156,6 @@ bool FurnaceGUI::loop() {
|
||||||
if (ImGui::MenuItem("save as...",BIND_FOR(GUI_ACTION_SAVE_AS))) {
|
if (ImGui::MenuItem("save as...",BIND_FOR(GUI_ACTION_SAVE_AS))) {
|
||||||
openFileDialog(GUI_FILE_SAVE);
|
openFileDialog(GUI_FILE_SAVE);
|
||||||
}
|
}
|
||||||
if (ImGui::MenuItem("save as .dmf (1.1.3+)...")) {
|
|
||||||
openFileDialog(GUI_FILE_SAVE_DMF);
|
|
||||||
}
|
|
||||||
if (ImGui::MenuItem("save as .dmf (1.0/legacy)...")) {
|
|
||||||
openFileDialog(GUI_FILE_SAVE_DMF_LEGACY);
|
|
||||||
}
|
|
||||||
ImGui::Separator();
|
ImGui::Separator();
|
||||||
if (settings.exportOptionsLayout==0) {
|
if (settings.exportOptionsLayout==0) {
|
||||||
if (ImGui::BeginMenu("export audio...")) {
|
if (ImGui::BeginMenu("export audio...")) {
|
||||||
|
|
@ -4200,6 +4194,10 @@ bool FurnaceGUI::loop() {
|
||||||
drawExportCommand();
|
drawExportCommand();
|
||||||
ImGui::EndMenu();
|
ImGui::EndMenu();
|
||||||
}
|
}
|
||||||
|
if (ImGui::BeginMenu("export .dmf...")) {
|
||||||
|
drawExportDMF();
|
||||||
|
ImGui::EndMenu();
|
||||||
|
}
|
||||||
} else if (settings.exportOptionsLayout==2) {
|
} else if (settings.exportOptionsLayout==2) {
|
||||||
if (ImGui::MenuItem("export audio...")) {
|
if (ImGui::MenuItem("export audio...")) {
|
||||||
curExportType=GUI_EXPORT_AUDIO;
|
curExportType=GUI_EXPORT_AUDIO;
|
||||||
|
|
@ -4237,6 +4235,10 @@ bool FurnaceGUI::loop() {
|
||||||
curExportType=GUI_EXPORT_CMD_STREAM;
|
curExportType=GUI_EXPORT_CMD_STREAM;
|
||||||
displayExport=true;
|
displayExport=true;
|
||||||
}
|
}
|
||||||
|
if (ImGui::MenuItem("export .dmf...")) {
|
||||||
|
curExportType=GUI_EXPORT_DMF;
|
||||||
|
displayExport=true;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
if (ImGui::MenuItem("export...",BIND_FOR(GUI_ACTION_EXPORT))) {
|
if (ImGui::MenuItem("export...",BIND_FOR(GUI_ACTION_EXPORT))) {
|
||||||
displayExport=true;
|
displayExport=true;
|
||||||
|
|
@ -7813,6 +7815,7 @@ FurnaceGUI::FurnaceGUI():
|
||||||
curTutorial(-1),
|
curTutorial(-1),
|
||||||
curTutorialStep(0),
|
curTutorialStep(0),
|
||||||
audioExportType(0),
|
audioExportType(0),
|
||||||
|
dmfExportVersion(0),
|
||||||
curExportType(GUI_EXPORT_NONE) {
|
curExportType(GUI_EXPORT_NONE) {
|
||||||
// value keys
|
// value keys
|
||||||
valueKeys[SDLK_0]=0;
|
valueKeys[SDLK_0]=0;
|
||||||
|
|
|
||||||
|
|
@ -586,7 +586,8 @@ enum FurnaceGUIExportTypes {
|
||||||
GUI_EXPORT_ZSM,
|
GUI_EXPORT_ZSM,
|
||||||
GUI_EXPORT_CMD_STREAM,
|
GUI_EXPORT_CMD_STREAM,
|
||||||
GUI_EXPORT_AMIGA_VAL,
|
GUI_EXPORT_AMIGA_VAL,
|
||||||
GUI_EXPORT_TEXT
|
GUI_EXPORT_TEXT,
|
||||||
|
GUI_EXPORT_DMF
|
||||||
};
|
};
|
||||||
|
|
||||||
enum FurnaceGUIFMAlgs {
|
enum FurnaceGUIFMAlgs {
|
||||||
|
|
@ -2462,6 +2463,7 @@ class FurnaceGUI {
|
||||||
|
|
||||||
// export options
|
// export options
|
||||||
int audioExportType;
|
int audioExportType;
|
||||||
|
int dmfExportVersion;
|
||||||
FurnaceGUIExportTypes curExportType;
|
FurnaceGUIExportTypes curExportType;
|
||||||
|
|
||||||
void drawExportAudio(bool onWindow=false);
|
void drawExportAudio(bool onWindow=false);
|
||||||
|
|
@ -2470,6 +2472,7 @@ class FurnaceGUI {
|
||||||
void drawExportAmigaVal(bool onWindow=false);
|
void drawExportAmigaVal(bool onWindow=false);
|
||||||
void drawExportText(bool onWindow=false);
|
void drawExportText(bool onWindow=false);
|
||||||
void drawExportCommand(bool onWindow=false);
|
void drawExportCommand(bool onWindow=false);
|
||||||
|
void drawExportDMF(bool onWindow=false);
|
||||||
|
|
||||||
void drawSSGEnv(unsigned char type, const ImVec2& size);
|
void drawSSGEnv(unsigned char type, const ImVec2& size);
|
||||||
void drawWaveform(unsigned char type, bool opz, const ImVec2& size);
|
void drawWaveform(unsigned char type, bool opz, const ImVec2& size);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue