/* LayoutManager.c generated by valac 0.56.19, the Vala compiler
 * generated from LayoutManager.vala, do not modify */

/*
 * Copyright 2026 elementary, Inc. (https://elementary.io)
 * SPDX-License-Identifier: GPL-3.0-or-later
 *
 * Authored by: Leonhard Kargl <leo.kargl@proton.me>
 */

#include <glib-object.h>
#include <meta/display.h>
#include <clutter/clutter.h>
#include <meta/meta-background-group.h>
#include "gala.h"
#include <glib.h>
#include <stdlib.h>
#include <string.h>
#include <meta/keybindings.h>
#include <meta/window.h>
#include <meta/prefs.h>
#include <float.h>
#include <math.h>
#include <meta/compositor.h>
#include <mtk/mtk.h>
#include <meta/meta-window-actor.h>
#include <gio/gio.h>
#include <cogl/cogl.h>
#include <meta/meta-background-actor.h>
#include <meta/meta-monitor-manager.h>
#include <meta/meta-context.h>
#include <meta/meta-backend.h>

#if !defined(VALA_STRICT_C)
#if !defined(__clang__) && defined(__GNUC__) && (__GNUC__ >= 14)
#pragma GCC diagnostic warning "-Wincompatible-pointer-types"
#elif defined(__clang__) && (__clang_major__ >= 16)
#pragma clang diagnostic ignored "-Wincompatible-function-pointer-types"
#pragma clang diagnostic ignored "-Wincompatible-pointer-types"
#endif
#endif
#if !defined(VALA_EXTERN)
#if defined(_MSC_VER)
#define VALA_EXTERN __declspec(dllexport) extern
#elif __GNUC__ >= 4
#define VALA_EXTERN __attribute__((visibility("default"))) extern
#else
#define VALA_EXTERN extern
#endif
#endif

#define GALA_TYPE_LAYOUT_MANAGER (gala_layout_manager_get_type ())
#define GALA_LAYOUT_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_LAYOUT_MANAGER, GalaLayoutManager))
#define GALA_LAYOUT_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_LAYOUT_MANAGER, GalaLayoutManagerClass))
#define GALA_IS_LAYOUT_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_LAYOUT_MANAGER))
#define GALA_IS_LAYOUT_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_LAYOUT_MANAGER))
#define GALA_LAYOUT_MANAGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_LAYOUT_MANAGER, GalaLayoutManagerClass))

typedef struct _GalaLayoutManager GalaLayoutManager;
typedef struct _GalaLayoutManagerClass GalaLayoutManagerClass;
typedef struct _GalaLayoutManagerPrivate GalaLayoutManagerPrivate;

#define GALA_TYPE_DAEMON_MANAGER (gala_daemon_manager_get_type ())
#define GALA_DAEMON_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_DAEMON_MANAGER, GalaDaemonManager))
#define GALA_DAEMON_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_DAEMON_MANAGER, GalaDaemonManagerClass))
#define GALA_IS_DAEMON_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_DAEMON_MANAGER))
#define GALA_IS_DAEMON_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_DAEMON_MANAGER))
#define GALA_DAEMON_MANAGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_DAEMON_MANAGER, GalaDaemonManagerClass))

typedef struct _GalaDaemonManager GalaDaemonManager;
typedef struct _GalaDaemonManagerClass GalaDaemonManagerClass;

#define GALA_TYPE_MULTITASKING_VIEW (gala_multitasking_view_get_type ())
#define GALA_MULTITASKING_VIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_MULTITASKING_VIEW, GalaMultitaskingView))
#define GALA_MULTITASKING_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_MULTITASKING_VIEW, GalaMultitaskingViewClass))
#define GALA_IS_MULTITASKING_VIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_MULTITASKING_VIEW))
#define GALA_IS_MULTITASKING_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_MULTITASKING_VIEW))
#define GALA_MULTITASKING_VIEW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_MULTITASKING_VIEW, GalaMultitaskingViewClass))

typedef struct _GalaMultitaskingView GalaMultitaskingView;
typedef struct _GalaMultitaskingViewClass GalaMultitaskingViewClass;

#define GALA_TYPE_WINDOW_OVERVIEW (gala_window_overview_get_type ())
#define GALA_WINDOW_OVERVIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_WINDOW_OVERVIEW, GalaWindowOverview))
#define GALA_WINDOW_OVERVIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_WINDOW_OVERVIEW, GalaWindowOverviewClass))
#define GALA_IS_WINDOW_OVERVIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_WINDOW_OVERVIEW))
#define GALA_IS_WINDOW_OVERVIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_WINDOW_OVERVIEW))
#define GALA_WINDOW_OVERVIEW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_WINDOW_OVERVIEW, GalaWindowOverviewClass))

typedef struct _GalaWindowOverview GalaWindowOverview;
typedef struct _GalaWindowOverviewClass GalaWindowOverviewClass;

#define GALA_TYPE_LOCK_SCREEN (gala_lock_screen_get_type ())
#define GALA_LOCK_SCREEN(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_LOCK_SCREEN, GalaLockScreen))
#define GALA_LOCK_SCREEN_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_LOCK_SCREEN, GalaLockScreenClass))
#define GALA_IS_LOCK_SCREEN(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_LOCK_SCREEN))
#define GALA_IS_LOCK_SCREEN_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_LOCK_SCREEN))
#define GALA_LOCK_SCREEN_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_LOCK_SCREEN, GalaLockScreenClass))

typedef struct _GalaLockScreen GalaLockScreen;
typedef struct _GalaLockScreenClass GalaLockScreenClass;

#define GALA_TYPE_SESSION_LOCKER (gala_session_locker_get_type ())
#define GALA_SESSION_LOCKER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_SESSION_LOCKER, GalaSessionLocker))
#define GALA_SESSION_LOCKER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_SESSION_LOCKER, GalaSessionLockerClass))
#define GALA_IS_SESSION_LOCKER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_SESSION_LOCKER))
#define GALA_IS_SESSION_LOCKER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_SESSION_LOCKER))
#define GALA_SESSION_LOCKER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_SESSION_LOCKER, GalaSessionLockerClass))

typedef struct _GalaSessionLocker GalaSessionLocker;
typedef struct _GalaSessionLockerClass GalaSessionLockerClass;

#define GALA_TYPE_POINTER_LOCATOR (gala_pointer_locator_get_type ())
#define GALA_POINTER_LOCATOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_POINTER_LOCATOR, GalaPointerLocator))
#define GALA_POINTER_LOCATOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_POINTER_LOCATOR, GalaPointerLocatorClass))
#define GALA_IS_POINTER_LOCATOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_POINTER_LOCATOR))
#define GALA_IS_POINTER_LOCATOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_POINTER_LOCATOR))
#define GALA_POINTER_LOCATOR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_POINTER_LOCATOR, GalaPointerLocatorClass))

typedef struct _GalaPointerLocator GalaPointerLocator;
typedef struct _GalaPointerLocatorClass GalaPointerLocatorClass;

#define GALA_TYPE_SYSTEM_BACKGROUND (gala_system_background_get_type ())
#define GALA_SYSTEM_BACKGROUND(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_SYSTEM_BACKGROUND, GalaSystemBackground))
#define GALA_SYSTEM_BACKGROUND_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_SYSTEM_BACKGROUND, GalaSystemBackgroundClass))
#define GALA_IS_SYSTEM_BACKGROUND(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_SYSTEM_BACKGROUND))
#define GALA_IS_SYSTEM_BACKGROUND_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_SYSTEM_BACKGROUND))
#define GALA_SYSTEM_BACKGROUND_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_SYSTEM_BACKGROUND, GalaSystemBackgroundClass))

typedef struct _GalaSystemBackground GalaSystemBackground;
typedef struct _GalaSystemBackgroundClass GalaSystemBackgroundClass;

#define GALA_TYPE_WINDOW_SWITCHER (gala_window_switcher_get_type ())
#define GALA_WINDOW_SWITCHER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_WINDOW_SWITCHER, GalaWindowSwitcher))
#define GALA_WINDOW_SWITCHER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_WINDOW_SWITCHER, GalaWindowSwitcherClass))
#define GALA_IS_WINDOW_SWITCHER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_WINDOW_SWITCHER))
#define GALA_IS_WINDOW_SWITCHER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_WINDOW_SWITCHER))
#define GALA_WINDOW_SWITCHER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_WINDOW_SWITCHER, GalaWindowSwitcherClass))

