Skip to content

Commit

Permalink
only accept gestures when ImGui doesn't want input
Browse files Browse the repository at this point in the history
  • Loading branch information
wkjarosz committed Jan 4, 2024
1 parent bd88f8e commit 5b15eeb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
6 changes: 5 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,11 @@ if(portable-file-dialogs_ADDED)
target_include_directories(portable-file-dialogs INTERFACE "${portable-file-dialogs_SOURCE_DIR}")
endif()

# set(HELLOIMGUI_USE_GLFW_METAL ON) set(HELLOIMGUI_USE_GLFW_OPENGL3 ON) set(HELLOIMGUI_USE_SDL_OPENGL3 ON)
# set(HELLOIMGUI_USE_GLFW_METAL ON)

# set(HELLOIMGUI_USE_GLFW_OPENGL3 ON)

# set(HELLOIMGUI_USE_SDL_OPENGL3 ON)
CPMAddPackage("gh:pthom/hello_imgui#8abe2c98dbf99e3a098eb5548b0a079c9f4c8a8f")
if(hello_imgui_ADDED)
message(STATUS "hello_imgui library added")
Expand Down
5 changes: 4 additions & 1 deletion src/app.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -958,7 +958,10 @@ void SampleViewer::draw_editor()

bool SampleViewer::process_event(void *e)
{
#ifdef HELLOIMGUI_USE_SDL_OPENGL3
#ifdef HELLOIMGUI_USE_SDL
if (ImGui::GetIO().WantCaptureMouse)
return false;

static bool sPinch = false;
SDL_Event *event = static_cast<SDL_Event *>(e);
switch (event->type)
Expand Down

0 comments on commit 5b15eeb

Please sign in to comment.