Jamie Slowgrove - MGP Assignment 2 - JAM
Main Page
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Macros
jni
src
JAM
Button.h
Go to the documentation of this file.
1
#pragma once
2
3
#include <string>
4
#include "
Entity.h
"
5
#include "
Text.h
"
6
11
class
JAM_Button
:
public
JAM_Entity
12
{
13
private
:
15
JAM_Text
*
text
;
17
float
border
;
19
bool
state
;
20
21
public
:
30
JAM_Button
(
JAM_Texture
*
sprite
,
float
x,
float
y,
float
width,
float
height);
31
47
JAM_Button
(
JAM_Texture
*
sprite
,
float
x,
float
y, std::string message, std::string fontLocation,
48
int
fontSize,
int
r,
int
g,
int
b, SDL_Renderer* renderer,
float
border,
float
minWidth,
float
minHeight);
49
53
~JAM_Button
();
54
59
void
update
(
float
dt);
60
66
bool
input
(SDL_Event& incomingEvent);
67
73
bool
tapInput
(SDL_Event& incomingEvent);
74
79
void
drawText
(SDL_Renderer* renderer);
80
};
JAM_Button::input
bool input(SDL_Event &incomingEvent)
Definition:
Button.cpp:73
JAM_Button::update
void update(float dt)
Definition:
Button.cpp:66
JAM_Entity::sprite
JAM_Texture * sprite
Definition:
Entity.h:14
JAM_Texture
Creates a Texture for use with a renderer. Creates a Texture from an image file, this can then be use...
Definition:
Texture.h:13
JAM_Button::~JAM_Button
~JAM_Button()
Definition:
Button.cpp:57
JAM_Button::tapInput
bool tapInput(SDL_Event &incomingEvent)
Definition:
Button.cpp:120
Entity.h
JAM_Button::state
bool state
Definition:
Button.h:19
Text.h
JAM_Button::text
JAM_Text * text
Definition:
Button.h:15
JAM_Button::JAM_Button
JAM_Button(JAM_Texture *sprite, float x, float y, float width, float height)
Definition:
Button.cpp:6
JAM_Button
Creates a Button object that inherits Entity.
Definition:
Button.h:11
JAM_Button::drawText
void drawText(SDL_Renderer *renderer)
Definition:
Button.cpp:157
JAM_Entity
Creates an Entity object.
Definition:
Entity.h:10
JAM_Text
Creates a Text Texture for use with a renderer. Creates a Text Texture from an image file...
Definition:
Text.h:15
JAM_Button::border
float border
Definition:
Button.h:17
Generated on Fri May 8 2015 04:48:20 for Jamie Slowgrove - MGP Assignment 2 - JAM by
1.8.8