Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix update property for dictionaries so that it updates only what is necessary. #88231

Merged
1 commit merged into from
Mar 24, 2024

Conversation

ajreckof
Copy link
Member

@ajreckof ajreckof commented Feb 12, 2024

This is the dictionary counter part of #80706.

This is a small step towards #76078 as I decided to break it into smaller pieces for it to be easier to make and review.

The last part could be removed from this PR if needed, I would then update #87140 once this PR is merged with what I removed from here. See #87140 (comment) for why the array parts are linked to dictionnary parts

@akien-mga akien-mga added this to the 4.3 milestone Feb 12, 2024
@fire fire changed the title Fix update property for dictionnaries so that it updates only what is necessary. Fix update property for dictionaries so that it updates only what is necessary. Feb 12, 2024
@ajreckof ajreckof force-pushed the fix-copy-paste-for-dictionnaries branch 3 times, most recently from 5dc1034 to fcd1d4e Compare February 25, 2024 14:45
@KoBeWi
Copy link
Member

KoBeWi commented Mar 6, 2024

It breaks dragging elements to other pages:

godot.windows.editor.dev.x86_64_f34FnBck1Z.mp4

@ajreckof ajreckof force-pushed the fix-copy-paste-for-dictionnaries branch from fcd1d4e to fa4c0d7 Compare March 8, 2024 16:48
@ajreckof
Copy link
Member Author

ajreckof commented Mar 8, 2024

It breaks dragging elements to other pages:

godot.windows.editor.dev.x86_64_f34FnBck1Z.mp4

Fixed

@ajreckof ajreckof force-pushed the fix-copy-paste-for-dictionnaries branch from fa4c0d7 to 625ac20 Compare March 8, 2024 16:49
editor/editor_properties_array_dict.cpp Outdated Show resolved Hide resolved
editor/editor_properties_array_dict.cpp Outdated Show resolved Hide resolved
editor/editor_properties_array_dict.cpp Outdated Show resolved Hide resolved
editor/editor_properties_array_dict.cpp Outdated Show resolved Hide resolved
@ajreckof ajreckof force-pushed the fix-copy-paste-for-dictionnaries branch from d6ae21d to 08b8782 Compare March 8, 2024 17:22
@KoBeWi
Copy link
Member

KoBeWi commented Mar 20, 2024

Fixed

It's still a little bugged 🤔

godot.windows.editor.dev.x86_64_ThlgrE8Clj.mp4

The original element gets focused once drag ends. But at least it's moved correctly, so maybe it's fine for now.

void set_index(int p_idx) {
index = p_idx;
switch (index) {
case -2:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The magic number should likely be replaced with a constant.

@ajreckof
Copy link
Member Author

Fixed

It's still a little bugged 🤔

godot.windows.editor.dev.x86_64_ThlgrE8Clj.mp4
The original element gets focused once drag ends. But at least it's moved correctly, so maybe it's fine for now.

This was not introduced by this PR(present on master). Should be easy to fix though. Do you think I should add the fix in this PR or create a separate issue/PR?

@KoBeWi
Copy link
Member

KoBeWi commented Mar 20, 2024

If it's pre-existing, you can open an issue (if it wasn't reported already).

@ajreckof ajreckof force-pushed the fix-copy-paste-for-dictionnaries branch from 08b8782 to 0331ecb Compare March 21, 2024 18:31
akien-mga added a commit that referenced this pull request Mar 24, 2024
Fix update property for dictionaries so that it updates only what is necessary.
@akien-mga akien-mga closed this pull request by merging all changes into godotengine:master in 06abc86 Mar 24, 2024
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants