]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix error when creating frames on NS with no main window
authorPo Lu <luangruo@yahoo.com>
Wed, 9 Mar 2022 08:28:33 +0000 (16:28 +0800)
committerPo Lu <luangruo@yahoo.com>
Wed, 9 Mar 2022 08:28:33 +0000 (16:28 +0800)
* nsfns.m (Fx_create_frame): If main window is not present,
center frame window instead of cascading it.

src/nsfns.m

index 6256bd220dda33ad0af6bb2e5cd2bf4dd17a89e6..720ed3f88e546b47a44787acb0b6fd6886498187 100644 (file)
@@ -1503,7 +1503,7 @@ DEFUN ("x-create-frame", Fx_create_frame, Sx_create_frame,
          [frame_window cascadeTopLeftFromPoint: top_left];
        }
       else
-       [main_window center];
+       [frame_window center];
     }
 
   /* Make sure windows on this frame appear in calls to next-window