예제 #1
0
        public static void AlignTop(this NSWindow from, NSWindow toView, int pixels)
        {
            var frame = from.Frame;

            frame.Location = new CGPoint(toView.Frame.Left, toView.AccessibilityFrame.Y + toView.Frame.Height + pixels);
            from.SetFrame(frame, true);
        }
예제 #2
0
        public static void AlignLeft(this NSWindow sender, NSWindow toView, int pixels)
        {
            var frame = sender.Frame;

            frame.Location = new CGPoint(toView.Frame.Left - sender.Frame.Width - pixels, toView.Frame.Bottom - frame.Height);
            sender.SetFrame(frame, true);
        }