View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0002363||JEDI VCL||00 JVCL Components||public||2004-12-06 07:52||2005-08-10 08:28|
|Target Version||Fixed in Version|
|Summary||0002363: TjvFormStorage slow down its owner form on display/close|
|Description||TjvFormStorage is a very useful component. I drop it on many of my forms. But this component slow the display and the close (Hide) of its owner form. In fact, when active is true, it performs a â€œSaveâ€ on every OnCloseQuery Event and does a â€œRestoreâ€ on every OnShowEvent of its owner form. I donâ€™t understand the utility of such â€œsaveâ€ and â€œrestoreâ€.|
I suggest modifying this component to do when itâ€™s active a:
- â€œRestoreâ€ just after its owner onCreate event.
- â€œSaveâ€ just before its owner OnDesrtroy event.
- Remove the redirection events of owner form: OnCloseQuery and OnShow.
For test and more information, here is my owner derived component of TjvFormStorage.
|Tags||No tags attached.|
PxFormStorage.pas (3,427 bytes)
And When there are no modiofication's to save, do not save it anyway.
I Uses it to modify my application settings, normol users have no write access to the aplication path and get a error after clossing.
To anonymous: Use OnRestorePlacement event to set Active to false when user have no write access to your application path. this is : TjvFormStorage(Sender).active := False.
When active is false no more save well be done any more after the first restore.
||For prevention of write down, you can also use JvAppStorage.Readonly := TRUE;|
Anyone else with comments?
For me the FormShow, FormOnClose Events are better. But i'm not shure.
Close is not always called, especially when the system is shutting down.
As to the initial bug, I don't like the proposed modifications, I'd rather have the user deactivate the TJvFormStorage from the appropriate event (or even constructor).
||See my last remark.|
|2004-12-06 07:52||nestor||New Issue|
|2004-12-06 07:52||nestor||File Added: PxFormStorage.pas|
|2004-12-06 14:54||anonymous||Note Added: 0005836|
|2004-12-06 15:23||nestor||Note Added: 0005837|
|2004-12-08 00:31||jfudickar||Note Added: 0005840|
|2004-12-14 00:17||jfudickar||Note Added: 0005880|
|2004-12-20 07:07||obones||Note Added: 0005960|
|2004-12-20 07:07||obones||Status||new => feedback|
|2005-08-10 08:28||obones||Status||feedback => resolved|
|2005-08-10 08:28||obones||Resolution||open => won't fix|
|2005-08-10 08:28||obones||Assigned To||=> obones|
|2005-08-10 08:28||obones||Note Added: 0007781|