Skip to content

Is there a way to deregister a GJS subclass type? #570

Answered by rcalixte
klangman asked this question in Development
Discussion options

You must be logged in to vote

I dealt with this for another applet. The source file should help you here. I ended up just hacking around the class name with the random value and that resolved the class register/deregister conundrum. (You can add logging to the applet and see the class names for how it registers/deregisters if you're curious.)

It's a hack because as you can imagine, it has the potential to waste memory for each register/deregister until Cinnamon is reloaded but as it isn't much memory and the number of events for it to matter would need to be rather extreme, it was a tradeoff I could live with. If your next applet (can't wait!) will require frequent and constant adjusting, it may not work. If the apple…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by klangman
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants