box.c
来自「这是一个开放源代码的与WINNT/WIN2K/WIN2003兼容的操作系统」· C语言 代码 · 共 45 行
C
45 行
/* ----------- box.c ------------ */
#include "dflat32/dflat.h"
int BoxProc(DFWINDOW wnd, DFMESSAGE msg, PARAM p1, PARAM p2)
{
int rtn;
DFWINDOW oldFocus;
CTLWINDOW *ct = GetControl(wnd);
static BOOL SettingFocus = FALSE;
if (ct != NULL)
{
switch (msg)
{
case SETFOCUS:
SettingFocus = isVisible(wnd);
rtn = BaseWndProc(BOX, wnd, msg, p1, p2);
SettingFocus = FALSE;
return rtn;
case PAINT:
return FALSE;
case LEFT_BUTTON:
case DFM_BUTTON_RELEASED:
return DfSendMessage(GetParent(wnd), msg, p1, p2);
case BORDER:
if (SettingFocus)
return TRUE;
oldFocus = inFocus;
inFocus = NULL;
rtn = BaseWndProc(BOX, wnd, msg, p1, p2);
inFocus = oldFocus;
if (ct != NULL)
if (ct->itext != NULL)
writeline(wnd, ct->itext, 1, 0, FALSE);
return rtn;
default:
break;
}
}
return BaseWndProc(BOX, wnd, msg, p1, p2);
}
/* EOF */
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?