typedef struct _GalaWindowSwitcher GalaWindowSwitcher;
typedef struct _GalaWindowSwitcherClass GalaWindowSwitcherClass;

#define GALA_TYPE_MODAL_GROUP (gala_modal_group_get_type ())
#define GALA_MODAL_GROUP(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_MODAL_GROUP, GalaModalGroup))
#define GALA_MODAL_GROUP_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_MODAL_GROUP, GalaModalGroupClass))
#define GALA_IS_MODAL_GROUP(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_MODAL_GROUP))
#define GALA_IS_MODAL_GROUP_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_MODAL_GROUP))
#define GALA_MODAL_GROUP_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_MODAL_GROUP, GalaModalGroupClass))

typedef struct _GalaModalGroup GalaModalGroup;
typedef struct _GalaModalGroupClass GalaModalGroupClass;
enum  {
	GALA_LAYOUT_MANAGER_0_PROPERTY,
	GALA_LAYOUT_MANAGER_DISPLAY_PROPERTY,
	GALA_LAYOUT_MANAGER_DAEMON_MANAGER_PROPERTY,
	GALA_LAYOUT_MANAGER_STAGE_PROPERTY,
	GALA_LAYOUT_MANAGER_UI_GROUP_PROPERTY,
	GALA_LAYOUT_MANAGER_WINDOW_GROUP_PROPERTY,
	GALA_LAYOUT_MANAGER_BACKGROUND_GROUP_PROPERTY,
	GALA_LAYOUT_MANAGER_TOP_WINDOW_GROUP_PROPERTY,
	GALA_LAYOUT_MANAGER_MULTITASKING_VIEW_PROPERTY,
	GALA_LAYOUT_MANAGER_WINDOW_OVERVIEW_PROPERTY,
	GALA_LAYOUT_MANAGER_LOCK_SCREEN_PROPERTY,
	GALA_LAYOUT_MANAGER_SESSION_LOCKER_PROPERTY,
	GALA_LAYOUT_MANAGER_POINTER_LOCATOR_PROPERTY,
	GALA_LAYOUT_MANAGER_NUM_PROPERTIES
};
static GParamSpec* gala_layout_manager_properties[GALA_LAYOUT_MANAGER_NUM_PROPERTIES];
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))

#define GALA_TYPE_PLUGIN_MANAGER (gala_plugin_manager_get_type ())
#define GALA_PLUGIN_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_PLUGIN_MANAGER, GalaPluginManager))
#define GALA_PLUGIN_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_PLUGIN_MANAGER, GalaPluginManagerClass))
#define GALA_IS_PLUGIN_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_PLUGIN_MANAGER))
#define GALA_IS_PLUGIN_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_PLUGIN_MANAGER))
#define GALA_PLUGIN_MANAGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_PLUGIN_MANAGER, GalaPluginManagerClass))

typedef struct _GalaPluginManager GalaPluginManager;
typedef struct _GalaPluginManagerClass GalaPluginManagerClass;

#define GALA_TYPE_SHELL_CLIENTS_MANAGER (gala_shell_clients_manager_get_type ())
#define GALA_SHELL_CLIENTS_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_SHELL_CLIENTS_MANAGER, GalaShellClientsManager))
#define GALA_SHELL_CLIENTS_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_SHELL_CLIENTS_MANAGER, GalaShellClientsManagerClass))
#define GALA_IS_SHELL_CLIENTS_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_SHELL_CLIENTS_MANAGER))
#define GALA_IS_SHELL_CLIENTS_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_SHELL_CLIENTS_MANAGER))
#define GALA_SHELL_CLIENTS_MANAGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_SHELL_CLIENTS_MANAGER, GalaShellClientsManagerClass))

typedef struct _GalaShellClientsManager GalaShellClientsManager;
typedef struct _GalaShellClientsManagerClass GalaShellClientsManagerClass;

#define GALA_TYPE_DWELL_CLICK_TIMER (gala_dwell_click_timer_get_type ())
#define GALA_DWELL_CLICK_TIMER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_DWELL_CLICK_TIMER, GalaDwellClickTimer))
#define GALA_DWELL_CLICK_TIMER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_DWELL_CLICK_TIMER, GalaDwellClickTimerClass))
#define GALA_IS_DWELL_CLICK_TIMER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_DWELL_CLICK_TIMER))
#define GALA_IS_DWELL_CLICK_TIMER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_DWELL_CLICK_TIMER))
#define GALA_DWELL_CLICK_TIMER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_DWELL_CLICK_TIMER, GalaDwellClickTimerClass))

typedef struct _GalaDwellClickTimer GalaDwellClickTimer;
typedef struct _GalaDwellClickTimerClass GalaDwellClickTimerClass;

#define GALA_TYPE_BACKGROUND_CONTAINER (gala_background_container_get_type ())
#define GALA_BACKGROUND_CONTAINER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GALA_TYPE_BACKGROUND_CONTAINER, GalaBackgroundContainer))
#define GALA_BACKGROUND_CONTAINER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GALA_TYPE_BACKGROUND_CONTAINER, GalaBackgroundContainerClass))
#define GALA_IS_BACKGROUND_CONTAINER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GALA_TYPE_BACKGROUND_CONTAINER))
#define GALA_IS_BACKGROUND_CONTAINER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GALA_TYPE_BACKGROUND_CONTAINER))
#define GALA_BACKGROUND_CONTAINER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GALA_TYPE_BACKGROUND_CONTAINER, GalaBackgroundContainerClass))

typedef struct _GalaBackgroundContainer GalaBackgroundContainer;
typedef struct _GalaBackgroundContainerClass GalaBackgroundContainerClass;
#define _g_free0(var) (var = (g_free (var), NULL))

struct _GalaLayoutManager {
	GObject parent_instance;
	GalaLayoutManagerPrivate * priv;
};

struct _GalaLayoutManagerClass {
	GObjectClass parent_class;
};

struct _GalaLayoutManagerPrivate {
	MetaDisplay* _display;
	GalaDaemonManager* _daemon_manager;
	ClutterStage* _stage;
	ClutterActor* _ui_group;
	ClutterActor* _window_group;
	MetaBackgroundGroup* _background_group;
	ClutterActor* _top_window_group;
	GalaMultitaskingView* _multitasking_view;
	GalaWindowOverview* _window_overview;
	GalaLockScreen* _lock_screen;
	GalaSessionLocker* _session_locker;
	GalaPointerLocator* _pointer_locator;
	GalaSystemBackground* system_background;
	GalaWindowSwitcher* window_switcher;
	ClutterActor* shell_group;
	ClutterActor* menu_group;
	GalaModalGroup* modal_group;
	ClutterActor* overlay_group;
};

static gint GalaLayoutManager_private_offset;
static gpointer gala_layout_manager_parent_class = NULL;

VALA_EXTERN GType gala_layout_manager_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaLayoutManager, g_object_unref)
VALA_EXTERN GType gala_daemon_manager_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaDaemonManager, g_object_unref)
VALA_EXTERN GType gala_multitasking_view_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaMultitaskingView, g_object_unref)
VALA_EXTERN GType gala_window_overview_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaWindowOverview, g_object_unref)
VALA_EXTERN GType gala_lock_screen_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaLockScreen, g_object_unref)
VALA_EXTERN GType gala_session_locker_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaSessionLocker, g_object_unref)
VALA_EXTERN GType gala_pointer_locator_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaPointerLocator, g_object_unref)
VALA_EXTERN GType gala_system_background_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaSystemBackground, g_object_unref)
VALA_EXTERN GType gala_window_switcher_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaWindowSwitcher, g_object_unref)
VALA_EXTERN GType gala_modal_group_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaModalGroup, g_object_unref)
VALA_EXTERN GalaLayoutManager* gala_layout_manager_new (MetaDisplay* display,
                                            GalaDaemonManager* daemon_manager);
VALA_EXTERN GalaLayoutManager* gala_layout_manager_construct (GType object_type,
                                                  MetaDisplay* display,
                                                  GalaDaemonManager* daemon_manager);
VALA_EXTERN void gala_layout_manager_init_ui (GalaLayoutManager* self,
                                  GalaWindowManager* wm);
VALA_EXTERN GalaMultitaskingView* gala_multitasking_view_new (GalaWindowManager* wm);
VALA_EXTERN GalaMultitaskingView* gala_multitasking_view_construct (GType object_type,
                                                        GalaWindowManager* wm);
static void gala_layout_manager_set_multitasking_view (GalaLayoutManager* self,
                                                GalaMultitaskingView* value);
