Decompile fn_11283 (UITabControl::TabCount)

Batch #1756 by ragnarok-clanker: 1 byte-identical, 0 confirmed by peer review.

- fn_11283 UITabControl::TabCount: byte-identical

Merged automatically: every function is byte-identical to the original.
This commit is contained in:
ragnarok-clanker 2026-10-28 22:02:36 +00:00
commit 715e4e7cde
5 changed files with 73 additions and 0 deletions

View file

@ -0,0 +1,17 @@
#ifndef RAGNAROK_SOURCE_UI_LISTS_UICHATHISBOX_H
#define RAGNAROK_SOURCE_UI_LISTS_UICHATHISBOX_H
#include "UI/Lists/UIListBox.h"
#include <string>
#include <vector>
class UIChatHisBox : public UIListBox {
public:
const char* HistoryText(unsigned int index);
/* 00DC */ unsigned char unknown_00DC[0x18];
/* 00F4 */ std::vector<std::string> history;
};
#endif

View file

@ -0,0 +1,16 @@
#ifndef RAGNAROK_SOURCE_UI_LISTS_UIIMGMENU_H
#define RAGNAROK_SOURCE_UI_LISTS_UIIMGMENU_H
#include "UI/Window/UIWindow.h"
class UIImgMenu : public UIWindow {
public:
int ItemAt(int x, int y);
/* 0080 */ int count;
/* 0084 */ int itemWidth;
/* 0088 */ int itemHeight;
/* 008C */ int horizontal;
};
#endif

View file

@ -29,6 +29,7 @@ public:
virtual void AddLine(const char* text, std::uint32_t color);
virtual void Clear();
virtual void Refresh();
int FindLine(const std::string& text);
/* 007C */ int backgroundRed;
/* 0080 */ int backgroundGreen;

View file

@ -4,6 +4,10 @@
#include "Resource/ResourceMgr.h"
#include "UI/Window/UIWindowMgr.h"
#include "UI/Lists/UIScrollBar.h"
#include "UI/Lists/UIChatHisBox.h"
#include "UI/Lists/UIImgMenu.h"
#include "UI/Lists/UIListBoxEx.h"
#include "UI/Lists/UITabControl.h"
#include <algorithm>
@ -315,3 +319,17 @@ void UIScrollBar::Configure(int x, int y, unsigned char vertical, int length) {
this->Slot15(width, height);
this->Slot22(width, height);
}
// OFFSET: 0x00880800
// OFFSET: 0x00880920
// OFFSET: 0x00880B20
// FUNCTION: fn_11283
int UITabControl::TabCount() {
return static_cast<int>(this->labels.size());
}
// OFFSET: 0x00880B40
// OFFSET: 0x00880BB0

View file

@ -0,0 +1,21 @@
#ifndef RAGNAROK_SOURCE_UI_LISTS_UITABCONTROL_H
#define RAGNAROK_SOURCE_UI_LISTS_UITABCONTROL_H
#include "UI/Window/UIWindow.h"
#include <string>
#include <vector>
class UITabControl : public UIWindow {
public:
int TabCount();
int TabAt(int x, int y);
/* 0080 */ int layout;
/* 0084 */ unsigned char unknown_0084[0x30];
/* 00B4 */ std::vector<std::string> labels;
/* 00C0 */ unsigned char unknown_00C0[0xC];
/* 00CC */ std::vector<int> widths;
};
#endif