linuxmint/cjs

[Question] is it possible to render desklets in an applet?

Closed this issue · 7 comments

Is it possible to load/render desklets (not those existing in the desktop/wrapper, but any) in an applet?

ChatGPT told me it is possible and even provided me an applet code supporting that; but as it is known, GPT sometimes get so creative at point of having hallucinations that can't be realistic implementations.

Theoretically sure - there's no reason you can't take the contents of a desklet and shove it into an applet box, though who knows what side-effects you'll have with it - it's all the same types of actors, part of the same overall 'stage'. I wouldn't expect it to work right though without some work... I guess I'd think of it as, if I had a desklet whose functionality I wanted on my panel, I'd make a new applet and adapt the guts from the desklet into it.

@mtwebster I mean, an applet rendering its own desklet container (similar to how the Windows 11's widgets "applet" do).

I haven't used windows 11, but there's nothing technically to prevent you doing anything like that - you can replace the entire desktop if you wanted.

For example, can an applet's button instead of displaying only icon/text, also displaying a text input?

There are different classes of Applet - icon, text, icon+text, and a generic 'do whatever you want' class js/ui/applet.js. Getting keyboard focus to work right might be tricky but it's doable I'm sure.

@mtwebster Just imagined that for your Internet Search applet, with a search box text input right on the panel.