|
|
LibN2L-4 Library Code Reference
Classes
Compounds
Files
Members
Method Index
Full Reference
n2l::cGuiElement Class Reference#include <cGuiElement.h>
Inheritance diagram for n2l::cGuiElement:
[legend]Collaboration diagram for n2l::cGuiElement:
[legend]List of all members.Public Types
Public Member Functions
Static Public Member Functions
Protected Types
Protected Member Functions
Static Protected Member Functions
- static void validateAndDecode (cDynVar &oDefinition, const cVfsNodeInterface &iNode, const tString &iRequiredHeader)
- A utility for inherited loaders, this checks for a required header, and then returns by reference the unserialization of the file buffer contents.
Protected Attributes
Friends
Detailed Description
Definition at line 55 of file cGuiElement.h.
Member Typedef Documentation
Constructor & Destructor Documentation
| n2l::cGuiElement::cGuiElement |
( |
|
) |
|
|
| n2l::cGuiElement::cGuiElement |
( |
const tGuiPos & |
iPos, |
|
|
const tGuiPos & |
iSize, |
|
|
const tString & |
iName = "" |
|
) |
|
|
| n2l::cGuiElement::~cGuiElement |
( |
|
) |
[virtual] |
|
Member Function Documentation
| void n2l::cGuiElement::addEffect |
( |
const cAutoPtr< cGuiSEInt > & |
i_ioEffect |
) |
[virtual] |
|
| const tGuiPos & n2l::cGuiElement::bottomRightPadding |
( |
|
) |
const [virtual] |
|
| void n2l::cGuiElement::canvas |
( |
cGuiCanvas *const |
iCanvas |
) |
[protected, virtual] |
|
| cGuiCanvas *const n2l::cGuiElement::canvas |
( |
|
) |
[virtual] |
|
| void n2l::cGuiElement::clearEffects |
( |
|
) |
[virtual] |
|
| void n2l::cGuiElement::clearUserActions |
( |
|
) |
[virtual] |
|
|
|
Method to return a copy of this element.
Useful as a way to get a non-const, bindable and canvas-able instance of an element from the resource loader. - Note:
- Bindings, name and canvas parent information are not cloned.
Implemented in n2l::cGuiButton, n2l::cGuiButtonSelectBox, n2l::cGuiCanvas, n2l::cGuiInteractive, n2l::cGuiLabel, n2l::cGuiModelView, n2l::cGuiProgressBar, n2l::cGuiSButton, n2l::cGuiSButtonSelectBox, n2l::cGuiSlider, n2l::cGuiSprite, n2l::cGuiSpriteMousePointer, n2l::cGuiTextDisplay, and n2l::cGuiTextInput. |
| void n2l::cGuiElement::cloneInto |
( |
const cAutoPtr< cGuiElement > & |
i_ioElement |
) |
const [protected, virtual] |
|
|
|
A component of clone, copy our properties into the provided element.
Definition at line 417 of file cGuiElement.cpp.
References bottomRightPadding(), n2l::GuiActionType_NumActionTypes, name(), pos(), renderOrder(), size(), and topLeftPadding().
Referenced by n2l::cGuiSpriteMousePointer::cloneInto(), n2l::cGuiSprite::cloneInto(), n2l::cGuiModelView::cloneInto(), n2l::cGuiLabel::cloneInto(), n2l::cGuiInteractive::cloneInto(), and n2l::cGuiCanvas::cloneInto(). |
| virtual void n2l::cGuiElement::commitSuicide |
( |
|
) |
[inline, virtual] |
|
| void n2l::cGuiElement::dimensionChanged |
( |
|
) |
[protected, virtual] |
|
|
|
Reimplemented in n2l::cGuiButtonSelectBox, n2l::cGuiSButtonSelectBox, n2l::cGuiSlider, n2l::cGuiTextDisplay, and n2l::cGuiTextInput.
Definition at line 400 of file cGuiElement.cpp.
References mBottomRightPadding, mPos, mSize, and mTopLeftPadding.
Referenced by cGuiElement(), n2l::cGuiTextInput::dimensionChanged(), n2l::cGuiTextDisplay::dimensionChanged(), n2l::cGuiSlider::dimensionChanged(), n2l::cGuiSButtonSelectBox::dimensionChanged(), n2l::cGuiButtonSelectBox::dimensionChanged(), padding(), pos(), and size(). |
| void n2l::cGuiElement::draw |
( |
|
) |
const [virtual] |
|
|
|
Draw ourselves on the screen.
- Note:
- This method does not set the projection matrix.
Reimplemented in n2l::cGuiButton, n2l::cGuiButtonSelectBox, n2l::cGuiCanvas, n2l::cGuiLabel, n2l::cGuiModelView, n2l::cGuiProgressBar, n2l::cGuiSButton, n2l::cGuiSButtonSelectBox, n2l::cGuiSlider, n2l::cGuiSprite, n2l::cGuiSpriteMousePointer, n2l::cGuiTextDisplay, and n2l::cGuiTextInput.
Definition at line 342 of file cGuiElement.cpp.
Referenced by n2l::cGuiCanvas::draw(). |
| void n2l::cGuiElement::focus |
( |
const tBool |
iFocus |
) |
[virtual] |
|
| const tBool n2l::cGuiElement::focus |
( |
|
) |
const [virtual] |
|
| const tBool n2l::cGuiElement::hasChildren |
( |
|
) |
const [virtual] |
|
|
|
Return whether or not this element has children that must be searched if trying to find a node.
Reimplemented in n2l::cGuiCanvas.
Definition at line 462 of file cGuiElement.cpp. |
| const tGuiPos& n2l::cGuiElement::innerPos |
( |
|
) |
const [inline] |
|
|
|
Definition at line 249 of file cGuiElement.h.
Referenced by n2l::cGuiTextDisplay::dimensionChanged(), n2l::cGuiSlider::dimensionChanged(), n2l::cGuiSButtonSelectBox::dimensionChanged(), n2l::cGuiButtonSelectBox::dimensionChanged(), n2l::cGuiTextInput::draw(), n2l::cGuiTextDisplay::draw(), n2l::cGuiSprite::draw(), n2l::cGuiSButton::draw(), n2l::cGuiProgressBar::draw(), n2l::cGuiLabel::draw(), n2l::cGuiCanvas::draw(), n2l::cGuiButton::draw(), and n2l::cGuiSlider::mouseMove(). |
| const tGuiPos& n2l::cGuiElement::innerSize |
( |
|
) |
const [inline] |
|
|
|
Definition at line 250 of file cGuiElement.h.
Referenced by n2l::cGuiTextDisplay::dimensionChanged(), n2l::cGuiSlider::dimensionChanged(), n2l::cGuiSButtonSelectBox::dimensionChanged(), n2l::cGuiButtonSelectBox::dimensionChanged(), n2l::cGuiTextInput::draw(), n2l::cGuiTextDisplay::draw(), n2l::cGuiSpriteMousePointer::draw(), n2l::cGuiSprite::draw(), n2l::cGuiSButton::draw(), n2l::cGuiProgressBar::draw(), n2l::cGuiLabel::draw(), n2l::cGuiCanvas::draw(), n2l::cGuiButton::draw(), and n2l::cGuiTextDisplay::propertyChanged(). |
| void n2l::cGuiElement::load |
( |
const cDynVar & |
iDefinition |
) |
[virtual] |
|
|
|
Load this elements properties from the provided definition.
Reimplemented in n2l::cGuiButton, n2l::cGuiButtonSelectBox, n2l::cGuiCanvas, n2l::cGuiInteractive, n2l::cGuiLabel, n2l::cGuiModelView, n2l::cGuiProgressBar, n2l::cGuiSButton, n2l::cGuiSButtonSelectBox, n2l::cGuiSlider, n2l::cGuiSprite, n2l::cGuiSpriteMousePointer, n2l::cGuiTextDisplay, and n2l::cGuiTextInput.
Definition at line 105 of file cGuiElement.cpp.
References n2l::asUint(), bindUserAction(), n2l::cGuiACFactory::current(), n2l::cGuiACFactory::load(), padding(), pos(), renderOrder(), and size(). |
|
|
Load this elements properties from the provided VFS Node.
Reimplemented in n2l::cGuiButton, n2l::cGuiButtonSelectBox, n2l::cGuiCanvas, n2l::cGuiLabel, n2l::cGuiModelView, n2l::cGuiProgressBar, n2l::cGuiSButton, n2l::cGuiSButtonSelectBox, n2l::cGuiSlider, n2l::cGuiSprite, n2l::cGuiSpriteMousePointer, n2l::cGuiTextDisplay, and n2l::cGuiTextInput.
Definition at line 97 of file cGuiElement.cpp.
References validateAndDecode().
Referenced by n2l::cGuiSpriteMousePointer::load(), n2l::cGuiSprite::load(), n2l::cGuiModelView::load(), n2l::cGuiLabel::load(), n2l::cGuiInteractive::load(), and n2l::cGuiCanvas::load(). |
| void n2l::cGuiElement::name |
( |
const tString & |
iName |
) |
[virtual] |
|
| const tString & n2l::cGuiElement::name |
( |
|
) |
const [virtual] |
|
| const tUint n2l::cGuiElement::nextElementNumber |
( |
|
) |
[protected] |
|
| const tUint n2l::cGuiElement::numEffects |
( |
|
) |
const [virtual] |
|
| const tGuiPos& n2l::cGuiElement::outerPos |
( |
|
) |
const [inline] |
|
| const tGuiPos& n2l::cGuiElement::outerSize |
( |
|
) |
const [inline] |
|
| void n2l::cGuiElement::padding |
( |
const tGuiPos & |
iTopLeft, |
|
|
const tGuiPos & |
iBottomRight |
|
) |
[virtual] |
|
| void n2l::cGuiElement::pos |
( |
const tGuiPos & |
iPos |
) |
[virtual] |
|
| const tGuiPos & n2l::cGuiElement::pos |
( |
|
) |
const [virtual] |
|
|
|
Definition at line 159 of file cGuiElement.cpp.
References mPos.
Referenced by n2l::cGuiSEFollowB3Curve::actOn(), cloneInto(), n2l::cGuiSpriteMousePointer::draw(), n2l::cGuiModelView::draw(), n2l::cGuiCanvas::draw(), load(), prop(), n2l::cGuiSpriteMousePointer::systemEvent(), n2l::cGuiInteractive::systemEvent(), n2l::cGuiCanvas::systemEvent(), n2l::cGuiInteractive::systemEventOutside(), and n2l::cGuiCanvas::systemEventOutside(). |
| const cDynVar n2l::cGuiElement::prop |
( |
const tString & |
iName, |
|
|
const tString & |
iInnerKey = "" |
|
) |
const [virtual] |
|
|
|
Reimplemented in n2l::cGuiCanvas, n2l::cGuiLabel, n2l::cGuiModelView, n2l::cGuiSButton, n2l::cGuiSprite, and n2l::cGuiTextDisplay.
Definition at line 235 of file cGuiElement.cpp.
References n2l::cDynVar::Array, bottomRightPadding(), mName, n2l::cDynVar::Null, renderOrder(), size(), topLeftPadding(), n2l::cVector2< TComponent, TComponentDiff, TMagnitude >::x(), and n2l::cVector2< TComponent, TComponentDiff, TMagnitude >::y(). |
| void n2l::cGuiElement::prop |
( |
const tString & |
iName, |
|
|
const cDynVar & |
iVal, |
|
|
const tString & |
iInnerKey = "" |
|
) |
[virtual] |
|
|
|
Set a property by name.
Which properites are supported and the format for each set is renegotiated as required. - Note:
- Each derived class needs to reimplement this method to support its own properties. Parent classes should be called AFTER the derived class checks, not before which is opposite to most similar classes.
Reimplemented in n2l::cGuiCanvas, n2l::cGuiLabel, n2l::cGuiModelView, n2l::cGuiSButton, n2l::cGuiSprite, and n2l::cGuiTextDisplay.
Definition at line 206 of file cGuiElement.cpp.
References n2l::cDynVar::isArray(), padding(), pos(), renderOrder(), n2l::cDynVar::size(), and size().
Referenced by n2l::cGuiSEColourTrans::actOn(), n2l::cGuiButton::cloneInto(), n2l::cGuiACSetProp::execute(), n2l::cGuiACIfProp::execute(), n2l::cGuiTextDisplay::prop(), n2l::cGuiSprite::prop(), n2l::cGuiSButton::prop(), n2l::cGuiModelView::prop(), n2l::cGuiLabel::prop(), and n2l::cGuiCanvas::prop(). |
| void n2l::cGuiElement::propertyChanged |
( |
|
) |
[protected, virtual] |
|
| const tSint & n2l::cGuiElement::renderOrder |
( |
|
) |
const [virtual] |
|
| void n2l::cGuiElement::renderOrder |
( |
const tSint |
iOrder |
) |
[virtual] |
|
| void n2l::cGuiElement::size |
( |
const tGuiPos & |
iSize |
) |
[virtual] |
|
| const tGuiPos & n2l::cGuiElement::size |
( |
|
) |
const [virtual] |
|
| void n2l::cGuiElement::stateChanged |
( |
|
) |
[protected, virtual] |
|
| virtual const tBool& n2l::cGuiElement::suicidal |
( |
|
) |
const [inline, virtual] |
|
| const tGuiPos & n2l::cGuiElement::topLeftPadding |
( |
|
) |
const [virtual] |
|
| void n2l::cGuiElement::unbindAction |
( |
const tActionBindingID |
iID, |
|
|
const tBool |
iUser |
|
) |
[protected, virtual] |
|
| void n2l::cGuiElement::unbindUserAction |
( |
const tActionBindingID |
iID |
) |
[virtual] |
|
| void n2l::cGuiElement::update |
( |
const tUint |
iTimePassed |
) |
[virtual] |
|
|
|
Inform the canvas how much time has passed since its last update, usually this is called once per frame.
Reimplemented in n2l::cGuiCanvas, n2l::cGuiModelView, and n2l::cGuiSButtonSelectBox.
Definition at line 308 of file cGuiElement.cpp.
References n2l::cDynVar::Array, broadcastAction(), n2l::GuiActionType_EffectComplete, n2l::GuiActionType_FirstUpdate, n2l::cDynVar::insert(), mEffects, and name().
Referenced by n2l::cGuiSButtonSelectBox::update(), n2l::cGuiModelView::update(), and n2l::cGuiCanvas::update(). |
|
|
A utility for inherited loaders, this checks for a required header, and then returns by reference the unserialization of the file buffer contents.
Definition at line 440 of file cGuiElement.cpp.
References n2l::cVfsNodeInterface::buffer(), n2l::cString::c_str(), n2l::cVfsNodeInterface::firstLine(), n2l::cVfsNodeInterface::likeFile(), n2l::cString::size(), and n2l::cDynVar::unserialize().
Referenced by n2l::cGuiTextStyle::load(), n2l::cGuiTextDisplay::load(), n2l::cGuiSprite::load(), n2l::cGuiSlider::load(), n2l::cGuiSButtonSelectBox::load(), n2l::cGuiSButton::load(), n2l::cGuiModelView::load(), n2l::cGuiLabel::load(), load(), n2l::cGuiCanvas::load(), n2l::cGuiButtonSelectBox::load(), and n2l::cGuiButton::load(). |
| const tBool n2l::cGuiElement::wantsFocus |
( |
|
) |
const [virtual] |
|
Friends And Related Function Documentation
Member Data Documentation
|
|
Definition at line 261 of file cGuiElement.h.
Referenced by n2l::cGuiInteractive::addExtraClickedData(), n2l::cGuiInteractive::addExtraFocusData(), n2l::cGuiInteractive::addExtraKeyData(), n2l::cGuiInteractive::addExtraOutData(), n2l::cGuiInteractive::addExtraOverData(), n2l::cGuiInteractive::addExtraPressedData(), n2l::cGuiInteractive::addExtraReleasedData(), cGuiElement(), name(), prop(), and n2l::cGuiSlider::value(). |
The documentation for this class was generated from the following files:
|