The following code illustrates adding the default size function to the system menu of a secondary window.
#define INCL_SW
#include <os2me.h>
HWND hwndFrame;
hwndFrame = WinLoadSecondaryWindow (HWND_DESKTOP, /* Parent window */
HWND_DESKTOP, /* Owner window */
MyDlgProc, /* Dialog procedure*/
NULL, /* Module handle */
ID_DIALOG, /* Resource ID */
NULL); /* Create parameter*/
WinInsertDefaultSize (hwndFrame, "~Default size"); /* Insert menu item */
WinDefaultSize (hwndFrame); /* Set window to its default size */