VALA_EXTERN ClutterActor* gala_layout_manager_get_ui_group (GalaLayoutManager* self);
VALA_EXTERN GalaMultitaskingView* gala_layout_manager_get_multitasking_view (GalaLayoutManager* self);
VALA_EXTERN GType gala_plugin_manager_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaPluginManager, g_object_unref)
VALA_EXTERN GalaPluginManager* gala_plugin_manager_get_default (void);
VALA_EXTERN const gchar* gala_plugin_manager_get_window_switcher_provider (GalaPluginManager* self);
VALA_EXTERN GalaWindowSwitcher* gala_window_switcher_new (GalaWindowManager* wm);
VALA_EXTERN GalaWindowSwitcher* gala_window_switcher_construct (GType object_type,
                                                    GalaWindowManager* wm);
VALA_EXTERN void gala_window_switcher_handle_switch_windows (GalaWindowSwitcher* self,
                                                 MetaDisplay* display,
                                                 MetaWindow* window,
                                                 ClutterKeyEvent* event,
                                                 MetaKeyBinding* binding);
static void _gala_window_switcher_handle_switch_windows_meta_key_handler_func (MetaDisplay* display,
                                                                        MetaWindow* window,
                                                                        const ClutterEvent* event,
                                                                        MetaKeyBinding* binding,
                                                                        gpointer self);
VALA_EXTERN GalaWindowOverview* gala_window_overview_new (GalaWindowManager* wm);
VALA_EXTERN GalaWindowOverview* gala_window_overview_construct (GType object_type,
                                                    GalaWindowManager* wm);
static void gala_layout_manager_set_window_overview (GalaLayoutManager* self,
                                              GalaWindowOverview* value);
VALA_EXTERN GalaWindowOverview* gala_layout_manager_get_window_overview (GalaLayoutManager* self);
VALA_EXTERN GalaLockScreen* gala_lock_screen_new (GalaWindowManager* wm);
VALA_EXTERN GalaLockScreen* gala_lock_screen_construct (GType object_type,
                                            GalaWindowManager* wm);
static void gala_layout_manager_set_lock_screen (GalaLayoutManager* self,
                                          GalaLockScreen* value);
VALA_EXTERN GalaLockScreen* gala_layout_manager_get_lock_screen (GalaLayoutManager* self);
VALA_EXTERN ClutterStage* gala_layout_manager_get_stage (GalaLayoutManager* self);
VALA_EXTERN GType gala_shell_clients_manager_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaShellClientsManager, g_object_unref)
VALA_EXTERN GalaShellClientsManager* gala_shell_clients_manager_get_instance (void);
VALA_EXTERN GalaModalGroup* gala_modal_group_new (GalaWindowManager* wm,
                                      GalaShellClientsManager* shell_clients);
VALA_EXTERN GalaModalGroup* gala_modal_group_construct (GType object_type,
                                            GalaWindowManager* wm,
                                            GalaShellClientsManager* shell_clients);
static MetaDisplay* gala_layout_manager_get_display (GalaLayoutManager* self);
VALA_EXTERN GalaPointerLocator* gala_pointer_locator_new (MetaDisplay* display);
VALA_EXTERN GalaPointerLocator* gala_pointer_locator_construct (GType object_type,
                                                    MetaDisplay* display);
static void gala_layout_manager_set_pointer_locator (GalaLayoutManager* self,
                                              GalaPointerLocator* value);
VALA_EXTERN GalaPointerLocator* gala_layout_manager_get_pointer_locator (GalaLayoutManager* self);
VALA_EXTERN GalaDwellClickTimer* gala_dwell_click_timer_new (MetaDisplay* display);
VALA_EXTERN GalaDwellClickTimer* gala_dwell_click_timer_construct (GType object_type,
                                                       MetaDisplay* display);
VALA_EXTERN GType gala_dwell_click_timer_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaDwellClickTimer, g_object_unref)
VALA_EXTERN GalaSessionLocker* gala_session_locker_new (GalaWindowManager* wm);
VALA_EXTERN GalaSessionLocker* gala_session_locker_construct (GType object_type,
                                                  GalaWindowManager* wm);
static void gala_layout_manager_set_session_locker (GalaLayoutManager* self,
                                             GalaSessionLocker* value);
VALA_EXTERN GalaSessionLocker* gala_layout_manager_get_session_locker (GalaLayoutManager* self);
static void gala_layout_manager_update_ui_group_size (GalaLayoutManager* self);
VALA_EXTERN void gala_layout_manager_change_window_group (GalaLayoutManager* self,
                                              MetaWindowActor* actor,
                                              GalaWindowGroup new_group);
VALA_EXTERN void gala_internal_utils_clutter_actor_reparent (ClutterActor* actor,
                                                 ClutterActor* new_parent);
static ClutterActor* gala_layout_manager_get_window_group_actor (GalaLayoutManager* self,
                                                          GalaWindowGroup group);
VALA_EXTERN ClutterActor* gala_lock_screen_get_window_group (GalaLockScreen* self);
VALA_EXTERN ClutterActor* gala_lock_screen_get_shell_group (GalaLockScreen* self);
VALA_EXTERN ClutterActor* gala_modal_group_get_window_group (GalaModalGroup* self);
static void gala_layout_manager_set_display (GalaLayoutManager* self,
                                      MetaDisplay* value);
static GalaDaemonManager* gala_layout_manager_get_daemon_manager (GalaLayoutManager* self);
static void gala_layout_manager_set_daemon_manager (GalaLayoutManager* self,
                                             GalaDaemonManager* value);
static void gala_layout_manager_set_stage (GalaLayoutManager* self,
                                    ClutterStage* value);
static void gala_layout_manager_set_ui_group (GalaLayoutManager* self,
                                       ClutterActor* value);
VALA_EXTERN ClutterActor* gala_layout_manager_get_window_group (GalaLayoutManager* self);
static void gala_layout_manager_set_window_group (GalaLayoutManager* self,
                                           ClutterActor* value);
VALA_EXTERN MetaBackgroundGroup* gala_layout_manager_get_background_group (GalaLayoutManager* self);
static void gala_layout_manager_set_background_group (GalaLayoutManager* self,
                                               MetaBackgroundGroup* value);
VALA_EXTERN ClutterActor* gala_layout_manager_get_top_window_group (GalaLayoutManager* self);
static void gala_layout_manager_set_top_window_group (GalaLayoutManager* self,
                                               ClutterActor* value);
static GObject * gala_layout_manager_constructor (GType type,
                                           guint n_construct_properties,
                                           GObjectConstructParam * construct_properties);
VALA_EXTERN GalaSystemBackground* gala_system_background_new (MetaDisplay* display);
VALA_EXTERN GalaSystemBackground* gala_system_background_construct (GType object_type,
                                                        MetaDisplay* display);
VALA_EXTERN MetaBackgroundActor* gala_system_background_get_background_actor (GalaSystemBackground* self);
static void _gala_layout_manager_update_ui_group_size_meta_monitor_manager_monitors_changed (MetaMonitorManager* _sender,
                                                                                      gpointer self);
VALA_EXTERN GalaBackgroundContainer* gala_background_container_new (MetaDisplay* display);
VALA_EXTERN GalaBackgroundContainer* gala_background_container_construct (GType object_type,
                                                              MetaDisplay* display);
VALA_EXTERN GType gala_background_container_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (GalaBackgroundContainer, g_object_unref)
VALA_EXTERN void gala_daemon_manager_show_background_menu (GalaDaemonManager* self,
                                               gint x,
                                               gint y,
                                               GAsyncReadyCallback _callback_,
                                               gpointer _user_data_);
VALA_EXTERN void gala_daemon_manager_show_background_menu_finish (GalaDaemonManager* self,
                                                      GAsyncResult* _res_);
static void _gala_daemon_manager_show_background_menu_gala_background_container_show_background_menu (GalaBackgroundContainer* _sender,
                                                                                               gint x,
                                                                                               gint y,
                                                                                               gpointer self);
static void gala_layout_manager_finalize (GObject * obj);
static GType gala_layout_manager_get_type_once (void);
static void _vala_gala_layout_manager_get_property (GObject * object,
                                             guint property_id,
                                             GValue * value,
                                             GParamSpec * pspec);
static void _vala_gala_layout_manager_set_property (GObject * object,
                                             guint property_id,
                                             const GValue * value,
                                             GParamSpec * pspec);

