Make WMCreateCommandButton into a proper function instead of a macro.

This commit is contained in:
2026-03-02 12:18:21 -05:00
parent eaabf7e20c
commit e882fd1f13
2 changed files with 9 additions and 5 deletions
+1 -5
View File
@@ -1039,11 +1039,7 @@ void WMCloseWindow(WMWindow *win);
void WMSetButtonAction(WMButton *bPtr, WMAction *action, void *clientData);
#define WMCreateCommandButton(parent) \
WMCreateCustomButton((parent), WBBSpringLoadedMask\
|WBBPushInMask\
|WBBPushLightMask\
|WBBPushChangeMask)
WMButton* WMCreateCommandButton(WMWidget *parent);
#define WMCreateRadioButton(parent) \
WMCreateButton((parent), WBTRadio)
+8
View File
@@ -216,6 +216,14 @@ WMButton *WMCreateButton(WMWidget * parent, WMButtonType type)
return bPtr;
}
WMButton *WMCreateCommandButton(WMWidget *parent)
{
return WMCreateCustomButton(
parent,
WBBSpringLoadedMask|WBBPushInMask|WBBPushLightMask|WBBPushChangeMask
);
}
static void updateDisabledMask(WMButton * bPtr)
{
WMScreen *scr = WMWidgetScreen(bPtr);