During the last days (more or less) I worked on prototypes -Appstates and classes- on a specific topic with a lot of comments. I do this, so I can use this work later in different use cases and already have
notes that help me understanding the concepts behind - sorry im generation wikipedia, I forget fast.
I made a basic colorchooser using the nice example about meshes and learned a
bit about meshes and coloring.
While reading about the topic I found another approach using ImageRaster and setting pixels dot by dot.
I made both ways working. Changing a slider, clicking the color pic is both changing the shown values, textfields and the color quad…
Later I found @Eric_Bourque filebrowser and got inspired to make my own.
Insteadt of many labels I use a listbox (I recently modified listboxes), that is switching the highlight on/off - depending if it is a file or folder. The advantage is, that slider is already there as well as basic scroll behaviour. I just added basic keyboard usage (arrows) to move through a folder.
Insteadt of buttons this file browser uses mouse behaviour to change directories.
You can also copy and paste the desired directory to the URL-textfield.
Pictures alone are boring and I may need a way to make a model preview.
This topic comes up often in the forum and I found this very good library
from @NemesisMate Sharing of debug & lemur utils
that provide ViewportPanels.
It took me a while to understand all of it, but finaly I found a working example in the forum
that helped me to add the functioanlity to the filebrowser. Just for example reason
it is possible to multiselect models, that are then previewed (using Tweens to rotate).
Pls. sorry I do suck in graphics, so the shown example models dont have the best quality - as I just took them from internet.
While adding the function I realized that the Viewport did not change its position when the
Panel is moved. I modified @NemesisMate library (after hours of headache but learning something
about Viewports) and now you can move the window as much as you want and the model preview will follow the movement. Great if you want to make a moveable popup with an animated unit preview or similiar stuff.
I send NemesisMate my adjustements for his library (like 1 line per h headache). If someone is interessted in the code for the filebrowser I could make it more readable and provide it.