Made old & new imgui cohabitate.

This commit is contained in:
Branimir Karadžić 2016-05-28 20:52:18 -07:00
parent 29b5174ebf
commit ddfb525931

View File

@ -873,7 +873,10 @@ struct Imgui
bgfx::setViewRect(_view, 0, 0, _width, _height);
}
updateInput(mx, my, _button, _scroll, _inputChar);
if (!ImGui::IsMouseHoveringAnyWindow() )
{
updateInput(mx, my, _button, _scroll, _inputChar);
}
m_hot = m_hotToBe;
m_hotToBe = 0;
@ -3567,7 +3570,10 @@ float imguiGetTextLength(const char* _text, ImguiFontHandle _handle)
bool imguiMouseOverArea()
{
return s_imgui.m_insideArea;
return s_imgui.m_insideArea
|| ImGui::IsAnyItemHovered()
|| ImGui::IsMouseHoveringAnyWindow()
;
}
bgfx::ProgramHandle imguiGetImageProgram(uint8_t _mip)