DetailFrameController#
- class omni.kit.window.filepicker.DetailFrameController(
- glyph: str = None,
- build_fn: Callable[[], None] = None,
- selection_changed_fn: Callable[[List[str]], None] = None,
- filename_changed_fn: Callable[[str], None] = None,
- destroy_fn: Callable[[], None] = None,
- **kwargs,
Bases:
objectMethods
__init__([glyph, build_fn, ...])Initialize the Detail Frame.
build_header(collapsed, title)Builds the header.
build_ui(frame)Builds the UI.
destroy()Destructor
on_filename_changed(filename)Called when the filename has changed.It will rebuild the detail frame.
on_selection_changed([selected])Called when the selection changes.
- __init__(
- glyph: str = None,
- build_fn: Callable[[], None] = None,
- selection_changed_fn: Callable[[List[str]], None] = None,
- filename_changed_fn: Callable[[str], None] = None,
- destroy_fn: Callable[[], None] = None,
- **kwargs,
Initialize the Detail Frame.
- Keyword Arguments:
glyph (Optional[str]) – The name of the glyph to use for the widget.
build_fn (Callable) – A function that will be called when build the detail frame. Function signature:void build_fn()
selection_changed_fn (Callable) – A function that will be called when the selection changes. Function signature:void selection_changed_fn(list[str])
filename_changed_fn (Callable) – A function that will be called when the filename of current item changes. Function signature:void filename_changed_fn(str)
destroy_fn (Callable) – A function that will be called when the widget is destroyed. Function signature:void destroy_fn()
- build_header(collapsed: bool, title: str)#
Builds the header. It is used to show the header of the DetailFrame. :param collapsed: True if the header is collapsed. :type collapsed: bool :param title: title of the header to be shown. :type title: str
- build_ui(frame: Frame)#
Builds the UI. :param frame: The frame that will be used to build the UI. :type frame: ui.Frame
- destroy()#
Destructor
- on_filename_changed(filename: str)#
Called when the filename has changed.It will rebuild the detail frame.
- Parameters:
filename (str) – The filename that has changed.
- on_selection_changed(
- selected: List[str] = [],
Called when the selection changes. It will rebuild the detail frame.
- Keywords Args:
selected(List[str]): List of selected items’s path.