コード例 #1
0
        public override void DidFinishLaunching(NSNotification notification)
        {
            new ConsoleLogger(LogLevel.DEBUG);

            mainWindowController = new MacWindowController();

            // This is where we setup our visual tree. These could be setup in MainWindow.xib, but
            // this example is showing programmatic creation.

            // We create a tab control to insert both examples into, and set it to take the entire window and resize
            CGRect frame = mainWindowController.Window.ContentView.Frame;

            stv = new ServerTable(frame);
            NSScrollView scrollView = new NSScrollView(frame)
            {
                AutoresizingMask      = NSViewResizingMask.HeightSizable | NSViewResizingMask.WidthSizable,
                HasHorizontalScroller = true,
                HasVerticalScroller   = true,
            };

            scrollView.DocumentView = stv.Table;


            mainWindowController.Window.ContentView.AddSubview(scrollView);
            mainWindowController.Window.MakeKeyAndOrderFront(this);

            autostartitem.State = NSCellStateValue.On;
            m = new Monitor(autostartitem.State == NSCellStateValue.On, ServerChanged);
        }
コード例 #2
0
 public TableDataSource(ServerTable stv)
 {
     this.stv = stv;
 }
コード例 #3
0
 public TableDelegate(ServerTable stv)
 {
     this.stv = stv;
 }