Fix unable to disconnect signal in Editor once created
Fixes https://github.com/godotengine/godot/issues/69348.
https://github.com/godotengine/godot/pull/66665's implementation was a bit too stupid and didn't account all cases. Most importantly, signals that had yet to be saved.
Do note the result of this function still isn't cached. It probably could and should be, but this is just about fixing this nuisance.
There is still a bug with this implementation. That is, a sub-scene's direct signals are considered to be editable, which they should not. It's possible I may be able to fix it efficiently in this PR, but it's still better than the current nuisance.
Seems like this PR makes it possible to disconnect foreign connections again...
Alright, back to work.
Thanks!
Seems like discarding instancing (using the Make Local option) doesn't remove the flag and the connections cannot be disconnected at all.
EDIT: Yep, the flag is incorrectly stored in the local scene. There is no way to remove it other than manually editing the tscn file. I'll open an issue I guess.