Note: You must be registered in order to post a reply. To register, click here. Registration is FREE!
T O P I C R E V I E W
zerob
Posted - Feb 07 2021 : 10:48:54 Is it possible to prevent a TImageEnFolderMView from scrolling down when adding new images with FillFromDirectory or adding them manually?
Having it scroll down, load the images there and then wait for a "AllDisplayed" event to do a "ViewY := 0" doesn't look that nice and loads images that don't need to be loaded yet as the ViewY should be 0.
I want my TImageEnFolderMView to start from top like the normal expected mode of windows lists like in the explorer or other tools.
3 L A T E S T R E P L I E S (Newest First)
xequte
Posted - Feb 07 2021 : 16:13:57 Hi
It should not be necessary to wait for OnAllDisplayed. You should be able to use:
Posted - Feb 07 2021 : 15:50:41 But how do i know when all files got loaded when i load them with FillFromDirectory(....LoadOnDemand = True....);
Right now i do wait for OnAllDisplayed and then scroll up with ViewY := 0
If i do a LockUpdate, then im unable to find out if tho know when to scroll up or do UnlockUpdate.
Right now if i do a Load FillFromDirectory(....LoadOnDemand = True....); it scrolls down, displays the images in view and then fires OnAllDisplayed. So i can scroll up.
But i don't want it to scroll down and load display the bottom most images but stay at top or scroll to top and only load these images (until the user scrolls down himself).
xequte
Posted - Feb 07 2021 : 15:37:45 Hi
You should lock the update when batch adding and then reset the position: