Exemple #1
0
        /****************** Upper right drawer ******************/

        /* Our two right drawers divide the right edge of the parent window between them.
         * In addition, they resize together horizontally, in such a way as to maintain a
         * constant total width.
         *
         * The upper right drawer will use our custom delegate class and the lower right drawer will events.
         */

        private void setupUpperRightDrawer()
        {
            CGSize contentSize = new CGSize(150, 150);

            upperRightDrawer = new NSDrawer(contentSize, NSRectEdge.MaxXEdge)
            {
                ParentWindow   = myParentWindow,
                MinContentSize = contentSize
            };

            // setup delegate to recompute the sizes and control close
            myDrawerDelegate          = new MyDrawerDelegate(this);
            upperRightDrawer.Delegate = myDrawerDelegate;
        }
		/****************** Upper right drawer ******************/

		/* Our two right drawers divide the right edge of the parent window between them. 
		In addition, they resize together horizontally, in such a way as to maintain a
		constant total width. 
		
		The upper right drawer will use our custom delegate class and the lower right drawer will events.
		*/
		
		private void setupUpperRightDrawer() {
			SizeF contentSize = new SizeF(150,150);
			upperRightDrawer = new NSDrawer(contentSize,NSRectEdge.MaxXEdge) {
				ParentWindow = myParentWindow,
				MinContentSize = contentSize
			};

			// setup delegate to recompute the sizes and control close
			myDrawerDelegate = new MyDrawerDelegate(this);
			upperRightDrawer.Delegate = myDrawerDelegate;
		}