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 dgTime: TRbwDataGrid;
Implicit lblNumberOfPeriods: TLabel;
Implicit pnlBottom: TPanel;
Implicit seTimeCount: TSpinEdit;

Methods

Implicit procedure btnOKClick(Sender: TObject);
Implicit procedure FormCreate(Sender: TObject); override;
Implicit procedure seTimeCountChanged(Sender: TObject; NewValue: Integer);
Private function CheckTimes: boolean;
Private procedure GetData;
Private procedure SetData;

Description

Fields

Implicit btnCancel: TBitBtn;

btnCancel: TBitBtn; Clicking btnCancel closes TfrmTimeControl without changing anything.

Implicit btnHelp: TBitBtn;

btnHelp: TBitBtn; Clicking btnHelp displays help on TfrmTimeControl.

Implicit btnOK: TBitBtn;

btnOK: TBitBtn; See btnOKClick.

Implicit dgTime: TRbwDataGrid;

dgTime: TRbwDataGrid; dgTime displays the time step sizes and ending times.

Implicit lblNumberOfPeriods: TLabel;

lblNumberOfPeriods: TLabel; lblNumberOfPeriods displays "Number of Periods".

Implicit pnlBottom: TPanel;

pnlBottom: TPanel; pnlBottom holds the controls at the bottom of TfrmTimeControl.

Implicit seTimeCount: TSpinEdit;

seTimeCount: TSpinEdit; seTimeCount specifies the number of stress periods. See seTimeCountChanged.

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 seTimeCountChanged(Sender: TObject; NewValue: Integer);

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

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.


Generated by PasDoc 0.10.0 on 2006-10-31 09:56:38