From dc1f1e02a176faf15de82c4b9289d1db68d1544b Mon Sep 17 00:00:00 2001 From: Bruno Herbelin Date: Sat, 2 Apr 2022 17:45:57 +0200 Subject: [PATCH] Unifying icons for session and group sources UI --- ImGuiVisitor.cpp | 11 +++++++---- MixingView.cpp | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/ImGuiVisitor.cpp b/ImGuiVisitor.cpp index 2160914..6f278bf 100644 --- a/ImGuiVisitor.cpp +++ b/ImGuiVisitor.cpp @@ -638,12 +638,12 @@ void ImGuiVisitor::visit (SessionFileSource& s) ImGui::SetCursorPos(pos); } - if ( ImGui::Button( ICON_FA_FILE_EXPORT " Import", ImVec2(IMGUI_RIGHT_ALIGN, 0)) ) + if ( ImGui::Button( ICON_FA_SIGN_OUT_ALT " Import", ImVec2(IMGUI_RIGHT_ALIGN, 0)) ) Mixer::manager().import( &s ); ImGui::SameLine(); ImGui::Text("Sources"); - if (ImGuiToolkit::ButtonIcon(3, 2)) s.session()->setFadingTarget(0.f); + if (ImGuiToolkit::IconButton(2, 1)) s.session()->setFadingTarget(0.f); float f = s.session()->fading(); ImGui::SameLine(0, IMGUI_SAME_LINE); ImGui::SetNextItemWidth(IMGUI_RIGHT_ALIGN); @@ -693,9 +693,12 @@ void ImGuiVisitor::visit (SessionGroupSource& s) ImGui::SetCursorPos(pos); } - if ( ImGui::Button( ICON_FA_UPLOAD " Expand", ImVec2(IMGUI_RIGHT_ALIGN, 0)) ){ + + + if ( ImGui::Button( ICON_FA_SIGN_OUT_ALT " Import", ImVec2(IMGUI_RIGHT_ALIGN, 0)) ) Mixer::manager().import( &s ); - } + ImGui::SameLine(); + ImGui::Text("Sources"); } void ImGuiVisitor::visit (RenderSource& s) diff --git a/MixingView.cpp b/MixingView.cpp index 0787bac..dadcb83 100644 --- a/MixingView.cpp +++ b/MixingView.cpp @@ -499,7 +499,7 @@ View::Cursor MixingView::grab (Source *s, glm::vec2 from, glm::vec2 to, std::pai // cursor feedback slider_->color = glm::vec4( COLOR_CIRCLE_OVER, 0.9f ); std::ostringstream info; - info << "Output " << 100 - int(f * 100.0) << " %"; + info << ICON_FA_ADJUST << " Output fading " << 100 - int(f * 100.0) << " %"; return Cursor(Cursor_Hand, info.str() ); } else if (pick.first == limbo_slider_) {