ditch the gnome titlebar (for now) as it doesn't work properly for me ;(

This commit is contained in:
Vivianne 2022-03-22 23:49:59 -07:00
parent 35b69747e8
commit 64ba90c802
4 changed files with 647 additions and 612 deletions

View file

@ -3,7 +3,6 @@
<interface>
<requires lib="gtk+" version="3.24"/>
<template class="DeskcandyDesktopWindow" parent="GtkWindow">
<property name="visible">True</property>
<property name="sensitive">False</property>
<property name="can-focus">False</property>
<property name="resizable">False</property>

View file

@ -23,19 +23,21 @@ namespace Deskcandy {
}
this.socket = new Gtk.Socket();
this.socket.set_visible(true);
this.add(this.socket);
this.socket.visible = true;
this.visible = true;
try {
this.proc = candy.launch((uint)this.socket.get_id(), "abstractile");
this.proc = candy.launch((uint)this.socket.get_id(), "unknownpleasures");
} catch (Error e) {
error(e.message);
}
}
private void on_initialized(BaseCandy[] candies) {
this.present();
//this.refresh_socket(candy);
this.refresh_socket(candies[0]);
}
}
}

File diff suppressed because it is too large Load diff

View file

@ -9,11 +9,11 @@ namespace Deskcandy {
[GtkChild]
private unowned Gtk.MenuButton open_menu_button;
[GtkChild]
private unowned Gtk.Box preview;
[GtkChild]
private unowned Gtk.HeaderBar headerbar;
private unowned Gtk.Bin preview;
[GtkChild]
private unowned Gtk.Stack main_stack;
[GtkChild]
private unowned Gtk.Label candy_status;
[GtkChild]
private unowned Gtk.ListStore screensavers_liststore;
@ -64,10 +64,8 @@ namespace Deskcandy {
}
this.socket = new Gtk.Socket();
this.socket.expand = true;
this.preview.add(this.socket);
this.socket.visible = true;
this.socket.realize();
this.preview.add(this.socket);
try {
this.proc = candy.launch((uint)this.socket.get_id(), name);
@ -120,7 +118,7 @@ namespace Deskcandy {
private void on_notify_enabled(Object o, GLib.ParamSpec param) {
var val = ((Application)o).enabled;
this.headerbar.subtitle = val ? "started" : "stopped";
this.candy_status.label = val ? "Candy started" : "Candy stopped";
}
}
}