static inline gpointer
gala_layout_manager_get_instance_private (GalaLayoutManager* self)
{
	return G_STRUCT_MEMBER_P (self, GalaLayoutManager_private_offset);
}

GalaLayoutManager*
gala_layout_manager_construct (GType object_type,
                               MetaDisplay* display,
                               GalaDaemonManager* daemon_manager)
{
	GalaLayoutManager * self = NULL;
	g_return_val_if_fail (display != NULL, NULL);
	g_return_val_if_fail (daemon_manager != NULL, NULL);
	self = (GalaLayoutManager*) g_object_new (object_type, "display", display, "daemon-manager", daemon_manager, NULL);
	return self;
}

GalaLayoutManager*
gala_layout_manager_new (MetaDisplay* display,
                         GalaDaemonManager* daemon_manager)
{
	return gala_layout_manager_construct (GALA_TYPE_LAYOUT_MANAGER, display, daemon_manager);
}

static void
_gala_window_switcher_handle_switch_windows_meta_key_handler_func (MetaDisplay* display,
                                                                   MetaWindow* window,
                                                                   const ClutterEvent* event,
                                                                   MetaKeyBinding* binding,
                                                                   gpointer self)
{
	gala_window_switcher_handle_switch_windows ((GalaWindowSwitcher*) self, display, window, event, binding);
}

static gpointer
_g_object_ref0 (gpointer self)
{
	return self ? g_object_ref (self) : NULL;
}

void
gala_layout_manager_init_ui (GalaLayoutManager* self,
                             GalaWindowManager* wm)
{
	GalaMultitaskingView* _tmp0_;
	GalaMultitaskingView* _tmp1_;
	ClutterActor* _tmp2_;
	GalaMultitaskingView* _tmp3_;
	GalaPluginManager* plugin_manager = NULL;
	GalaPluginManager* _tmp4_;
	GalaPluginManager* _tmp5_;
	const gchar* _tmp6_;
	const gchar* _tmp7_;
	GalaWindowOverview* _tmp17_;
	GalaWindowOverview* _tmp18_;
	ClutterActor* _tmp19_;
	GalaWindowOverview* _tmp20_;
	ClutterActor* _tmp21_;
	ClutterActor* _tmp22_;
	ClutterActor* _tmp23_;
	ClutterActor* _tmp24_;
	ClutterActor* _tmp25_;
	ClutterActor* _tmp26_;
	GalaLockScreen* _tmp27_;
	GalaLockScreen* _tmp28_;
	GalaLockScreen* _tmp29_;
	ClutterStage* _tmp30_;
	ClutterBindConstraint* _tmp31_;
	ClutterBindConstraint* _tmp32_;
	ClutterActor* _tmp33_;
	GalaLockScreen* _tmp34_;
	GalaShellClientsManager* _tmp35_;
	GalaModalGroup* _tmp36_;
	GalaModalGroup* _tmp37_;
	ClutterStage* _tmp38_;
	ClutterBindConstraint* _tmp39_;
	ClutterBindConstraint* _tmp40_;
	ClutterActor* _tmp41_;
	GalaModalGroup* _tmp42_;
	ClutterActor* _tmp43_;
	ClutterActor* _tmp44_;
	ClutterActor* _tmp45_;
	ClutterActor* feedback_group = NULL;
	MetaDisplay* _tmp46_;
	MetaCompositor* _tmp47_;
	ClutterActor* _tmp48_;
	ClutterActor* _tmp49_;
	ClutterStage* _tmp50_;
	ClutterActor* _tmp51_;
	MetaDisplay* _tmp52_;
	GalaPointerLocator* _tmp53_;
	GalaPointerLocator* _tmp54_;
	ClutterActor* _tmp55_;
	GalaPointerLocator* _tmp56_;
	ClutterActor* _tmp57_;
	MetaDisplay* _tmp58_;
	GalaDwellClickTimer* _tmp59_;
	GalaDwellClickTimer* _tmp60_;
	GalaSessionLocker* _tmp61_;
	GalaSessionLocker* _tmp62_;
	ClutterActor* _tmp63_;
	GalaSessionLocker* _tmp64_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (wm != NULL);
	_tmp0_ = gala_multitasking_view_new (wm);
	g_object_ref_sink (_tmp0_);
	_tmp1_ = _tmp0_;
	gala_layout_manager_set_multitasking_view (self, _tmp1_);
	_g_object_unref0 (_tmp1_);
	_tmp2_ = self->priv->_ui_group;
	_tmp3_ = self->priv->_multitasking_view;
	clutter_actor_add_child (_tmp2_, (ClutterActor*) _tmp3_);
	_tmp4_ = gala_plugin_manager_get_default ();
	plugin_manager = _tmp4_;
	_tmp5_ = plugin_manager;
	_tmp6_ = gala_plugin_manager_get_window_switcher_provider (_tmp5_);
	_tmp7_ = _tmp6_;
	if (_tmp7_ == NULL) {
		GalaWindowSwitcher* _tmp8_;
		ClutterActor* _tmp9_;
		GalaWindowSwitcher* _tmp10_;
		GalaWindowSwitcher* _tmp11_;
		GalaWindowSwitcher* _tmp12_;
		GalaWindowSwitcher* _tmp13_;
		GalaWindowSwitcher* _tmp14_;
		GalaWindowSwitcher* _tmp15_;
		GalaWindowSwitcher* _tmp16_;
		_tmp8_ = gala_window_switcher_new (wm);
		g_object_ref_sink (_tmp8_);
		_g_object_unref0 (self->priv->window_switcher);
		self->priv->window_switcher = _tmp8_;
		_tmp9_ = self->priv->_ui_group;
		_tmp10_ = self->priv->window_switcher;
		clutter_actor_add_child (_tmp9_, (ClutterActor*) _tmp10_);
		_tmp11_ = self->priv->window_switcher;
		meta_keybindings_set_custom_handler ("switch-applications", _gala_window_switcher_handle_switch_windows_meta_key_handler_func, g_object_ref (_tmp11_), g_object_unref);
		_tmp12_ = self->priv->window_switcher;
		meta_keybindings_set_custom_handler ("switch-applications-backward", _gala_window_switcher_handle_switch_windows_meta_key_handler_func, g_object_ref (_tmp12_), g_object_unref);
		_tmp13_ = self->priv->window_switcher;
		meta_keybindings_set_custom_handler ("switch-windows", _gala_window_switcher_handle_switch_windows_meta_key_handler_func, g_object_ref (_tmp13_), g_object_unref);
		_tmp14_ = self->priv->window_switcher;
		meta_keybindings_set_custom_handler ("switch-windows-backward", _gala_window_switcher_handle_switch_windows_meta_key_handler_func, g_object_ref (_tmp14_), g_object_unref);
		_tmp15_ = self->priv->window_switcher;
		meta_keybindings_set_custom_handler ("switch-group", _gala_window_switcher_handle_switch_windows_meta_key_handler_func, g_object_ref (_tmp15_), g_object_unref);
		_tmp16_ = self->priv->window_switcher;
		meta_keybindings_set_custom_handler ("switch-group-backward", _gala_window_switcher_handle_switch_windows_meta_key_handler_func, g_object_ref (_tmp16_), g_object_unref);
	}
	_tmp17_ = gala_window_overview_new (wm);
	g_object_ref_sink (_tmp17_);
	_tmp18_ = _tmp17_;
	gala_layout_manager_set_window_overview (self, _tmp18_);
	_g_object_unref0 (_tmp18_);
	_tmp19_ = self->priv->_ui_group;
	_tmp20_ = self->priv->_window_overview;
	clutter_actor_add_child (_tmp19_, (ClutterActor*) _tmp20_);
	_tmp21_ = clutter_actor_new ();
	g_object_ref_sink (_tmp21_);
	_g_object_unref0 (self->priv->shell_group);
	self->priv->shell_group = _tmp21_;
	_tmp22_ = self->priv->_ui_group;
	_tmp23_ = self->priv->shell_group;
	clutter_actor_add_child (_tmp22_, _tmp23_);
	_tmp24_ = clutter_actor_new ();
	g_object_ref_sink (_tmp24_);
	_g_object_unref0 (self->priv->menu_group);
	self->priv->menu_group = _tmp24_;
	_tmp25_ = self->priv->_ui_group;
	_tmp26_ = self->priv->menu_group;
	clutter_actor_add_child (_tmp25_, _tmp26_);
	_tmp27_ = gala_lock_screen_new (wm);
	g_object_ref_sink (_tmp27_);
	_tmp28_ = _tmp27_;
	gala_layout_manager_set_lock_screen (self, _tmp28_);
	_g_object_unref0 (_tmp28_);
	_tmp29_ = self->priv->_lock_screen;
	_tmp30_ = self->priv->_stage;
	_tmp31_ = (ClutterBindConstraint*) clutter_bind_constraint_new ((ClutterActor*) _tmp30_, CLUTTER_BIND_SIZE, (gfloat) 0);
	g_object_ref_sink (_tmp31_);
	_tmp32_ = _tmp31_;
	clutter_actor_add_constraint ((ClutterActor*) _tmp29_, (ClutterConstraint*) _tmp32_);
	_g_object_unref0 (_tmp32_);
	_tmp33_ = self->priv->_ui_group;
	_tmp34_ = self->priv->_lock_screen;
	clutter_actor_add_child (_tmp33_, (ClutterActor*) _tmp34_);
	_tmp35_ = gala_shell_clients_manager_get_instance ();
	_tmp36_ = gala_modal_group_new (wm, _tmp35_);
	g_object_ref_sink (_tmp36_);
	_g_object_unref0 (self->priv->modal_group);
	self->priv->modal_group = _tmp36_;
	_tmp37_ = self->priv->modal_group;
	_tmp38_ = self->priv->_stage;
	_tmp39_ = (ClutterBindConstraint*) clutter_bind_constraint_new ((ClutterActor*) _tmp38_, CLUTTER_BIND_SIZE, (gfloat) 0);
	g_object_ref_sink (_tmp39_);
	_tmp40_ = _tmp39_;
	clutter_actor_add_constraint ((ClutterActor*) _tmp37_, (ClutterConstraint*) _tmp40_);
	_g_object_unref0 (_tmp40_);
	_tmp41_ = self->priv->_ui_group;
	_tmp42_ = self->priv->modal_group;
	clutter_actor_add_child (_tmp41_, (ClutterActor*) _tmp42_);
	_tmp43_ = clutter_actor_new ();
	g_object_ref_sink (_tmp43_);
	_g_object_unref0 (self->priv->overlay_group);
	self->priv->overlay_group = _tmp43_;
	_tmp44_ = self->priv->_ui_group;
	_tmp45_ = self->priv->overlay_group;
	clutter_actor_add_child (_tmp44_, _tmp45_);
	_tmp46_ = self->priv->_display;
	_tmp47_ = meta_display_get_compositor (_tmp46_);
	_tmp48_ = meta_compositor_get_feedback_group (_tmp47_);
	_tmp49_ = _g_object_ref0 (_tmp48_);
	feedback_group = _tmp49_;
	_tmp50_ = self->priv->_stage;
	clutter_actor_remove_child ((ClutterActor*) _tmp50_, feedback_group);
	_tmp51_ = self->priv->_ui_group;
	clutter_actor_add_child (_tmp51_, feedback_group);
	_tmp52_ = self->priv->_display;
	_tmp53_ = gala_pointer_locator_new (_tmp52_);
	g_object_ref_sink (_tmp53_);
	_tmp54_ = _tmp53_;
	gala_layout_manager_set_pointer_locator (self, _tmp54_);
	_g_object_unref0 (_tmp54_);
	_tmp55_ = self->priv->_ui_group;
	_tmp56_ = self->priv->_pointer_locator;
	clutter_actor_add_child (_tmp55_, (ClutterActor*) _tmp56_);
	_tmp57_ = self->priv->_ui_group;
	_tmp58_ = self->priv->_display;
	_tmp59_ = gala_dwell_click_timer_new (_tmp58_);
	g_object_ref_sink (_tmp59_);
	_tmp60_ = _tmp59_;
	clutter_actor_add_child (_tmp57_, (ClutterActor*) _tmp60_);
	_g_object_unref0 (_tmp60_);
	_tmp61_ = gala_session_locker_new (wm);
	g_object_ref_sink (_tmp61_);
	_tmp62_ = _tmp61_;
	gala_layout_manager_set_session_locker (self, _tmp62_);
	_g_object_unref0 (_tmp62_);
	_tmp63_ = self->priv->_ui_group;
	_tmp64_ = self->priv->_session_locker;
	clutter_actor_add_child (_tmp63_, (ClutterActor*) _tmp64_);
	_g_object_unref0 (feedback_group);
}

