@@ -82,31 +82,21 @@ ClipboardCompositor {
8282 readonly property real sf: userScale * Math .max (0.5 , Math .min (2.5 , Math .min (root .width / 1024.0 , root .height / 768.0 )))
8383
8484 // ── Global State ──
85- property bool loggedIn: true
86- property string currentUser: " ainux "
87- property string sessionId: " system "
85+ property bool loggedIn: false
86+ property string currentUser: " "
87+ property string sessionId: " "
8888 property var openWindows: []
8989 property string settingsOpenTab: " " // Set before opening Settings to jump to a tab
9090
9191 // ── Open App helper (usable from Desktop, context menu, etc.) ──
9292 // searchName/cmd are optional — used for native app surface matching
9393 function openAppWindow (appId , title , icon , searchName , cmd ) {
9494 for (var i = 0 ; i < openWindows .length ; i++ ) {
95- if (openWindows[i].appId === appId) {
96- focusWindow (appId);
97- return ;
98- }
95+ if (openWindows[i].appId === appId) return ;
9996 }
10097 var wins = openWindows .slice ();
10198 wins .push ({ appId: appId, title: title, icon: icon, searchName: searchName || " " , cmd: cmd || " " });
10299 openWindows = wins;
103-
104- // Launch the native app immediately here (only once!)
105- var isNative = appId .indexOf (" native-" ) === 0 || appId .indexOf (" wayland-" ) === 0 ;
106- if (isNative && cmd && cmd .length > 0 ) {
107- console .log (" WhaleOS: Launching native app via openAppWindow:" , title, cmd);
108- sysManager .launchNativeApp (cmd);
109- }
110100 }
111101
112102 // ── Launch a native app directly (no loader window) ──
@@ -123,23 +113,23 @@ ClipboardCompositor {
123113 // ── API ──
124114 property string apiBase: " http://127.0.0.1:7777/dashboard/api"
125115
126- // ── Theme Constants — Warm Light ──
127- readonly property color bgVoid: " #f8f9fa "
128- readonly property color bgSurface: Qt . rgba ( 1 , 1 , 1 , 0.92 )
129- readonly property color bgElevated: Qt . rgba ( 1 , 1 , 1 , 0.96 )
130- readonly property color bgCard: Qt . rgba ( 1 , 1 , 1 , 0.85 )
131- readonly property color borderColor: Qt . rgba ( 0 , 0 , 0 , 0.08 )
132- readonly property color borderLight: Qt . rgba ( 0 , 0 , 0 , 0.05 )
133- readonly property color textPrimary: " #000000 "
134- readonly property color textSecondary: " #111827 "
135- readonly property color textMuted: " #374151 "
136- readonly property color accentBlue: " #2563eb "
137- readonly property color accentGreen: " #16a34a "
138- readonly property color accentRed: " #dc2626 "
139- readonly property color accentOrange: " #ea580c "
140- readonly property color accentPurple: " #7c3aed "
141- readonly property color accentPink: " #db2777 "
142- readonly property color accentCyan: " #0891b2 "
116+ // ── Theme Constants — Cyber Glass ──
117+ readonly property color bgVoid: " #030712 "
118+ readonly property color bgSurface: " #0a0e1a "
119+ readonly property color bgElevated: " #111827 "
120+ readonly property color bgCard: " #1a1f36 "
121+ readonly property color borderColor: " #1e293b "
122+ readonly property color borderLight: " #334155 "
123+ readonly property color textPrimary: " #f0f4ff "
124+ readonly property color textSecondary: " #94a3b8 "
125+ readonly property color textMuted: " #64748b "
126+ readonly property color accentBlue: " #00e5ff "
127+ readonly property color accentGreen: " #00e676 "
128+ readonly property color accentRed: " #ff1744 "
129+ readonly property color accentOrange: " #ff9100 "
130+ readonly property color accentPurple: " #b388ff "
131+ readonly property color accentPink: " #ff4081 "
132+ readonly property color accentCyan: " #00e5ff "
143133 readonly property int radiusSm: Math .round (6 * sf)
144134 readonly property int radiusMd: Math .round (10 * sf)
145135 readonly property int radiusLg: Math .round (14 * sf)
@@ -168,12 +158,6 @@ ClipboardCompositor {
168158 win .z = nextZ;
169159 }
170160
171- function focusWindow (appId ) {
172- if (desktopLoader .status === Loader .Ready && desktopLoader .item ) {
173- desktopLoader .item .focusWindow (appId);
174- }
175- }
176-
177161 // ── Assign a Wayland surface to an AppWindow ──
178162 function assignSurface (toplevel , xdgSurface ) {
179163 // Try immediate match first
@@ -187,26 +171,17 @@ ClipboardCompositor {
187171 }
188172
189173 function tryMatchSurface (toplevel , xdgSurface ) {
190- var appTitle = (toplevel .title || " " ).toLowerCase ();
191- var appId = (toplevel .appId || " " ).toLowerCase ();
192-
193- // Skip background/helper utilities (like clipboard bridge)
194- var isBackground = (appId .indexOf (" clipboard" ) >= 0 || appTitle .indexOf (" clipboard" ) >= 0 ||
195- appId .indexOf (" cutsel" ) >= 0 || appTitle .indexOf (" cutsel" ) >= 0 ||
196- appId .indexOf (" xclip" ) >= 0 || appTitle .indexOf (" xsel" ) >= 0 );
197- if (isBackground) {
198- console .log (" WhaleOS: Ignoring background helper surface:" , toplevel .title , toplevel .appId );
199- return true ; // consume and discard
200- }
174+ var appTitle = toplevel .title || " " ;
175+ var appId = toplevel .appId || " " ;
201176
202177 // First: try to match an existing AppWindow waiting for a surface
203178 for (var i = 0 ; i < openWindows .length ; i++ ) {
204179 var win = openWindows[i];
205180 if (win .appId && win .appId .indexOf (" native-" ) === 0 && ! win .surface ) {
206181 var searchName = win .searchName || " " ;
207182 if (searchName .length > 0 && (appTitle .length > 0 || appId .length > 0 ) &&
208- (appTitle .indexOf (searchName .toLowerCase ()) >= 0 ||
209- appId .indexOf (searchName .toLowerCase ()) >= 0 )) {
183+ (appTitle .toLowerCase (). indexOf (searchName .toLowerCase ()) >= 0 ||
184+ appId .toLowerCase (). indexOf (searchName .toLowerCase ()) >= 0 )) {
210185 var wins = openWindows .slice ();
211186 wins[i] = {
212187 appId: win .appId ,
@@ -226,8 +201,8 @@ ClipboardCompositor {
226201 // Second: auto-create an AppWindow for this surface
227202 // Skip empty/clipboard surfaces that have no title or appId
228203 if (! appTitle && ! appId) {
229- console .log (" WhaleOS: Empty surface title/appId — return false to retry matching " );
230- return false ;
204+ console .log (" WhaleOS: Ignoring empty WlShell surface (likely clipboard/system) " );
205+ return true ; // consume but don't create a window
231206 }
232207 root .autoSurfaceCounter ++ ;
233208 var windowTitle = appTitle || appId || " App" ;
@@ -312,7 +287,7 @@ ClipboardCompositor {
312287 toastIcon .text = " ✕" ;
313288 toastIcon .color = " #fff" ;
314289 } else {
315- toastBg .color = Qt .rgba (0.22 , 0.74 , 0.97 , 0.92 );
290+ toastBg .color = Qt .rgba (0.0 , 0.90 , 1.0 , 0.92 );
316291 toastIcon .text = " ℹ" ;
317292 toastIcon .color = " #030712" ;
318293 }
@@ -334,7 +309,7 @@ ClipboardCompositor {
334309 Rectangle {
335310 id: toastBg
336311 anchors .fill : parent; radius: Math .round (12 * root .sf )
337- color: Qt .rgba (0.22 , 0.74 , 0.97 , 0.92 )
312+ color: Qt .rgba (0.0 , 0.90 , 1.0 , 0.92 )
338313
339314 Row {
340315 id: toastRow
0 commit comments