Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions data/dock.gschema.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,12 @@
<description>Logical pixel size of app launcher icons</description>
</key>

<key type="i" name="height">
<default>-1</default>
<summary>Current allocated height</summary>
<description>Current allocated height</description>
</key>

<key type="as" name="launchers">
<default>['io.elementary.files.desktop', 'org.gnome.Epiphany.desktop', 'io.elementary.mail.desktop', 'io.elementary.tasks.desktop', 'io.elementary.calendar.desktop', 'io.elementary.music.desktop', 'io.elementary.videos.desktop', 'io.elementary.photos.desktop', 'io.elementary.appcenter.desktop', 'io.elementary.installer.desktop']</default>
<summary>An ordered array of app id's to show as launchers</summary>
Expand Down
3 changes: 3 additions & 0 deletions src/MainWindow.vala
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,8 @@ public class Dock.MainWindow : Gtk.ApplicationWindow {
private void init_panel () {
unowned var surface = (Gdk.Toplevel) get_surface ();

settings.set_int ("height", surface.height);

surface.compute_size.connect ((surface, size) => {
// manually set shadow width since the additional margin we add to avoid icons clipping when
// bouncing isn't added by default and instead counts to the frame
Expand All @@ -118,6 +120,7 @@ public class Dock.MainWindow : Gtk.ApplicationWindow {
});

surface.layout.connect ((surface, width, height) => {
settings.set_int ("height", height);
// manually set input region since container's shadow are is the content of the window
// and it still gets window events
var item_manager_width = item_manager.get_width ();
Expand Down