CEikProgressInfo Class Reference

API published in: S60 1st Ed

Link against: avkon.lib eikctl.lib eikcdlg.lib

Capability Information

Required Capabilities

None


#include <eikprogi.h>

Inherits CEikBorderedControl.


Detailed Description

Control used to indicate the progress of an operation.

Progress consists of a rectangular block that grows during an increment and shrinks during a decrement. The control can have progress text within the bar that provides updated information on how far the operation has progressed. The text can be displayed as either a percentage or a fraction. The bar can also have a series of invisible splits, or lines. These splits are displayed by the rectangular blocks as it fills the bar. When the control is in this mode progress text cannot be used.

This class has an associated PROGRESSINFO resource and EEikCtProgInfo control factory identifier.


Public Member Functions

IMPORT_C  ~CEikProgressInfo ()
  Destructor.
IMPORT_C  CEikProgressInfo ()
  C++ default constructor.
IMPORT_C  CEikProgressInfo (const SInfo &aProgInfo)
  Constructs a progress information control using the information held in the specified SInfo struct.
IMPORT_C void  IncrementAndDraw (TInt aInc)
  Adds the specified increment to the current progress value and, if the progress value has increased, redraws the control.
IMPORT_C void  SetAndDraw (TInt aValue)
  Sets the specified value as the new progress value and redraws the control if the new value differs from the old value.
IMPORT_C void  ConstructFromResourceL (TResourceReader &aReader)
  From CCoeControl.
IMPORT_C void  SetLayout (const SLayout &aLayout)
  Sets the layout for the control.
IMPORT_C void  SetBorder (const TGulBorder &aBorder)
  Sets the control's border.
IMPORT_C void  SetFinalValue (TInt aFinalValue)
  Sets the final value for the progress information control.
IMPORT_C void  ConstructL ()
  By default Symbian 2nd phase constructor is private.
const SInfo Info () const
  Gets a pointer to the information used to define the progress information control's type.
const SLayout Layout () const
  Gets a pointer to the colours and layout of the progress information control.
TInt  CurrentValue () const
  Gets the current value, indicating how far the operation has progressed.
IMPORT_C void  ActivateL ()
  From CCoeControl.
IMPORT_C TSize  MinimumSize ()
  From CCoeControl.
IMPORT_C void  SizeChanged ()
  From CCoeControl.
virtual IMPORT_C void  GetColorUseListL (CArrayFix< TCoeColorUse > &aColorUseList) const
  From CCoeControl.
virtual IMPORT_C void  HandleResourceChange (TInt aType)
  From CCoeControl.
IMPORT_C void  HandlePointerEventL (const TPointerEvent &aPointerEvent)
  From CCoeControl.

Protected Member Functions

virtual IMPORT_C const TDesC *  EvaluateText (TDes &aTextBuf) const
  Evaluates the progress text.
IMPORT_C void  WriteInternalStateL (RWriteStream &aWriteStream) const
  From CCoeControl.

Data Structures

struct   SInfo
  Defines the progress control's type. More...
struct   SLayout
  Defines the layout and colours for a progress information control. More...

Constructor & Destructor Documentation

IMPORT_C CEikProgressInfo::~CEikProgressInfo  ) 
 

Destructor.

IMPORT_C CEikProgressInfo::CEikProgressInfo  ) 
 

C++ default constructor.

IMPORT_C CEikProgressInfo::CEikProgressInfo const SInfo aProgInfo  ) 
 

Constructs a progress information control using the information held in the specified SInfo struct.

Uses default layout values.

Parameters:
aProgInfo  Holds information about the type of progress information control.

Member Function Documentation

IMPORT_C void CEikProgressInfo::ActivateL  ) 
 

From CCoeControl.

Activates the progress information control.

IMPORT_C void CEikProgressInfo::ConstructFromResourceL TResourceReader &  aReader  ) 
 

From CCoeControl.

Constructs a progress information control from a PROGRESSINFO resource. Uses default layout values.

Parameters:
aReader  The resource reader to use.
IMPORT_C void CEikProgressInfo::ConstructL  ) 
 

By default Symbian 2nd phase constructor is private.

