jQuery UI Widgets Forums Editors Button, RepeatButton, ToggleButton, LinkButton buttongroup delete+add buttons dynamically

This topic contains 2 replies, has 2 voices, and was last updated by  Dimitar 10 years, 4 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • buttongroup delete+add buttons dynamically #59337

    fimbul
    Participant

    I’m looking to use buttongroup as a breadcrumbs-type widget (I think there should be an appropriate widget for this, by the way), and I can’t find a way to add and remove buttons from the widget. I know I can disable and enable specific buttons, but adding/removing them seems to be impossible, especially since I lose access to the underlying button elements.

    I tried removing the divs that jqxButtonGroup creates, and that works to an extent, but it not only breaks the widget’s style, it also is probably going to break the entire widget.

    Is there a way to do that or should I be using some other widgets to create my breadcrumbs?

    buttongroup delete+add buttons dynamically #59339

    fimbul
    Participant

    I figured I can just delete the DIVs and call the jqxButtonGroup(“render”) method to “fix” it visually. However, doing so changes the underlying structure of the widget, thus making it harder and harder to inject elements.

    I’m also not sure if I should be adding/removing buttons by adding prebaked div elements to it.

    buttongroup delete+add buttons dynamically #59352

    Dimitar
    Participant

    Hello fimbul,

    Unfortunately, adding buttons to a button group dynamically is not supported. You may try destroying the widget and creating it with the updated number of buttons, if that suits your purposes.

    Best Regards,
    Dimitar

    jQWidgets team
    http://www.jqwidgets.com/

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.