Batch #6096 by eAthena: 0 byte-identical, 2 confirmed by peer review. - fn_16206 CUIListBoxEx<ProbabilityTable::CUIItem,ProbabilityTable::CItemData>::RebindIndex: logic confirmed by peer review - fn_16207 CUIProbabilityTable::SendMsg: logic confirmed by peer review Peer-reviewed-by: alisonrag, Lumen, Snow Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes). Adds to the build: Source/UI/ProbabilityTable/UIProbabilityTableEvents.cpp
53 lines
1.5 KiB
C++
53 lines
1.5 KiB
C++
#ifndef RAGNAROK_SOURCE_UI_PROBABILITYTABLE_UIPROBABILITYTABLE_H
|
|
#define RAGNAROK_SOURCE_UI_PROBABILITYTABLE_UIPROBABILITYTABLE_H
|
|
|
|
#include "UI/FrameSkin.h"
|
|
#include "UI/Lists/UIListBoxTemplate.h"
|
|
#include "UI/Text/UITextViewerControl.h"
|
|
|
|
#include <cstdint>
|
|
#include <string>
|
|
|
|
namespace ProbabilityTable {
|
|
|
|
class CItemData {
|
|
public:
|
|
/* 0000 */ std::uint32_t color;
|
|
/* 0004 */ std::string name;
|
|
/* 001C */ int unknown_001C;
|
|
/* 0020 */ double probability;
|
|
};
|
|
|
|
class CUIItem : public CUIListItem {
|
|
public:
|
|
void Slot15(int width, int height) override;
|
|
void Slot16() override;
|
|
void Paint() override;
|
|
void Slot25(int x, int y) override;
|
|
|
|
/* 00E8 */ CUITextViewer* nameText;
|
|
/* 00EC */ CUITextViewer* probabilityText;
|
|
/* 00F0 */ std::uint32_t backgroundColor;
|
|
/* 00F4 */ unsigned char unknown_00F4[0x04];
|
|
};
|
|
|
|
}
|
|
class CUIEditBoxEx;
|
|
class CUIProbabilityTable : public CUIFrameWnd {
|
|
public:
|
|
void Paint() override;
|
|
virtual void Slot53();
|
|
int SendMsg(UIWindow* sender, int message, std::intptr_t argument1, std::intptr_t argument2, std::intptr_t argument3, std::intptr_t argument4) override;
|
|
void OnButtonClick();
|
|
void OnPrepareItem(ProbabilityTable::CUIItem* item, const ProbabilityTable::CItemData& data);
|
|
|
|
/* 00D8 */ unsigned char unknown_00D8[0x08];
|
|
/* 00E0 */ CUIEditBoxEx* m_searchEdit;
|
|
};
|
|
|
|
#if defined(_WIN32) && !defined(_WIN64)
|
|
static_assert(sizeof(ProbabilityTable::CItemData) == 0x28);
|
|
static_assert(sizeof(ProbabilityTable::CUIItem) == 0xF8);
|
|
#endif
|
|
|
|
#endif
|