public StationView(StationModel model)
            : base(model)
        {
            this.model = model;
            HeadersVisible = true;

            TreeViewColumn station_column = AppendColumn(Catalog.GetString("Station"),
                new CellRendererStation(model), "text", 0);
            station_column.Sizing = TreeViewColumnSizing.Autosize;

            TreeViewColumn comment_column = AppendColumn(Catalog.GetString("Comment"),
                new CellRendererText(), "text", 1);
            comment_column.Sizing = TreeViewColumnSizing.Autosize;

            model.Reloaded += delegate {
                ExpandStations();
            };
        }
        public StationView(StationModel model) : base(model)
        {
            this.model     = model;
            HeadersVisible = true;

            TreeViewColumn station_column = AppendColumn(Catalog.GetString("Station"),
                                                         new CellRendererStation(model), "text", 0);

            station_column.Sizing = TreeViewColumnSizing.Autosize;

            TreeViewColumn comment_column = AppendColumn(Catalog.GetString("Comment"),
                                                         new CellRendererText(), "text", 1);

            comment_column.Sizing = TreeViewColumnSizing.Autosize;

            model.Reloaded += delegate {
                ExpandStations();
            };
        }
Beispiel #3
0
 public CellRendererStation(StationModel model)
 {
     this.model = model;
 }
        private void BuildInterface()
        {
            box = new VBox();

            model = new StationModel(plugin);
            view = new StationView(model);
            view.RowActivated += OnViewRowActivated;
            view.Popup += OnViewPopup;
            view.Selection.Changed += OnViewSelectionChanged;

            ScrolledWindow view_scroll = new ScrolledWindow();
            view_scroll.HscrollbarPolicy = PolicyType.Never;
            view_scroll.VscrollbarPolicy = PolicyType.Automatic;
            view_scroll.ShadowType = ShadowType.In;

            view_scroll.Add(view);

            status_bar = new HighlightMessageArea();
            status_bar.BorderWidth = 5;
            status_bar.LeftPadding = 15;

            box.PackStart(view_scroll, true, true, 0);
            box.PackStart(status_bar, false, false, 0);

            view_scroll.ShowAll();
            box.Show();
            status_bar.Hide();
        }
 public CellRendererStation(StationModel model)
 {
     this.model = model;
 }