C# Class Divine_Right.InterfaceComponents.Components.TextLogComponent

A Component which logs a number of text messages
Inheritance: IGameInterfaceComponent
Mostrar archivo Open project: Haedrian/Divine-Right Class Usage Examples

Protected Properties

Property Type Description
feedback List
globalLog List
locationX int
locationY int

Public Methods

Method Description
Draw ( Microsoft content, Microsoft batch ) : void
HandleClick ( int x, int y, System.Objects mouseAction, DRObjects &actionType, InternalActionEnum &internalActionType, object &args, MapItem &itm, DRObjects &coord, bool &destroy ) : bool
HandleKeyboard ( Microsoft keyboard, DRObjects &actionType, object &args, DRObjects &coord, bool &destroy ) : bool
HandleMouseOver ( int x, int y ) : void
IsModal ( ) : bool
Move ( int x, int y ) : void

Moves the TextLogComponent to a new location. This is intended to be used for resizing purposes

PerformDrag ( int deltaX, int deltaY ) : void
ReturnLocation ( ) : Rectangle
TextLogComponent ( int x, int y, List globalLog ) : System
UpdateLog ( ) : void

Updates the log with new items

Method Details

Draw() public method

public Draw ( Microsoft content, Microsoft batch ) : void
content Microsoft
batch Microsoft
return void

HandleClick() public method

public HandleClick ( int x, int y, System.Objects mouseAction, DRObjects &actionType, InternalActionEnum &internalActionType, object &args, MapItem &itm, DRObjects &coord, bool &destroy ) : bool
x int
y int
mouseAction System.Objects
actionType DRObjects
internalActionType InternalActionEnum
args object
itm DRObjects.MapItem
coord DRObjects
destroy bool
return bool

HandleKeyboard() public method

public HandleKeyboard ( Microsoft keyboard, DRObjects &actionType, object &args, DRObjects &coord, bool &destroy ) : bool
keyboard Microsoft
actionType DRObjects
args object
coord DRObjects
destroy bool
return bool

HandleMouseOver() public method

public HandleMouseOver ( int x, int y ) : void
x int
y int
return void

IsModal() public method

public IsModal ( ) : bool
return bool

Move() public method

Moves the TextLogComponent to a new location. This is intended to be used for resizing purposes
public Move ( int x, int y ) : void
x int
y int
return void

PerformDrag() public method

public PerformDrag ( int deltaX, int deltaY ) : void
deltaX int
deltaY int
return void

ReturnLocation() public method

public ReturnLocation ( ) : Rectangle
return Microsoft.Xna.Framework.Rectangle

TextLogComponent() public method

public TextLogComponent ( int x, int y, List globalLog ) : System
x int
y int
globalLog List
return System

UpdateLog() public method

Updates the log with new items
public UpdateLog ( ) : void
return void

Property Details

feedback protected_oe property

Cleaned feedback to display. We will basically take a look at the global log each time. If there's anything new, we clean it up and put it in the top. Then we try to draw all of them. If we run out of bottom draw space, then we trim the feedback list to save some memory.
protected List feedback
return List

globalLog protected_oe property

A link to the log which we will be sampling from
protected List globalLog
return List

locationX protected_oe property

protected int locationX
return int

locationY protected_oe property

protected int locationY
return int