static void
gala_layout_manager_update_ui_group_size (GalaLayoutManager* self)
{
	gint max_width = 0;
	gint max_height = 0;
	gint num_monitors = 0;
	MetaDisplay* _tmp0_;
	ClutterActor* _tmp11_;
	g_return_if_fail (self != NULL);
	max_width = 0;
	max_height = 0;
	_tmp0_ = self->priv->_display;
	num_monitors = meta_display_get_n_monitors (_tmp0_);
	{
		gint i = 0;
		i = 0;
		{
			gboolean _tmp1_ = FALSE;
			_tmp1_ = TRUE;
			while (TRUE) {
				MtkRectangle geom = {0};
				MetaDisplay* _tmp3_;
				MtkRectangle _tmp4_ = {0};
				gint total_width = 0;
				MtkRectangle _tmp5_;
				MtkRectangle _tmp6_;
				gint total_height = 0;
				MtkRectangle _tmp7_;
				MtkRectangle _tmp8_;
				gint _tmp9_ = 0;
				gint _tmp10_ = 0;
				if (!_tmp1_) {
					gint _tmp2_;
					_tmp2_ = i;
					i = _tmp2_ + 1;
				}
				_tmp1_ = FALSE;
				if (!(i < num_monitors)) {
					break;
				}
				_tmp3_ = self->priv->_display;
				meta_display_get_monitor_geometry (_tmp3_, i, &_tmp4_);
				geom = _tmp4_;
				_tmp5_ = geom;
				_tmp6_ = geom;
				total_width = _tmp5_.x + _tmp6_.width;
				_tmp7_ = geom;
				_tmp8_ = geom;
				total_height = _tmp7_.y + _tmp8_.height;
				if (max_width > total_width) {
					_tmp9_ = max_width;
				} else {
					_tmp9_ = total_width;
				}
				max_width = _tmp9_;
				if (max_height > total_height) {
					_tmp10_ = max_height;
				} else {
					_tmp10_ = total_height;
				}
				max_height = _tmp10_;
			}
		}
	}
	_tmp11_ = self->priv->_ui_group;
	clutter_actor_set_size (_tmp11_, (gfloat) max_width, (gfloat) max_height);
}

void
gala_layout_manager_change_window_group (GalaLayoutManager* self,
                                         MetaWindowActor* actor,
                                         GalaWindowGroup new_group)
{
	ClutterActor* _tmp0_;
	ClutterActor* _tmp1_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (actor != NULL);
	_tmp0_ = gala_layout_manager_get_window_group_actor (self, new_group);
	_tmp1_ = _tmp0_;
	gala_internal_utils_clutter_actor_reparent ((ClutterActor*) actor, _tmp1_);
	_g_object_unref0 (_tmp1_);
}

static ClutterActor*
gala_layout_manager_get_window_group_actor (GalaLayoutManager* self,
                                            GalaWindowGroup group)
{
	ClutterActor* result;
	g_return_val_if_fail (self != NULL, NULL);
	switch (group) {
		case GALA_WINDOW_GROUP_DESKTOP_SHELL:
		{
			ClutterActor* _tmp0_;
			ClutterActor* _tmp1_;
			_tmp0_ = self->priv->shell_group;
			_tmp1_ = _g_object_ref0 (_tmp0_);
			result = _tmp1_;
			return result;
		}
		case GALA_WINDOW_GROUP_MENU:
		{
			ClutterActor* _tmp2_;
			ClutterActor* _tmp3_;
			_tmp2_ = self->priv->menu_group;
			_tmp3_ = _g_object_ref0 (_tmp2_);
			result = _tmp3_;
			return result;
		}
		case GALA_WINDOW_GROUP_LOCK_SCREEN:
		{
			GalaLockScreen* _tmp4_;
			ClutterActor* _tmp5_;
			ClutterActor* _tmp6_;
			ClutterActor* _tmp7_;
			_tmp4_ = self->priv->_lock_screen;
			_tmp5_ = gala_lock_screen_get_window_group (_tmp4_);
			_tmp6_ = _tmp5_;
			_tmp7_ = _g_object_ref0 (_tmp6_);
			result = _tmp7_;
			return result;
		}
		case GALA_WINDOW_GROUP_LOCK_SCREEN_SHELL:
		{
			GalaLockScreen* _tmp8_;
			ClutterActor* _tmp9_;
			ClutterActor* _tmp10_;
			ClutterActor* _tmp11_;
			_tmp8_ = self->priv->_lock_screen;
			_tmp9_ = gala_lock_screen_get_shell_group (_tmp8_);
			_tmp10_ = _tmp9_;
			_tmp11_ = _g_object_ref0 (_tmp10_);
			result = _tmp11_;
			return result;
		}
		case GALA_WINDOW_GROUP_MODAL:
		{
			GalaModalGroup* _tmp12_;
			ClutterActor* _tmp13_;
			ClutterActor* _tmp14_;
			ClutterActor* _tmp15_;
			_tmp12_ = self->priv->modal_group;
			_tmp13_ = gala_modal_group_get_window_group (_tmp12_);
			_tmp14_ = _tmp13_;
			_tmp15_ = _g_object_ref0 (_tmp14_);
			result = _tmp15_;
			return result;
		}
		case GALA_WINDOW_GROUP_OVERLAY:
		{
			ClutterActor* _tmp16_;
			ClutterActor* _tmp17_;
			_tmp16_ = self->priv->overlay_group;
			_tmp17_ = _g_object_ref0 (_tmp16_);
			result = _tmp17_;
			return result;
		}
		default:
		{
			g_assert_not_reached ();
		}
	}
}

