From e7e1c7b8f6f94c4530d58abe166e186d49c8854a Mon Sep 17 00:00:00 2001 From: sergiotarxz Date: Mon, 11 Mar 2024 18:17:45 +0100 Subject: [PATCH] Fix for windows. --- lib/GEmeTool/View/PokemonPCWindow.pm | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/lib/GEmeTool/View/PokemonPCWindow.pm b/lib/GEmeTool/View/PokemonPCWindow.pm index 16bea79..e069728 100644 --- a/lib/GEmeTool/View/PokemonPCWindow.pm +++ b/lib/GEmeTool/View/PokemonPCWindow.pm @@ -65,17 +65,11 @@ sub start { my $save = $self->_save; my $pc = $save->get_pc_system; my $box = $pc->get_box(0); - my $headerbar = Gtk4::HeaderBar->new; - $headerbar->set_decoration_layout(''); - my $title_grid = Gtk4::Grid->new; - $title_grid->attach(Gtk4::Label->new('Pokémon Storage System'), 0, 0, 12, 1); my $save_button = Gtk4::Button->new_with_label('Save'); $save_button->signal_connect(clicked => sub { $self->_save->get_pc_system->save; }); - $title_grid->attach($save_button, 0, 1, 2, 1); - $headerbar->set_title_widget($title_grid); - $gtk_window->set_titlebar($headerbar); + $gtk_window->set_title('PC Storage System'); $controller_gesture->set_button(1); $self->_current_box($box); $controller_gesture->signal_connect( @@ -121,7 +115,12 @@ sub start { $self->draw_cursor($cairo); } ); - $gtk_window->set_child($canvas); + my $window_box = Gtk4::Box->new('vertical', 1); + $window_box->append($save_button); + $canvas->set_hexpand(1); + $canvas->set_vexpand(1); + $window_box->append($canvas); + $gtk_window->set_child($window_box); $gtk_window->present; Glib::Timeout->add( 1000 / 15,