[gnome-shell-extensions] static-workspaces: New extension
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell-extensions] static-workspaces: New extension
- Date: Tue, 11 Dec 2012 00:00:22 +0000 (UTC)
commit 0fed304f79d888cd992a2fc364c84d24513773b9
Author: Florian MÃllner <fmuellner gnome org>
Date: Wed Dec 5 22:29:20 2012 +0100
static-workspaces: New extension
Just as the default-min-max extension, this extension reverts a
gnome-shell override and is meant to be used in classic mode.
https://bugzilla.gnome.org/show_bug.cgi?id=689739
configure.ac | 5 +++--
extensions/static-workspaces/Makefile.am | 3 +++
extensions/static-workspaces/extension.js | 18 ++++++++++++++++++
extensions/static-workspaces/metadata.json.in | 11 +++++++++++
extensions/static-workspaces/stylesheet.css | 1 +
5 files changed, 36 insertions(+), 2 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 90f14bc..c9d416d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -27,7 +27,7 @@ fi
AC_SUBST([SHELL_VERSION])
dnl keep this in alphabetic order
-CLASSIC_EXTENSIONS="apps-menu places-menu alternate-tab default-min-max"
+CLASSIC_EXTENSIONS="apps-menu places-menu alternate-tab default-min-max static-workspaces"
DEFAULT_EXTENSIONS="$CLASSIC_EXTENSIONS alternative-status-menu drive-menu windowsNavigator workspace-indicator"
ALL_EXTENSIONS="$DEFAULT_EXTENSIONS auto-move-windows example native-window-placement systemMonitor user-theme xrandr-indicator"
AC_SUBST(CLASSIC_EXTENSIONS, [$CLASSIC_EXTENSIONS])
@@ -62,7 +62,7 @@ for e in $enable_extensions; do
[AC_MSG_WARN([gnome-desktop-3.0 not found, disabling xrandr-indicator])])
;;
dnl keep this in alphabetic order
- alternate-tab|alternative-status-menu|apps-menu|auto-move-windows|default-min-max|drive-menu|example|native-window-placement|places-menu|user-theme|windowsNavigator|workspace-indicator)
+ alternate-tab|alternative-status-menu|apps-menu|auto-move-windows|default-min-max|drive-menu|example|native-window-placement|places-menu|static-workspaces|user-theme|windowsNavigator|workspace-indicator)
ENABLED_EXTENSIONS="$ENABLED_EXTENSIONS $e"
;;
*)
@@ -84,6 +84,7 @@ AC_CONFIG_FILES([
extensions/example/Makefile
extensions/native-window-placement/Makefile
extensions/places-menu/Makefile
+ extensions/static-workspaces/Makefile
extensions/systemMonitor/Makefile
extensions/user-theme/Makefile
extensions/windowsNavigator/Makefile
diff --git a/extensions/static-workspaces/Makefile.am b/extensions/static-workspaces/Makefile.am
new file mode 100644
index 0000000..d8e4181
--- /dev/null
+++ b/extensions/static-workspaces/Makefile.am
@@ -0,0 +1,3 @@
+EXTENSION_ID = static-workspaces
+
+include ../../extension.mk
diff --git a/extensions/static-workspaces/extension.js b/extensions/static-workspaces/extension.js
new file mode 100644
index 0000000..8a73699
--- /dev/null
+++ b/extensions/static-workspaces/extension.js
@@ -0,0 +1,18 @@
+// -*- mode: js2; indent-tabs-mode: nil; js2-basic-offset: 4 -*-
+
+const Meta = imports.gi.Meta;
+
+function init(metadata) {
+}
+
+function enable() {
+ // Override gnome-shell's overrides
+ Meta.prefs_override_preference_schema('dynamic-workspaces',
+ 'org.gnome.mutter');
+}
+
+function disable() {
+ // Restore gnome-shell's overrides
+ Meta.prefs_override_preference_schema('dynamic-workspaces',
+ 'org.gnome.shell.overrides');
+}
diff --git a/extensions/static-workspaces/metadata.json.in b/extensions/static-workspaces/metadata.json.in
new file mode 100644
index 0000000..fda157c
--- /dev/null
+++ b/extensions/static-workspaces/metadata.json.in
@@ -0,0 +1,11 @@
+{
+"extension-id": "@extension_id@",
+"uuid": "@uuid@",
+"settings-schema": "@gschemaname@",
+"gettext-domain": "@gettext_domain@",
+"name": "Static workspaces",
+"description": "Disable dynamic workspace management",
+"original-authors": [ "fmuellner gnome org" ],
+"shell-version": [ "@shell_current@" ],
+"url": "@url@"
+}
diff --git a/extensions/static-workspaces/stylesheet.css b/extensions/static-workspaces/stylesheet.css
new file mode 100644
index 0000000..25134b6
--- /dev/null
+++ b/extensions/static-workspaces/stylesheet.css
@@ -0,0 +1 @@
+/* This extensions requires no special styling */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]