Use default parameter values in JORMContext calls where appropriate (#3057)

This commit is contained in:
Max Roncace
2026-01-19 21:18:30 -05:00
committed by GitHub
parent d83996c711
commit 1fba6e13e5
134 changed files with 5369 additions and 6826 deletions
+4 -1
View File
@@ -29,6 +29,8 @@
#define JORM_DEFAULT_WIDTH 0x200
#define JORM_DEFAULT_HEIGHT 0x18
#define JORM_DEFAULT_COMBOBOX_WIDTH 0x100
#define JORM_DEFAULT_COMBOBOX_HEIGHT 0x1a
#define DEFINE_GEN_CHECKBOX(T, kind) \
void genCheckBox(const char* label, T* pSrc, T mask, u32 style = 0, \
@@ -65,7 +67,8 @@
#define DEFINE_START_COMBO_BOX(T, kind) \
void startComboBox(const char* label, T* pSrc, u32 style = 0, \
JOREventListener* pListener = NULL, u16 posX = -1, u16 posY = -1, \
u16 width = JORM_DEFAULT_WIDTH, u16 height = JORM_DEFAULT_HEIGHT) { \
u16 width = JORM_DEFAULT_COMBOBOX_WIDTH, \
u16 height = JORM_DEFAULT_COMBOBOX_HEIGHT) { \
startSelectorSub('CMBX', kind, label, (uintptr_t)pSrc, style, *pSrc, pListener, posX, \
posY, width, height); \
}
+3 -5
View File
@@ -99,13 +99,11 @@ public:
virtual ~daObj_KamHIO_c() {}
void genMessage(JORMContext* context) {
// Golden insect (stag beetle)
context->genLabel("黄金蟲(カブト)", 0x80000001, 0, NULL, -1, -1, 0x200, 0x18);
context->genLabel("黄金蟲(カブト)", 0x80000001);
// Model scale (male)
context->genSlider("モデルスケール(オス)", &mModelScaleMale, 0.1f, 4.0f, 0, NULL, -1, -1, 0x200,
0x18);
context->genSlider("モデルスケール(オス)", &mModelScaleMale, 0.1f, 4.0f);
// Model scale (female)
context->genSlider("モデルスケール(メス)", &mModelScaleFemale, 0.1f, 4.0f, 0, NULL, -1, -1, 0x200,
0x18);
context->genSlider("モデルスケール(メス)", &mModelScaleFemale, 0.1f, 4.0f);
}
s8 field_0x4;
+3 -5
View File
@@ -100,13 +100,11 @@ public:
void genMessage(JORMContext* ctx) {
// Golden Snail
ctx->genLabel("黄金蟲(カタツムリ)", 0x80000001, 0, NULL, -1, -1, 0x200, 24);
ctx->genLabel("黄金蟲(カタツムリ)", 0x80000001);
// Model scale (male)
ctx->genSlider("モデルスケール(オス)", &this->mScaleMale, 0.1f, 4.0f, 0, NULL, -1, -1,
0x200, 24);
ctx->genSlider("モデルスケール(オス)", &this->mScaleMale, 0.1f, 4.0f);
// Model scale (female)
ctx->genSlider("モデルスケール(メス)", &this->mScaleFemale, 0.1f, 4.0f, 0, NULL, -1, -1,
0x200, 24);
ctx->genSlider("モデルスケール(メス)", &this->mScaleFemale, 0.1f, 4.0f);
}
s8 field_0x4;
+9 -13
View File
@@ -71,26 +71,22 @@ public:
#if DEBUG
void genMessage(JORMContext* ctx) {
// Speed
ctx->genLabel("--- 速 出現時---", 0, 0, NULL, 0xffff, 0xffff, 0x200, 0x18);
ctx->genLabel("--- 速 出現時---", 0);
// Initial speed
ctx->genSlider("初速", &mInitialSpeed, 0.0f, 10000.0f, 0, NULL, 0xffff, 0xffff, 0x200,
0x18);
ctx->genSlider("初速", &mInitialSpeed, 0.0f, 10000.0f);
// Max
ctx->genSlider("最大", &mMaxSpeed, 0.0f, 10000.0f, 0, NULL, 0xffff, 0xffff, 0x200, 0x18);
ctx->genSlider("最大", &mMaxSpeed, 0.0f, 10000.0f);
// Speed when pulling
ctx->genLabel("--- 速度 引っ込み時---", 0, 0, NULL, 0xffff, 0xffff, 0x200, 0x18);
ctx->genSlider("初速", &mInitialDownSpeed, 0.0, 10000.0, 0, NULL, 0xffff, 0xffff, 0x200,
0x18);
ctx->genLabel("--- 速度 引っ込み時---", 0);
ctx->genSlider("初速", &mInitialDownSpeed, 0.0, 10000.0);
// Max
ctx->genSlider("最大", &mMaxDownSpeed, 0.0f, 10000.0f, 0, NULL, 0xffff, 0xffff, 0x200,
0x18);
ctx->genSlider("最大", &mMaxDownSpeed, 0.0f, 10000.0f);
// Range
ctx->genSlider("範囲", &mRange, 0.1f, 1000.0f, 0, NULL, 0xffff, 0xffff, 0x200, 0x18);
ctx->genSlider("範囲", &mRange, 0.1f, 1000.0f);
// Spinner speed
ctx->genSlider("スピナー速度", &mSpinnerSpeed, 0.0f, 100.0f, 0, NULL, 0xffff, 0xffff, 0x200,
0x18);
ctx->genSlider("スピナー速度", &mSpinnerSpeed, 0.0f, 100.0f);
// Vibration
ctx->startComboBox("振動", &mVibration, 0, NULL, 0xffff, 0xffff, 0x100, 0x1a);
ctx->startComboBox("振動", &mVibration);
// Strength 1-8
ctx->genComboBoxItem("強さ1", 1);
ctx->genComboBoxItem("強さ2", 2);