TInt CEikProgressInfo::CurrentValue  )  const [inline]
 

Gets the current value, indicating how far the operation has progressed.

Returns:
The value for how far the operation has progressed.
virtual IMPORT_C const TDesC* CEikProgressInfo::EvaluateText TDes &  aTextBuf  )  const [protected, virtual]
 

Evaluates the progress text.

Parameters:
[out]  aTextBuf  On return, the evaluted text. This is the same as the return value.
Returns:
The evaluated text. Null if progress information is not held as text. A percentage if it is held as a percentage. Otherwise, the current value and final value separated by a slash. Subclassers may wish to use their own buffer.
virtual IMPORT_C void CEikProgressInfo::GetColorUseListL CArrayFix< TCoeColorUse > &  aColorUseList  )  const [virtual]
 

From CCoeControl.

Gets a list of the logical colours used to draw the control, appended to aColorUseList.

Parameters:
[out]  aColorUseList  On return, the colours used to draw the control.

Reimplemented from CEikBorderedControl.

IMPORT_C void CEikProgressInfo::HandlePointerEventL const TPointerEvent &  aPointerEvent  ) 
 

From CCoeControl.

Handles pointer events. This function gets called whenever a pointer event occurs in the control, i.e. when the pointer is within the control's extent, or when the control has grabbed the pointer. The control should implement this function to handle pointer events.

Note: events of type EButton1Down are processed before HandlePointerEventL() is called, in order to transfer keyboard focus to the control in which the EButton1Down event occurred. If overriding HandlePointerEventL(), the implementation must include a base call to CCoeControl's HandlePointerEventL().

Parameters:
aPointerEvent  The pointer event.

Reimplemented from CEikBorderedControl.

virtual IMPORT_C void CEikProgressInfo::HandleResourceChange TInt  aType  )  [virtual]
 

From CCoeControl.

Handles a change to the control's resources.

Parameters:
aType  A message UID value.

Reimplemented from CEikBorderedControl.

IMPORT_C void CEikProgressInfo::IncrementAndDraw TInt  aInc  ) 
 

Adds the specified increment to the current progress value and, if the progress value has increased, redraws the control.

Parameters:
aInc  The increment to add to the current progress value.
const SInfo& CEikProgressInfo::Info  )  const [inline]
 

Gets a pointer to the information used to define the progress information control's type.

Returns:
The information that defines the type of progress information control.
const SLayout& CEikProgressInfo::Layout  )  const [inline]
 

Gets a pointer to the colours and layout of the progress information control.

Returns:
Defines the layout of the control.
IMPORT_C TSize CEikProgressInfo::MinimumSize  ) 
 

From CCoeControl.

Gets the minimum size required to draw the control.

Returns:
Two-dimensional size as a width and a height value.
IMPORT_C void CEikProgressInfo::SetAndDraw TInt  aValue  ) 
 

Sets the specified value as the new progress value and redraws the control if the new value differs from the old value.

Parameters:
aValue  The new progress value.
IMPORT_C void CEikProgressInfo::SetBorder const TGulBorder &  aBorder  ) 
 

Sets the control's border.

Parameters:
aBorder  The control's border.
IMPORT_C void CEikProgressInfo::SetFinalValue TInt  aFinalValue  ) 
 

Sets the final value for the progress information control.

This value indicates the operation being monitored is complete.

Parameters:
aFinalValue  The final value for the progress information control. If this is specified as zero, the value is set to one.
IMPORT_C void CEikProgressInfo::SetLayout const SLayout aLayout  ) 
 

Sets the layout for the control.

Parameters:
aLayout  The layout for the control.
IMPORT_C void CEikProgressInfo::SizeChanged  ) 
 

From CCoeControl.

Recalculates the control's size in response to a size change.

IMPORT_C void CEikProgressInfo::WriteInternalStateL RWriteStream &  aWriteStream  )  const [protected]
 

From CCoeControl.

Writes the internal state of the control and its components to a stream. This function is empty in release builds. It is intended to be overridden and base called by subclasses.

Parameters:
aWriteStream  The internal state of the control and its components.

Reimplemented from CEikBorderedControl.


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

Copyright © Nokia Corporation 2001-2008
Back to top