diff options
| author | Manolo Gouy <Manolo> | 2010-02-11 09:32:26 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2010-02-11 09:32:26 +0000 |
| commit | 1ff2af5fd30272885bdcbec22809377fb2e3456f (patch) | |
| tree | d7cbbde7fb8c35c967c2f0e4a6150410816b78a7 /src | |
| parent | 881c882629abd6c05266a18588176943c06a367c (diff) | |
update event_x_root and event_x earlier is more accurate
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7062 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
| -rw-r--r-- | src/Fl_cocoa.mm | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/Fl_cocoa.mm b/src/Fl_cocoa.mm index 334720b3d..46b9fad24 100644 --- a/src/Fl_cocoa.mm +++ b/src/Fl_cocoa.mm @@ -53,7 +53,9 @@ extern "C" { #include <FL/x.H> #include <FL/Fl_Window.H> #include <FL/Fl_Tooltip.H> -#if __GNUC__ == 3 // because Fl_Image.H uses a private variable name id that's illegal under GCC 3 +#if __GNUC__ == 3 +// because Fl_Image.H, included by Fl_Sys_Menu_Bar.H, uses a private variable name id +// that's illegal under GCC 3 -x -objective-c++ #define id id_ #endif #include <FL/Fl_Sys_Menu_Bar.H> @@ -1310,11 +1312,11 @@ extern "C" { pt.x = 0; pt.y = [[nsw contentView] frame].size.height; pt2 = [nsw convertBaseToScreen:pt]; + update_e_xy_and_e_xy_root(nsw); window->position((int)pt2.x, (int)([[nsw screen] frame].size.height - pt2.y)); if ([nsw containsGLsubwindow] ) { [nsw display];// redraw window after moving if it contains OpenGL subwindows } - update_e_xy_and_e_xy_root(nsw); } - (void)windowDidResize:(NSNotification *)notif { @@ -1326,11 +1328,11 @@ extern "C" { pt.y = [[nsw contentView] frame].size.height; pt2 = [nsw convertBaseToScreen:pt]; resize_from_system = window; + update_e_xy_and_e_xy_root(nsw); window->resize((int)pt2.x, (int)([[nsw screen] frame].size.height - pt2.y), (int)r.size.width, (int)r.size.height); - update_e_xy_and_e_xy_root(nsw); } - (void)windowDidBecomeKey:(NSNotification *)notif { |
