Class TfrmTimeControl

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type TfrmTimeControl = class(TfrmCustomGoPhast)

Description

TfrmTimeControl is used to edit frmGoPhast.Model.Times.

Hierarchy

Overview

Fields

Implicit btnCancel: TBitBtn;
Implicit btnHelp: TBitBtn;
Implicit btnOK: TBitBtn;
Implicit lblNumberOfPeriods: TLabel;
Implicit pnlBottom: TPanel;
Implicit seTimeCount: TJvSpinEdit;
Implicit dgTime: TRbwDataGrid4;
Implicit rdeStartTime: TRbwDataEntry;
Implicit lblStartTime: TLabel;
Implicit pnlTop: TPanel;
Implicit rdeLength: TRbwDataEntry;

Methods

Implicit procedure btnOKClick(Sender: TObject);
Implicit procedure FormCreate(Sender: TObject); override;
Implicit procedure seTimeCountChange(Sender: TObject);
Implicit procedure FormKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
Implicit procedure dgTimeColSize(Sender: TObject; ACol, PriorWidth: Integer);
Implicit procedure dgTimeHorizontalScroll(Sender: TObject);
Implicit procedure dgTimeMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
Implicit procedure rdeLengthChange(Sender: TObject);
Implicit procedure dgTimeSetEditText(Sender: TObject; ACol, ARow: Integer; const Value: string);
Private function CheckTimes: boolean;
Private procedure GetData;
Private procedure SetData;
Private procedure LayoutMultiRowEditControl;

Description

Fields

Implicit btnCancel: TBitBtn;

Clicking btnCancel closes TfrmTimeControl without changing anything.

Implicit btnHelp: TBitBtn;

Clicking btnHelp displays help on TfrmTimeControl.

Implicit btnOK: TBitBtn;

See btnOKClick.

Implicit lblNumberOfPeriods: TLabel;

lblNumberOfPeriods displays "Number of Periods".

Implicit pnlBottom: TPanel;

pnlBottom holds the controls at the bottom of TfrmTimeControl.

Implicit seTimeCount: TJvSpinEdit;

seTimeCount specifies the number of stress periods. See seTimeCountChange.

Implicit dgTime: TRbwDataGrid4;

dgTime holds the time step sizes and ending times of the stress periods.

Implicit rdeStartTime: TRbwDataEntry;
 
Implicit lblStartTime: TLabel;
 
Implicit pnlTop: TPanel;
 
Implicit rdeLength: TRbwDataEntry;
 

Methods

Implicit procedure btnOKClick(Sender: TObject);

btnOKClick calls CheckTimes if it returns True, btnOKClick calls SetData. Otherwise ModalResult is set to mrNone.

Implicit procedure FormCreate(Sender: TObject); override;

FormCreate initializes TfrmTimeControl and calls GetData.

Implicit procedure seTimeCountChange(Sender: TObject);

seTimeCountChange changes the number of rows in dgTime to be consistent with the value in seTimeCount.

Implicit procedure FormKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
 
Implicit procedure dgTimeColSize(Sender: TObject; ACol, PriorWidth: Integer);
 
Implicit procedure dgTimeHorizontalScroll(Sender: TObject);
 
Implicit procedure dgTimeMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
 
Implicit procedure rdeLengthChange(Sender: TObject);
 
Implicit procedure dgTimeSetEditText(Sender: TObject; ACol, ARow: Integer; const Value: string);
 
Private function CheckTimes: boolean;

CheckTimes checks that the ending times of all the stress periods are unique. If they aren't, the user will be given a chance to cancel setting the data. If the user chooses to continue, the the rows with the duplicate ending times will be deleted before setting the data.

Private procedure GetData;

GetData displays frmGoPhast.Model.Times in TfrmTimeControl.

Private procedure SetData;

SetData sets frmGoPhast.Model.Times with the values in TfrmTimeControl using a TUndoTimes.

Private procedure LayoutMultiRowEditControl;
 

Generated by PasDoc 0.12.1 on 2013-05-13 15:41:41