Hi, I'm net to Qt and QML - this seems like a rather simple issue but I can't find a simple solution to it.

Say I have the following example QML

Qt Code:
  1. Item {
  2. ... lots of other stuff
  3.  
  4. Item {
  5. id: obj_container
  6.  
  7. property var obj
  8.  
  9. Text {
  10. text: obj.name
  11. }
  12.  
  13. Image {
  14. source: obj.source
  15. }
  16. }
  17. }
To copy to clipboard, switch view to plain text mode 

Now when the obj property becomes null, I would like to fade out the obj_container item, while still displaying the values it had before it was set to null.

Alternatively, if the obj item changes to a different obj, I would like to fade out the obj_container item (still displaying its previous values) and then fade it in again with the new values.

How would I go about this?