public GUI() : base("yo") { //GLib.Timeout.Add(5, GlobalKeyChecker); Destroyed += quit; KeyPressEvent += OpenConsole; player = new Audio.Walkman(); player.Volume(0.3); consoleHide = false; console = new AConsole(player); menu = new Menu(player); label = new Label("shit"); box = new VBox(); music = new PlaylistViewContainer(player); //box.Add(menu); //box.Add(music); //box.Add(console); var menutest = new MenuBar(); menutest.Add(new Label("test")); menutest.Style = menu.Style; //menutest.HeightRequest = 30; //box.PackStart(menutest, false, false, 0); menu.HeightRequest = 30; var hboxtest = new HBox(); hboxtest.HeightRequest = 30; box.PackStart(menu, false, false, 0); box.PackStart(music, true, true, 0); box.PackStart(console, false, false, 0); this.SetDefaultSize(1280, 720); var p = player.createPlaylist("Play1", "s.flac", "s.mp3", "reaper.flac", "t.mp3"); player.createPlaylist("Test", "r.mp3", "reaper.flac"); player.setPlaylist(p); Add(box); }
private void SwitchPageHandler(object o, SwitchPageArgs args) { var playlistView = (PlaylistViewWindow)CurrentPageWidget; player.setPlaylist(playlistView.playlist); }