Live data from Hacker News

Replacing My Window Manager with Google Chrome

foxmoss.com

21–30 of 32 posts

Re: Replacing My Window Manager with Google Chrome

#21
post #11
post #10

This is a pretty neat idea, and shows that maybe a desktop environment could be a lot more flexible than we're used to if it was based on something flexible. Not exactly counter intuitive. I'd like to see how complex a CEF-based Wayland compositor would be in comparison. How about using Godot instead of CEF? It has a pretty full-featured UI system. So many possibilities.

While you're at it, go on a huge tangent writing a library that allows one implementation to work as both an X11 and Wayland compositor. Actually why stop there? Make said library also compile to a full screen Windows and Macos application that somehow renders the contents of windows to textures and does event handing etc. that way you can write your desktop environment once and use it everywhere. I've gone crazy wit…

[deleted]

Re: Replacing My Window Manager with Google Chrome

#23
post #17
post #9

This is based on the Chromium Embedded Framework. I've always been surprised this kind of framework was not encouraged for Firefox by Mozilla (I've read they were even against it).

Before they got rid of XUL, this was the sort of thing possible with it.

Exactly, this sort of thing was the whole idea of XUL.

It was a little too flexible to make secure and fast though.

Re: Replacing My Window Manager with Google Chrome

#24

I looked around the Windows skin source but I guess I'm too dumb for it because this line makes no sense to me https://github.com/FoxMoss/dote-dreamland-win95-example/blob...

I strongly suspect I know what that does because I worked with Svelte 4 for years (you no longer have to do this in Svelte 5. I can recommend Svelte 5, it's nice).

Basically, assigning a state to itself tells it to signal that that state has changed and update anything that is listening to it. The `state` object is actually a JS Proxy returned by createState [0], which allows intercepting the assignment to the `windows` property and emit signals. Usually you dont have to do that, but in this case, the proxy doesn't notice that `state.windows.push(X)` is a mutation. Only assignments directly to the state object count as mutations.

TLDR, `state.windows = state.windows` tells the framework that `windows` changed.

[0]: https://github.com/MercuryWorkshop/dreamlandjs/blob/1e7a34a1...

Re: Replacing My Window Manager with Google Chrome

#25
post #24

I looked around the Windows skin source but I guess I'm too dumb for it because this line makes no sense to me https://github.com/FoxMoss/dote-dreamland-win95-example/blob...

I strongly suspect I know what that does because I worked with Svelte 4 for years (you no longer have to do this in Svelte 5. I can recommend Svelte 5, it's nice). Basically, assigning a state to itself tells it to signal that that state has changed and update anything that is listening to it. The `state` object is actually a JS Proxy returned by createState [0], which allows intercepting the assignment to the `windo…

I was drafting a reply when you sent this, this is the correct interpretation and why I did it.

Re: Replacing My Window Manager with Google Chrome

#26

I believe the earlier versions of Chrome/Chromium OS took this to the logical extreme. https://www.technologyreview.com/2009/11/19/208062/google-gi...

This reminds me of the Windows 8 version they had for a short time where you got a full-blown ChromeOS "clone" when launching the Metro version: https://www.howtogeek.com/179980/how-to-use-the-chrome-os-de...

How bizarre. Thanks for sharing.

Re: Replacing My Window Manager with Google Chrome

#30
> On Linux this is mainly X11 written by MIT in 1984, it’s old and starting to show it’s age

"Windows 1.0 is the first major release of Microsoft Windows, a family of graphical user shells and operating systems for personal computers developed by Microsoft. It was first released to manufacturing in the United States on November 20, 1985"

So, I guess, Windows also is "starting to show it’s age". /s

Post reply on HN