mirror of
				https://gitlab.com/freepascal.org/lazarus/lazarus.git
				synced 2025-10-31 01:04:50 +01:00 
			
		
		
		
	* Detect name changes when loading (Bug ID #38452)
git-svn-id: trunk@57464 -
This commit is contained in:
		
							parent
							
								
									7f15e1c27b
								
							
						
					
					
						commit
						05534b1892
					
				| @ -268,6 +268,7 @@ type | |||||||
|     procedure VAlignExecute(Sender: TObject); |     procedure VAlignExecute(Sender: TObject); | ||||||
|     procedure VResizeExecute(Sender: TObject); |     procedure VResizeExecute(Sender: TObject); | ||||||
|   private |   private | ||||||
|  |     FLoadModified : Boolean; | ||||||
|     MRUMenuManager1: TMRUMenuManager; |     MRUMenuManager1: TMRUMenuManager; | ||||||
|     FAutoSaveOnClose: Boolean; |     FAutoSaveOnClose: Boolean; | ||||||
|     FDesignOptions: TFPReportDesignOptions; |     FDesignOptions: TFPReportDesignOptions; | ||||||
| @ -501,6 +502,12 @@ begin | |||||||
|     AddPageDesign(I+1,Report.Pages[I]); |     AddPageDesign(I+1,Report.Pages[I]); | ||||||
|   ShowReportData; |   ShowReportData; | ||||||
|   ResetObjectInspector; |   ResetObjectInspector; | ||||||
|  |   if FLoadModified then | ||||||
|  |     begin | ||||||
|  |     Modified:=True; | ||||||
|  |     FLoadModified:=false; | ||||||
|  |     end | ||||||
|  |   else | ||||||
|     Modified:=False; |     Modified:=False; | ||||||
| end; | end; | ||||||
| 
 | 
 | ||||||
| @ -1331,6 +1338,7 @@ end; | |||||||
| function TFPReportDesignerForm.OpenReport: Boolean; | function TFPReportDesignerForm.OpenReport: Boolean; | ||||||
| 
 | 
 | ||||||
| begin | begin | ||||||
|  |   FLoadModified:=False; | ||||||
|   Result:=Assigned(OnOpenReport); |   Result:=Assigned(OnOpenReport); | ||||||
|   if Result then |   if Result then | ||||||
|     begin |     begin | ||||||
| @ -1446,6 +1454,7 @@ begin | |||||||
|     FFilename:=AFileName; |     FFilename:=AFileName; | ||||||
|     if Errs.Count>0 then |     if Errs.Count>0 then | ||||||
|       MessageDlg(SErrAccessingData,Format(SErrAccessingDataDetails,[Errs.Text]),mtWarning,[mbOK],''); |       MessageDlg(SErrAccessingData,Format(SErrAccessingDataDetails,[Errs.Text]),mtWarning,[mbOK],''); | ||||||
|  |     FLoadModified:=rs.IsModified; | ||||||
|   finally |   finally | ||||||
|     FreeAndNil(rs); |     FreeAndNil(rs); | ||||||
|     FreeAndNil(Errs); |     FreeAndNil(Errs); | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 michael
						michael