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

Add Delete All button to ItemList editor #44352

Merged
merged 1 commit into from
Sep 24, 2021

Conversation

KoBeWi
Copy link
Member

@KoBeWi KoBeWi commented Dec 13, 2020

Closes godotengine/godot-proposals#1975
chUdP56gyn

Loosely depends on #33300, which loosely depends on #43872

@@ -350,6 +357,11 @@ ItemListEditor::ItemListEditor() {

hbc->add_spacer();

clear_button = memnew(Button);
Copy link
Contributor

@EricEzaM EricEzaM Dec 14, 2020

Choose a reason for hiding this comment

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

Should the name in the code match the name given in the display? For consistency?

delete_all_button, _delete_all_pressed()

Copy link
Member Author

Choose a reason for hiding this comment

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

Maybe. I thought it's easier to distinguish this way.

@akien-mga
Copy link
Member

Maybe there should be a confirmation dialog mentioning how many entries will be removed?

@KoBeWi
Copy link
Member Author

KoBeWi commented Dec 14, 2020

I could add the dialog, but IMO it would be better if we could just undo it.

Copy link
Member

@Calinou Calinou left a comment

Choose a reason for hiding this comment

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

The implementation looks good to me, but this shouldn't be merged until undo/redo support for the ItemList editor is merged (or a confirmation dialog is added).

Adding a confirmation dialog will also make this cherry-pickable to the 3.x branch.

@reduz
Copy link
Member

reduz commented Aug 30, 2021

I think the plan is now to refactor the itemlist and other similar nodes to be edited directly on the inspector with the new upcoming PR from @groud. As such, I think it may make more sense to close this? What do you think?

@akien-mga
Copy link
Member

As such, I think it may make more sense to close this? What do you think?

I think it doesn't hurt to merge this in the meantime, if this is refactored to be integrated in the Inspector, the whole file will be removed/redone anyway.

@akien-mga
Copy link
Member

Needs a rebase.

@akien-mga akien-mga merged commit 89c718c into godotengine:master Sep 24, 2021
@akien-mga
Copy link
Member

Thanks!

@KoBeWi KoBeWi deleted the ItemList🔥🔥🔥🔥🔥 branch September 24, 2021 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add a clear button to the item list editor
5 participants