You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A handful of widgets seem to require more than one touch event to activate. I'm utilizing ImGui on a touch screen device without keyboard or mouse. The device runs wayland (no X11).
Screenshots/Video
(None Currently)
Standalone, minimal, complete and verifiable example:
The ImGui demo recreates this issue with no modifications.
Inside the demo window, select the "Tab widget". Tapping on the tab items consistently requires 2 touches to have the tab switch. The majority of other widgets appear to work fine - buttons require only a single press generally.
Hacky (Fix?)
A (probably incorrect) code change seemed to get behavior as desired was responding to SDL_FINGERUP, inside of imgui_impl_sdl.cpp . Enabling the preprocessor block here results in the desired behavior - but I'm not entirely certain what the exact chain of events is or if the behavior I'm creating is correct or not. (Also - probably wrong if we're dealing with Mouse + Touch screen interactions!) Still need to debug.
On my version of SDL, the FINGERUP appears to happen after the "button release" event.
bool ImGui_ImplSDL2_ProcessEvent(const SDL_Event* event)
{
ImGuiIO& io = ImGui::GetIO();
ImGui_ImplSDL2_Data* bd = ImGui_ImplSDL2_GetBackendData();
switch (event->type)
{
case SDL_FINGERUP:
{
#if 0
printf("FINGER UP EVENT - Set Mouse Pos - Single Clikck on Tab Item OK!\n");
io.AddMousePosEvent(-1, -1);
return true;
#else
printf("FINGER UP IGNORED - Do nothing (current behavior)\n");
#endif
break;
}
The text was updated successfully, but these errors were encountered:
Version/Branch of Dear ImGui:
Version: v1.87 (exact tag)
Branch: master
Back-end/Renderer/Compiler/OS
Back-ends: imgui_impl_sdl.cpp + imgui_impl_opengl3.cpp
Compiler: gcc 9.3.0
Operating System: embedded linux w/ wayland
My Issue/Question:
A handful of widgets seem to require more than one touch event to activate. I'm utilizing ImGui on a touch screen device without keyboard or mouse. The device runs wayland (no X11).
Screenshots/Video
(None Currently)
Standalone, minimal, complete and verifiable example:
The ImGui demo recreates this issue with no modifications.
Inside the demo window, select the "Tab widget". Tapping on the tab items consistently requires 2 touches to have the tab switch. The majority of other widgets appear to work fine - buttons require only a single press generally.
Hacky (Fix?)
A (probably incorrect) code change seemed to get behavior as desired was responding to SDL_FINGERUP, inside of imgui_impl_sdl.cpp . Enabling the preprocessor block here results in the desired behavior - but I'm not entirely certain what the exact chain of events is or if the behavior I'm creating is correct or not. (Also - probably wrong if we're dealing with Mouse + Touch screen interactions!) Still need to debug.
On my version of SDL, the FINGERUP appears to happen after the "button release" event.
The text was updated successfully, but these errors were encountered: