summaryrefslogtreecommitdiff
path: root/include/d/lyt/msg_window/d_lyt_msg_window_demo.h
blob: dad4d33290237c5676540b17a38d7ac9a5913c07 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
#ifndef D_LYT_MSG_WINDOW_DEMO_H
#define D_LYT_MSG_WINDOW_DEMO_H

#include "d/d_tag_processor.h"
#include "d/d_textwindow_unk.h"
#include "d/lyt/d2d.h"
#include "d/lyt/d_textbox.h"
#include "d/lyt/msg_window/d_lyt_msg_window_common.h"
#include "m/m_vec.h"
#include "nw4r/lyt/lyt_pane.h"
#include "s/s_State.hpp"
#include "sized_string.h"

class dLytMsgWindowDemo_c : public dLytMsgWindowSubtype {
public:
    dLytMsgWindowDemo_c() : mStateMgr(*this) {}
    /* vt 0x08 */ virtual ~dLytMsgWindowDemo_c() {}
    /* vt 0x0C */ virtual void draw() override;
    /* vt 0x10 */ virtual bool
    build(d2d::ResAccIf_c *resAcc1, d2d::ResAccIf_c *resAcc, dTagProcessor_c *tagProcessor) override;
    /* vt 0x14 */ virtual bool remove() override;
    /* vt 0x18 */ virtual bool execute() override;
    /* vt 0x1C */ virtual void open(dAcObjBase_c *obj, u32 param) override;
    /* vt 0x20 */ virtual bool isDoneOpening() const override;
    /* vt 0x24 */ virtual void close() override;
    /* vt 0x28 */ virtual bool isDoneClosing() const override;
    /* vt 0x2C */ virtual bool setText(const wchar_t *text) override;
    /* vt 0x30 */ virtual dTextBox_c *getTextBox() override {
        return mpTextboxes[0];
    }

    dLytMsgWindowCharData *getCharData() {
        return mBlurRelated.getCharData();
    }

    STATE_FUNC_DECLARE(dLytMsgWindowDemo_c, Invisible);
    STATE_FUNC_DECLARE(dLytMsgWindowDemo_c, In);
    STATE_FUNC_DECLARE(dLytMsgWindowDemo_c, Visible);
    STATE_FUNC_DECLARE(dLytMsgWindowDemo_c, Out);

private:
    static SizedString<64> getTextLabel();

    MSG_WINDOW_STATE_MGR_INLINE(dLytMsgWindowDemo_c)
    /* 0x010 */ UI_STATE_MGR_DECLARE(dLytMsgWindowDemo_c);
    /* 0x04C */ d2d::ResAccIf_c mResAcc;
    /* 0x3BC */ d2d::LytBase_c mLyt;
    /* 0x44C */ d2d::AnmGroup_c mAnm[2];

    /* 0x4CC */ nw4r::lyt::Pane *mpPane;
    /* 0x4D0 */ dTextBox_c *mpTextboxes[2];
    /* 0x4D8 */ dTagProcessor_c *mpTagProcessor;
    /* 0x4DC */ mVec2_c mOffsets[2];
    /* 0x4EC */ dLytTextLight mText;
    /* 0x5C8 */ MsgWindowBlurRelated mBlurRelated;

    /* 0x55B8 */ bool mShouldBeOpen;
};

#endif