Adapt to removal of Mutter namespace
MutterWindow and MutterPlugin have been renamed to MetaWindowActor and MetaPlugin, mutter_plugin_list_windows() to meta_plugin_list_window_actors(). Adapt to those changes. https://bugzilla.gnome.org/show_bug.cgi?id=632500
This commit is contained in:
parent
6b47b78d4d
commit
2fa6f7ba7e
@ -233,7 +233,7 @@ Chrome.prototype = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
_windowsRestacked: function() {
|
_windowsRestacked: function() {
|
||||||
let windows = global.get_windows();
|
let windows = global.get_window_actors();
|
||||||
let primary = global.get_primary_monitor();
|
let primary = global.get_primary_monitor();
|
||||||
|
|
||||||
// The chrome layer should be visible unless there is a window
|
// The chrome layer should be visible unless there is a window
|
||||||
|
@ -220,7 +220,7 @@ WindowList.prototype = {
|
|||||||
|
|
||||||
_updateWindowList: function() {
|
_updateWindowList: function() {
|
||||||
this.actor.get_children().forEach(function (actor) { actor.destroy(); });
|
this.actor.get_children().forEach(function (actor) { actor.destroy(); });
|
||||||
let windows = global.get_windows();
|
let windows = global.get_window_actors();
|
||||||
let tracker = Shell.WindowTracker.get_default();
|
let tracker = Shell.WindowTracker.get_default();
|
||||||
for (let i = 0; i < windows.length; i++) {
|
for (let i = 0; i < windows.length; i++) {
|
||||||
let metaWindow = windows[i].metaWindow;
|
let metaWindow = windows[i].metaWindow;
|
||||||
|
@ -253,11 +253,11 @@ function _relayout() {
|
|||||||
// metacity-clutter currently uses the same prefs as plain metacity,
|
// metacity-clutter currently uses the same prefs as plain metacity,
|
||||||
// which probably means we'll be starting out with multiple workspaces;
|
// which probably means we'll be starting out with multiple workspaces;
|
||||||
// remove any unused ones. (We do this from an idle handler, because
|
// remove any unused ones. (We do this from an idle handler, because
|
||||||
// global.get_windows() still returns NULL at the point when start()
|
// global.get_window_actors() still returns NULL at the point when start()
|
||||||
// is called.)
|
// is called.)
|
||||||
function _removeUnusedWorkspaces() {
|
function _removeUnusedWorkspaces() {
|
||||||
|
|
||||||
let windows = global.get_windows();
|
let windows = global.get_window_actors();
|
||||||
let maxWorkspace = 0;
|
let maxWorkspace = 0;
|
||||||
for (let i = 0; i < windows.length; i++) {
|
for (let i = 0; i < windows.length; i++) {
|
||||||
let win = windows[i];
|
let win = windows[i];
|
||||||
|
@ -415,7 +415,7 @@ WindowManager.prototype = {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
let windows = global.get_windows();
|
let windows = global.get_window_actors();
|
||||||
|
|
||||||
/* @direction is the direction that the "camera" moves, so the
|
/* @direction is the direction that the "camera" moves, so the
|
||||||
* screen contents have to move one screen's worth in the
|
* screen contents have to move one screen's worth in the
|
||||||
|
@ -602,7 +602,7 @@ Workspace.prototype = {
|
|||||||
this.actor.height = global.screen_height;
|
this.actor.height = global.screen_height;
|
||||||
this.scale = 1.0;
|
this.scale = 1.0;
|
||||||
|
|
||||||
let windows = global.get_windows().filter(this._isMyWindow, this);
|
let windows = global.get_window_actors().filter(this._isMyWindow, this);
|
||||||
|
|
||||||
// Find the desktop window
|
// Find the desktop window
|
||||||
for (let i = 0; i < windows.length; i++) {
|
for (let i = 0; i < windows.length; i++) {
|
||||||
|
@ -190,7 +190,7 @@ GenericWorkspacesView.prototype = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
_onRestacked: function() {
|
_onRestacked: function() {
|
||||||
let stack = global.get_windows();
|
let stack = global.get_window_actors();
|
||||||
let stackIndices = {};
|
let stackIndices = {};
|
||||||
|
|
||||||
for (let i = 0; i < stack.length; i++) {
|
for (let i = 0; i < stack.length; i++) {
|
||||||
|
@ -25,8 +25,7 @@
|
|||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#define MUTTER_BUILDING_PLUGIN 1
|
#include <meta-plugin.h>
|
||||||
#include <mutter-plugin.h>
|
|
||||||
|
|
||||||
#include <glib/gi18n-lib.h>
|
#include <glib/gi18n-lib.h>
|
||||||
|
|
||||||
@ -57,38 +56,40 @@
|
|||||||
static void gnome_shell_plugin_dispose (GObject *object);
|
static void gnome_shell_plugin_dispose (GObject *object);
|
||||||
static void gnome_shell_plugin_finalize (GObject *object);
|
static void gnome_shell_plugin_finalize (GObject *object);
|
||||||
|
|
||||||
static void gnome_shell_plugin_start (MutterPlugin *plugin);
|
static void gnome_shell_plugin_start (MetaPlugin *plugin);
|
||||||
static void gnome_shell_plugin_minimize (MutterPlugin *plugin,
|
static void gnome_shell_plugin_minimize (MetaPlugin *plugin,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
static void gnome_shell_plugin_maximize (MutterPlugin *plugin,
|
static void gnome_shell_plugin_maximize (MetaPlugin *plugin,
|
||||||
MutterWindow *actor,
|
MetaWindowActor *actor,
|
||||||
gint x,
|
gint x,
|
||||||
gint y,
|
gint y,
|
||||||
gint width,
|
gint width,
|
||||||
gint height);
|
gint height);
|
||||||
static void gnome_shell_plugin_unmaximize (MutterPlugin *plugin,
|
static void gnome_shell_plugin_unmaximize (MetaPlugin *plugin,
|
||||||
MutterWindow *actor,
|
MetaWindowActor *actor,
|
||||||
gint x,
|
gint x,
|
||||||
gint y,
|
gint y,
|
||||||
gint width,
|
gint width,
|
||||||
gint height);
|
gint height);
|
||||||
static void gnome_shell_plugin_map (MutterPlugin *plugin,
|
static void gnome_shell_plugin_map (MetaPlugin *plugin,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
static void gnome_shell_plugin_destroy (MutterPlugin *plugin,
|
static void gnome_shell_plugin_destroy (MetaPlugin *plugin,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
|
|
||||||
static void gnome_shell_plugin_switch_workspace (MutterPlugin *plugin,
|
static void gnome_shell_plugin_switch_workspace (MetaPlugin *plugin,
|
||||||
gint from,
|
gint from,
|
||||||
gint to,
|
gint to,
|
||||||
MetaMotionDirection direction);
|
MetaMotionDirection direction);
|
||||||
|
|
||||||
static void gnome_shell_plugin_kill_window_effects (MutterPlugin *plugin,
|
static void gnome_shell_plugin_kill_window_effects (MetaPlugin *plugin,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
static void gnome_shell_plugin_kill_switch_workspace (MutterPlugin *plugin);
|
static void gnome_shell_plugin_kill_switch_workspace (MetaPlugin *plugin);
|
||||||
|
|
||||||
|
|
||||||
|
static gboolean gnome_shell_plugin_xevent_filter (MetaPlugin *plugin,
|
||||||
|
XEvent *event);
|
||||||
|
static const MetaPluginInfo *gnome_shell_plugin_plugin_info (MetaPlugin *plugin);
|
||||||
|
|
||||||
static gboolean gnome_shell_plugin_xevent_filter (MutterPlugin *plugin,
|
|
||||||
XEvent *event);
|
|
||||||
static const MutterPluginInfo *gnome_shell_plugin_plugin_info (MutterPlugin *plugin);
|
|
||||||
|
|
||||||
#define GNOME_TYPE_SHELL_PLUGIN (gnome_shell_plugin_get_type ())
|
#define GNOME_TYPE_SHELL_PLUGIN (gnome_shell_plugin_get_type ())
|
||||||
#define GNOME_SHELL_PLUGIN(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GNOME_TYPE_SHELL_PLUGIN, GnomeShellPlugin))
|
#define GNOME_SHELL_PLUGIN(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GNOME_TYPE_SHELL_PLUGIN, GnomeShellPlugin))
|
||||||
@ -102,7 +103,7 @@ typedef struct _GnomeShellPluginClass GnomeShellPluginClass;
|
|||||||
|
|
||||||
struct _GnomeShellPlugin
|
struct _GnomeShellPlugin
|
||||||
{
|
{
|
||||||
MutterPlugin parent;
|
MetaPlugin parent;
|
||||||
|
|
||||||
GjsContext *gjs_context;
|
GjsContext *gjs_context;
|
||||||
Atom panel_action;
|
Atom panel_action;
|
||||||
@ -116,20 +117,20 @@ struct _GnomeShellPlugin
|
|||||||
|
|
||||||
struct _GnomeShellPluginClass
|
struct _GnomeShellPluginClass
|
||||||
{
|
{
|
||||||
MutterPluginClass parent_class;
|
MetaPluginClass parent_class;
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Create the plugin struct; function pointers initialized in
|
* Create the plugin struct; function pointers initialized in
|
||||||
* g_module_check_init().
|
* g_module_check_init().
|
||||||
*/
|
*/
|
||||||
MUTTER_PLUGIN_DECLARE(GnomeShellPlugin, gnome_shell_plugin);
|
META_PLUGIN_DECLARE(GnomeShellPlugin, gnome_shell_plugin);
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_class_init (GnomeShellPluginClass *klass)
|
gnome_shell_plugin_class_init (GnomeShellPluginClass *klass)
|
||||||
{
|
{
|
||||||
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
|
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
|
||||||
MutterPluginClass *plugin_class = MUTTER_PLUGIN_CLASS (klass);
|
MetaPluginClass *plugin_class = META_PLUGIN_CLASS (klass);
|
||||||
|
|
||||||
gobject_class->dispose = gnome_shell_plugin_dispose;
|
gobject_class->dispose = gnome_shell_plugin_dispose;
|
||||||
gobject_class->finalize = gnome_shell_plugin_finalize;
|
gobject_class->finalize = gnome_shell_plugin_finalize;
|
||||||
@ -306,7 +307,7 @@ gvc_muted_debug_log_handler (const char *log_domain,
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_start (MutterPlugin *plugin)
|
gnome_shell_plugin_start (MetaPlugin *plugin)
|
||||||
{
|
{
|
||||||
GnomeShellPlugin *shell_plugin = GNOME_SHELL_PLUGIN (plugin);
|
GnomeShellPlugin *shell_plugin = GNOME_SHELL_PLUGIN (plugin);
|
||||||
MetaScreen *screen;
|
MetaScreen *screen;
|
||||||
@ -336,7 +337,7 @@ gnome_shell_plugin_start (MutterPlugin *plugin)
|
|||||||
NULL);
|
NULL);
|
||||||
update_font_options (settings);
|
update_font_options (settings);
|
||||||
|
|
||||||
screen = mutter_plugin_get_screen (plugin);
|
screen = meta_plugin_get_screen (plugin);
|
||||||
display = meta_screen_get_display (screen);
|
display = meta_screen_get_display (screen);
|
||||||
|
|
||||||
xdisplay = meta_display_get_xdisplay (display);
|
xdisplay = meta_display_get_xdisplay (display);
|
||||||
@ -371,7 +372,7 @@ gnome_shell_plugin_start (MutterPlugin *plugin)
|
|||||||
/* Initialize the global object here. */
|
/* Initialize the global object here. */
|
||||||
global = shell_global_get ();
|
global = shell_global_get ();
|
||||||
|
|
||||||
_shell_global_set_plugin (global, MUTTER_PLUGIN(shell_plugin));
|
_shell_global_set_plugin (global, META_PLUGIN(shell_plugin));
|
||||||
_shell_global_set_gjs_context (global, shell_plugin->gjs_context);
|
_shell_global_set_gjs_context (global, shell_plugin->gjs_context);
|
||||||
|
|
||||||
add_statistics (shell_plugin);
|
add_statistics (shell_plugin);
|
||||||
@ -427,8 +428,8 @@ get_shell_wm (void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_minimize (MutterPlugin *plugin,
|
gnome_shell_plugin_minimize (MetaPlugin *plugin,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
_shell_wm_minimize (get_shell_wm (),
|
_shell_wm_minimize (get_shell_wm (),
|
||||||
actor);
|
actor);
|
||||||
@ -436,70 +437,70 @@ gnome_shell_plugin_minimize (MutterPlugin *plugin,
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_maximize (MutterPlugin *plugin,
|
gnome_shell_plugin_maximize (MetaPlugin *plugin,
|
||||||
MutterWindow *actor,
|
MetaWindowActor *actor,
|
||||||
gint x,
|
gint x,
|
||||||
gint y,
|
gint y,
|
||||||
gint width,
|
gint width,
|
||||||
gint height)
|
gint height)
|
||||||
{
|
{
|
||||||
_shell_wm_maximize (get_shell_wm (),
|
_shell_wm_maximize (get_shell_wm (),
|
||||||
actor, x, y, width, height);
|
actor, x, y, width, height);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_unmaximize (MutterPlugin *plugin,
|
gnome_shell_plugin_unmaximize (MetaPlugin *plugin,
|
||||||
MutterWindow *actor,
|
MetaWindowActor *actor,
|
||||||
gint x,
|
gint x,
|
||||||
gint y,
|
gint y,
|
||||||
gint width,
|
gint width,
|
||||||
gint height)
|
gint height)
|
||||||
{
|
{
|
||||||
_shell_wm_unmaximize (get_shell_wm (),
|
_shell_wm_unmaximize (get_shell_wm (),
|
||||||
actor, x, y, width, height);
|
actor, x, y, width, height);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_map (MutterPlugin *plugin,
|
gnome_shell_plugin_map (MetaPlugin *plugin,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
_shell_wm_map (get_shell_wm (),
|
_shell_wm_map (get_shell_wm (),
|
||||||
actor);
|
actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_destroy (MutterPlugin *plugin,
|
gnome_shell_plugin_destroy (MetaPlugin *plugin,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
_shell_wm_destroy (get_shell_wm (),
|
_shell_wm_destroy (get_shell_wm (),
|
||||||
actor);
|
actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_switch_workspace (MutterPlugin *plugin,
|
gnome_shell_plugin_switch_workspace (MetaPlugin *plugin,
|
||||||
gint from,
|
gint from,
|
||||||
gint to,
|
gint to,
|
||||||
MetaMotionDirection direction)
|
MetaMotionDirection direction)
|
||||||
{
|
{
|
||||||
_shell_wm_switch_workspace (get_shell_wm(), from, to, direction);
|
_shell_wm_switch_workspace (get_shell_wm(), from, to, direction);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_kill_window_effects (MutterPlugin *plugin,
|
gnome_shell_plugin_kill_window_effects (MetaPlugin *plugin,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
_shell_wm_kill_window_effects (get_shell_wm(), actor);
|
_shell_wm_kill_window_effects (get_shell_wm(), actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnome_shell_plugin_kill_switch_workspace (MutterPlugin *plugin)
|
gnome_shell_plugin_kill_switch_workspace (MetaPlugin *plugin)
|
||||||
{
|
{
|
||||||
_shell_wm_kill_switch_workspace (get_shell_wm());
|
_shell_wm_kill_switch_workspace (get_shell_wm());
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
gnome_shell_plugin_xevent_filter (MutterPlugin *plugin,
|
gnome_shell_plugin_xevent_filter (MetaPlugin *plugin,
|
||||||
XEvent *xev)
|
XEvent *xev)
|
||||||
{
|
{
|
||||||
#ifdef GLX_INTEL_swap_event
|
#ifdef GLX_INTEL_swap_event
|
||||||
GnomeShellPlugin *shell_plugin = GNOME_SHELL_PLUGIN (plugin);
|
GnomeShellPlugin *shell_plugin = GNOME_SHELL_PLUGIN (plugin);
|
||||||
@ -539,9 +540,9 @@ gnome_shell_plugin_xevent_filter (MutterPlugin *plugin,
|
|||||||
}
|
}
|
||||||
|
|
||||||
static const
|
static const
|
||||||
MutterPluginInfo *gnome_shell_plugin_plugin_info (MutterPlugin *plugin)
|
MetaPluginInfo *gnome_shell_plugin_plugin_info (MetaPlugin *plugin)
|
||||||
{
|
{
|
||||||
static const MutterPluginInfo info = {
|
static const MetaPluginInfo info = {
|
||||||
.name = "GNOME Shell",
|
.name = "GNOME Shell",
|
||||||
.version = "0.1",
|
.version = "0.1",
|
||||||
.author = "Various",
|
.author = "Various",
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
#include <gjs/gjs.h>
|
#include <gjs/gjs.h>
|
||||||
|
|
||||||
void _shell_global_set_plugin (ShellGlobal *global,
|
void _shell_global_set_plugin (ShellGlobal *global,
|
||||||
MutterPlugin *plugin);
|
MetaPlugin *plugin);
|
||||||
void _shell_global_set_gjs_context (ShellGlobal *global,
|
void _shell_global_set_gjs_context (ShellGlobal *global,
|
||||||
GjsContext *context);
|
GjsContext *context);
|
||||||
|
|
||||||
|
@ -52,7 +52,7 @@ struct _ShellGlobal {
|
|||||||
XserverRegion input_region;
|
XserverRegion input_region;
|
||||||
|
|
||||||
GjsContext *js_context;
|
GjsContext *js_context;
|
||||||
MutterPlugin *plugin;
|
MetaPlugin *plugin;
|
||||||
ShellWM *wm;
|
ShellWM *wm;
|
||||||
GSettings *settings;
|
GSettings *settings;
|
||||||
const char *datadir;
|
const char *datadir;
|
||||||
@ -124,7 +124,7 @@ shell_global_get_property(GObject *object,
|
|||||||
switch (prop_id)
|
switch (prop_id)
|
||||||
{
|
{
|
||||||
case PROP_OVERLAY_GROUP:
|
case PROP_OVERLAY_GROUP:
|
||||||
g_value_set_object (value, mutter_plugin_get_overlay_group (global->plugin));
|
g_value_set_object (value, meta_plugin_get_overlay_group (global->plugin));
|
||||||
break;
|
break;
|
||||||
case PROP_SCREEN:
|
case PROP_SCREEN:
|
||||||
g_value_set_object (value, shell_global_get_screen (global));
|
g_value_set_object (value, shell_global_get_screen (global));
|
||||||
@ -136,7 +136,7 @@ shell_global_get_property(GObject *object,
|
|||||||
{
|
{
|
||||||
int width, height;
|
int width, height;
|
||||||
|
|
||||||
mutter_plugin_query_screen_size (global->plugin, &width, &height);
|
meta_plugin_query_screen_size (global->plugin, &width, &height);
|
||||||
g_value_set_int (value, width);
|
g_value_set_int (value, width);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -144,18 +144,18 @@ shell_global_get_property(GObject *object,
|
|||||||
{
|
{
|
||||||
int width, height;
|
int width, height;
|
||||||
|
|
||||||
mutter_plugin_query_screen_size (global->plugin, &width, &height);
|
meta_plugin_query_screen_size (global->plugin, &width, &height);
|
||||||
g_value_set_int (value, height);
|
g_value_set_int (value, height);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case PROP_STAGE:
|
case PROP_STAGE:
|
||||||
g_value_set_object (value, mutter_plugin_get_stage (global->plugin));
|
g_value_set_object (value, meta_plugin_get_stage (global->plugin));
|
||||||
break;
|
break;
|
||||||
case PROP_STAGE_INPUT_MODE:
|
case PROP_STAGE_INPUT_MODE:
|
||||||
g_value_set_enum (value, global->input_mode);
|
g_value_set_enum (value, global->input_mode);
|
||||||
break;
|
break;
|
||||||
case PROP_WINDOW_GROUP:
|
case PROP_WINDOW_GROUP:
|
||||||
g_value_set_object (value, mutter_plugin_get_window_group (global->plugin));
|
g_value_set_object (value, meta_plugin_get_window_group (global->plugin));
|
||||||
break;
|
break;
|
||||||
case PROP_WINDOW_MANAGER:
|
case PROP_WINDOW_MANAGER:
|
||||||
g_value_set_object (value, global->wm);
|
g_value_set_object (value, global->wm);
|
||||||
@ -391,9 +391,9 @@ shell_global_focus_stage (ShellGlobal *global)
|
|||||||
ClutterActor *stage;
|
ClutterActor *stage;
|
||||||
Window xstage;
|
Window xstage;
|
||||||
|
|
||||||
stage = mutter_plugin_get_stage (global->plugin);
|
stage = meta_plugin_get_stage (global->plugin);
|
||||||
xstage = clutter_x11_get_stage_window (CLUTTER_STAGE (stage));
|
xstage = clutter_x11_get_stage_window (CLUTTER_STAGE (stage));
|
||||||
xdpy = mutter_plugin_get_xdisplay (global->plugin);
|
xdpy = meta_plugin_get_xdisplay (global->plugin);
|
||||||
XSetInputFocus (xdpy, xstage, RevertToPointerRoot,
|
XSetInputFocus (xdpy, xstage, RevertToPointerRoot,
|
||||||
shell_global_get_current_time (global));
|
shell_global_get_current_time (global));
|
||||||
}
|
}
|
||||||
@ -430,11 +430,11 @@ shell_global_set_stage_input_mode (ShellGlobal *global,
|
|||||||
g_return_if_fail (SHELL_IS_GLOBAL (global));
|
g_return_if_fail (SHELL_IS_GLOBAL (global));
|
||||||
|
|
||||||
if (mode == SHELL_STAGE_INPUT_MODE_NONREACTIVE || global->gtk_grab_active)
|
if (mode == SHELL_STAGE_INPUT_MODE_NONREACTIVE || global->gtk_grab_active)
|
||||||
mutter_plugin_set_stage_reactive (global->plugin, FALSE);
|
meta_plugin_set_stage_reactive (global->plugin, FALSE);
|
||||||
else if (mode == SHELL_STAGE_INPUT_MODE_FULLSCREEN || !global->input_region)
|
else if (mode == SHELL_STAGE_INPUT_MODE_FULLSCREEN || !global->input_region)
|
||||||
mutter_plugin_set_stage_reactive (global->plugin, TRUE);
|
meta_plugin_set_stage_reactive (global->plugin, TRUE);
|
||||||
else
|
else
|
||||||
mutter_plugin_set_stage_input_region (global->plugin, global->input_region);
|
meta_plugin_set_stage_input_region (global->plugin, global->input_region);
|
||||||
|
|
||||||
if (mode == SHELL_STAGE_INPUT_MODE_FOCUSED)
|
if (mode == SHELL_STAGE_INPUT_MODE_FOCUSED)
|
||||||
shell_global_focus_stage (global);
|
shell_global_focus_stage (global);
|
||||||
@ -503,7 +503,7 @@ shell_global_set_cursor (ShellGlobal *global,
|
|||||||
}
|
}
|
||||||
if (!global->stage_window)
|
if (!global->stage_window)
|
||||||
{
|
{
|
||||||
ClutterStage *stage = CLUTTER_STAGE (mutter_plugin_get_stage (global->plugin));
|
ClutterStage *stage = CLUTTER_STAGE (meta_plugin_get_stage (global->plugin));
|
||||||
|
|
||||||
global->stage_window = gdk_window_foreign_new (clutter_x11_get_stage_window (stage));
|
global->stage_window = gdk_window_foreign_new (clutter_x11_get_stage_window (stage));
|
||||||
}
|
}
|
||||||
@ -542,7 +542,7 @@ void
|
|||||||
shell_global_set_stage_input_region (ShellGlobal *global,
|
shell_global_set_stage_input_region (ShellGlobal *global,
|
||||||
GSList *rectangles)
|
GSList *rectangles)
|
||||||
{
|
{
|
||||||
MetaScreen *screen = mutter_plugin_get_screen (global->plugin);
|
MetaScreen *screen = meta_plugin_get_screen (global->plugin);
|
||||||
MetaDisplay *display = meta_screen_get_display (screen);
|
MetaDisplay *display = meta_screen_get_display (screen);
|
||||||
Display *xdpy = meta_display_get_xdisplay (display);
|
Display *xdpy = meta_display_get_xdisplay (display);
|
||||||
MetaRectangle *rect;
|
MetaRectangle *rect;
|
||||||
@ -583,7 +583,7 @@ shell_global_set_stage_input_region (ShellGlobal *global,
|
|||||||
MetaScreen *
|
MetaScreen *
|
||||||
shell_global_get_screen (ShellGlobal *global)
|
shell_global_get_screen (ShellGlobal *global)
|
||||||
{
|
{
|
||||||
return mutter_plugin_get_screen (global->plugin);
|
return meta_plugin_get_screen (global->plugin);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -600,18 +600,18 @@ shell_global_get_gdk_screen (ShellGlobal *global)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_global_get_windows:
|
* shell_global_get_window_actors:
|
||||||
*
|
*
|
||||||
* Gets the list of MutterWindows for the plugin's screen
|
* Gets the list of #MetaWindowActor for the plugin's screen
|
||||||
*
|
*
|
||||||
* Return value: (element-type Meta.MutterWindow) (transfer none): the list of windows
|
* Return value: (element-type Meta.WindowActor) (transfer none): the list of windows
|
||||||
*/
|
*/
|
||||||
GList *
|
GList *
|
||||||
shell_global_get_windows (ShellGlobal *global)
|
shell_global_get_window_actors (ShellGlobal *global)
|
||||||
{
|
{
|
||||||
g_return_val_if_fail (SHELL_IS_GLOBAL (global), NULL);
|
g_return_val_if_fail (SHELL_IS_GLOBAL (global), NULL);
|
||||||
|
|
||||||
return mutter_plugin_get_windows (global->plugin);
|
return meta_plugin_get_window_actors (global->plugin);
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
@ -620,7 +620,7 @@ update_screen_size (gpointer data)
|
|||||||
int width, height;
|
int width, height;
|
||||||
ShellGlobal *global = SHELL_GLOBAL (data);
|
ShellGlobal *global = SHELL_GLOBAL (data);
|
||||||
|
|
||||||
mutter_plugin_query_screen_size (global->plugin, &width, &height);
|
meta_plugin_query_screen_size (global->plugin, &width, &height);
|
||||||
|
|
||||||
if (global->last_change_screen_width == width && global->last_change_screen_height == height)
|
if (global->last_change_screen_width == width && global->last_change_screen_height == height)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
@ -683,8 +683,8 @@ global_stage_after_paint (ClutterStage *stage,
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_shell_global_set_plugin (ShellGlobal *global,
|
_shell_global_set_plugin (ShellGlobal *global,
|
||||||
MutterPlugin *plugin)
|
MetaPlugin *plugin)
|
||||||
{
|
{
|
||||||
ClutterActor *stage;
|
ClutterActor *stage;
|
||||||
MetaScreen *screen;
|
MetaScreen *screen;
|
||||||
@ -696,7 +696,7 @@ _shell_global_set_plugin (ShellGlobal *global,
|
|||||||
global->plugin = plugin;
|
global->plugin = plugin;
|
||||||
global->wm = shell_wm_new (plugin);
|
global->wm = shell_wm_new (plugin);
|
||||||
|
|
||||||
stage = mutter_plugin_get_stage (plugin);
|
stage = meta_plugin_get_stage (plugin);
|
||||||
|
|
||||||
g_signal_connect (stage, "notify::width",
|
g_signal_connect (stage, "notify::width",
|
||||||
G_CALLBACK (global_stage_notify_width), global);
|
G_CALLBACK (global_stage_notify_width), global);
|
||||||
@ -718,7 +718,7 @@ _shell_global_set_plugin (ShellGlobal *global,
|
|||||||
"End of stage page repaint",
|
"End of stage page repaint",
|
||||||
"");
|
"");
|
||||||
|
|
||||||
screen = mutter_plugin_get_screen (global->plugin);
|
screen = meta_plugin_get_screen (global->plugin);
|
||||||
display = meta_screen_get_display (screen);
|
display = meta_screen_get_display (screen);
|
||||||
g_signal_connect (display, "notify::focus-window",
|
g_signal_connect (display, "notify::focus-window",
|
||||||
G_CALLBACK (focus_window_changed), global);
|
G_CALLBACK (focus_window_changed), global);
|
||||||
@ -751,10 +751,10 @@ gboolean
|
|||||||
shell_global_begin_modal (ShellGlobal *global,
|
shell_global_begin_modal (ShellGlobal *global,
|
||||||
guint32 timestamp)
|
guint32 timestamp)
|
||||||
{
|
{
|
||||||
ClutterStage *stage = CLUTTER_STAGE (mutter_plugin_get_stage (global->plugin));
|
ClutterStage *stage = CLUTTER_STAGE (meta_plugin_get_stage (global->plugin));
|
||||||
Window stagewin = clutter_x11_get_stage_window (stage);
|
Window stagewin = clutter_x11_get_stage_window (stage);
|
||||||
|
|
||||||
return mutter_plugin_begin_modal (global->plugin, stagewin, None, 0, timestamp);
|
return meta_plugin_begin_modal (global->plugin, stagewin, None, 0, timestamp);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -767,7 +767,7 @@ void
|
|||||||
shell_global_end_modal (ShellGlobal *global,
|
shell_global_end_modal (ShellGlobal *global,
|
||||||
guint32 timestamp)
|
guint32 timestamp)
|
||||||
{
|
{
|
||||||
mutter_plugin_end_modal (global->plugin, timestamp);
|
meta_plugin_end_modal (global->plugin, timestamp);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -788,7 +788,7 @@ shell_global_end_modal (ShellGlobal *global,
|
|||||||
gboolean
|
gboolean
|
||||||
shell_global_display_is_grabbed (ShellGlobal *global)
|
shell_global_display_is_grabbed (ShellGlobal *global)
|
||||||
{
|
{
|
||||||
MetaScreen *screen = mutter_plugin_get_screen (global->plugin);
|
MetaScreen *screen = meta_plugin_get_screen (global->plugin);
|
||||||
MetaDisplay *display = meta_screen_get_display (screen);
|
MetaDisplay *display = meta_screen_get_display (screen);
|
||||||
|
|
||||||
return meta_display_get_grab_op (display) != META_GRAB_OP_NONE;
|
return meta_display_get_grab_op (display) != META_GRAB_OP_NONE;
|
||||||
@ -1262,7 +1262,7 @@ shell_global_create_root_pixmap_actor (ShellGlobal *global)
|
|||||||
/* Initialize to the stage color, since that's what will be seen
|
/* Initialize to the stage color, since that's what will be seen
|
||||||
* in the main view if there's no actual background window.
|
* in the main view if there's no actual background window.
|
||||||
*/
|
*/
|
||||||
stage = mutter_plugin_get_stage (global->plugin);
|
stage = meta_plugin_get_stage (global->plugin);
|
||||||
clutter_stage_get_color (CLUTTER_STAGE (stage), &stage_color);
|
clutter_stage_get_color (CLUTTER_STAGE (stage), &stage_color);
|
||||||
clutter_texture_set_from_rgb_data (CLUTTER_TEXTURE (global->root_pixmap),
|
clutter_texture_set_from_rgb_data (CLUTTER_TEXTURE (global->root_pixmap),
|
||||||
/* ClutterColor has the same layout
|
/* ClutterColor has the same layout
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
#ifndef __SHELL_GLOBAL_H__
|
#ifndef __SHELL_GLOBAL_H__
|
||||||
#define __SHELL_GLOBAL_H__
|
#define __SHELL_GLOBAL_H__
|
||||||
|
|
||||||
#include "mutter-plugin.h"
|
#include "meta-plugin.h"
|
||||||
#include <clutter/clutter.h>
|
#include <clutter/clutter.h>
|
||||||
#include <glib-object.h>
|
#include <glib-object.h>
|
||||||
#include <gdk-pixbuf/gdk-pixbuf.h>
|
#include <gdk-pixbuf/gdk-pixbuf.h>
|
||||||
@ -70,7 +70,7 @@ void shell_global_set_stage_input_mode (ShellGlobal *global,
|
|||||||
void shell_global_set_stage_input_region (ShellGlobal *global,
|
void shell_global_set_stage_input_region (ShellGlobal *global,
|
||||||
GSList *rectangles);
|
GSList *rectangles);
|
||||||
|
|
||||||
GList *shell_global_get_windows (ShellGlobal *global);
|
GList *shell_global_get_window_actors (ShellGlobal *global);
|
||||||
|
|
||||||
gboolean shell_global_begin_modal (ShellGlobal *global,
|
gboolean shell_global_begin_modal (ShellGlobal *global,
|
||||||
guint32 timestamp);
|
guint32 timestamp);
|
||||||
|
@ -8,32 +8,32 @@ G_BEGIN_DECLS
|
|||||||
|
|
||||||
/* These forward along the different effects from GnomeShellPlugin */
|
/* These forward along the different effects from GnomeShellPlugin */
|
||||||
|
|
||||||
void _shell_wm_minimize (ShellWM *wm,
|
void _shell_wm_minimize (ShellWM *wm,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
void _shell_wm_maximize (ShellWM *wm,
|
void _shell_wm_maximize (ShellWM *wm,
|
||||||
MutterWindow *actor,
|
MetaWindowActor *actor,
|
||||||
gint x,
|
gint x,
|
||||||
gint y,
|
gint y,
|
||||||
gint width,
|
gint width,
|
||||||
gint height);
|
gint height);
|
||||||
void _shell_wm_unmaximize (ShellWM *wm,
|
void _shell_wm_unmaximize (ShellWM *wm,
|
||||||
MutterWindow *actor,
|
MetaWindowActor *actor,
|
||||||
gint x,
|
gint x,
|
||||||
gint y,
|
gint y,
|
||||||
gint width,
|
gint width,
|
||||||
gint height);
|
gint height);
|
||||||
void _shell_wm_map (ShellWM *wm,
|
void _shell_wm_map (ShellWM *wm,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
void _shell_wm_destroy (ShellWM *wm,
|
void _shell_wm_destroy (ShellWM *wm,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
|
|
||||||
void _shell_wm_switch_workspace (ShellWM *wm,
|
void _shell_wm_switch_workspace (ShellWM *wm,
|
||||||
gint from,
|
gint from,
|
||||||
gint to,
|
gint to,
|
||||||
MetaMotionDirection direction);
|
MetaMotionDirection direction);
|
||||||
void _shell_wm_kill_window_effects (ShellWM *wm,
|
void _shell_wm_kill_window_effects (ShellWM *wm,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
void _shell_wm_kill_switch_workspace (ShellWM *wm);
|
void _shell_wm_kill_switch_workspace (ShellWM *wm);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
|
102
src/shell-wm.c
102
src/shell-wm.c
@ -13,7 +13,7 @@
|
|||||||
struct _ShellWM {
|
struct _ShellWM {
|
||||||
GObject parent;
|
GObject parent;
|
||||||
|
|
||||||
MutterPlugin *plugin;
|
MetaPlugin *plugin;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Signals */
|
/* Signals */
|
||||||
@ -63,7 +63,7 @@ shell_wm_class_init (ShellWMClass *klass)
|
|||||||
NULL, NULL,
|
NULL, NULL,
|
||||||
g_cclosure_marshal_VOID__OBJECT,
|
g_cclosure_marshal_VOID__OBJECT,
|
||||||
G_TYPE_NONE, 1,
|
G_TYPE_NONE, 1,
|
||||||
MUTTER_TYPE_COMP_WINDOW);
|
META_TYPE_WINDOW_ACTOR);
|
||||||
shell_wm_signals[MAXIMIZE] =
|
shell_wm_signals[MAXIMIZE] =
|
||||||
g_signal_new ("maximize",
|
g_signal_new ("maximize",
|
||||||
G_TYPE_FROM_CLASS (klass),
|
G_TYPE_FROM_CLASS (klass),
|
||||||
@ -72,7 +72,7 @@ shell_wm_class_init (ShellWMClass *klass)
|
|||||||
NULL, NULL,
|
NULL, NULL,
|
||||||
_shell_marshal_VOID__OBJECT_INT_INT_INT_INT,
|
_shell_marshal_VOID__OBJECT_INT_INT_INT_INT,
|
||||||
G_TYPE_NONE, 5,
|
G_TYPE_NONE, 5,
|
||||||
MUTTER_TYPE_COMP_WINDOW, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT);
|
META_TYPE_WINDOW_ACTOR, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT);
|
||||||
shell_wm_signals[UNMAXIMIZE] =
|
shell_wm_signals[UNMAXIMIZE] =
|
||||||
g_signal_new ("unmaximize",
|
g_signal_new ("unmaximize",
|
||||||
G_TYPE_FROM_CLASS (klass),
|
G_TYPE_FROM_CLASS (klass),
|
||||||
@ -81,7 +81,7 @@ shell_wm_class_init (ShellWMClass *klass)
|
|||||||
NULL, NULL,
|
NULL, NULL,
|
||||||
_shell_marshal_VOID__OBJECT_INT_INT_INT_INT,
|
_shell_marshal_VOID__OBJECT_INT_INT_INT_INT,
|
||||||
G_TYPE_NONE, 1,
|
G_TYPE_NONE, 1,
|
||||||
MUTTER_TYPE_COMP_WINDOW, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT);
|
META_TYPE_WINDOW_ACTOR, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT);
|
||||||
shell_wm_signals[MAP] =
|
shell_wm_signals[MAP] =
|
||||||
g_signal_new ("map",
|
g_signal_new ("map",
|
||||||
G_TYPE_FROM_CLASS (klass),
|
G_TYPE_FROM_CLASS (klass),
|
||||||
@ -90,7 +90,7 @@ shell_wm_class_init (ShellWMClass *klass)
|
|||||||
NULL, NULL,
|
NULL, NULL,
|
||||||
g_cclosure_marshal_VOID__OBJECT,
|
g_cclosure_marshal_VOID__OBJECT,
|
||||||
G_TYPE_NONE, 1,
|
G_TYPE_NONE, 1,
|
||||||
MUTTER_TYPE_COMP_WINDOW);
|
META_TYPE_WINDOW_ACTOR);
|
||||||
shell_wm_signals[DESTROY] =
|
shell_wm_signals[DESTROY] =
|
||||||
g_signal_new ("destroy",
|
g_signal_new ("destroy",
|
||||||
G_TYPE_FROM_CLASS (klass),
|
G_TYPE_FROM_CLASS (klass),
|
||||||
@ -99,7 +99,7 @@ shell_wm_class_init (ShellWMClass *klass)
|
|||||||
NULL, NULL,
|
NULL, NULL,
|
||||||
g_cclosure_marshal_VOID__OBJECT,
|
g_cclosure_marshal_VOID__OBJECT,
|
||||||
G_TYPE_NONE, 1,
|
G_TYPE_NONE, 1,
|
||||||
MUTTER_TYPE_COMP_WINDOW);
|
META_TYPE_WINDOW_ACTOR);
|
||||||
shell_wm_signals[SWITCH_WORKSPACE] =
|
shell_wm_signals[SWITCH_WORKSPACE] =
|
||||||
g_signal_new ("switch-workspace",
|
g_signal_new ("switch-workspace",
|
||||||
G_TYPE_FROM_CLASS (klass),
|
G_TYPE_FROM_CLASS (klass),
|
||||||
@ -125,7 +125,7 @@ shell_wm_class_init (ShellWMClass *klass)
|
|||||||
NULL, NULL,
|
NULL, NULL,
|
||||||
g_cclosure_marshal_VOID__OBJECT,
|
g_cclosure_marshal_VOID__OBJECT,
|
||||||
G_TYPE_NONE, 1,
|
G_TYPE_NONE, 1,
|
||||||
MUTTER_TYPE_COMP_WINDOW);
|
META_TYPE_WINDOW_ACTOR);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ShellWM::keybinding:
|
* ShellWM::keybinding:
|
||||||
@ -174,77 +174,77 @@ _shell_wm_switch_workspace (ShellWM *wm,
|
|||||||
void
|
void
|
||||||
shell_wm_completed_switch_workspace (ShellWM *wm)
|
shell_wm_completed_switch_workspace (ShellWM *wm)
|
||||||
{
|
{
|
||||||
mutter_plugin_switch_workspace_completed (wm->plugin);
|
meta_plugin_switch_workspace_completed (wm->plugin);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_wm_completed_minimize
|
* shell_wm_completed_minimize
|
||||||
* @wm: the ShellWM
|
* @wm: the ShellWM
|
||||||
* @actor: the MutterWindow actor
|
* @actor: the MetaWindowActor actor
|
||||||
*
|
*
|
||||||
* The plugin must call this when it has completed a window minimize effect.
|
* The plugin must call this when it has completed a window minimize effect.
|
||||||
**/
|
**/
|
||||||
void
|
void
|
||||||
shell_wm_completed_minimize (ShellWM *wm,
|
shell_wm_completed_minimize (ShellWM *wm,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
mutter_plugin_minimize_completed (wm->plugin, actor);
|
meta_plugin_minimize_completed (wm->plugin, actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_wm_completed_maximize
|
* shell_wm_completed_maximize
|
||||||
* @wm: the ShellWM
|
* @wm: the ShellWM
|
||||||
* @actor: the MutterWindow actor
|
* @actor: the MetaWindowActor actor
|
||||||
*
|
*
|
||||||
* The plugin must call this when it has completed a window maximize effect.
|
* The plugin must call this when it has completed a window maximize effect.
|
||||||
**/
|
**/
|
||||||
void
|
void
|
||||||
shell_wm_completed_maximize (ShellWM *wm,
|
shell_wm_completed_maximize (ShellWM *wm,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
mutter_plugin_maximize_completed (wm->plugin, actor);
|
meta_plugin_maximize_completed (wm->plugin, actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_wm_completed_unmaximize
|
* shell_wm_completed_unmaximize
|
||||||
* @wm: the ShellWM
|
* @wm: the ShellWM
|
||||||
* @actor: the MutterWindow actor
|
* @actor: the MetaWindowActor actor
|
||||||
*
|
*
|
||||||
* The plugin must call this when it has completed a window unmaximize effect.
|
* The plugin must call this when it has completed a window unmaximize effect.
|
||||||
**/
|
**/
|
||||||
void
|
void
|
||||||
shell_wm_completed_unmaximize (ShellWM *wm,
|
shell_wm_completed_unmaximize (ShellWM *wm,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
mutter_plugin_unmaximize_completed (wm->plugin, actor);
|
meta_plugin_unmaximize_completed (wm->plugin, actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_wm_completed_map
|
* shell_wm_completed_map
|
||||||
* @wm: the ShellWM
|
* @wm: the ShellWM
|
||||||
* @actor: the MutterWindow actor
|
* @actor: the MetaWindowActor actor
|
||||||
*
|
*
|
||||||
* The plugin must call this when it has completed a window map effect.
|
* The plugin must call this when it has completed a window map effect.
|
||||||
**/
|
**/
|
||||||
void
|
void
|
||||||
shell_wm_completed_map (ShellWM *wm,
|
shell_wm_completed_map (ShellWM *wm,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
mutter_plugin_map_completed (wm->plugin, actor);
|
meta_plugin_map_completed (wm->plugin, actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_wm_completed_destroy
|
* shell_wm_completed_destroy
|
||||||
* @wm: the ShellWM
|
* @wm: the ShellWM
|
||||||
* @actor: the MutterWindow actor
|
* @actor: the MetaWindowActor actor
|
||||||
*
|
*
|
||||||
* The plugin must call this when it has completed a window destroy effect.
|
* The plugin must call this when it has completed a window destroy effect.
|
||||||
**/
|
**/
|
||||||
void
|
void
|
||||||
shell_wm_completed_destroy (ShellWM *wm,
|
shell_wm_completed_destroy (ShellWM *wm,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
mutter_plugin_destroy_completed (wm->plugin, actor);
|
meta_plugin_destroy_completed (wm->plugin, actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -254,66 +254,66 @@ _shell_wm_kill_switch_workspace (ShellWM *wm)
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_shell_wm_kill_window_effects (ShellWM *wm,
|
_shell_wm_kill_window_effects (ShellWM *wm,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
g_signal_emit (wm, shell_wm_signals[KILL_WINDOW_EFFECTS], 0, actor);
|
g_signal_emit (wm, shell_wm_signals[KILL_WINDOW_EFFECTS], 0, actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
_shell_wm_minimize (ShellWM *wm,
|
_shell_wm_minimize (ShellWM *wm,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
g_signal_emit (wm, shell_wm_signals[MINIMIZE], 0, actor);
|
g_signal_emit (wm, shell_wm_signals[MINIMIZE], 0, actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_shell_wm_maximize (ShellWM *wm,
|
_shell_wm_maximize (ShellWM *wm,
|
||||||
MutterWindow *actor,
|
MetaWindowActor *actor,
|
||||||
int target_x,
|
int target_x,
|
||||||
int target_y,
|
int target_y,
|
||||||
int target_width,
|
int target_width,
|
||||||
int target_height)
|
int target_height)
|
||||||
{
|
{
|
||||||
g_signal_emit (wm, shell_wm_signals[MAXIMIZE], 0, actor, target_x, target_y, target_width, target_height);
|
g_signal_emit (wm, shell_wm_signals[MAXIMIZE], 0, actor, target_x, target_y, target_width, target_height);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_shell_wm_unmaximize (ShellWM *wm,
|
_shell_wm_unmaximize (ShellWM *wm,
|
||||||
MutterWindow *actor,
|
MetaWindowActor *actor,
|
||||||
int target_x,
|
int target_x,
|
||||||
int target_y,
|
int target_y,
|
||||||
int target_width,
|
int target_width,
|
||||||
int target_height)
|
int target_height)
|
||||||
{
|
{
|
||||||
g_signal_emit (wm, shell_wm_signals[UNMAXIMIZE], 0, actor, target_x, target_y, target_width, target_height);
|
g_signal_emit (wm, shell_wm_signals[UNMAXIMIZE], 0, actor, target_x, target_y, target_width, target_height);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_shell_wm_map (ShellWM *wm,
|
_shell_wm_map (ShellWM *wm,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
g_signal_emit (wm, shell_wm_signals[MAP], 0, actor);
|
g_signal_emit (wm, shell_wm_signals[MAP], 0, actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_shell_wm_destroy (ShellWM *wm,
|
_shell_wm_destroy (ShellWM *wm,
|
||||||
MutterWindow *actor)
|
MetaWindowActor *actor)
|
||||||
{
|
{
|
||||||
g_signal_emit (wm, shell_wm_signals[DESTROY], 0, actor);
|
g_signal_emit (wm, shell_wm_signals[DESTROY], 0, actor);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_wm_new:
|
* shell_wm_new:
|
||||||
* @plugin: the #MutterPlugin
|
* @plugin: the #MetaPlugin
|
||||||
*
|
*
|
||||||
* Creates a new window management interface by hooking into @plugin.
|
* Creates a new window management interface by hooking into @plugin.
|
||||||
*
|
*
|
||||||
* Return value: the new window-management interface
|
* Return value: the new window-management interface
|
||||||
**/
|
**/
|
||||||
ShellWM *
|
ShellWM *
|
||||||
shell_wm_new (MutterPlugin *plugin)
|
shell_wm_new (MetaPlugin *plugin)
|
||||||
{
|
{
|
||||||
ShellWM *wm;
|
ShellWM *wm;
|
||||||
|
|
||||||
@ -342,7 +342,7 @@ shell_wm_key_handler (MetaDisplay *display,
|
|||||||
/**
|
/**
|
||||||
* shell_wm_takeover_keybinding:
|
* shell_wm_takeover_keybinding:
|
||||||
* @wm: the #ShellWM
|
* @wm: the #ShellWM
|
||||||
* @binding_name: a mutter keybinding name
|
* @binding_name: a meta keybinding name
|
||||||
*
|
*
|
||||||
* Tells mutter to forward keypresses for @binding_name to the shell
|
* Tells mutter to forward keypresses for @binding_name to the shell
|
||||||
* rather than processing them internally. This will cause a
|
* rather than processing them internally. This will cause a
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#define __SHELL_WM_H__
|
#define __SHELL_WM_H__
|
||||||
|
|
||||||
#include <glib-object.h>
|
#include <glib-object.h>
|
||||||
#include <mutter-plugin.h>
|
#include <meta-plugin.h>
|
||||||
|
|
||||||
G_BEGIN_DECLS
|
G_BEGIN_DECLS
|
||||||
|
|
||||||
@ -25,19 +25,19 @@ struct _ShellWMClass
|
|||||||
|
|
||||||
GType shell_wm_get_type (void) G_GNUC_CONST;
|
GType shell_wm_get_type (void) G_GNUC_CONST;
|
||||||
|
|
||||||
ShellWM *shell_wm_new (MutterPlugin *plugin);
|
ShellWM *shell_wm_new (MetaPlugin *plugin);
|
||||||
|
|
||||||
void shell_wm_completed_minimize (ShellWM *wm,
|
void shell_wm_completed_minimize (ShellWM *wm,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
void shell_wm_completed_maximize (ShellWM *wm,
|
void shell_wm_completed_maximize (ShellWM *wm,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
void shell_wm_completed_unmaximize (ShellWM *wm,
|
void shell_wm_completed_unmaximize (ShellWM *wm,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
void shell_wm_completed_map (ShellWM *wm,
|
void shell_wm_completed_map (ShellWM *wm,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
void shell_wm_completed_destroy (ShellWM *wm,
|
void shell_wm_completed_destroy (ShellWM *wm,
|
||||||
MutterWindow *actor);
|
MetaWindowActor *actor);
|
||||||
void shell_wm_completed_switch_workspace (ShellWM *wm);
|
void shell_wm_completed_switch_workspace (ShellWM *wm);
|
||||||
|
|
||||||
/* Keybinding stuff */
|
/* Keybinding stuff */
|
||||||
void shell_wm_takeover_keybinding (ShellWM *wm,
|
void shell_wm_takeover_keybinding (ShellWM *wm,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user