forked from Green-Sky/tomato
fix bitset getting rendered all the time
This commit is contained in:
parent
9777cb81cb
commit
f2027befc8
@ -1246,8 +1246,14 @@ void ChatGui4::renderMessageBodyFile(Message3Registry& reg, const Message3 e) {
|
|||||||
overlay_buf
|
overlay_buf
|
||||||
);
|
);
|
||||||
|
|
||||||
auto const cursor_start_vec = ImGui::GetCursorScreenPos();
|
ImVec2 orig_curser_pos = ImGui::GetCursorPos();
|
||||||
const ImVec2 bar_size{ImGui::GetContentRegionAvail().x, TEXT_BASE_HEIGHT*0.15f};
|
const ImVec2 bar_size{ImGui::GetContentRegionAvail().x, TEXT_BASE_HEIGHT*0.15f};
|
||||||
|
// deploy dummy and check visibility
|
||||||
|
ImGui::Dummy(bar_size);
|
||||||
|
if (ImGui::IsItemVisible()) {
|
||||||
|
ImGui::SetCursorPos(orig_curser_pos); // reset before dummy
|
||||||
|
|
||||||
|
auto const cursor_start_vec = ImGui::GetCursorScreenPos();
|
||||||
// TODO: replace with own version, so we dont have to internal
|
// TODO: replace with own version, so we dont have to internal
|
||||||
ImGui::RenderFrame(
|
ImGui::RenderFrame(
|
||||||
cursor_start_vec,
|
cursor_start_vec,
|
||||||
@ -1267,6 +1273,7 @@ void ChatGui4::renderMessageBodyFile(Message3Registry& reg, const Message3 e) {
|
|||||||
{1.f, 1.f}, // default
|
{1.f, 1.f}, // default
|
||||||
ImGui::GetStyleColorVec4(ImGuiCol_PlotHistogram)
|
ImGui::GetStyleColorVec4(ImGuiCol_PlotHistogram)
|
||||||
);
|
);
|
||||||
|
}
|
||||||
|
|
||||||
ImGui::EndGroup();
|
ImGui::EndGroup();
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user