From 0ba6c0e381c205c949edf34d9cf77c4cd4a7bb63 Mon Sep 17 00:00:00 2001 From: Manolo Gouy Date: Tue, 18 Oct 2011 12:18:22 +0000 Subject: Simplified window positioning on main screen. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9135 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_cocoa.mm | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'src') diff --git a/src/Fl_cocoa.mm b/src/Fl_cocoa.mm index 0519797a1..8a14eaf8e 100644 --- a/src/Fl_cocoa.mm +++ b/src/Fl_cocoa.mm @@ -1976,7 +1976,6 @@ static void q_set_window_title(NSWindow *nsw, const char * name, const char *mi */ void Fl_X::make(Fl_Window* w) { - static int xyPos = 100; if ( w->parent() ) { // create a subwindow Fl_Group::current(0); // our subwindow needs this structure to know about its clipping. @@ -2061,13 +2060,7 @@ void Fl_X::make(Fl_Window* w) wp += 2*bx; hp += 2*by+bt; } - if (!(w->flags() & Fl_Window::FORCE_POSITION)) { - // default window positioning on the main screen - w->x(xyPos+Fl::x()); - w->y(xyPos+Fl::y()); - xyPos += 25; - if (xyPos>200) xyPos = 100; - } else { + if (w->flags() & Fl_Window::FORCE_POSITION) { if (!Fl::grab()) { xp = xwm; yp = ywm; w->x(xp);w->y(yp); -- cgit v1.2.3