mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-11 00:04:24 +00:00
Backends: OSX: Added support for io.AddMouseSourceEvent(). (#6314)
Also marked "mouse" input in example_apple_metal's UIKit micro-backend as being touch input. # Conflicts: # docs/CHANGELOG.txt
This commit is contained in:
parent
db4c4e3321
commit
e92b29ad53
4 changed files with 35 additions and 1 deletions
|
|
@ -228,6 +228,7 @@
|
|||
UITouch *anyTouch = event.allTouches.anyObject;
|
||||
CGPoint touchLocation = [anyTouch locationInView:self.view];
|
||||
ImGuiIO &io = ImGui::GetIO();
|
||||
io.AddMouseSourceEvent(ImGuiMouseSource_TouchScreen);
|
||||
io.AddMousePosEvent(touchLocation.x, touchLocation.y);
|
||||
|
||||
BOOL hasActiveTouch = NO;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue