C# Class Gruppe22.Client.ProgressBar

A progress bar
Inheritance: UIElement, Backend.IHandleEvent
Show file Open project: propra13-orga/gruppe22 Class Usage Examples

Public Methods

Method Description
Draw ( GameTime gameTime ) : void

Display the progressbar using appropriate position,style and color

IsHit ( int x, int y ) : bool
ProgressBar ( Backend parent, SpriteBatch spriteBatch, Microsoft.Xna.Framework.Content.ContentManager content, Rectangle displayRect, ProgressStyle style = ProgressStyle.Default, int total = 100, int start ) : System

Create a new progress bar

Update ( GameTime gameTime ) : void

Move progress bar (if animated)

Method Details

Draw() public method

Display the progressbar using appropriate position,style and color
public Draw ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime
return void

IsHit() public method

public IsHit ( int x, int y ) : bool
x int
y int
return bool

ProgressBar() public method

Create a new progress bar
public ProgressBar ( Backend parent, SpriteBatch spriteBatch, Microsoft.Xna.Framework.Content.ContentManager content, Rectangle displayRect, ProgressStyle style = ProgressStyle.Default, int total = 100, int start ) : System
parent Backend A parent object to pass events to
spriteBatch Microsoft.Xna.Framework.Graphics.SpriteBatch A spritebatch used for drawing
content Microsoft.Xna.Framework.Content.ContentManager A Contentmanager used for loading resources
displayRect Microsoft.Xna.Framework.Rectangle The area of the progress bar
style ProgressStyle The design of the progress bar
total int A maximum amount to be displayed on the progress bar
start int The start value
return System

Update() public method

Move progress bar (if animated)
public Update ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime
return void