CLEANUP: removed preferences -> not needed

This commit is contained in:
2024-07-01 10:28:48 +01:00
parent faaf3a4840
commit d6a850c3d8
8 changed files with 1 additions and 146 deletions

4
.gitignore vendored
View File

@@ -1,4 +1,2 @@
**node_modules
package-lock.json
floatbar.zip
**.compiled
package-lock.json

10
dist/metadata.json vendored
View File

@@ -1,10 +0,0 @@
{
"name": "float bar",
"description": "Adaptive floating topbar",
"uuid": "floatbar@tomtroeger.de",
"settings-schema": "org.gnome.shell.extensions.my-extension",
"shell-version": [
"46"
]
}

42
dist/prefs.js vendored
View File

@@ -1,42 +0,0 @@
import Gtk from "gi://Gtk";
import Adw from "gi://Adw";
import Gio from "gi://Gio";
import { ExtensionPreferences, gettext as _ } from "resource:///org/gnome/Shell/Extensions/js/extensions/prefs.js";
export default class GnomeRectanglePreferences extends ExtensionPreferences {
_settings;
fillPreferencesWindow(window) {
this._settings = this.getSettings();
const page = new Adw.PreferencesPage({
title: _("General"),
iconName: "dialog-information-symbolic",
});
const animationGroup = new Adw.PreferencesGroup({
title: _("Animation"),
description: _("Configure move/resize animation"),
});
page.add(animationGroup);
const animationEnabled = new Adw.SwitchRow({
title: _("Enabled"),
subtitle: _("Floating Window"),
});
animationGroup.add(animationEnabled);
const paddingGroup = new Adw.PreferencesGroup({
title: _("Paddings"),
description: _("Configure the padding between windows"),
});
page.add(paddingGroup);
const paddingInner = new Adw.SpinRow({
title: _("Inner"),
subtitle: _("Padding between windows"),
adjustment: new Gtk.Adjustment({
lower: 0,
upper: 1000,
stepIncrement: 1,
}),
});
paddingGroup.add(paddingInner);
window.add(page);
this._settings.bind("float", animationEnabled, "active", Gio.SettingsBindFlags.DEFAULT);
this._settings.bind("padding-inner", paddingInner, "value", Gio.SettingsBindFlags.DEFAULT);
}
}

View File

@@ -1,15 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<schemalist>
<schema id="org.gnome.shell.extensions.my-extension" path="/org/gnome/shell/extensions/my-extension/">
<key name="padding-inner" type="i">
<default>8</default>
<summary>Inner padding</summary>
<description>Padding between windows</description>
</key>
<key name="float" type="b">
<default>true</default>
<summary>Floating</summary>
<description>Whether the topbar floats or not</description>
</key>
</schema>
</schemalist>

9
dist/stylesheet.css vendored
View File

@@ -1,9 +0,0 @@
#panel.floating {
margin: 3px;
border-radius: 9999px;
}
#panel.solid {
margin: 0;
border-radius: 0;
}

View File

@@ -1,51 +0,0 @@
import Gtk from "gi://Gtk";
import Adw from "gi://Adw";
import Gio from "gi://Gio";
import { ExtensionPreferences, gettext as _ } from "resource:///org/gnome/Shell/Extensions/js/extensions/prefs.js";
export default class GnomeRectanglePreferences extends ExtensionPreferences {
_settings?: Gio.Settings;
fillPreferencesWindow(window: Adw.PreferencesWindow) {
this._settings = this.getSettings();
const page = new Adw.PreferencesPage({
title: _("General"),
iconName: "dialog-information-symbolic",
});
const animationGroup = new Adw.PreferencesGroup({
title: _("Animation"),
description: _("Configure move/resize animation"),
});
page.add(animationGroup);
const animationEnabled = new Adw.SwitchRow({
title: _("Enabled"),
subtitle: _("Floating Window"),
});
animationGroup.add(animationEnabled);
const paddingGroup = new Adw.PreferencesGroup({
title: _("Paddings"),
description: _("Configure the padding between windows"),
});
page.add(paddingGroup);
const paddingInner = new Adw.SpinRow({
title: _("Inner"),
subtitle: _("Padding between windows"),
adjustment: new Gtk.Adjustment({
lower: 0,
upper: 1000,
stepIncrement: 1,
}),
});
paddingGroup.add(paddingInner);
window.add(page);
this._settings!.bind("float", animationEnabled, "active", Gio.SettingsBindFlags.DEFAULT);
this._settings!.bind("padding-inner", paddingInner, "value", Gio.SettingsBindFlags.DEFAULT);
}
}

View File

@@ -1,15 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<schemalist>
<schema id="org.gnome.shell.extensions.my-extension" path="/org/gnome/shell/extensions/my-extension/">
<key name="padding-inner" type="i">
<default>8</default>
<summary>Inner padding</summary>
<description>Padding between windows</description>
</key>
<key name="float" type="b">
<default>true</default>
<summary>Floating</summary>
<description>Whether the topbar floats or not</description>
</key>
</schema>
</schemalist>

View File

@@ -15,6 +15,5 @@
],
"files": [
"extension.ts",
"prefs.ts"
],
}