diff options
author | Robert Tari <robert@tari.in> | 2023-05-08 04:11:37 +0200 |
---|---|---|
committer | Robert Tari <robert@tari.in> | 2023-05-08 04:11:37 +0200 |
commit | 886d9b70cbe8d948843d75f648f852c437c0a6e2 (patch) | |
tree | 1d0630d3bb91729d2f43ff3122caa6dc8628be27 /src/main-window.vala | |
parent | 9b4d66446225aa5d5e6e089e01917408535cc362 (diff) | |
download | arctica-greeter-886d9b70cbe8d948843d75f648f852c437c0a6e2.tar.gz arctica-greeter-886d9b70cbe8d948843d75f648f852c437c0a6e2.tar.bz2 arctica-greeter-886d9b70cbe8d948843d75f648f852c437c0a6e2.zip |
src/main-window: Rewrite some deprecated Gtk.Alignments
Diffstat (limited to 'src/main-window.vala')
-rw-r--r-- | src/main-window.vala | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/src/main-window.vala b/src/main-window.vala index 32df287..5e500af 100644 --- a/src/main-window.vala +++ b/src/main-window.vala @@ -64,7 +64,6 @@ public class MainWindow : Gtk.Window /* Box for menubar shadow */ var menubox = new Gtk.EventBox (); - var menualign = new Gtk.Alignment (0.0f, 0.0f, 1.0f, 0.0f); var shadow_path = Path.build_filename (Config.PKGDATADIR, "shadow.png", null); var shadow_style = ""; @@ -92,16 +91,18 @@ public class MainWindow : Gtk.Window */ menubox.set_size_request (-1, MENUBAR_HEIGHT); menubox.show (); - menualign.show (); - menubox.add (menualign); login_box.add (menubox); - ArcticaGreeter.add_style_class (menualign); ArcticaGreeter.add_style_class (menubox); menubar = new MenuBar (background, accel_group); + menubar.set_hexpand (true); + menubar.set_vexpand (false); + menubar.set_halign (Gtk.Align.FILL); + menubar.set_valign (Gtk.Align.START); menubar.show (); - menualign.add (menubar); + menubox.add (menubar); ArcticaGreeter.add_style_class (menubar); + ArcticaGreeter.add_style_class (menubox); hbox = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 0); hbox.expand = true; @@ -143,13 +144,13 @@ public class MainWindow : Gtk.Window align.add (back_button); - align = new Gtk.Alignment (0.0f, 0.5f, 0.0f, 1.0f); - align.show (); - hbox.add (align); - stack = new ListStack (); stack.show (); - align.add (stack); + stack.set_hexpand (false); + stack.set_vexpand (true); + stack.set_halign (Gtk.Align.CENTER); + stack.set_valign (Gtk.Align.FILL); + hbox.add (stack); add_user_list (); |