Remove DockThemeManager (#1294)

This commit is contained in:
Danielle Foré 2021-11-06 11:17:57 -07:00 committed by GitHub
parent ebfa8ea45d
commit 336332f4e7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 1 additions and 68 deletions

View File

@ -20,7 +20,6 @@ You'll need the following dependencies:
* libgranite-dev (>= 5.4.0) * libgranite-dev (>= 5.4.0)
* libgtk-3-dev (>= 3.10.0) * libgtk-3-dev (>= 3.10.0)
* libmutter-6-dev (>= 3.35.1) | libmutter-dev (>= 3.18.3) * libmutter-6-dev (>= 3.35.1) | libmutter-dev (>= 3.18.3)
* libplank-dev (>= 0.11.0)
* libxml2-utils * libxml2-utils
* valac (>= 0.28.0) * valac (>= 0.28.0)

View File

@ -81,7 +81,6 @@ add_project_arguments([
# Dependencies # Dependencies
glib_version_required = '2.44.0' glib_version_required = '2.44.0'
gtk_version_required = '3.10.0' gtk_version_required = '3.10.0'
plank_version_required = '0.11.0'
gsd_version_required = '3.15.2' gsd_version_required = '3.15.2'
canberra_dep = dependency('libcanberra') canberra_dep = dependency('libcanberra')
@ -91,7 +90,6 @@ gio_dep = dependency('gio-2.0', version: '>= @0@'.format(glib_version_required))
gmodule_dep = dependency('gmodule-2.0') gmodule_dep = dependency('gmodule-2.0')
gtk_dep = [dependency('gtk+-3.0', version: '>= @0@'.format(gtk_version_required)), dependency('gdk-x11-3.0')] gtk_dep = [dependency('gtk+-3.0', version: '>= @0@'.format(gtk_version_required)), dependency('gdk-x11-3.0')]
gee_dep = dependency('gee-0.8') gee_dep = dependency('gee-0.8')
plank_dep = dependency('plank', version: '>= @0@'.format(plank_version_required))
granite_dep = dependency('granite', version: '>= 5.4.0') granite_dep = dependency('granite', version: '>= 5.4.0')
gnome_desktop_dep = dependency('gnome-desktop-3.0') gnome_desktop_dep = dependency('gnome-desktop-3.0')
gsd_dep = dependency('gnome-settings-daemon', version: '>= @0@'.format(gsd_version_required)) gsd_dep = dependency('gnome-settings-daemon', version: '>= @0@'.format(gsd_version_required))
@ -170,7 +168,7 @@ endif
add_project_arguments(vala_flags, language: 'vala') add_project_arguments(vala_flags, language: 'vala')
add_project_link_arguments(['-Wl,-rpath,@0@'.format(mutter_typelib_dir)], language: 'c') add_project_link_arguments(['-Wl,-rpath,@0@'.format(mutter_typelib_dir)], language: 'c')
gala_base_dep = [canberra_dep, glib_dep, gobject_dep, gio_dep, gmodule_dep, gee_dep, gtk_dep, plank_dep, mutter_dep, granite_dep, gnome_desktop_dep, m_dep, posix_dep, gexiv2_dep, config_dep] gala_base_dep = [canberra_dep, glib_dep, gobject_dep, gio_dep, gmodule_dep, gee_dep, gtk_dep, mutter_dep, granite_dep, gnome_desktop_dep, m_dep, posix_dep, gexiv2_dep, config_dep]
if get_option('systemd') if get_option('systemd')
gala_base_dep += systemd_dep gala_base_dep += systemd_dep

View File

@ -1,61 +0,0 @@
//
// Copyright (C) 2012 Tom Beckmann, Rico Tzschichholz
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
//
namespace Gala {
/**
* Provides access to a PlankDrawingDockTheme and PlankDockPrefereces
*/
public class DockThemeManager : Object {
static DockThemeManager? instance = null;
public static unowned DockThemeManager get_default () {
if (instance == null)
instance = new DockThemeManager ();
return instance;
}
Plank.DockPreferences? dock_settings = null;
Plank.DockTheme? dock_theme = null;
public signal void dock_theme_changed (Plank.DockTheme? old_theme,
Plank.DockTheme new_theme);
DockThemeManager () {
dock_settings = new Plank.DockPreferences ("dock1");
dock_settings.notify["Theme"].connect (load_dock_theme);
}
public Plank.DockTheme get_dock_theme () {
if (dock_theme == null)
load_dock_theme ();
return dock_theme;
}
public Plank.DockPreferences get_dock_settings () {
return dock_settings;
}
void load_dock_theme () {
var new_theme = new Plank.DockTheme (dock_settings.Theme);
new_theme.load ("dock");
dock_theme_changed (dock_theme, new_theme);
dock_theme = new_theme;
}
}
}

View File

@ -97,8 +97,6 @@ namespace Gala {
GLib.Environment.unset_variable ("NO_AT_BRIDGE"); GLib.Environment.unset_variable ("NO_AT_BRIDGE");
#endif #endif
Plank.Paths.initialize ("plank", Config.DATADIR + "/plank");
// Force initialization of static fields in Utils class // Force initialization of static fields in Utils class
// https://gitlab.gnome.org/GNOME/vala/-/issues/11 // https://gitlab.gnome.org/GNOME/vala/-/issues/11
typeof (Gala.Utils).class_ref (); typeof (Gala.Utils).class_ref ();

View File

@ -1,7 +1,6 @@
gala_bin_sources = files( gala_bin_sources = files(
'DBus.vala', 'DBus.vala',
'DBusAccelerator.vala', 'DBusAccelerator.vala',
'DockThemeManager.vala',
'GalaAccountsServicePlugin.vala', 'GalaAccountsServicePlugin.vala',
'InternalUtils.vala', 'InternalUtils.vala',
'KeyboardManager.vala', 'KeyboardManager.vala',