GUI: move the edit button in asset list
it messes with muscle memory
This commit is contained in:
parent
387d9e0654
commit
70413291de
|
@ -354,25 +354,6 @@ void FurnaceGUI::drawInsList(bool asChild) {
|
|||
}
|
||||
if (began) {
|
||||
if (settings.unifiedDataView) settings.horizontalDataView=0;
|
||||
ImGui::BeginDisabled(e->song.insLen==0 && e->song.waveLen==0 && e->song.sampleLen==0);
|
||||
if (ImGui::Button(ICON_FA_PENCIL)) {
|
||||
switch (lastAssetType) {
|
||||
case 0:
|
||||
nextWindow=GUI_WINDOW_INS_EDIT;
|
||||
break;
|
||||
case 1:
|
||||
nextWindow=GUI_WINDOW_WAVE_EDIT;
|
||||
break;
|
||||
case 2:
|
||||
nextWindow=GUI_WINDOW_SAMPLE_EDIT;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (ImGui::IsItemHovered(ImGuiHoveredFlags_AllowWhenDisabled)) {
|
||||
ImGui::SetTooltip(_("Edit"));
|
||||
}
|
||||
ImGui::EndDisabled();
|
||||
ImGui::SameLine();
|
||||
if (ImGui::Button(ICON_FA_PLUS "##InsAdd")) {
|
||||
if (settings.unifiedDataView) {
|
||||
switch (lastAssetType) {
|
||||
|
@ -545,6 +526,25 @@ void FurnaceGUI::drawInsList(bool asChild) {
|
|||
ImGui::EndPopup();
|
||||
}
|
||||
ImGui::SameLine();
|
||||
ImGui::BeginDisabled(e->song.insLen==0 && e->song.waveLen==0 && e->song.sampleLen==0);
|
||||
if (ImGui::Button(ICON_FA_PENCIL)) {
|
||||
switch (lastAssetType) {
|
||||
case 0:
|
||||
nextWindow=GUI_WINDOW_INS_EDIT;
|
||||
break;
|
||||
case 1:
|
||||
nextWindow=GUI_WINDOW_WAVE_EDIT;
|
||||
break;
|
||||
case 2:
|
||||
nextWindow=GUI_WINDOW_SAMPLE_EDIT;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (ImGui::IsItemHovered(ImGuiHoveredFlags_AllowWhenDisabled)) {
|
||||
ImGui::SetTooltip(_("Edit"));
|
||||
}
|
||||
ImGui::EndDisabled();
|
||||
ImGui::SameLine();
|
||||
pushToggleColors(insListDir);
|
||||
if (ImGui::Button(ICON_FA_SITEMAP "##DirMode")) {
|
||||
doAction(GUI_ACTION_INS_LIST_DIR_VIEW);
|
||||
|
@ -805,15 +805,6 @@ void FurnaceGUI::drawWaveList(bool asChild) {
|
|||
began=ImGui::Begin("Wavetables",&waveListOpen,globalWinFlags,_("Wavetables"));
|
||||
}
|
||||
if (began) {
|
||||
ImGui::BeginDisabled(e->song.waveLen==0);
|
||||
if (ImGui::Button(ICON_FA_PENCIL)) {
|
||||
nextWindow=GUI_WINDOW_WAVE_EDIT;
|
||||
}
|
||||
if (ImGui::IsItemHovered(ImGuiHoveredFlags_AllowWhenDisabled)) {
|
||||
ImGui::SetTooltip(_("Edit"));
|
||||
}
|
||||
ImGui::EndDisabled();
|
||||
ImGui::SameLine();
|
||||
if (ImGui::Button(ICON_FA_PLUS "##WaveAdd")) {
|
||||
doAction(GUI_ACTION_WAVE_LIST_ADD);
|
||||
}
|
||||
|
@ -862,6 +853,15 @@ void FurnaceGUI::drawWaveList(bool asChild) {
|
|||
}
|
||||
}
|
||||
ImGui::SameLine();
|
||||
ImGui::BeginDisabled(e->song.waveLen==0);
|
||||
if (ImGui::Button(ICON_FA_PENCIL)) {
|
||||
nextWindow=GUI_WINDOW_WAVE_EDIT;
|
||||
}
|
||||
if (ImGui::IsItemHovered(ImGuiHoveredFlags_AllowWhenDisabled)) {
|
||||
ImGui::SetTooltip(_("Edit"));
|
||||
}
|
||||
ImGui::EndDisabled();
|
||||
ImGui::SameLine();
|
||||
pushToggleColors(waveListDir);
|
||||
if (ImGui::Button(ICON_FA_SITEMAP "##WaveDirMode")) {
|
||||
doAction(GUI_ACTION_WAVE_LIST_DIR_VIEW);
|
||||
|
@ -949,15 +949,6 @@ void FurnaceGUI::drawSampleList(bool asChild) {
|
|||
began=ImGui::Begin("Samples",&sampleListOpen,globalWinFlags,_("Samples"));
|
||||
}
|
||||
if (began) {
|
||||
ImGui::BeginDisabled(e->song.sampleLen==0);
|
||||
if (ImGui::Button(ICON_FA_PENCIL)) {
|
||||
nextWindow=GUI_WINDOW_SAMPLE_EDIT;
|
||||
}
|
||||
if (ImGui::IsItemHovered(ImGuiHoveredFlags_AllowWhenDisabled)) {
|
||||
ImGui::SetTooltip(_("Edit"));
|
||||
}
|
||||
ImGui::EndDisabled();
|
||||
ImGui::SameLine();
|
||||
if (ImGui::Button(ICON_FA_FILE "##SampleAdd")) {
|
||||
doAction(GUI_ACTION_SAMPLE_LIST_ADD);
|
||||
}
|
||||
|
@ -1016,6 +1007,15 @@ void FurnaceGUI::drawSampleList(bool asChild) {
|
|||
ImGui::EndPopup();
|
||||
}
|
||||
ImGui::SameLine();
|
||||
ImGui::BeginDisabled(e->song.sampleLen==0);
|
||||
if (ImGui::Button(ICON_FA_PENCIL)) {
|
||||
nextWindow=GUI_WINDOW_SAMPLE_EDIT;
|
||||
}
|
||||
if (ImGui::IsItemHovered(ImGuiHoveredFlags_AllowWhenDisabled)) {
|
||||
ImGui::SetTooltip(_("Edit"));
|
||||
}
|
||||
ImGui::EndDisabled();
|
||||
ImGui::SameLine();
|
||||
pushToggleColors(sampleListDir);
|
||||
if (ImGui::Button(ICON_FA_SITEMAP "##SampleDirMode")) {
|
||||
doAction(GUI_ACTION_SAMPLE_LIST_DIR_VIEW);
|
||||
|
|
Loading…
Reference in a new issue