Skip to content

Commit

Permalink
Code Style - (#790)
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremypw authored Sep 16, 2024
1 parent 2c04d1b commit 1a6b46b
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 12 deletions.
5 changes: 3 additions & 2 deletions src/Dialogs/ColorPreferencesDialog.vala
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,14 @@ public class Terminal.Dialogs.ColorPreferences : Granite.Dialog {

public ColorPreferences (Gtk.Window? parent) {
Object (
resizable: false,
title: _("Color Preferences"),
transient_for: parent
);
}

construct {
resizable = false;
title = _("Color Preferences");

var window_theme_label = settings_label (_("Window style:"));
window_theme_label.margin_bottom = 12;

Expand Down
11 changes: 6 additions & 5 deletions src/Widgets/TerminalView.vala
Original file line number Diff line number Diff line change
Expand Up @@ -38,20 +38,21 @@ public class Terminal.TerminalView : Gtk.Box {

public TerminalView (MainWindow window) {
Object (
main_window: window,
orientation: Gtk.Orientation.VERTICAL,
hexpand: true,
vexpand: true
main_window: window
);
}

construct {
orientation = Gtk.Orientation.VERTICAL;
hexpand = true;
vexpand = true;

var app_instance = (Gtk.Application) GLib.Application.get_default ();

tab_view = new Hdy.TabView () {
hexpand = true,
vexpand = true
};

tab_view.menu_model = create_menu_model ();
tab_view.setup_menu.connect (tab_view_setup_menu);

Expand Down
13 changes: 8 additions & 5 deletions src/Widgets/TerminalWidget.vala
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ namespace Terminal {

GLib.Pid child_pid;

public unowned MainWindow main_window;
public unowned MainWindow main_window { get; construct set; }

private Terminal.Application app {
get {
return main_window.app;
Expand Down Expand Up @@ -154,13 +155,15 @@ namespace Terminal {
public signal void cwd_changed (string cwd);

public TerminalWidget (MainWindow parent_window) {
pointer_autohide = true;
Object (
main_window: parent_window
);
}

construct {
pointer_autohide = true;
terminal_id = "%i".printf (terminal_id_counter++);

init_complete = false;

main_window = parent_window;
child_has_exited = false;
killed = false;

Expand Down

0 comments on commit 1a6b46b

Please sign in to comment.