♻️ refactor: reorganize windows and widgets in a modular way

plus, better code for bluetooth device pairing and connecting
This commit is contained in:
retrozinndev
2025-09-25 13:19:52 -03:00
parent 7f3e66cc71
commit ba83c673aa
37 changed files with 186 additions and 176 deletions
+2 -2
View File
@@ -1,16 +1,16 @@
import { Gtk } from "ags/gtk4";
import { Wireplumber } from "./volume";
import { Windows } from "../windows";
import { restartInstance } from "./reload-handler";
import { timeout } from "ags/time";
import { Runner } from "../runner/Runner";
import { showWorkspaceNumber } from "../widget/bar/Workspaces";
import { showWorkspaceNumber } from "../window/bar/widgets/Workspaces";
import { playSystemBell } from "./utils";
import { player, setPlayer } from "./media";
import { generalConfig, Shell } from "../app";
import AstalIO from "gi://AstalIO";
import AstalMpris from "gi://AstalMpris";
import { Gtk } from "ags/gtk4";
export type RemoteCaller = {
+5
View File
@@ -32,6 +32,11 @@ export class Bluetooth extends GObject.Object {
createRoot((_) => {
this.#scope = getScope();
if(this.astalBl.adapters.length > 0) {
this.#isAvailable = true;
this.notify("is-available");
}
this.#connections.set(
AstalBluetooth.get_default(),
AstalBluetooth.get_default().connect("adapter-added", (self, adapter) => {