You've already forked lazarus-ccr
* fpspreadsheet: fpsgrid: show hourglass when loading/saving files
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3105 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -4,8 +4,7 @@ program fpsvisual;
|
||||
|
||||
uses
|
||||
Interfaces, // this includes the LCL widgetset
|
||||
Forms, mainform, LResources, laz_fpspreadsheet_visual
|
||||
{ you can add units after this };
|
||||
Forms, mainform, LResources, laz_fpspreadsheet_visual;
|
||||
|
||||
{$R *.res}
|
||||
|
||||
|
@ -570,7 +570,14 @@ begin
|
||||
exit;
|
||||
|
||||
if SaveDialog.Execute then
|
||||
begin
|
||||
Screen.Cursor := crHourglass;
|
||||
try
|
||||
WorksheetGrid.SaveToSpreadsheetFile(SaveDialog.FileName);
|
||||
finally
|
||||
Screen.Cursor := crDefault;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TForm1.CbBackgroundColorGetColors(Sender: TCustomColorBox; Items: TStrings);
|
||||
@ -659,6 +666,8 @@ var
|
||||
i: Integer;
|
||||
begin
|
||||
// Load file
|
||||
Screen.Cursor := crHourglass;
|
||||
try
|
||||
WorksheetGrid.LoadFromSpreadsheetFile(UTF8ToSys(AFileName));
|
||||
|
||||
// Update user interface
|
||||
@ -673,7 +682,7 @@ begin
|
||||
SetupBackgroundColorBox;
|
||||
|
||||
// Create a tab in the pagecontrol for each worksheet contained in the workbook
|
||||
// This would be easer with a TTabControl. This has display issues, though.
|
||||
// This would be easier with a TTabControl. This has display issues, though.
|
||||
pages := TStringList.Create;
|
||||
try
|
||||
WorksheetGrid.GetSheets(pages);
|
||||
@ -687,6 +696,9 @@ begin
|
||||
end;
|
||||
|
||||
WorksheetGridSelection(nil, WorksheetGrid.Col, WorksheetGrid.Row);
|
||||
finally
|
||||
Screen.Cursor := crDefault;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TForm1.PageControl1Change(Sender: TObject);
|
||||
|
Reference in New Issue
Block a user