static MetaDisplay*
gala_layout_manager_get_display (GalaLayoutManager* self)
{
	MetaDisplay* result;
	MetaDisplay* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_display;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_display (GalaLayoutManager* self,
                                 MetaDisplay* value)
{
	MetaDisplay* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_display (self);
	if (old_value != value) {
		MetaDisplay* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_display);
		self->priv->_display = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_DISPLAY_PROPERTY]);
	}
}

static GalaDaemonManager*
gala_layout_manager_get_daemon_manager (GalaLayoutManager* self)
{
	GalaDaemonManager* result;
	GalaDaemonManager* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_daemon_manager;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_daemon_manager (GalaLayoutManager* self,
                                        GalaDaemonManager* value)
{
	GalaDaemonManager* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_daemon_manager (self);
	if (old_value != value) {
		GalaDaemonManager* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_daemon_manager);
		self->priv->_daemon_manager = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_DAEMON_MANAGER_PROPERTY]);
	}
}

ClutterStage*
gala_layout_manager_get_stage (GalaLayoutManager* self)
{
	ClutterStage* result;
	ClutterStage* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_stage;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_stage (GalaLayoutManager* self,
                               ClutterStage* value)
{
	ClutterStage* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_stage (self);
	if (old_value != value) {
		ClutterStage* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_stage);
		self->priv->_stage = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_STAGE_PROPERTY]);
	}
}

ClutterActor*
gala_layout_manager_get_ui_group (GalaLayoutManager* self)
{
	ClutterActor* result;
	ClutterActor* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_ui_group;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_ui_group (GalaLayoutManager* self,
                                  ClutterActor* value)
{
	ClutterActor* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_ui_group (self);
	if (old_value != value) {
		ClutterActor* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_ui_group);
		self->priv->_ui_group = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_UI_GROUP_PROPERTY]);
	}
}

ClutterActor*
gala_layout_manager_get_window_group (GalaLayoutManager* self)
{
	ClutterActor* result;
	ClutterActor* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_window_group;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_window_group (GalaLayoutManager* self,
                                      ClutterActor* value)
{
	ClutterActor* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_window_group (self);
	if (old_value != value) {
		ClutterActor* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_window_group);
		self->priv->_window_group = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_WINDOW_GROUP_PROPERTY]);
	}
}

MetaBackgroundGroup*
gala_layout_manager_get_background_group (GalaLayoutManager* self)
{
	MetaBackgroundGroup* result;
	MetaBackgroundGroup* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_background_group;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_background_group (GalaLayoutManager* self,
                                          MetaBackgroundGroup* value)
{
	MetaBackgroundGroup* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_background_group (self);
	if (old_value != value) {
		MetaBackgroundGroup* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_background_group);
		self->priv->_background_group = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_BACKGROUND_GROUP_PROPERTY]);
	}
}

ClutterActor*
gala_layout_manager_get_top_window_group (GalaLayoutManager* self)
{
	ClutterActor* result;
	ClutterActor* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_top_window_group;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_top_window_group (GalaLayoutManager* self,
                                          ClutterActor* value)
{
	ClutterActor* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_top_window_group (self);
	if (old_value != value) {
		ClutterActor* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_top_window_group);
		self->priv->_top_window_group = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_TOP_WINDOW_GROUP_PROPERTY]);
	}
}

GalaMultitaskingView*
gala_layout_manager_get_multitasking_view (GalaLayoutManager* self)
{
	GalaMultitaskingView* result;
	GalaMultitaskingView* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_multitasking_view;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_multitasking_view (GalaLayoutManager* self,
                                           GalaMultitaskingView* value)
{
	GalaMultitaskingView* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_multitasking_view (self);
	if (old_value != value) {
		GalaMultitaskingView* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_multitasking_view);
		self->priv->_multitasking_view = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_MULTITASKING_VIEW_PROPERTY]);
	}
}

GalaWindowOverview*
gala_layout_manager_get_window_overview (GalaLayoutManager* self)
{
	GalaWindowOverview* result;
	GalaWindowOverview* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_window_overview;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_window_overview (GalaLayoutManager* self,
                                         GalaWindowOverview* value)
{
	GalaWindowOverview* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_window_overview (self);
	if (old_value != value) {
		GalaWindowOverview* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_window_overview);
		self->priv->_window_overview = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_WINDOW_OVERVIEW_PROPERTY]);
	}
}

GalaLockScreen*
gala_layout_manager_get_lock_screen (GalaLayoutManager* self)
{
	GalaLockScreen* result;
	GalaLockScreen* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_lock_screen;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_lock_screen (GalaLayoutManager* self,
                                     GalaLockScreen* value)
{
	GalaLockScreen* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_lock_screen (self);
	if (old_value != value) {
		GalaLockScreen* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_lock_screen);
		self->priv->_lock_screen = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_LOCK_SCREEN_PROPERTY]);
	}
}

GalaSessionLocker*
gala_layout_manager_get_session_locker (GalaLayoutManager* self)
{
	GalaSessionLocker* result;
	GalaSessionLocker* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_session_locker;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_session_locker (GalaLayoutManager* self,
                                        GalaSessionLocker* value)
{
	GalaSessionLocker* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_session_locker (self);
	if (old_value != value) {
		GalaSessionLocker* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_session_locker);
		self->priv->_session_locker = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_SESSION_LOCKER_PROPERTY]);
	}
}

GalaPointerLocator*
gala_layout_manager_get_pointer_locator (GalaLayoutManager* self)
{
	GalaPointerLocator* result;
	GalaPointerLocator* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_pointer_locator;
	result = _tmp0_;
	return result;
}

static void
gala_layout_manager_set_pointer_locator (GalaLayoutManager* self,
                                         GalaPointerLocator* value)
{
	GalaPointerLocator* old_value;
	g_return_if_fail (self != NULL);
	old_value = gala_layout_manager_get_pointer_locator (self);
	if (old_value != value) {
		GalaPointerLocator* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_pointer_locator);
		self->priv->_pointer_locator = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_POINTER_LOCATOR_PROPERTY]);
	}
}

static void
_vala_cogl_color_from_string (const gchar* str,
                              CoglColor* result)
{
	CoglColor color = {0};
	CoglColor _tmp0_ = {0};
	g_return_if_fail (str != NULL);
	color = _tmp0_;
	cogl_color_from_string (&color, str);
	*result = color;
	return;
}

static void
_gala_layout_manager_update_ui_group_size_meta_monitor_manager_monitors_changed (MetaMonitorManager* _sender,
                                                                                 gpointer self)
{
	gala_layout_manager_update_ui_group_size ((GalaLayoutManager*) self);
}

static void
_gala_daemon_manager_show_background_menu_gala_background_container_show_background_menu (GalaBackgroundContainer* _sender,
                                                                                          gint x,
                                                                                          gint y,
                                                                                          gpointer self)
{
	gala_daemon_manager_show_background_menu ((GalaDaemonManager*) self, x, y, NULL, NULL);
}

