ScummVM API documentation
MM::MM1::ViewsEnh::Locations::BlacksmithItems Class Reference
Inheritance diagram for MM::MM1::ViewsEnh::Locations::BlacksmithItems:
MM::MM1::ViewsEnh::ItemsView MM::MM1::BlacksmithData MM::MM1::BuyWeaponData MM::MM1::BuyArmorData MM::MM1::BuyMiscData MM::MM1::ViewsEnh::PartyView MM::MM1::ViewsEnh::ScrollView MM::MM1::ViewsEnh::TextView MM::MM1::UIElement

Public Member Functions

bool msgFocus (const FocusMessage &msg) override
 
void draw () override
 
bool msgKeypress (const KeypressMessage &msg) override
 
bool msgAction (const ActionMessage &msg) override
 
- Public Member Functions inherited from MM::MM1::ViewsEnh::ItemsView
 ItemsView (const Common::String &name)
 
bool msgMouseDown (const MouseDownMessage &msg) override
 
void timeout () override
 
- Public Member Functions inherited from MM::MM1::ViewsEnh::PartyView
 PartyView (const Common::String &name)
 
 PartyView (const Common::String &name, UIElement *owner)
 
void draw () override
 
bool msgFocus (const FocusMessage &msg) override
 
bool msgUnfocus (const UnfocusMessage &msg) override
 
bool msgMouseDown (const MouseDownMessage &msg) override
 
bool msgGame (const GameMessage &msg) override
 
bool msgAction (const ActionMessage &msg) override
 
- Public Member Functions inherited from MM::MM1::ViewsEnh::ScrollView
 ScrollView (const Common::String &name)
 
 ScrollView (const Common::String &name, UIElement *owner)
 
void clearButtons ()
 
int addButton (Shared::Xeen::SpriteResource *sprites, const Common::Point &pos, int frame, const Common::KeyState &key, bool halfSize=false)
 
int addButton (Shared::Xeen::SpriteResource *sprites, const Common::Point &pos, int frame, KeybindingAction action, bool halfSize=false)
 
int addButton (const Common::Rect &r, const Common::KeyState &key)
 
int addButton (const Common::Rect &r, KeybindingAction action)
 
void setButtonEnabled (int buttonNum, bool enabled)
 
bool isButtonEnabled (int buttonNum) const
 
void setButtonPos (int buttonNum, const Common::Point &pos)
 
void removeButtons (int start, int end=-2)
 
void resetSelectedButton ()
 
void draw () override
 
bool msgFocus (const FocusMessage &msg) override
 
bool msgMouseDown (const MouseDownMessage &msg) override
 
bool msgMouseUp (const MouseUpMessage &msg) override
 
- Public Member Functions inherited from MM::MM1::ViewsEnh::TextView
 TextView (const Common::String &name)
 
 TextView (const Common::String &name, UIElement *owner)
 
void setReduced (bool flag)
 
- Public Member Functions inherited from MM::MM1::UIElement
 UIElement (const Common::String &name, UIElement *uiParent)
 
bool needsRedraw () const
 
void redraw ()
 
void focus ()
 
virtual void close ()
 
bool isFocused () const
 
void replaceView (UIElement *ui, bool replaceAllViews=false)
 
void replaceView (const Common::String &name, bool replaceAllViews=false)
 
void addView (UIElement *ui)
 
void addView (const Common::String &name)
 
void addView ()
 
void open ()
 
int getRandomNumber (int minNumber, int maxNumber)
 
int getRandomNumber (int maxNumber)
 
Common::String getName () const
 
virtual void setBounds (const Common::Rect &r)
 
Common::Rect getBounds () const
 
Graphics::ManagedSurface getSurface () const
 
virtual bool tick ()
 
virtual UIElementfindView (const Common::String &name)
 
bool send (const Common::String &viewName, const FocusMessage &msg)
 
bool send (const FocusMessage &msg)
 
bool send (const Common::String &viewName, const UnfocusMessage &msg)
 
bool send (const UnfocusMessage &msg)
 
bool send (const Common::String &viewName, const KeypressMessage &msg)
 
bool send (const KeypressMessage &msg)
 
bool send (const Common::String &viewName, const MouseDownMessage &msg)
 
bool send (const MouseDownMessage &msg)
 
bool send (const Common::String &viewName, const MouseUpMessage &msg)
 
bool send (const MouseUpMessage &msg)
 
bool send (const Common::String &viewName, const ActionMessage &msg)
 
bool send (const ActionMessage &msg)
 
bool send (const Common::String &viewName, const GameMessage &msg)
 
bool send (const GameMessage &msg)
 
bool send (const Common::String &viewName, const HeaderMessage &msg)
 
bool send (const HeaderMessage &msg)
 
bool send (const Common::String &viewName, const InfoMessage &msg)
 
bool send (const InfoMessage &msg)
 
bool send (const Common::String &viewName, const DrawGraphicMessage &msg)
 
bool send (const DrawGraphicMessage &msg)
 

Protected Member Functions

int getLineColor () const override
 
void itemSelected () override
 
void charSwitched (Character *priorChar) override
 
- Protected Member Functions inherited from MM::MM1::ViewsEnh::ItemsView
void addButton (int frame, const Common::String &text, Common::KeyCode keycode)
 
void backpackFull ()
 
void notEnoughGold ()
 
void displayMessage (const Common::String &msg)
 
void clearButtons ()
 
- Protected Member Functions inherited from MM::MM1::ViewsEnh::PartyView
virtual bool canSwitchChar ()
 
virtual bool canSwitchToChar (Character *dst)
 
virtual bool selectCharByDefault () const
 
- Protected Member Functions inherited from MM::MM1::ViewsEnh::ScrollView
void frame ()
 
