private void _initToolsColumn() { AddFileButton.Clicked += OnFileAddedClicked; RemoveButton.Clicked += OnRemoveFile; ImportButton.Clicked += OnImportClicked; ExportButton.Clicked += OnExport; System.EventHandler exportSelected = (sender, e) => { String output; exporterController.Export(selectedFile, out output); WriteLine(output); }; ExportSelectedButton.Clicked += exportSelected; }
public MainWindow(ExportSettingsController exportSettingsController, ExporterController exporterController, ConfigController configController) : base(Gtk.WindowType.Toplevel) { this.exporterController = exporterController; this.exportSettingsController = exportSettingsController; this.configController = configController; Build(); UpdateUI(); _initNodeStore(); _initDragAndDrop(); _initToolsColumn(); GlobalOptionsEntry.Buffer.Changed += (sender, e) => exportSettingsController.SetGlobalOptions(GlobalOptionsEntry.Buffer.Text); //Autoscroll console ConsoleText.SizeAllocated += (o, args) => { ConsoleScrollbox.Vadjustment.Value = ConsoleScrollbox.Vadjustment.Upper - ConsoleScrollbox.Vadjustment.PageSize; }; ExportMenuButton.Activated += (sender, e) => { String output; exporterController.Export(selectedFile, out output); WriteLine(output); }; ExportAllAction.Activated += OnExport; }