static GObject *
gala_layout_manager_constructor (GType type,
                                 guint n_construct_properties,
                                 GObjectConstructParam * construct_properties)
{
	GObject * obj;
	GObjectClass * parent_class;
	GalaLayoutManager * self;
	MetaDisplay* _tmp0_;
	MetaCompositor* _tmp1_;
	ClutterStage* _tmp2_;
	GSettings* background_settings = NULL;
	GSettings* _tmp3_;
	gchar* color = NULL;
	GSettings* _tmp4_;
	gchar* _tmp5_;
	ClutterStage* _tmp6_;
	const gchar* _tmp7_;
	CoglColor _tmp8_ = {0};
	MetaDisplay* _tmp9_;
	GalaSystemBackground* _tmp10_;
	GalaSystemBackground* _tmp11_;
	MetaBackgroundActor* _tmp12_;
	MetaBackgroundActor* _tmp13_;
	ClutterStage* _tmp14_;
	ClutterBindConstraint* _tmp15_;
	ClutterBindConstraint* _tmp16_;
	ClutterStage* _tmp17_;
	GalaSystemBackground* _tmp18_;
	MetaBackgroundActor* _tmp19_;
	MetaBackgroundActor* _tmp20_;
	ClutterActor* _tmp21_;
	ClutterActor* _tmp22_;
	ClutterStage* _tmp23_;
	ClutterActor* _tmp24_;
	MetaMonitorManager* monitor_manager = NULL;
	MetaDisplay* _tmp25_;
	MetaContext* _tmp26_;
	MetaBackend* _tmp27_;
	MetaMonitorManager* _tmp28_;
	MetaMonitorManager* _tmp29_;
	MetaDisplay* _tmp30_;
	MetaCompositor* _tmp31_;
	ClutterActor* _tmp32_;
	ClutterStage* _tmp33_;
	ClutterActor* _tmp34_;
	ClutterActor* _tmp35_;
	ClutterActor* _tmp36_;
	MetaDisplay* _tmp37_;
	GalaBackgroundContainer* _tmp38_;
	GalaBackgroundContainer* _tmp39_;
	MetaBackgroundGroup* _tmp40_;
	GalaDaemonManager* _tmp41_;
	ClutterActor* _tmp42_;
	MetaBackgroundGroup* _tmp43_;
	ClutterActor* _tmp44_;
	MetaBackgroundGroup* _tmp45_;
	MetaDisplay* _tmp46_;
	MetaCompositor* _tmp47_;
	ClutterActor* _tmp48_;
	ClutterStage* _tmp49_;
	ClutterActor* _tmp50_;
	ClutterActor* _tmp51_;
	ClutterActor* _tmp52_;
	parent_class = G_OBJECT_CLASS (gala_layout_manager_parent_class);
	obj = parent_class->constructor (type, n_construct_properties, construct_properties);
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, GALA_TYPE_LAYOUT_MANAGER, GalaLayoutManager);
	_tmp0_ = self->priv->_display;
	_tmp1_ = meta_display_get_compositor (_tmp0_);
	_tmp2_ = meta_compositor_get_stage (_tmp1_);
	gala_layout_manager_set_stage (self, G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, clutter_stage_get_type (), ClutterStage));
	_tmp3_ = g_settings_new ("org.gnome.desktop.background");
	background_settings = _tmp3_;
	_tmp4_ = background_settings;
	_tmp5_ = g_settings_get_string (_tmp4_, "primary-color");
	color = _tmp5_;
	_tmp6_ = self->priv->_stage;
	_tmp7_ = color;
	_vala_cogl_color_from_string (_tmp7_, &_tmp8_);
	clutter_actor_set_background_color ((ClutterActor*) _tmp6_, &_tmp8_);
	_tmp9_ = self->priv->_display;
	_tmp10_ = gala_system_background_new (_tmp9_);
	_g_object_unref0 (self->priv->system_background);
	self->priv->system_background = _tmp10_;
	_tmp11_ = self->priv->system_background;
	_tmp12_ = gala_system_background_get_background_actor (_tmp11_);
	_tmp13_ = _tmp12_;
	_tmp14_ = self->priv->_stage;
	_tmp15_ = (ClutterBindConstraint*) clutter_bind_constraint_new ((ClutterActor*) _tmp14_, CLUTTER_BIND_ALL, (gfloat) 0);
	g_object_ref_sink (_tmp15_);
	_tmp16_ = _tmp15_;
	clutter_actor_add_constraint ((ClutterActor*) _tmp13_, (ClutterConstraint*) _tmp16_);
	_g_object_unref0 (_tmp16_);
	_tmp17_ = self->priv->_stage;
	_tmp18_ = self->priv->system_background;
	_tmp19_ = gala_system_background_get_background_actor (_tmp18_);
	_tmp20_ = _tmp19_;
	clutter_actor_insert_child_below ((ClutterActor*) _tmp17_, (ClutterActor*) _tmp20_, NULL);
	_tmp21_ = clutter_actor_new ();
	g_object_ref_sink (_tmp21_);
	_tmp22_ = _tmp21_;
	gala_layout_manager_set_ui_group (self, _tmp22_);
	_g_object_unref0 (_tmp22_);
	gala_layout_manager_update_ui_group_size (self);
	_tmp23_ = self->priv->_stage;
	_tmp24_ = self->priv->_ui_group;
	clutter_actor_add_child ((ClutterActor*) _tmp23_, _tmp24_);
	_tmp25_ = self->priv->_display;
	_tmp26_ = meta_display_get_context (_tmp25_);
	_tmp27_ = meta_context_get_backend (_tmp26_);
	_tmp28_ = meta_backend_get_monitor_manager (_tmp27_);
	monitor_manager = _tmp28_;
	_tmp29_ = monitor_manager;
	g_signal_connect_object (_tmp29_, "monitors-changed", (GCallback) _gala_layout_manager_update_ui_group_size_meta_monitor_manager_monitors_changed, self, 0);
	_tmp30_ = self->priv->_display;
	_tmp31_ = meta_display_get_compositor (_tmp30_);
	_tmp32_ = meta_compositor_get_window_group (_tmp31_);
	gala_layout_manager_set_window_group (self, _tmp32_);
	_tmp33_ = self->priv->_stage;
	_tmp34_ = self->priv->_window_group;
	clutter_actor_remove_child ((ClutterActor*) _tmp33_, _tmp34_);
	_tmp35_ = self->priv->_ui_group;
	_tmp36_ = self->priv->_window_group;
	clutter_actor_add_child (_tmp35_, _tmp36_);
	_tmp37_ = self->priv->_display;
	_tmp38_ = gala_background_container_new (_tmp37_);
	g_object_ref_sink (_tmp38_);
	_tmp39_ = _tmp38_;
	gala_layout_manager_set_background_group (self, (MetaBackgroundGroup*) _tmp39_);
	_g_object_unref0 (_tmp39_);
	_tmp40_ = self->priv->_background_group;
	_tmp41_ = self->priv->_daemon_manager;
	g_signal_connect_object (G_TYPE_CHECK_INSTANCE_CAST (_tmp40_, GALA_TYPE_BACKGROUND_CONTAINER, GalaBackgroundContainer), "show-background-menu", (GCallback) _gala_daemon_manager_show_background_menu_gala_background_container_show_background_menu, _tmp41_, 0);
	_tmp42_ = self->priv->_window_group;
	_tmp43_ = self->priv->_background_group;
	clutter_actor_add_child (_tmp42_, (ClutterActor*) _tmp43_);
	_tmp44_ = self->priv->_window_group;
	_tmp45_ = self->priv->_background_group;
	clutter_actor_set_child_below_sibling (_tmp44_, (ClutterActor*) _tmp45_, NULL);
	_tmp46_ = self->priv->_display;
	_tmp47_ = meta_display_get_compositor (_tmp46_);
	_tmp48_ = meta_compositor_get_top_window_group (_tmp47_);
	gala_layout_manager_set_top_window_group (self, _tmp48_);
	_tmp49_ = self->priv->_stage;
	_tmp50_ = self->priv->_top_window_group;
	clutter_actor_remove_child ((ClutterActor*) _tmp49_, _tmp50_);
	_tmp51_ = self->priv->_ui_group;
	_tmp52_ = self->priv->_top_window_group;
	clutter_actor_add_child (_tmp51_, _tmp52_);
	_g_free0 (color);
	_g_object_unref0 (background_settings);
	return obj;
}

