# Vault 7: Projects

This publication series is about specific projects related to the Vault 7 main publication.

### Protego

# MLA -- Graphics Library

- 1
- 2
…
- 241
- 242
- 243
- 244
- 245
…
- 373
- 374

Returns
None.
Description
This function sets the position of the progress bar.
The value used for the position should be within the range set for the object.
Function will have an undefined behavior if the position is outside the range.
Preconditions
Object must exist in memory.
Example
GFX_GOL_PROGRESSBAR *pPb;
uint8_t direction = 1;
// this code increments and decrements the progress bar by 1
// assume progress bar was created and initialized before
while (1)
{
if(direction)
{
if(pPb ->pos == pPb ->range)
direction = 0;
else
GFX_GOL_ProgressBarPositionSet(
pPb,
GFX_GOL_ProgressBarPositionGet(pPb)+1);
}
else
{
if(pPb ->pos == 0)
direction = 1;
else
GFX_GOL_ProgressBarPositionSet(
pPb,
GFX_GOL_ProgressBarPositionGet(pPb)-1);
}
}
Parameters
Parameters Description
pObject pointer to the object.
position the new position of the scroll bar thumb.
Function
void GFX_GOL_ProgressBarPositionSet(
GFX_GOL_PROGRESSBAR *pObject,
uint16_t position)
1.6.2.1.9.7 GFX_GOL_ProgressBarRangeSet Function
This function sets the range of the progress bar.
File
gfx_gol_progress_bar.h
Syntax
void GFX_GOL_ProgressBarRangeSet(GFX_GOL_PROGRESSBAR * pObject, uint16_t range);
1.6 Library Interface MLA - Graphics Library Help Graphics Object Layer
243

- 1
- 2
…
- 241
- 242
- 243
- 244
- 245
…
- 373
- 374