how do I build a list-multi-select widget using a box with operators? What I'm trying to do is write a ui for an export script to export multiple selected actions of the selected armature(s) to multiple files.

I can't seem to find an example to define an operator for use in a layout.box() instance which can be selected like the layout.template_list() widget.

Of course, I'm working with a python list of gathered actions, so that widget is out of the question, since Blender has no internal support for this.

So, how do I define an operator which can be "selected" from a box widget?

Mockup of what I'm working with:

definitely draw(this, context ):

    # not typing the gathering code.

    box = layout.box()
    for action in gathered_actions:
        row = box.row()
        row.label( text=action.name, translate=False, icon="ACTION" ) # what I currently have.


I want to replace the label with an operator, but don't know how to build the operator.

Might I note, I'm not experienced with blender, just python, so I'm delving into a new area with this.
Ok, so after some reviewing and paying around with stuff...

The short answer is forget about it...
blender's api just doesn't have enough thought put into it, and what's needed simply doesn't exist.

The long answer, build a collection property and wrap it with a pointer property for use in a template_list.

Here's my code for it with an example showing it in action:


Sorry my code is an image...
phone's can only do so much...

So I think that makes me the first to do something like this :)

Now if only I could get active selections to have a blue background rather than white text. >_>