Skip to content

Implement DictionaryPropertyEdit .

Chen Tao requested to merge github/fork/jagt/dictionary_property_edit into master

This PR implements DictionaryPropertyEdit for editting exported dictionary properties (#10018 (closed)).
Here's a screenshot:

image

However there're some usability issues which I really need some help from you guys:

  1. Changing the size field won't work atm as I don't see a way for this to work for a dictionary. So currently there's no way to add/remove new items through the inspector. I think the most common way to handle this is to add a button/widget to add new items, but I don't find a way to add button in inspector/.
  2. Can't handle duplicated keys. If one change a key to be equal to a existing key, the dictionary will actually shrink the dictionary by one. I don't really know how to handle this through the UI. Should duplicate key changes be ignored or report a error? Or I should simply make keys readonly.
  3. Changing keys will change item order. Maybe this can be fixed by adding data to track item orders.

Most of the problems are related to key editing. Your input on this will be really helpful.

Merge request reports