static void
gala_layout_manager_class_init (GalaLayoutManagerClass * klass,
                                gpointer klass_data)
{
	gala_layout_manager_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &GalaLayoutManager_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_gala_layout_manager_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_gala_layout_manager_set_property;
	G_OBJECT_CLASS (klass)->constructor = gala_layout_manager_constructor;
	G_OBJECT_CLASS (klass)->finalize = gala_layout_manager_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_DISPLAY_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_DISPLAY_PROPERTY] = g_param_spec_object ("display", "display", "display", meta_display_get_type (), G_PARAM_STATIC_STRINGS | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_DAEMON_MANAGER_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_DAEMON_MANAGER_PROPERTY] = g_param_spec_object ("daemon-manager", "daemon-manager", "daemon-manager", GALA_TYPE_DAEMON_MANAGER, G_PARAM_STATIC_STRINGS | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_STAGE_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_STAGE_PROPERTY] = g_param_spec_object ("stage", "stage", "stage", clutter_stage_get_type (), G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_UI_GROUP_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_UI_GROUP_PROPERTY] = g_param_spec_object ("ui-group", "ui-group", "ui-group", clutter_actor_get_type (), G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_WINDOW_GROUP_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_WINDOW_GROUP_PROPERTY] = g_param_spec_object ("window-group", "window-group", "window-group", clutter_actor_get_type (), G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_BACKGROUND_GROUP_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_BACKGROUND_GROUP_PROPERTY] = g_param_spec_object ("background-group", "background-group", "background-group", meta_background_group_get_type (), G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_TOP_WINDOW_GROUP_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_TOP_WINDOW_GROUP_PROPERTY] = g_param_spec_object ("top-window-group", "top-window-group", "top-window-group", clutter_actor_get_type (), G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_MULTITASKING_VIEW_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_MULTITASKING_VIEW_PROPERTY] = g_param_spec_object ("multitasking-view", "multitasking-view", "multitasking-view", GALA_TYPE_MULTITASKING_VIEW, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_WINDOW_OVERVIEW_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_WINDOW_OVERVIEW_PROPERTY] = g_param_spec_object ("window-overview", "window-overview", "window-overview", GALA_TYPE_WINDOW_OVERVIEW, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_LOCK_SCREEN_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_LOCK_SCREEN_PROPERTY] = g_param_spec_object ("lock-screen", "lock-screen", "lock-screen", GALA_TYPE_LOCK_SCREEN, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_SESSION_LOCKER_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_SESSION_LOCKER_PROPERTY] = g_param_spec_object ("session-locker", "session-locker", "session-locker", GALA_TYPE_SESSION_LOCKER, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GALA_LAYOUT_MANAGER_POINTER_LOCATOR_PROPERTY, gala_layout_manager_properties[GALA_LAYOUT_MANAGER_POINTER_LOCATOR_PROPERTY] = g_param_spec_object ("pointer-locator", "pointer-locator", "pointer-locator", GALA_TYPE_POINTER_LOCATOR, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
}

static void
gala_layout_manager_instance_init (GalaLayoutManager * self,
                                   gpointer klass)
{
	self->priv = gala_layout_manager_get_instance_private (self);
}

static void
gala_layout_manager_finalize (GObject * obj)
{
	GalaLayoutManager * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, GALA_TYPE_LAYOUT_MANAGER, GalaLayoutManager);
	_g_object_unref0 (self->priv->_display);
	_g_object_unref0 (self->priv->_daemon_manager);
	_g_object_unref0 (self->priv->_stage);
	_g_object_unref0 (self->priv->_ui_group);
	_g_object_unref0 (self->priv->_window_group);
	_g_object_unref0 (self->priv->_background_group);
	_g_object_unref0 (self->priv->_top_window_group);
	_g_object_unref0 (self->priv->_multitasking_view);
	_g_object_unref0 (self->priv->_window_overview);
	_g_object_unref0 (self->priv->_lock_screen);
	_g_object_unref0 (self->priv->_session_locker);
	_g_object_unref0 (self->priv->_pointer_locator);
	_g_object_unref0 (self->priv->system_background);
	_g_object_unref0 (self->priv->window_switcher);
	_g_object_unref0 (self->priv->shell_group);
	_g_object_unref0 (self->priv->menu_group);
	_g_object_unref0 (self->priv->modal_group);
	_g_object_unref0 (self->priv->overlay_group);
	G_OBJECT_CLASS (gala_layout_manager_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
gala_layout_manager_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (GalaLayoutManagerClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) gala_layout_manager_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (GalaLayoutManager), 0, (GInstanceInitFunc) gala_layout_manager_instance_init, NULL };
	GType gala_layout_manager_type_id;
	gala_layout_manager_type_id = g_type_register_static (G_TYPE_OBJECT, "GalaLayoutManager", &g_define_type_info, G_TYPE_FLAG_NONE);
	GalaLayoutManager_private_offset = g_type_add_instance_private (gala_layout_manager_type_id, sizeof (GalaLayoutManagerPrivate));
	return gala_layout_manager_type_id;
}

GType
gala_layout_manager_get_type (void)
{
	static gsize gala_layout_manager_type_id__once = 0;
	if (g_once_init_enter (&gala_layout_manager_type_id__once)) {
		GType gala_layout_manager_type_id;
		gala_layout_manager_type_id = gala_layout_manager_get_type_once ();
		g_once_init_leave (&gala_layout_manager_type_id__once, gala_layout_manager_type_id);
	}
	return gala_layout_manager_type_id__once;
}

static void
_vala_gala_layout_manager_get_property (GObject * object,
                                        guint property_id,
                                        GValue * value,
                                        GParamSpec * pspec)
{
	GalaLayoutManager * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, GALA_TYPE_LAYOUT_MANAGER, GalaLayoutManager);
	switch (property_id) {
		case GALA_LAYOUT_MANAGER_DISPLAY_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_display (self));
		break;
		case GALA_LAYOUT_MANAGER_DAEMON_MANAGER_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_daemon_manager (self));
		break;
		case GALA_LAYOUT_MANAGER_STAGE_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_stage (self));
		break;
		case GALA_LAYOUT_MANAGER_UI_GROUP_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_ui_group (self));
		break;
		case GALA_LAYOUT_MANAGER_WINDOW_GROUP_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_window_group (self));
		break;
		case GALA_LAYOUT_MANAGER_BACKGROUND_GROUP_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_background_group (self));
		break;
		case GALA_LAYOUT_MANAGER_TOP_WINDOW_GROUP_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_top_window_group (self));
		break;
		case GALA_LAYOUT_MANAGER_MULTITASKING_VIEW_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_multitasking_view (self));
		break;
		case GALA_LAYOUT_MANAGER_WINDOW_OVERVIEW_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_window_overview (self));
		break;
		case GALA_LAYOUT_MANAGER_LOCK_SCREEN_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_lock_screen (self));
		break;
		case GALA_LAYOUT_MANAGER_SESSION_LOCKER_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_session_locker (self));
		break;
		case GALA_LAYOUT_MANAGER_POINTER_LOCATOR_PROPERTY:
		g_value_set_object (value, gala_layout_manager_get_pointer_locator (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_gala_layout_manager_set_property (GObject * object,
                                        guint property_id,
                                        const GValue * value,
                                        GParamSpec * pspec)
{
	GalaLayoutManager * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, GALA_TYPE_LAYOUT_MANAGER, GalaLayoutManager);
	switch (property_id) {
		case GALA_LAYOUT_MANAGER_DISPLAY_PROPERTY:
		gala_layout_manager_set_display (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_DAEMON_MANAGER_PROPERTY:
		gala_layout_manager_set_daemon_manager (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_STAGE_PROPERTY:
		gala_layout_manager_set_stage (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_UI_GROUP_PROPERTY:
		gala_layout_manager_set_ui_group (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_WINDOW_GROUP_PROPERTY:
		gala_layout_manager_set_window_group (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_BACKGROUND_GROUP_PROPERTY:
		gala_layout_manager_set_background_group (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_TOP_WINDOW_GROUP_PROPERTY:
		gala_layout_manager_set_top_window_group (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_MULTITASKING_VIEW_PROPERTY:
		gala_layout_manager_set_multitasking_view (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_WINDOW_OVERVIEW_PROPERTY:
		gala_layout_manager_set_window_overview (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_LOCK_SCREEN_PROPERTY:
		gala_layout_manager_set_lock_screen (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_SESSION_LOCKER_PROPERTY:
		gala_layout_manager_set_session_locker (self, g_value_get_object (value));
		break;
		case GALA_LAYOUT_MANAGER_POINTER_LOCATOR_PROPERTY:
		gala_layout_manager_set_pointer_locator (self, g_value_get_object (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