void fill ()
 
void writeSymbol (int symbolId)
 
int getButtonAt (const Common::Point &pos)
 
size_t getButtonCount () const
 
void drawButtons ()
 
- Protected Member Functions inherited from MM::MM1::ViewsEnh::TextView
byte setTextColor (byte col)
 
void writeChar (unsigned char c)
 
void writeChar (int x, int y, unsigned char c)
 
void writeString (const Common::String &str, TextAlign align=ALIGN_LEFT)
 
void writeString (int x, int y, const Common::String &str, TextAlign align=ALIGN_LEFT)
 
void writeNumber (int val)
 
void writeNumber (int x, int y, int val)
 
void writeLine (int lineNum, const Common::String &str, TextAlign align=ALIGN_LEFT, int xp=0)
 
size_t getStringWidth (const Common::String &str)
 
void newLine ()
 
Common::StringArray splitLines (const Common::String &str, int firstLineWidth=-1)
 
void clearSurface () override
 
void drawGraphic (int gfxNum)
 
- Protected Member Functions inherited from MM::MM1::UIElement
Common::Rect getLineBounds (int line1, int line2) const
 
void delaySeconds (uint seconds)
 
void delayFrames (uint frames)
 
bool isDelayActive () const
 
void cancelDelay ()
 
bool endDelay ()
 
virtual bool msgHeader (const HeaderMessage &e)
 
virtual bool msgInfo (const InfoMessage &e)
 
virtual bool msgDrawGraphic (const DrawGraphicMessage &e)
 

Additional Inherited Members

- Public Attributes inherited from MM::MM1::BlacksmithData
const byte BLACKSMITH_CLASS_USAGE [6] = { 0x20, 0x10, 8, 4, 2, 1 }
 
- Public Attributes inherited from MM::MM1::BuyWeaponData
const byte WEAPONS_TOWN1 [6] = { 2, 3, 5, 61, 62, 86 }
 
const byte WEAPONS_TOWN2 [6] = { 4, 6, 8, 63, 87, 88 }
 
const byte WEAPONS_TOWN3 [6] = { 9, 10, 62, 64, 89, 91 }
 
const byte WEAPONS_TOWN4 [6] = { 23, 67, 69, 93, 97, 99 }
 
const byte WEAPONS_TOWN5 [6] = { 7, 11, 64, 65, 90, 92 }
 
const byte * WEAPONS [5]
 
- Public Attributes inherited from MM::MM1::BuyArmorData
const byte ARMOR_TOWN1 [6] = { 156, 121, 122, 123, 124, 125 }
 
const byte ARMOR_TOWN2 [6] = { 156, 157, 121, 122, 123, 124 }
 
const byte ARMOR_TOWN3 [6] = { 157, 121, 124, 125, 126, 127 }
 
const byte ARMOR_TOWN4 [6] = { 160, 128, 131, 132, 133, 134 }
 
const byte ARMOR_TOWN5 [6] = { 157, 123, 124, 125, 126, 127 }
 
const byte * ARMOR [5]
 
- Public Attributes inherited from MM::MM1::BuyMiscData
const byte MISC_TOWN1 [6] = { 172, 171, 175, 178, 185, 192 }
 
const byte MISC_TOWN2 [6] = { 172, 171, 174, 183, 188, 195 }
 
const byte MISC_TOWN3 [6] = { 173, 175, 176, 179, 184, 195 }
 
const byte MISC_TOWN4 [6] = { 180, 196, 211, 215, 219, 223 }
 
const byte MISC_TOWN5 [6] = { 171, 173, 177, 185, 186, 192 }
 
const byte * MISC [5]
 
- Protected Types inherited from MM::MM1::ViewsEnh::ItemsView
enum  CostMode { SHOW_COST, SHOW_VALUE, NO_COST }
 
- Protected Attributes inherited from MM::MM1::ViewsEnh::ItemsView
int _selectedItem = -1
 
CostMode _costMode = NO_COST
 
Common::Array< int > _items
 
const Common::Rect _buttonsArea
 
Shared::Xeen::SpriteResource _btnSprites
 
Common::StringArray _btnText
 
- Protected Attributes inherited from MM::MM1::ViewsEnh::ScrollView
Common::Point _symbolPos
 
- Protected Attributes inherited from MM::MM1::ViewsEnh::TextView
Common::Point _textPos
 
int _colorsNum = 0
 
bool _fontReduced = false
 
- Protected Attributes inherited from MM::MM1::UIElement
UIElement_parent
 
Common::Array< UIElement * > _children
 
Common::Rect _innerBounds
 
Bounds _bounds
 
bool _needsRedraw = true
 
Common::String _name
 

Member Function Documentation

◆ getLineColor()

int MM::MM1::ViewsEnh::Locations::BlacksmithItems::getLineColor ( ) const
overrideprotectedvirtual

Get the text color for a line

Reimplemented from MM::MM1::ViewsEnh::ItemsView.

◆ itemSelected()

void MM::MM1::ViewsEnh::Locations::BlacksmithItems::itemSelected ( )
overrideprotectedvirtual

Called when an item is selected

Implements MM::MM1::ViewsEnh::ItemsView.

◆ charSwitched()

void MM::MM1::ViewsEnh::Locations::BlacksmithItems::charSwitched ( Character priorChar)
overrideprotectedvirtual

When the selected character is changed

Reimplemented from MM::MM1::ViewsEnh::PartyView.

◆ draw()

void MM::MM1::ViewsEnh::Locations::BlacksmithItems::draw ( )
overridevirtual

Draws the element

Reimplemented from MM::MM1::ViewsEnh::ItemsView.


The documentation for this class was generated from the following file: