2002-10-29 06:19:52 +00:00
|
|
|
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
|
|
|
|
|
|
|
|
/* gnome-window-manager.h
|
|
|
|
* Copyright (C) 2002 Seth Nickell
|
|
|
|
* Copyright (C) 2002 Red Hat, Inc.
|
|
|
|
*
|
|
|
|
* Written by: Seth Nickell <snickell@stanford.edu>,
|
|
|
|
* Havoc Pennington <hp@redhat.com>
|
|
|
|
*
|
|
|
|
* 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 2, 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, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
|
|
|
* 02111-1307, USA.
|
|
|
|
*/
|
|
|
|
|
2002-05-15 00:57:00 +00:00
|
|
|
#include "gnome-window-manager.h"
|
|
|
|
|
|
|
|
#include <gmodule.h>
|
|
|
|
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
static GObjectClass *parent_class;
|
|
|
|
|
|
|
|
struct _GnomeWindowManagerPrivate {
|
2002-10-29 06:19:52 +00:00
|
|
|
char *window_manager_name;
|
|
|
|
GnomeDesktopItem *ditem;
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
};
|
|
|
|
|
2002-05-15 00:57:00 +00:00
|
|
|
GObject *
|
2002-10-29 06:19:52 +00:00
|
|
|
gnome_window_manager_new (GnomeDesktopItem *it)
|
2002-05-15 00:57:00 +00:00
|
|
|
{
|
2002-10-29 06:19:52 +00:00
|
|
|
const char *settings_lib;
|
|
|
|
char *module_name;
|
|
|
|
GnomeWindowManagerNewFunc wm_new_func = NULL;
|
|
|
|
GObject *wm;
|
|
|
|
GModule *module;
|
|
|
|
gboolean success;
|
|
|
|
|
|
|
|
settings_lib = gnome_desktop_item_get_string (it, "X-GNOME-WMSettingsModule");
|
|
|
|
|
|
|
|
module_name = g_module_build_path (GNOME_WINDOW_MANAGER_MODULE_PATH,
|
|
|
|
settings_lib);
|
|
|
|
|
|
|
|
module = g_module_open (module_name, G_MODULE_BIND_LAZY);
|
|
|
|
if (module == NULL) {
|
|
|
|
g_warning ("Couldn't load window manager settings module `%s' (%s)", module_name, g_module_error ());
|
Patch from Kjartan Maraas to fix a bunch of leaks.
Thu Feb 13 18:51:37 2003 Jonathan Blandford <jrb@redhat.com>
* capplets/common/gconf-property-editor.c: (gconf_peditor_new):
* capplets/common/gnome-theme-info.c: (read_meta_theme),
(update_theme_index), (update_common_theme_dir_index),
(top_theme_dir_changed), (top_icon_theme_dir_changed),
(add_common_theme_dir_monitor), (real_add_top_theme_dir_monitor):
* capplets/default-applications/gnome-default-applications-properti
es.c: (initialize_default_applications), (read_editor),
(read_terminal):
* capplets/file-types/mime-edit-dialog.c: (fill_dialog):
* capplets/file-types/mime-type-info.c: (load_all_mime_types):
* capplets/file-types/mime-types-model.c:
(mime_types_model_get_value):
* capplets/font/main.c: (font_render_get_gconf), (enum_group_load):
* capplets/mouse/gnome-mouse-properties.c: (read_cursor_font),
(cursor_changed):
* capplets/theme-switcher/gnome-theme-details.c:
(window_theme_selection_changed):
* capplets/theme-switcher/gnome-theme-manager.c:
(meta_theme_selection_changed):
* capplets/theme-switcher/theme-thumbnail.c:
(generate_theme_thumbnail):
* libsounds/sound-properties.c: (sound_properties_add_directory),
(sound_properties_add_file):
* libsounds/sound-view.c: (compare_func):
* libwindow-settings/gnome-window-manager.c:
(gnome_window_manager_new): Patch from Kjartan Maraas to fix a
bunch of leaks.
2003-02-14 00:02:50 +00:00
|
|
|
g_free (module_name);
|
2002-10-29 06:19:52 +00:00
|
|
|
return NULL;
|
|
|
|
}
|
|
|
|
|
|
|
|
success = g_module_symbol (module, "window_manager_new",
|
|
|
|
(gpointer *) &wm_new_func);
|
2002-05-15 00:57:00 +00:00
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
if ((!success) || wm_new_func == NULL) {
|
|
|
|
g_warning ("Couldn't load window manager settings module `%s`, couldn't find symbol \'window_manager_new\'", module_name);
|
Patch from Kjartan Maraas to fix a bunch of leaks.
Thu Feb 13 18:51:37 2003 Jonathan Blandford <jrb@redhat.com>
* capplets/common/gconf-property-editor.c: (gconf_peditor_new):
* capplets/common/gnome-theme-info.c: (read_meta_theme),
(update_theme_index), (update_common_theme_dir_index),
(top_theme_dir_changed), (top_icon_theme_dir_changed),
(add_common_theme_dir_monitor), (real_add_top_theme_dir_monitor):
* capplets/default-applications/gnome-default-applications-properti
es.c: (initialize_default_applications), (read_editor),
(read_terminal):
* capplets/file-types/mime-edit-dialog.c: (fill_dialog):
* capplets/file-types/mime-type-info.c: (load_all_mime_types):
* capplets/file-types/mime-types-model.c:
(mime_types_model_get_value):
* capplets/font/main.c: (font_render_get_gconf), (enum_group_load):
* capplets/mouse/gnome-mouse-properties.c: (read_cursor_font),
(cursor_changed):
* capplets/theme-switcher/gnome-theme-details.c:
(window_theme_selection_changed):
* capplets/theme-switcher/gnome-theme-manager.c:
(meta_theme_selection_changed):
* capplets/theme-switcher/theme-thumbnail.c:
(generate_theme_thumbnail):
* libsounds/sound-properties.c: (sound_properties_add_directory),
(sound_properties_add_file):
* libsounds/sound-view.c: (compare_func):
* libwindow-settings/gnome-window-manager.c:
(gnome_window_manager_new): Patch from Kjartan Maraas to fix a
bunch of leaks.
2003-02-14 00:02:50 +00:00
|
|
|
g_free (module_name);
|
2002-10-29 06:19:52 +00:00
|
|
|
return NULL;
|
|
|
|
}
|
|
|
|
|
Patch from Kjartan Maraas to fix a bunch of leaks.
Thu Feb 13 18:51:37 2003 Jonathan Blandford <jrb@redhat.com>
* capplets/common/gconf-property-editor.c: (gconf_peditor_new):
* capplets/common/gnome-theme-info.c: (read_meta_theme),
(update_theme_index), (update_common_theme_dir_index),
(top_theme_dir_changed), (top_icon_theme_dir_changed),
(add_common_theme_dir_monitor), (real_add_top_theme_dir_monitor):
* capplets/default-applications/gnome-default-applications-properti
es.c: (initialize_default_applications), (read_editor),
(read_terminal):
* capplets/file-types/mime-edit-dialog.c: (fill_dialog):
* capplets/file-types/mime-type-info.c: (load_all_mime_types):
* capplets/file-types/mime-types-model.c:
(mime_types_model_get_value):
* capplets/font/main.c: (font_render_get_gconf), (enum_group_load):
* capplets/mouse/gnome-mouse-properties.c: (read_cursor_font),
(cursor_changed):
* capplets/theme-switcher/gnome-theme-details.c:
(window_theme_selection_changed):
* capplets/theme-switcher/gnome-theme-manager.c:
(meta_theme_selection_changed):
* capplets/theme-switcher/theme-thumbnail.c:
(generate_theme_thumbnail):
* libsounds/sound-properties.c: (sound_properties_add_directory),
(sound_properties_add_file):
* libsounds/sound-view.c: (compare_func):
* libwindow-settings/gnome-window-manager.c:
(gnome_window_manager_new): Patch from Kjartan Maraas to fix a
bunch of leaks.
2003-02-14 00:02:50 +00:00
|
|
|
g_free (module_name);
|
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
wm = (* wm_new_func) (GNOME_WINDOW_MANAGER_INTERFACE_VERSION);
|
|
|
|
|
|
|
|
if (wm == NULL)
|
|
|
|
return NULL;
|
|
|
|
|
|
|
|
(GNOME_WINDOW_MANAGER (wm))->p->window_manager_name = g_strdup (gnome_desktop_item_get_string (it, GNOME_DESKTOP_ITEM_NAME));
|
|
|
|
(GNOME_WINDOW_MANAGER (wm))->p->ditem = gnome_desktop_item_ref (it);
|
2002-05-15 00:57:00 +00:00
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
return wm;
|
2002-05-15 00:57:00 +00:00
|
|
|
}
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
|
|
|
|
const char *
|
|
|
|
gnome_window_manager_get_name (GnomeWindowManager *wm)
|
|
|
|
{
|
2002-10-29 06:19:52 +00:00
|
|
|
return wm->p->window_manager_name;
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
}
|
2002-06-04 23:00:19 +00:00
|
|
|
|
|
|
|
GnomeDesktopItem *
|
|
|
|
gnome_window_manager_get_ditem (GnomeWindowManager *wm)
|
|
|
|
{
|
2002-10-29 06:19:52 +00:00
|
|
|
return gnome_desktop_item_ref (wm->p->ditem);
|
2002-06-04 23:00:19 +00:00
|
|
|
}
|
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
GList *
|
|
|
|
gnome_window_manager_get_theme_list (GnomeWindowManager *wm)
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
{
|
2002-10-29 06:19:52 +00:00
|
|
|
GnomeWindowManagerClass *klass = GNOME_WINDOW_MANAGER_GET_CLASS (wm);
|
|
|
|
if (klass->get_theme_list)
|
|
|
|
return klass->get_theme_list (wm);
|
|
|
|
else
|
|
|
|
return NULL;
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
}
|
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
char *
|
|
|
|
gnome_window_manager_get_user_theme_folder (GnomeWindowManager *wm)
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
{
|
2002-10-29 06:19:52 +00:00
|
|
|
GnomeWindowManagerClass *klass = GNOME_WINDOW_MANAGER_GET_CLASS (wm);
|
|
|
|
if (klass->get_user_theme_folder)
|
|
|
|
return klass->get_user_theme_folder (wm);
|
|
|
|
else
|
|
|
|
return NULL;
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
2002-10-29 06:19:52 +00:00
|
|
|
gnome_window_manager_get_double_click_actions (GnomeWindowManager *wm,
|
|
|
|
const GnomeWMDoubleClickAction **actions,
|
|
|
|
int *n_actions)
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
{
|
2002-10-29 06:19:52 +00:00
|
|
|
GnomeWindowManagerClass *klass = GNOME_WINDOW_MANAGER_GET_CLASS (wm);
|
|
|
|
|
|
|
|
*actions = NULL;
|
|
|
|
*n_actions = 0;
|
|
|
|
|
|
|
|
if (klass->get_double_click_actions)
|
2003-01-08 05:41:30 +00:00
|
|
|
klass->get_double_click_actions (wm, actions, n_actions);
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
}
|
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
void
|
|
|
|
gnome_window_manager_change_settings (GnomeWindowManager *wm,
|
|
|
|
const GnomeWMSettings *settings)
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
{
|
2002-10-29 06:19:52 +00:00
|
|
|
GnomeWindowManagerClass *klass = GNOME_WINDOW_MANAGER_GET_CLASS (wm);
|
|
|
|
|
|
|
|
(* klass->change_settings) (wm, settings);
|
2002-08-08 07:13:38 +00:00
|
|
|
}
|
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
void
|
|
|
|
gnome_window_manager_get_settings (GnomeWindowManager *wm,
|
|
|
|
GnomeWMSettings *settings)
|
2002-08-08 07:13:38 +00:00
|
|
|
{
|
2002-10-29 06:19:52 +00:00
|
|
|
GnomeWindowManagerClass *klass = GNOME_WINDOW_MANAGER_GET_CLASS (wm);
|
|
|
|
int mask;
|
|
|
|
|
|
|
|
mask = (* klass->get_settings_mask) (wm);
|
|
|
|
settings->flags &= mask; /* avoid back compat issues by not returning
|
|
|
|
* fields to the caller that the WM module
|
|
|
|
* doesn't know about
|
|
|
|
*/
|
|
|
|
|
|
|
|
(* klass->get_settings) (wm, settings);
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
gnome_window_manager_init (GnomeWindowManager *gnome_window_manager, GnomeWindowManagerClass *class)
|
|
|
|
{
|
|
|
|
gnome_window_manager->p = g_new0 (GnomeWindowManagerPrivate, 1);
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
gnome_window_manager_finalize (GObject *object)
|
|
|
|
{
|
|
|
|
GnomeWindowManager *gnome_window_manager;
|
|
|
|
|
|
|
|
g_return_if_fail (object != NULL);
|
|
|
|
g_return_if_fail (IS_GNOME_WINDOW_MANAGER (object));
|
|
|
|
|
|
|
|
gnome_window_manager = GNOME_WINDOW_MANAGER (object);
|
|
|
|
|
|
|
|
g_free (gnome_window_manager->p);
|
|
|
|
|
|
|
|
parent_class->finalize (object);
|
|
|
|
}
|
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
enum {
|
|
|
|
SETTINGS_CHANGED,
|
|
|
|
LAST_SIGNAL
|
|
|
|
};
|
|
|
|
|
|
|
|
static guint signals[LAST_SIGNAL] = { 0 };
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
|
|
|
|
static void
|
|
|
|
gnome_window_manager_class_init (GnomeWindowManagerClass *class)
|
|
|
|
{
|
|
|
|
GObjectClass *object_class;
|
|
|
|
GnomeWindowManagerClass *wm_class;
|
|
|
|
|
|
|
|
object_class = G_OBJECT_CLASS (class);
|
|
|
|
wm_class = GNOME_WINDOW_MANAGER_CLASS (class);
|
|
|
|
|
|
|
|
object_class->finalize = gnome_window_manager_finalize;
|
2002-10-29 06:19:52 +00:00
|
|
|
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
parent_class = g_type_class_peek_parent (class);
|
2002-10-29 06:19:52 +00:00
|
|
|
|
|
|
|
|
|
|
|
signals[SETTINGS_CHANGED] =
|
|
|
|
g_signal_new ("settings_changed",
|
|
|
|
G_OBJECT_CLASS_TYPE (class),
|
|
|
|
G_SIGNAL_RUN_FIRST | G_SIGNAL_NO_RECURSE,
|
|
|
|
G_STRUCT_OFFSET (GnomeWindowManagerClass, settings_changed),
|
|
|
|
NULL, NULL,
|
|
|
|
g_cclosure_marshal_VOID__VOID,
|
|
|
|
G_TYPE_NONE, 0);
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
}
|
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
GType
|
|
|
|
gnome_window_manager_get_type (void)
|
|
|
|
{
|
|
|
|
static GType gnome_window_manager_type = 0;
|
|
|
|
|
|
|
|
if (!gnome_window_manager_type) {
|
|
|
|
static GTypeInfo gnome_window_manager_info = {
|
|
|
|
sizeof (GnomeWindowManagerClass),
|
|
|
|
NULL, /* GBaseInitFunc */
|
|
|
|
NULL, /* GBaseFinalizeFunc */
|
|
|
|
(GClassInitFunc) gnome_window_manager_class_init,
|
|
|
|
NULL, /* GClassFinalizeFunc */
|
|
|
|
NULL, /* user-supplied data */
|
|
|
|
sizeof (GnomeWindowManager),
|
|
|
|
0, /* n_preallocs */
|
|
|
|
(GInstanceInitFunc) gnome_window_manager_init,
|
|
|
|
NULL
|
|
|
|
};
|
|
|
|
|
|
|
|
gnome_window_manager_type =
|
|
|
|
g_type_register_static (G_TYPE_OBJECT,
|
2002-10-29 06:19:52 +00:00
|
|
|
"GnomeWindowManager",
|
|
|
|
&gnome_window_manager_info, 0);
|
Update to deal with the .pc file that gets generated.
2002-06-02 Seth Nickell <snickell@stanford.edu>
* .cvsignore:
Update to deal with the .pc file that gets generated.
* Makefile.am:
Build a real library, not just a non-installed. This is to get around
problems dealing with GObject inheritance and static memory problems. We
have a run time loaded object deriving from the library, so it has to link it in. But then
the problem that occurs is that both the run-time loaded library and the
program that calls it statically link the .la in. Then they have different
memory spaces, and type registration goes to pot. Open to suggestions if there's
a way of doing this without making an installed library.
* gnome-window-manager.c: (gnome_window_manager_new),
(gnome_window_manager_get_name), (gnome_window_manager_set_theme),
(gnome_window_manager_get_theme_list),
(gnome_window_manager_set_font),
(gnome_window_manager_get_focus_follows_mouse),
(gnome_window_manager_set_focus_follows_mouse),
(gnome_window_manager_init), (gnome_window_manager_finalize),
(gnome_window_manager_class_init), (gnome_window_manager_get_type):
* gnome-window-manager.h:
Lots of formatting fixes, change some of the boilerplate.
* gnome-window-settings-2.0.pc.in:
Since we're installing a library, go the whole way. Its good to make this
easy to depend on for external window managers anyway, now that I think
of it.
* gnome-wm-manager.c: (gnome_wm_manager_init),
(gnome_wm_manager_get_list), (gnome_wm_manager_set_current),
(gnome_wm_manager_get_current),
(gnome_wm_manager_change_wm_to_settings), (restart_label_update),
(restart_dialog_raise), (restart_dialog_destroyed),
(show_restart_dialog), (hide_restart_dialog), (init_session),
(update_session), (init_callback), (restart_finalize),
(restart_failure), (show_restart_info), (restart_finish),
(restart_callback), (restart), (revert_callback),
(cancel_callback):
* gnome-wm-manager.h:
Add code for doing the window manager switch to the library,
snitched out of wm-properties. Its probably a little broken right now.
* wm-exec.c: (wm_is_running), (find_gnome_wm_window),
(find_wm_window_from_client), (window_has_wm_state),
(descendent_has_wm_state), (find_wm_window_from_hunt),
(find_wm_window), (start_timeout), (start_do), (kill_timeout),
(wm_restart), (wm_guess_current):
* wm-list.c: (is_blank), (wm_compare), (wm_free),
(wm_check_present), (wm_copy), (wm_list_find), (wm_list_find_exec),
(wm_list_find_files), (wm_list_read_dir), (wm_list_init),
(wm_list_save), (wm_list_revert), (wm_list_add), (wm_list_delete),
(wm_list_set_current), (wm_list_get_current), (wm_list_get_revert),
(wm_read_from_xml), (wm_list_read_from_xml), (wm_write_to_xml),
(wm_list_write_to_xml), (xml_read_bool), (xml_write_bool):
* wm-properties.h:
Take wm-switching code out of the capplet, move it here.
(Jacob, I did a make dist and build the resulting tarball, hope things
don't break for you this time ... )
2002-06-03 00:33:59 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
return gnome_window_manager_type;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2002-10-29 06:19:52 +00:00
|
|
|
void
|
|
|
|
gnome_window_manager_settings_changed (GnomeWindowManager *wm)
|
|
|
|
{
|
|
|
|
g_signal_emit (wm, signals[SETTINGS_CHANGED], 0);
|
|
|
|
}
|