don-tnowe / godot-inspector-extender

Using just comments, add specialized inspectors for your Godot 4 scripts.
MIT License
97 stars 8 forks source link

Open dictionary seems to break show_if #11

Closed EnigmaEmmy closed 2 months ago

EnigmaEmmy commented 2 months ago

Opening or having a dictionary open when you select the node seems to prevent the show_if from working:

Screen Recording 2024-08-31 213456

don-tnowe commented 2 months ago

Additional details:

don-tnowe commented 2 months ago

Found it. It's caused by _can_handle called when a Dictionary is opened, passing the created property editor. Normally, it would pass the edited object (here this would be the dictionary), so it's just unusual engine behaviour. Though I think I see the use case.

HOWEVER, it also breaks when a subresource is opened, and it is my own code's problem and I will fix it now.