rodecomp/Source/UI/Window/UINoteWnd.cpp
ragnarok-clanker 0c10747096 Decompile 12 functions in Source/UI/Quest/UIQuestDisplay.cpp, Source/UI/Quest/UIQuestDisplay.h, ...
Batch #7711 by secret: 0 byte-identical, 12 confirmed by peer review.

- fn_12846 UIAccountLimitedToolWnd::UIAccountLimitedToolWnd: logic confirmed by peer review
- fn_12847 UIBalloonOpenBtn::UIBalloonOpenBtn: logic confirmed by peer review
- fn_12848 UIDebuffRemoveWnd::UIDebuffRemoveWnd: logic confirmed by peer review
- fn_12850 UIMileageWnd::UIMileageWnd: logic confirmed by peer review
- fn_12852 UINoteWnd::UINoteWnd: logic confirmed by peer review
- fn_12853 UIOpenMailBoxWnd::UIOpenMailBoxWnd: logic confirmed by peer review
- fn_12854 UIOpenRoulletteWnd::UIOpenRoulletteWnd: logic confirmed by peer review
- fn_12855 UIQuestDisplay::UIQuestDisplay: logic confirmed by peer review
- fn_12856 UIRPImageWnd2::UIRPImageWnd2: logic confirmed by peer review
- fn_12857 UISecondCostumeWnd::UISecondCostumeWnd: logic confirmed by peer review
- fn_12858 UIShowWarpWnd::UIShowWarpWnd: logic confirmed by peer review
- fn_12859 UITransMenuWnd::UITransMenuWnd: logic confirmed by peer review

Peer-reviewed-by: eAthena, Yommy
Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
2026-10-31 11:28:47 +00:00

68 lines
1.9 KiB
C++

#include "UI/Window/UINoteWnd.h"
#include "Contents/MessageTable.h"
#include "UI/Buttons/UIBasicButton.h"
#include "UI/Lists/UIScrollBar.h"
#include "UI/Window/WindowBorder.h"
// OFFSET: 0x0094C2D0
// FUNCTION: fn_12895
void UINoteWnd::Slot15(int width, int height) {
UIBasicButton* button = new UIBasicButton(*this->m_context, *this->m_controls);
button->Configure(60, LookupMessage(0xBE5));
button->Move(width - 68, height - 26);
button->SetId(201);
this->AddChild(button);
this->m_scroll = new UINoteWnd_Scroll(*this->m_context, width - 35, height - 59);
this->m_scroll->Move(16, 16);
this->AddChild(this->m_scroll);
}
// OFFSET: 0x0094D870
// FUNCTION: fn_12907
void UINoteWnd::Paint() {
this->ClearSurface(0xFFFF00FF);
DrawFilledRoundedBorder(*this, 0, 0, this->geometry.width, this->geometry.height, 0xFFFFFF);
DrawRoundedBorder(*this, 2, 2, this->geometry.width - 4, this->geometry.height - 4, 0xC8C8C8);
this->FillRegion(8, 8, this->geometry.width - 16, this->geometry.height - 38, 0xF7F7F7);
}
// OFFSET: 0x0094D8E0
// FUNCTION: fn_12908
void UINoteWnd_Scroll::Paint() {
this->ClearSurface(0xF7F7F7);
}
// OFFSET: 0x0094EE80
// FUNCTION: fn_12919
void UINoteWnd_Scroll::Slot25(int x, int y) {
if (this->parent) {
this->parent->Slot25(x + 23, y + 27);
}
}
// OFFSET: 0x0094EF80
// FUNCTION: fn_12924
void UINoteWnd_Scroll::Slot31(int x, int y) {
if (this->parent) {
this->parent->Slot31(x + 23, y + 27);
}
}
// OFFSET: 0x0094F2C0
// FUNCTION: fn_12935
void UINoteWnd_Scroll::Slot35(int delta) {
if (this->wheelScroll == 1) {
if (delta < 0) {
this->SendMsg(this->scrollBar, 7, 12, 0, 0, 0);
} else {
this->SendMsg(this->scrollBar, 7, -12, 0, 0, 0);
}
}
}
// OFFSET: 0x00946D00
// FUNCTION: fn_12852
UINoteWnd::UINoteWnd(UIWindowContext& windows, UIFrameContext& frames, UIButtonContext& controls)
: UIFrameWnd(windows, frames, 0), m_scroll(nullptr), m_controls(&controls) {
}