View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0037668||Lazarus||IDE||public||2020-08-31 00:44||2020-10-22 15:36|
|Reporter||Manlio||Assigned To||Juha Manninen|
|Platform||Windows and Mac|
|Summary||0037668: When reloading files changed on disk, IDE doesn't reload changes in LFM|
|Description||While a file e.g. UNIT1 is open in the IDE, and both PAS and LFM are modified on disk (e.g. by SVN Update), and you accept the prompt to reload the file from the disk, the source code (PAS file) is indeed reloaded, but the form (LFM) is not. The old form remains loaded in the IDE. |
Only if you immediately manually close and reopen UNIT1, the new form is indeed reloaded. But if you make any changes to the form (e.g. add components, change size, etc.) then these changes will overwrite the changes on the disk, and all the changes received (e.g. via SVN Update) will be lost, and quite possibly break the build because there may no longer be a correspondence between components in the LFM and components in the source code.
|Steps To Reproduce||1. Have Unit1 with a form and a button and some code, open in the IDE.|
2. Do a Subversion Update, in which Unit1 code has changed -- BOTH in the unit1.pas and in unit1.lfm. Let's say that a new button has been added to the form.
(Alternatively, manually change both .pas and .lfm files, in a text editor, while the IDE is also open)
3. When you go back to the IDE, you will receive the warning that the file on disk has changed, and you will be prompted to reload it. So far, so good.
4. Choose to reload the changed files from disk. This is where the bug takes place:
The unit1.pas file with the new code is indeed reloaded, but the form, from unit1.lfm, is NOT reloaded. You still see the old form with 1 button.
5. The work-around for this bug is to close unit1 immediately from the IDE, and then reopen it. Now the new new form, with two buttons, will be loaded.
6. Note: if you don't immediately close and reopen unit1 manually, if the form is changed in any way, e.g. the position on the screen, or components changed, then this change will overwrite any changes received with the Update -- indeed you will never even see the changes in the form that should have been reloaded with unit1 after the Update.
|Additional Information||I noted this problem on both Windows and MacOS IDEs, versions 2.0.6 and 2.0.10 respectively.|
The solution, obviously, is that after prompting the user to reload the changed files, both the source code (.pas) and the form file (lfm) should be reloaded, and not only the .pas file
|Tags||No tags attached.|
|Fixed in Revision||r64048|
|2020-08-31 00:44||Manlio||New Issue|
|2020-09-02 17:36||Juha Manninen||Relationship added||related to 0021587|
|2020-10-09 20:41||Juha Manninen||Assigned To||=> Juha Manninen|
|2020-10-09 20:41||Juha Manninen||Status||new => assigned|
|2020-10-22 15:36||Juha Manninen||Status||assigned => resolved|
|2020-10-22 15:36||Juha Manninen||Resolution||open => fixed|
|2020-10-22 15:36||Juha Manninen||Fixed in Revision||=> r64048|
|2020-10-22 15:36||Juha Manninen||LazTarget||=> -|
|2020-10-22 15:36||Juha Manninen||Note Added: 0126460|
|2020-10-22 15:36||Juha Manninen||Relationship replaced||duplicate of 0021587|