Notifications
Clear all
[Closed] Docking a rollout broke some of the UI
Aug 31, 2014 11:58 am
Double clicking in the MultiListBox doesn’t work any more when docked but right clicking work, strange !! :argh:
rollout CLst "test" width:165 height:650
(
button alnlft "<" pos:[3,3] width:15 height:15
button alnrgt ">" pos:[145,3] width:15 height:15
button alnmdl "=" pos:[43,3] width:80 height:15
MultiListBox lst "List:" pos:[8,65] width:144 height:23 items:#("one","two","three")
on alnlft pressed do
(
cui.RegisterDialogbar CLst style:#(#cui_dock_left, #cui_floatable, #cui_handles)
cui.DockDialogbar CLst #cui_dock_left
)
on alnrgt pressed do
(
cui.RegisterDialogbar CLst style:#(#cui_dock_right, #cui_floatable, #cui_handles)
cui.DockDialogbar CLst #cui_dock_right
)
on alnmdl pressed do
(
try (cui.UnRegisterDialogBar CLst) catch()
)
on lst doubleClicked itm do
(
print (lst.items[itm])
)
on lst rightClick itm do
(
print (lst.items[itm] + " right clicked")
)
)
createDialog CLst style:#(#style_toolwindow, #style_border, #style_sysmenu)
4 Replies
Aug 31, 2014 11:58 am
I found by accident that viewportcanvas docks nicely ,I searched for the script and got the code
you must create a floater first and then add the rollout also you do not need the docking buttons
The above code should be like this:
rollout CLst "test" width:165 height:650
(
MultiListBox lst "List:" pos:[8,65] width:144 height:23 items:#("one","two","three")
on lst doubleClicked itm do
(
print (lst.items[itm])
)
on lst rightClick itm do
(
print (lst.items[itm] + " right clicked")
)
)
CsMainFloater = newRolloutFloater "test dock" 170 700
addRollout CLst CsMainFloater border:true
cui.RegisterDialogBar CsMainFloater style:#(#cui_floatable, #cui_dock_left) --minSize:[236,100] maxSize:[236,1600]
cui.DockDialogBar CsMainFloater #cui_dock_left