Updating the list of entries in a RibbonComboBoxProjection? #553
-
|
In our application, we have configured a RibbonComboBoxContentModel to contain a list of items, added it to a RibbonComboBoxProjection, and then added the projection to a JFlowRibbonBand. During runtime, we have a need to occasionally update/change the list of items. I realize the model is intended to be immutable. Short of removing the projection from the band and replacing it with an updated projection (or maybe removing the content model from the projection and replacing it), is there an elegant means to accomplish this? Replacing the projection/model seems very likely to cause visual, focus, and state side effects. |
Beta Was this translation helpful? Give feedback.
Replies: 7 comments 5 replies
-
|
How does this look like with a core |
Beta Was this translation helpful? Give feedback.
-
|
With these wrappers, I'm not looking to replace the core Swing components. So if there's nothing "nice" in the default combobox model, I won't be reinventing that wheel here in Radiance. |
Beta Was this translation helpful? Give feedback.
-
|
No, there is no intention here to add more wrappers for the core Swing |
Beta Was this translation helpful? Give feedback.
-
|
What I meant was that everything under These blueprints do not aim to wrap all existing use cases of the more complex components such as comboboxes and spinners, but are more of a starting point for app-specific exploration. |
Beta Was this translation helpful? Give feedback.
-
|
Depends on the complexity of it. Long time ago I had a large code contribution for editable combobox auto-completion, and it was difficult to meaningfully maintain it over the years since I never got into the deeper details of it. I ended up removing it altogether a few years ago. |
Beta Was this translation helpful? Give feedback.
-
|
We were able to solve our problem without modification to the Radiance library. All that was needed was to switch from using the |
Beta Was this translation helpful? Give feedback.
-
|
There's nothing negative or positive about |
Beta Was this translation helpful? Give feedback.
We were able to solve our problem without modification to the Radiance library. All that was needed was to switch from using the
RibbonComboBoxContentModelinterface to theRibbonDefaultComboBoxContentModelclass as the class makes the add/remove methods accessible. We could instead modify theRibbonComboBoxContentModelinterface to include custom mutator methods, but I don't see a need to mess with the library functionality. I'm just wondering whether any negative impact of the switch toRibbonDefaultComboBoxContentModelis foreseen.