Version: 3.2.5
wxAppProgressIndicator Class Reference

#include <wx/appprogress.h>

Detailed Description

A helper class that can be used to update the progress bar in the taskbar button on Windows and the dock icon on macOS.

Library:  wxCore
Category:  Miscellaneous
Availability:  only available for the wxMSW, wxOSX/Cocoa ports.
See also
wxTaskBarButton
Since
3.1.0

Public Member Functions

 wxAppProgressIndicator (wxWindow *parent=NULL, int maxValue=100)
 Constructs the wxAppProgressIndicator. More...
 
virtual ~wxAppProgressIndicator ()
 Destructor, stops displaying progress and returns the indicator to its normal state. More...
 
bool IsAvailable () const
 Check if the application progress display is available. More...
 
void SetValue (int value)
 Set the progress value in taskbar button of parent window. More...
 
void SetRange (int range)
 Set the progress range in taskbar button of parent window. More...
 
bool Pulse ()
 Makes the progress bar run in indeterminate mode. More...
 

Constructor & Destructor Documentation

◆ wxAppProgressIndicator()

wxAppProgressIndicator::wxAppProgressIndicator ( wxWindow parent = NULL,
int  maxValue = 100 
)

Constructs the wxAppProgressIndicator.

Parameters
parentThe parent window of wxAppProgressIndicator. Note that the window should has taskbar button showing. If parent is NULL, the progress will reflect on the taskbar buttons of all the top level windows.
maxValueInteger range (maximum value) of the progress indicator.

◆ ~wxAppProgressIndicator()

virtual wxAppProgressIndicator::~wxAppProgressIndicator ( )
virtual

Destructor, stops displaying progress and returns the indicator to its normal state.

Member Function Documentation

◆ IsAvailable()

bool wxAppProgressIndicator::IsAvailable ( ) const

Check if the application progress display is available.

Currently this only returns true when using wxMSW and running under Windows 7 or later systems (which provide task bar button API) or when using wxOSX.

If this method returns false, no other methods of this class do anything, but they may still be called without any ill effects.

◆ Pulse()

bool wxAppProgressIndicator::Pulse ( )

Makes the progress bar run in indeterminate mode.

◆ SetRange()

void wxAppProgressIndicator::SetRange ( int  range)

Set the progress range in taskbar button of parent window.

◆ SetValue()

void wxAppProgressIndicator::SetValue ( int  value)

Set the progress value in taskbar button of parent window.

Parameters
valueThe new value of the progress meter. It should be less than or equal to the range.