Comprehensively rename to Mutter
Code: All references in the code not related to themes, keybindings, or GConf were changed from 'metacity' to 'mutter'. This includes, among other things, strings, comments, the atoms used in the message protocol, and the envvars used for debugging. The GConf schema file was reduced to the 3 settings new to mutter. The overall version was brought up to 2.27 to match current gnome. Structure: All files named '*metacity*' were renamed '*mutter*' with appropriate changes in the automake system. Files removed are doc/creating_themes, src/themes, doc/metacity-theme.dtd, metacity.doap. These files will eventually end up in an external gnome-wm-data module. Installation location: On the filesystem the mutter-plugindir was change from $(libdir)/metacity/plugins/clutter to just $(libdir)/mutter/plugins. The mutter-plugins.pc.in reflects these changes. Note: mutter.desktop.in and mutter-wm.desktop both continue to have X-GNOME-WMSettingsModule=metacity set. This allows gnome-control-center to continue using libmetacity.so for configuration. This is fine since most the general keybindings and wm settings are being read from /apps/metacity/* in gconf.
This commit is contained in:

committed by
Owen W. Taylor

parent
9127993d84
commit
51a6467968
@@ -1,6 +1,6 @@
|
||||
/* -*- mode: C; c-file-style: "gnu"; indent-tabs-mode: nil; -*- */
|
||||
|
||||
/* Metacity Session Management */
|
||||
/* Mutter Session Management */
|
||||
|
||||
/*
|
||||
* Copyright (C) 2001 Havoc Pennington (some code in here from
|
||||
@@ -309,8 +309,8 @@ meta_session_init (const char *previous_client_id,
|
||||
prop1.type = SmARRAY8;
|
||||
prop1.num_vals = 1;
|
||||
prop1.vals = &prop1val;
|
||||
prop1val.value = "metacity";
|
||||
prop1val.length = strlen ("metacity");
|
||||
prop1val.value = "mutter";
|
||||
prop1val.length = strlen ("mutter");
|
||||
|
||||
/* twm sets getuid() for this, but the SM spec plainly
|
||||
* says pw_name, twm is on crack
|
||||
@@ -596,7 +596,7 @@ set_clone_restart_commands (void)
|
||||
g_return_if_fail (client_id);
|
||||
|
||||
i = 0;
|
||||
restartv[i] = "metacity";
|
||||
restartv[i] = "mutter";
|
||||
++i;
|
||||
restartv[i] = "--sm-client-id";
|
||||
++i;
|
||||
@@ -617,7 +617,7 @@ set_clone_restart_commands (void)
|
||||
/* Clone (no client ID) */
|
||||
|
||||
i = 0;
|
||||
clonev[i] = "metacity";
|
||||
clonev[i] = "mutter";
|
||||
++i;
|
||||
clonev[i] = NULL;
|
||||
|
||||
@@ -818,7 +818,7 @@ decode_text_from_utf8 (const char *text)
|
||||
static void
|
||||
save_state (void)
|
||||
{
|
||||
char *metacity_dir;
|
||||
char *mutter_dir;
|
||||
char *session_dir;
|
||||
FILE *outfile;
|
||||
GSList *windows;
|
||||
@@ -837,19 +837,19 @@ save_state (void)
|
||||
* we probably already have full_save_path figured out and therefore
|
||||
* can just use the directory name from that.
|
||||
*/
|
||||
metacity_dir = g_strconcat (g_get_user_config_dir (),
|
||||
G_DIR_SEPARATOR_S "metacity",
|
||||
mutter_dir = g_strconcat (g_get_user_config_dir (),
|
||||
G_DIR_SEPARATOR_S "mutter",
|
||||
NULL);
|
||||
|
||||
session_dir = g_strconcat (metacity_dir,
|
||||
session_dir = g_strconcat (mutter_dir,
|
||||
G_DIR_SEPARATOR_S "sessions",
|
||||
NULL);
|
||||
|
||||
if (mkdir (metacity_dir, 0700) < 0 &&
|
||||
if (mkdir (mutter_dir, 0700) < 0 &&
|
||||
errno != EEXIST)
|
||||
{
|
||||
meta_warning (_("Could not create directory '%s': %s\n"),
|
||||
metacity_dir, g_strerror (errno));
|
||||
mutter_dir, g_strerror (errno));
|
||||
}
|
||||
|
||||
if (mkdir (session_dir, 0700) < 0 &&
|
||||
@@ -871,14 +871,14 @@ save_state (void)
|
||||
}
|
||||
|
||||
/* The file format is:
|
||||
* <metacity_session id="foo">
|
||||
* <mutter_session id="foo">
|
||||
* <window id="bar" class="XTerm" name="xterm" title="/foo/bar" role="blah" type="normal" stacking="5">
|
||||
* <workspace index="2"/>
|
||||
* <workspace index="4"/>
|
||||
* <sticky/> <minimized/> <maximized/>
|
||||
* <geometry x="100" y="100" width="200" height="200" gravity="northwest"/>
|
||||
* </window>
|
||||
* </metacity_session>
|
||||
* </mutter_session>
|
||||
*
|
||||
* Note that attributes on <window> are the match info we use to
|
||||
* see if the saved state applies to a restored window, and
|
||||
@@ -886,7 +886,7 @@ save_state (void)
|
||||
*
|
||||
*/
|
||||
|
||||
fprintf (outfile, "<metacity_session id=\"%s\">\n",
|
||||
fprintf (outfile, "<mutter_session id=\"%s\">\n",
|
||||
client_id);
|
||||
|
||||
windows = meta_display_list_windows (meta_get_display ());
|
||||
@@ -998,7 +998,7 @@ save_state (void)
|
||||
|
||||
g_slist_free (windows);
|
||||
|
||||
fputs ("</metacity_session>\n", outfile);
|
||||
fputs ("</mutter_session>\n", outfile);
|
||||
|
||||
out:
|
||||
if (outfile)
|
||||
@@ -1016,7 +1016,7 @@ save_state (void)
|
||||
}
|
||||
}
|
||||
|
||||
g_free (metacity_dir);
|
||||
g_free (mutter_dir);
|
||||
g_free (session_dir);
|
||||
}
|
||||
|
||||
@@ -1055,7 +1055,7 @@ static void text_handler (GMarkupParseContext *context,
|
||||
gpointer user_data,
|
||||
GError **error);
|
||||
|
||||
static GMarkupParser metacity_session_parser = {
|
||||
static GMarkupParser mutter_session_parser = {
|
||||
start_element_handler,
|
||||
end_element_handler,
|
||||
text_handler,
|
||||
@@ -1076,7 +1076,7 @@ load_state (const char *previous_save_file)
|
||||
char *session_file;
|
||||
|
||||
session_file = g_strconcat (g_get_user_config_dir (),
|
||||
G_DIR_SEPARATOR_S "metacity"
|
||||
G_DIR_SEPARATOR_S "mutter"
|
||||
G_DIR_SEPARATOR_S "sessions" G_DIR_SEPARATOR_S,
|
||||
previous_save_file,
|
||||
NULL);
|
||||
@@ -1089,9 +1089,9 @@ load_state (const char *previous_save_file)
|
||||
{
|
||||
char *canonical_session_file = session_file;
|
||||
|
||||
/* Maybe they were doing it the old way, with ~/.metacity */
|
||||
/* Maybe they were doing it the old way, with ~/.mutter */
|
||||
session_file = g_strconcat (g_get_home_dir (),
|
||||
G_DIR_SEPARATOR_S ".metacity"
|
||||
G_DIR_SEPARATOR_S ".mutter"
|
||||
G_DIR_SEPARATOR_S "sessions"
|
||||
G_DIR_SEPARATOR_S,
|
||||
previous_save_file,
|
||||
@@ -1122,7 +1122,7 @@ load_state (const char *previous_save_file)
|
||||
parse_data.info = NULL;
|
||||
parse_data.previous_id = NULL;
|
||||
|
||||
context = g_markup_parse_context_new (&metacity_session_parser,
|
||||
context = g_markup_parse_context_new (&mutter_session_parser,
|
||||
0, &parse_data, NULL);
|
||||
|
||||
error = NULL;
|
||||
@@ -1173,7 +1173,7 @@ start_element_handler (GMarkupParseContext *context,
|
||||
|
||||
pd = user_data;
|
||||
|
||||
if (strcmp (element_name, "metacity_session") == 0)
|
||||
if (strcmp (element_name, "mutter_session") == 0)
|
||||
{
|
||||
/* Get previous ID */
|
||||
int i;
|
||||
@@ -1192,7 +1192,7 @@ start_element_handler (GMarkupParseContext *context,
|
||||
g_set_error (error,
|
||||
G_MARKUP_ERROR,
|
||||
G_MARKUP_ERROR_PARSE,
|
||||
_("<metacity_session> attribute seen but we already have the session ID"));
|
||||
_("<mutter_session> attribute seen but we already have the session ID"));
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1206,7 +1206,7 @@ start_element_handler (GMarkupParseContext *context,
|
||||
G_MARKUP_ERROR,
|
||||
G_MARKUP_ERROR_UNKNOWN_ATTRIBUTE,
|
||||
_("Unknown attribute %s on <%s> element"),
|
||||
name, "metacity_session");
|
||||
name, "mutter_session");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1530,7 +1530,7 @@ get_possible_matches (MetaWindow *window)
|
||||
|
||||
retval = NULL;
|
||||
|
||||
ignore_client_id = g_getenv ("METACITY_DEBUG_SM") != NULL;
|
||||
ignore_client_id = g_getenv ("MUTTER_DEBUG_SM") != NULL;
|
||||
|
||||
tmp = window_info_list;
|
||||
while (tmp != NULL)
|
||||
@@ -1715,7 +1715,7 @@ regenerate_save_file (void)
|
||||
|
||||
if (client_id)
|
||||
full_save_path = g_strconcat (g_get_user_config_dir (),
|
||||
G_DIR_SEPARATOR_S "metacity"
|
||||
G_DIR_SEPARATOR_S "mutter"
|
||||
G_DIR_SEPARATOR_S "sessions" G_DIR_SEPARATOR_S,
|
||||
client_id,
|
||||
".ms",
|
||||
|
Reference in New Issue
Block a user