mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-09 23:54:20 +00:00
Backends: OSX: Fix keyboard support. Handle scroll cancel. Don't set mouse cursor shape unconditionally. (#4759, #4253, #1873)
Note the original FIXME: refered to GLFWs Cocoa implementation, which is largely what this commit provides.
This commit is contained in:
parent
f71ee5203e
commit
1b6b8602c1
5 changed files with 213 additions and 102 deletions
|
|
@ -119,7 +119,7 @@
|
|||
return event;
|
||||
}];
|
||||
|
||||
ImGui_ImplOSX_Init();
|
||||
ImGui_ImplOSX_Init(self.view);
|
||||
|
||||
#endif
|
||||
}
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@
|
|||
//ImGui::StyleColorsClassic();
|
||||
|
||||
// Setup Platform/Renderer backends
|
||||
ImGui_ImplOSX_Init();
|
||||
ImGui_ImplOSX_Init(self);
|
||||
ImGui_ImplOpenGL2_Init();
|
||||
|
||||
// Load Fonts
|
||||
|
|
@ -149,9 +149,6 @@
|
|||
-(void)reshape { [[self openGLContext] update]; [self updateAndDrawDemoView]; }
|
||||
-(void)drawRect:(NSRect)bounds { [self updateAndDrawDemoView]; }
|
||||
-(void)animationTimerFired:(NSTimer*)timer { [self setNeedsDisplay:YES]; }
|
||||
-(BOOL)acceptsFirstResponder { return (YES); }
|
||||
-(BOOL)becomeFirstResponder { return (YES); }
|
||||
-(BOOL)resignFirstResponder { return (YES); }
|
||||
-(void)dealloc { animationTimer = nil; }
|
||||
|
||||
//-----------------------------------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue