Code Monkey home page Code Monkey logo

Comments (4)

CorvetteCole avatar CorvetteCole commented on May 16, 2024

If I am missing something obvious which explains this, please let me know. I am going to work on creating a solution to this

from blur-my-shell.

CorvetteCole avatar CorvetteCole commented on May 16, 2024

I think the easiest solution to this would be to hold a list of Connections classes in the main extension.js file, then iterate through those when we do an extension disable and call disconnect_all() on all of them. Then in each class we could call disconnect_all() in disable and that would only disconnect the signals from that class.

from blur-my-shell.

CorvetteCole avatar CorvetteCole commented on May 16, 2024

Also on that note, we aren't allowed to do anything in init(), including creating objects. See here: https://wiki.gnome.org/Projects/GnomeShell/Extensions/Review. We need to move these settings and connections object creations elsewhere anyways. I will implement these changes

from blur-my-shell.

aunetx avatar aunetx commented on May 16, 2024

Sorry for the late responses, I really needed (and still need) to work :p and thanks for working so much on the extension!
You're right, the signal are not disconnected until the extension is disabled... I though that this was probably not too bad, as they were at least cleaned up after disabling the extension, but this is obviously not a clean solution
I guess the simplest thing would be to create a different Connections class for each element, and then make sure to remove all of them when extension is disabled!

For the init() part, sorry I though it was ok to create objects if they did not do anything to the shell! Do you think we will need to create them in enable() then?

from blur-my-shell.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.