Coder Social home page Coder Social logo

Comments (3)

adrianinsaval avatar adrianinsaval commented on May 22, 2024

I this relevant? I think this use case is now covered well by the simple copy command, consider closing this issue

from freecad.

FlachyJoe avatar FlachyJoe commented on May 22, 2024

@wwmayer you tell me about this issue, do you think a Freezed state is needed for DocumentObject in order to prevent re-computation?
I had a look on the code and I think it's easy to implement.
A freezed object will always return false to mustRecompute() and it's properties will be readonly.

from freecad.

wwmayer avatar wwmayer commented on May 22, 2024

you tell me about this issue, do you think a Freezed state is needed for DocumentObject in order to prevent re-computation?

Unlike to my suggestion at that time I wouldn't use a PropertyBool any more because this has an extra cost of additional memory for every object type which is unused in 99% of all cases. I prefer to extend the ObjectStatus enum with a further value e.g. "NonParametric" or "Frozen" or whatever.

A frozen object will always return false to mustRecompute()

Yes.

and it's properties will be readonly

This will be a bit tricky because the flag can be reverted and there is no easy way to restore the original status of all properties. I would just leave the properties untouched. It should be checked if doing nothing inside DocumentObject::onChanged is sufficient.

from freecad.

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.