wavetable list selectable sizing fix
This commit is contained in:
parent
4eda4aeb39
commit
65fbdba831
|
@ -172,10 +172,12 @@ void FurnaceGUI::waveListItem(int i, float* wavePreview, int dir, int asset) {
|
|||
wavePreview[i]=wave->data[i];
|
||||
}
|
||||
if (wave->len>0) wavePreview[wave->len]=wave->data[wave->len-1];
|
||||
if (ImGui::Selectable(fmt::sprintf("%d##_WAVE%d\n",i,i).c_str(),curWave==i)) {
|
||||
ImGui::PushStyleVar(ImGuiStyleVar_SelectableTextAlign, ImVec2(0,0.5f));
|
||||
if (ImGui::Selectable(fmt::sprintf(" %d##_WAVE%d\n",i,i).c_str(),curWave==i, 0, ImVec2(0,23*dpiScale))) {//i didnt think that the 0 would work, but it does
|
||||
curWave=i;
|
||||
lastAssetType=1;
|
||||
}
|
||||
ImGui::PopStyleVar();
|
||||
if (wantScrollList && curWave==i) ImGui::SetScrollHereY();
|
||||
if (ImGui::IsItemHovered()) {
|
||||
if (ImGui::IsMouseDoubleClicked(ImGuiMouseButton_Left)) {
|
||||
|
|
Loading…
Reference in New Issue