CEikRangeEditor Class Reference

API published in: S60 1st Ed

Link against: avkon.lib eikctl.lib eikcoctl.lib uiklaf.lib form.lib

Capability Information

Required Capabilities

None


#include <eikmfne.h>

Inherits CEikMfne.


Detailed Description

Numeric range editor.

This editor supports editing an integer range. It has two fields; the first represents the lower value and the second the upper value. The second value must be greater than, or equal to, the first.

Minimum and maximum values for the editor are specified during construction. If a number is entered which is not within the editor's minimum and maximum values, it is automatically reset to the nearest allowable value.

The editor has an associated resource struct RANGE_EDITOR and control factory identifier EEikCtRangeEditor.


Public Member Functions

IMPORT_C  CEikRangeEditor ()
  Default constructor.
IMPORT_C void  ConstructL (TInt aMinimumValue, TInt aMaximumValue, const SEikRange &aInitialRange, HBufC *aSeparatorText)
  Second phase constructor.
IMPORT_C void  SetMinimumAndMaximum (TInt aMinimumValue, TInt aMaximumValue)
  Sets the range editor's minimum and maximum values.
IMPORT_C void  GetMinimumAndMaximum (TInt &aMinimumValue, TInt &aMaximumValue) const
  Gets the range editor's minimum and maximum values.
IMPORT_C void  SetRange (const SEikRange &aRange)
  Sets the range editor's current values.
IMPORT_C SEikRange  Range () const
  Gets the range editor's current values.
virtual IMPORT_C void  ConstructFromResourceL (TResourceReader &aResourceReader)
  Second phase constructor from resource.
IMPORT_C void  HandlePointerEventL (const TPointerEvent &aPointerEvent)
  From CCoeControl.

Constructor & Destructor Documentation

IMPORT_C CEikRangeEditor::CEikRangeEditor  ) 
 

Default constructor.

This function should be used as the first stage in two stage construction, followed by a call to either ConstructFromResourceL() to initialise the editor's field values from a resource file, or ConstructL() if no resource file is used.


Member Function Documentation

virtual IMPORT_C void CEikRangeEditor::ConstructFromResourceL TResourceReader &  aResourceReader  )  [virtual]
 

Second phase constructor from resource.

This function completes construction of a newly-allocated range editor. It sets the minimum and maximum values, initial range and separator text as specified by the resource.

Parameters:
aResourceReader  A resource reader.
IMPORT_C void CEikRangeEditor::ConstructL TInt  aMinimumValue,
TInt  aMaximumValue,
const SEikRange aInitialRange,
HBufC *  aSeparatorText
 

Second phase constructor.

This function completes construction of a range editor. It sets the minimum and maximum values, initial range and separator text. It should be called by the container only if the control is not constructed from a resource file.

Parameters:
aMinimumValue  The minimum value for the range editor.
aMaximumValue  The maximum value for the range editor.
aInitialRange  Struct containing upper and lower range limits. Must be within the minimum and maximum values.
aSeparatorText  The text to be used to separate the numeric values.
Panic:
8 If the initial lower or upper limit is outside the minimum or maximum bounds.
IMPORT_C void CEikRangeEditor::GetMinimumAndMaximum TInt &  aMinimumValue,
TInt &  aMaximumValue
const
 

Gets the range editor's minimum and maximum values.

Parameters:
aMinimumValue  On return, the minimum value for the range editor.
aMaximumValue  On return, the maximum value for the range editor.
IMPORT_C void CEikRangeEditor::HandlePointerEventL const TPointerEvent &  aPointerEvent  )  [virtual]
 

From CCoeControl.

Handles pointer events.

Parameters:
aPointerEvent  The pointer event.

Reimplemented from CEikMfne.

IMPORT_C SEikRange CEikRangeEditor::Range  )  const
 

Gets the range editor's current values.

Can only be called if CEikMfne::PrepareForFocusLossL() succeeded

Returns:
Struct containing current range values.
IMPORT_C void CEikRangeEditor::SetMinimumAndMaximum TInt  aMinimumValue,
TInt  aMaximumValue
 

Sets the range editor's minimum and maximum values.

Any values are permitted. If the range values are outside the new minimum / maximum they are changed to be within the new minimum / maximum.

Parameters:
aMinimumValue  The minimum value for the range editor.
aMaximumValue  The maximum value for the range editor.
IMPORT_C void CEikRangeEditor::SetRange const SEikRange aRange  ) 
 

Sets the range editor's current values.

Parameters:
aRange  Struct containing new range values.

The documentation for this class was generated from the following file:

Copyright © Nokia Corporation 2001-2008
Back to top