1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
62
69
70
74
75
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
101
108
113
114
118
125
126
127
128
132
133
134
135
136
137
138
139
142
143
144
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
192
193
194
195
196
197
198
199
200
201
202
205
206
207
208
209
213
219
220
224
230
231
235
260
261
265
266
267
268
269
270
271
272
273
285
286
287
291
292
293
294
295
296
297
298
299
302
303
304
305
306
307
308
309
310
311
312
313
314
319
344
346
347
348
349
353
374
375
379
390
391
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
438
439
440
441
442
443
444
445
446
447
448
449
455
459
462
463
467
468
469
470
471
472
473
476
477
478
482
483
488
489
490
494
495
496
497
498
499
500
503
508
509
510
511
515
516
517
518
519
522
523
524
525
529
530
531
532
537
540
541
548
549
550
551
552
553
554
555
558
559
560
561
562
563
564
565
568
569
570
571
574
575
576
577
581
584
585
589
592
593
597
600
601
605
609
610
614
618
619
626
631
632
636
640
641
645
653
654
658
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
707
708
709
710
711
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
736
740
741
745
746
747
748
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
774
775
776
777
778
779
791
792
795
/* ... */
/* ... */
#include "GUIDEMO.h"
#include "main.h"
/* ... */
static const GUI_WIDGET_CREATE_INFO _aFrameWinControl[] = {
{ FRAMEWIN_CreateIndirect, "Control", 0, 0, 0, CONTROL_SIZE_X, CONTROL_SIZE_Y, 0, 0 },
{ BUTTON_CreateIndirect, "Halt", GUI_ID_HALT, 2, 24, BUTTON_SIZE_X, BUTTON_SIZE_Y, 0, 0 },
{ BUTTON_CreateIndirect, "Next", GUI_ID_NEXT, 36, 24, BUTTON_SIZE_X, BUTTON_SIZE_Y, 0, 0 },
{ PROGBAR_CreateIndirect, 0, GUI_ID_PROGBAR0, 2, 11, PROGBAR_SIZE_X, PROGBAR_SIZE_Y, WM_CF_HIDE, 0 },
{ TEXT_CreateIndirect, 0, GUI_ID_TEXT0, 2, 2, TEXT_SIZE_X, TEXT_SIZE_Y, 0, 0 }
...};
static const GUI_WIDGET_CREATE_INFO _aFrameWinInfo[] = {
{ FRAMEWIN_CreateIndirect, "STemWin Demo", 0, 0, 0, 0, 0, 0, 0 },
{ TEXT_CreateIndirect, "", GUI_ID_TEXT0, 3, 3, 0, 0, 0, 0 }
...};
/* ... */
static GUIDEMO_CONFIG _GUIDemoConfig;
static WM_HWIN _hDialogControl;
static WM_HWIN _hDialogInfo;
static void (* _pfDrawBk)(int DrawLogo);
static int _iDemo;
static int _iDemoMinor;
static int _HaltTime;
static int _HaltTimeStart;
static int _Halt;
static int _Next;
static int _Pressed;
static U8 _DrawLogo;
/* ... */
/* ... */
static void _ClearHalt(void) {
_Halt = 0;
_HaltTime = 0;
_HaltTimeStart = 0;
}{ ... }
/* ... */
static void _DrawBkSimple(int DrawLogo) {
GUI_SetBkColor(BK_COLOR_1);
GUI_Clear();
if (DrawLogo) {
GUI_DrawBitmap(&bmSTLogo70x35, 5, 5);
}if (DrawLogo) { ... }
}{ ... }
#if GUIDEMO_USE_AUTO_BK
/* ... */
static void _DrawBk(int DrawLogo) {
int xSize;
int ySize;
xSize = LCD_GetXSize();
ySize = LCD_GetYSize();
GUI_DrawGradientV(0, 0, xSize, ySize, BK_COLOR_0, BK_COLOR_1);
if (DrawLogo) {
GUI_DrawBitmap(&bmSTLogo70x35, 5, 5);
}if (DrawLogo) { ... }
}{ ... }
/* ... */
static void _DrawBkCircle(int DrawLogo) {
static GUI_MEMDEV_Handle hMemStretch;
GUI_MEMDEV_Handle hMemGradient;
GUI_MEMDEV_Handle hMemCircle;
GUI_MEMDEV_Handle hMemOld;
int CircleWidth;
int ySizeV;
int xSize;
int ySize;
int i;
U32 * pData;
xSize = LCD_GetXSize();
ySize = LCD_GetYSize();
ySizeV = LCD_GetVYSize();
if (ySizeV > ySize) {
GUI_SetBkColor(BK_COLOR_1);
GUI_ClearRect(0, 0, xSize, ySizeV);
}if (ySizeV > ySize) { ... }
if (hMemStretch == 0) {
CircleWidth = (CIRCLE_RADIUS << 1) + 1;
hMemCircle = GUI_MEMDEV_CreateFixed(0, 0, CircleWidth, CircleWidth, GUI_MEMDEV_NOTRANS, GUI_MEMDEV_APILIST_32, GUI_COLOR_CONV_8888);
hMemStretch = GUI_MEMDEV_CreateEx (0, 0, xSize, ySize, GUI_MEMDEV_NOTRANS);
hMemGradient = GUI_MEMDEV_CreateFixed(0, 0, 1, CIRCLE_RADIUS, GUI_MEMDEV_NOTRANS, GUI_MEMDEV_APILIST_32, GUI_COLOR_CONV_8888);
hMemOld = GUI_MEMDEV_Select(hMemCircle);
GUI_SetBkColor(BK_COLOR_1);
GUI_Clear();
GUI_MEMDEV_Select(hMemGradient);
GUI_DrawGradientV(0, 0, 0, CIRCLE_RADIUS, BK_COLOR_0, BK_COLOR_1);
pData = (U32 *)GUI_MEMDEV_GetDataPtr(hMemGradient);
GUI_MEMDEV_Select(hMemCircle);
for (i = 0; i < CIRCLE_RADIUS; i++, pData++) {
GUI_SetColor(*pData);
GUI_DrawCircle(CIRCLE_RADIUS, CIRCLE_RADIUS, i);
}for (i = 0; i < CIRCLE_RADIUS; i++, pData++) { ... }
GUI_MEMDEV_Select(hMemStretch);
GUI_MEMDEV_DrawPerspectiveX(hMemCircle, 0, 0, ySize, ySize, xSize, 0);
GUI_MEMDEV_Delete(hMemCircle);
GUI_MEMDEV_Delete(hMemGradient);
GUI_MEMDEV_Select(hMemOld);
}if (hMemStretch == 0) { ... }
GUI_MEMDEV_Write(hMemStretch);
if (DrawLogo) {
GUI_DrawBitmap(&bmSTLogo70x35, LOGO_DIST_BORDER, LOGO_DIST_BORDER);
}if (DrawLogo) { ... }
}{ ... }
/* ... */#endif
/* ... */
static void _HideProgress(void) {
PROGBAR_Handle hProg;
hProg = WM_GetDialogItem(_hDialogControl, GUI_ID_PROGBAR0);
WM_HideWindow(hProg);
}{ ... }
/* ... */
static void _ShowProgress(void) {
PROGBAR_Handle hProg;
hProg = WM_GetDialogItem(_hDialogControl, GUI_ID_PROGBAR0);
WM_ShowWindow(hProg);
}{ ... }
/* ... */
static void _cbBk(WM_MESSAGE * pMsg) {
WM_KEY_INFO * pInfo;
switch (pMsg->MsgId) {
case WM_PAINT:
_pfDrawBk(_DrawLogo);
break;case WM_PAINT:
case WM_SET_FOCUS:
pMsg->Data.v = 0;
break;case WM_SET_FOCUS:
case WM_KEY:
pInfo = (WM_KEY_INFO *)pMsg->Data.p;
if (pInfo->PressedCnt) {
switch (pInfo->Key) {
case 'n':
_Next = 1;
break;case 'n':
}switch (pInfo->Key) { ... }
}if (pInfo->PressedCnt) { ... }
break;case WM_KEY:
default:
WM_DefaultProc(pMsg);
break;default
}switch (pMsg->MsgId) { ... }
}{ ... }
/* ... */
static int _cbEffect(int TimeRem, void * pVoid) {
GUI_PID_STATE State;
int Pressed;
GUI_USE_PARA(TimeRem);
Pressed = *((int *)pVoid);
GUI_Exec();
GUI_PID_GetState(&State);
if (State.Pressed) {
*((int *)pVoid) = 1;
return 0;
}if (State.Pressed) { ... } else {
if ((State.Pressed == 0) && (Pressed == 1)) {
*((int *)pVoid) = 0;
_Next = 1;
return 1;
}if ((State.Pressed == 0) && (Pressed == 1)) { ... }
_Next = GUIDEMO_CheckCancel();
return _Next;
}else { ... }
}{ ... }
/* ... */
static void _cbFrameWinControl(WM_MESSAGE * pMsg) {
WM_HWIN hItem;
int xSize;
int ySize;
int NCode;
int Id;
switch (pMsg->MsgId) {
case WM_KEY:
WM_SendMessage(WM_HBKWIN, pMsg);
break;case WM_KEY:
case WM_INIT_DIALOG:
hItem = WM_GetDialogItem(pMsg->hWin, GUI_ID_PROGBAR0);
PROGBAR_SetTextAlign(hItem, GUI_TA_HCENTER | GUI_TA_VCENTER);
PROGBAR_SetFont(hItem, &GUI_FontD6x8);
hItem = WM_GetDialogItem(pMsg->hWin, GUI_ID_HALT);
BUTTON_SetFocussable(hItem, 0);
hItem = WM_GetDialogItem(pMsg->hWin, GUI_ID_NEXT);
BUTTON_SetFocussable(hItem, 0);
hItem = WM_GetDialogItem(pMsg->hWin, GUI_ID_TEXT0);
TEXT_SetText(hItem, "Intro");
TEXT_SetFont(hItem, &GUI_Font8_ASCII);
break;case WM_INIT_DIALOG:
case WM_PAINT:
xSize = WM_GetWindowSizeX(pMsg->hWin);
ySize = WM_GetWindowSizeY(pMsg->hWin);
GUI_DrawGradientV(0, 0, xSize - 1, ySize - 1, 0xFFFFFF, 0xDCCEC0);
break;case WM_PAINT:
case WM_NOTIFY_PARENT:
Id = WM_GetId(pMsg->hWinSrc);
NCode = pMsg->Data.v;
switch (NCode) {
case WM_NOTIFICATION_RELEASED:
switch (Id) {
case GUI_ID_HALT:
if (_Halt) {
_Halt = 0;
_HaltTime = GUI_GetTime() - _HaltTimeStart;
WM_MakeModal(0);
}if (_Halt) { ... } else {
_Halt = 1;
_HaltTimeStart = GUI_GetTime() - _HaltTime;
WM_MakeModal(pMsg->hWin);
}else { ... }
break;case GUI_ID_HALT:
case GUI_ID_NEXT:
_Next = 1;
_ClearHalt();
break;case GUI_ID_NEXT:
}switch (Id) { ... }
break;case WM_NOTIFICATION_RELEASED:
}switch (NCode) { ... }
break;case WM_NOTIFY_PARENT:
default:
WM_DefaultProc(pMsg);default
}switch (pMsg->MsgId) { ... }
}{ ... }
/* ... */
static void _cbFrameWinInfo(WM_MESSAGE * pMsg) {
int xSize;
int ySize;
switch (pMsg->MsgId) {
case WM_KEY:
WM_SendMessage(WM_HBKWIN, pMsg);
break;case WM_KEY:
case WM_CREATE:
xSize = LCD_GetXSize();
WM_SetWindowPos(pMsg->hWin, xSize >> 1, 0, xSize >> 1, INFO_SIZE_Y);
break;case WM_CREATE:
case WM_PAINT:
xSize = WM_GetWindowSizeX(pMsg->hWin);
ySize = WM_GetWindowSizeY(pMsg->hWin);
GUI_DrawGradientV(0, 0, xSize - 1, ySize - 1, 0xFFFFFF, 0xDCCEC0);
break;case WM_PAINT:
default:
WM_DefaultProc(pMsg);default
}switch (pMsg->MsgId) { ... }
}{ ... }
/* ... */
static int _FRAMEWIN_DrawSkinFlex(const WIDGET_ITEM_DRAW_INFO * pDrawItemInfo) {
switch (pDrawItemInfo->Cmd) {
case WIDGET_ITEM_CREATE:
FRAMEWIN_SetTextAlign(pDrawItemInfo->hWin, GUI_TA_HCENTER | GUI_TA_VCENTER);
FRAMEWIN_SetTextColor(pDrawItemInfo->hWin, GUI_BLACK);
break;case WIDGET_ITEM_CREATE:
default:
return FRAMEWIN_DrawSkinFlex(pDrawItemInfo);default
}switch (pDrawItemInfo->Cmd) { ... }
return 0;
}{ ... }
/* ... */
static void _Main(void) {
int xSize;
int ySize;
WM_SelectWindow(WM_HBKWIN);
GUI_Clear();
#if (GUI_SUPPORT_CURSOR | GUI_SUPPORT_TOUCH)
#endif
xSize = LCD_GetXSize();
ySize = LCD_GetYSize();
_hDialogControl = GUI_CreateDialogBox(_aFrameWinControl, GUI_COUNTOF(_aFrameWinControl), &_cbFrameWinControl, WM_HBKWIN, xSize - CONTROL_SIZE_X, ySize - CONTROL_SIZE_Y);
_hDialogInfo = GUI_CreateDialogBox(_aFrameWinInfo, GUI_COUNTOF(_aFrameWinInfo), &_cbFrameWinInfo, WM_HBKWIN, (xSize >> 1) - 1, 0);
WM_HideWindow(_hDialogInfo);
WM_InvalidateWindow(_hDialogControl);
WM_DisableMemdev(WM_HBKWIN);
GUI_Exec();
WM_EnableMemdev(WM_HBKWIN);
GUI_SetBkColor(GUI_RED);
GUI_Clear();
GUI_SetBkColor(GUI_GREEN);
GUI_Clear();
GUI_SetBkColor(GUI_BLUE);
GUI_Clear();
GUIDEMO_Intro();
for (_iDemo = 0; _GUIDemoConfig.apFunc[_iDemo]; _iDemo++) {
_ClearHalt();
GUIDEMO_UpdateControlText();
(*_GUIDemoConfig.apFunc[_iDemo])();
_iDemoMinor = 0;
_Pressed = 0;
}for (_iDemo = 0; _GUIDemoConfig.apFunc[_iDemo]; _iDemo++) { ... }
_iDemo = 0;
WM_DeleteWindow(_hDialogControl);
WM_DeleteWindow(_hDialogInfo);
#if (GUI_SUPPORT_CURSOR | GUI_SUPPORT_TOUCH)
GUI_CURSOR_Hide();
#endif
}{ ... }
/* ... */
/* ... */
void GUIDEMO_SetDrawLogo(U8 OnOff) {
_DrawLogo = OnOff ? 1 : 0;
}{ ... }
/* ... */
void GUIDEMO_AddIntToString(char * pText, unsigned int Number) {
int TextLen;
int LenNum;
int i;
TextLen = 0;
while (*(pText + TextLen)) {
TextLen++;
}while (*(pText + TextLen)) { ... }
i = 1;
LenNum = 1;
while ((Number / i) >= 10) {
i *= 10;
LenNum++;
}while ((Number / i) >= 10) { ... }
*(pText + TextLen + LenNum) = '\0';
while (LenNum) {
*(pText + TextLen + LenNum - 1) = '0' + Number % 10;
Number /= 10;
LenNum--;
}while (LenNum) { ... }
}{ ... }
/* ... */
void GUIDEMO_AddStringToString(char * pText, const char * acAdd) {
int i;
int j;
i = 0;
j = 0;
while (*(pText + i)) {
i++;
}while (*(pText + i)) { ... }
while (*(acAdd + j)) {
*(pText + i) = *(acAdd + j);
i++;
j++;
}while (*(acAdd + j)) { ... }
*(pText + i) = '\0';
}{ ... }
/* ... */
int GUIDEMO_CheckCancel(void) {
while (_Halt == 1) {
GUI_Delay(10);
}while (_Halt == 1) { ... }
if (_Next == 1) {
_Next = 0;
return 1;
}if (_Next == 1) { ... }
return 0;
}{ ... }
/* ... */
void GUIDEMO_ClearText(char * pText) {
*pText = 0;
}{ ... }
/* ... */
void GUIDEMO_Delay(int TimeDelay) {
PROGBAR_Handle hProg;
int NextState;
U32 TimeStart;
U32 TimeDiff;
hProg = WM_GetDialogItem(_hDialogControl, GUI_ID_PROGBAR0);
if (TimeDelay > SHOW_PROGBAR_AT) {
_ShowProgress();
}if (TimeDelay > SHOW_PROGBAR_AT) { ... }
PROGBAR_SetValue(hProg, 0);
PROGBAR_SetMinMax(hProg, 0, TimeDelay);
TimeStart = GUI_GetTime();
do {
TimeDiff = GUIDEMO_GetTime() - TimeStart;
if (TimeDelay > SHOW_PROGBAR_AT) {
PROGBAR_SetValue(hProg, TimeDiff);
}if (TimeDelay > SHOW_PROGBAR_AT) { ... }
GUI_Delay(5);
NextState = GUIDEMO_CheckCancel();
...} while (TimeDiff < (U32)TimeDelay && !NextState);
if (TimeDelay > SHOW_PROGBAR_AT) {
_HideProgress();
}if (TimeDelay > SHOW_PROGBAR_AT) { ... }
GUI_Exec();
}{ ... }
/* ... */
void GUIDEMO_DrawBk(int DrawLogo) {
_pfDrawBk(DrawLogo);
}{ ... }
/* ... */
U16 GUIDEMO_GetConfFlag(U16 Flag) {
return (_GUIDemoConfig.Flags & Flag) ? 1 : 0;
}{ ... }
/* ... */
int GUIDEMO_GetTime(void) {
return _Halt ? _HaltTimeStart : GUI_GetTime() - _HaltTime;
}{ ... }
/* ... */
void GUIDEMO_HideControlWin(void) {
WM_HideWindow(_hDialogControl);
WM_ValidateWindow(WM_HBKWIN);
}{ ... }
/* ... */
void GUIDEMO_HideInfoWin(void) {
WM_HideWindow(_hDialogInfo);
WM_ValidateWindow(WM_HBKWIN);
}{ ... }
/* ... */
void GUIDEMO_NotifyStartNext(void) {
_iDemoMinor++;
_ClearHalt();
GUIDEMO_UpdateControlText();
}{ ... }
/* ... */
void GUIDEMO_ShowControlWin(void) {
WM_ShowWindow(_hDialogControl);
GUI_Exec();
}{ ... }
/* ... */
void GUIDEMO_ShowInfo(const char * acInfo) {
TEXT_Handle hText;
if (WM_IsVisible(_hDialogInfo)) {
hText = WM_GetDialogItem(_hDialogInfo, GUI_ID_TEXT0);
TEXT_SetText(hText, acInfo);
}if (WM_IsVisible(_hDialogInfo)) { ... }
}{ ... }
/* ... */
void GUIDEMO_ShowInfoWin(void) {
WM_ShowWindow(_hDialogInfo);
}{ ... }
/* ... */
void GUIDEMO_ShowIntro(const char * acTitle, const char * acDescription) {
int FontDistY;
int TimeWait;
int xCenter;
int yCenter;
int xSize;
int ySize;
int i;
xSize = LCD_GetXSize();
ySize = LCD_GetYSize();
xCenter = xSize >> 1;
yCenter = ySize >> 1;
GUIDEMO_HideInfoWin();
GUIDEMO_ShowControlWin();
GUI_Exec();
GUIDEMO_DrawBk(1);
GUI_SetColor(GUI_WHITE);
GUI_SetTextMode(GUI_TM_TRANS);
GUI_SetFont(&GUI_FontRounded22);
GUI_DispStringHCenterAt(acTitle, xCenter, 60);
GUI_SetFont(&GUI_Font16_ASCII);
FontDistY = GUI_GetFontDistY();
GUI_DispStringHCenterAt(acDescription, xCenter, yCenter - FontDistY + 10);
i = 0;
while (acDescription[i]) {
i++;
}while (acDescription[i]) { ... }
TimeWait = i * CHAR_READING_TIME;
GUIDEMO_Wait(TimeWait);
}{ ... }
/* ... */
void GUIDEMO_UpdateControlText(void) {
TEXT_Handle hText;
char acText[20] = { 0 };
hText = WM_GetDialogItem(_hDialogControl, GUI_ID_TEXT0);
GUIDEMO_AddStringToString(acText, "Demo ");
GUIDEMO_AddIntToString (acText, _iDemo + 1);
GUIDEMO_AddStringToString(acText, ".");
GUIDEMO_AddIntToString (acText, _iDemoMinor);
GUIDEMO_AddStringToString(acText, "/");
GUIDEMO_AddIntToString (acText, _GUIDemoConfig.NumDemos - 1);
TEXT_SetText (hText, acText);
}{ ... }
/* ... */
void GUIDEMO_Wait(int TimeWait) {
GUIDEMO_Delay(TimeWait);
GUIDEMO_NotifyStartNext();
}{ ... }
/* ... */
void GUIDEMO_Main(void) {
FRAMEWIN_SKINFLEX_PROPS Framewin_Props;
#if GUIDEMO_USE_AUTO_BK
int NumFreeBytes;
int BitsPerPixel;/* ... */
#endif
GUI_MEMDEV_SetAnimationCallback(_cbEffect, (void *)&_Pressed);
WM_SetCallback(WM_HBKWIN, _cbBk);
BUTTON_SetReactOnLevel();
FRAMEWIN_GetSkinFlexProps(&Framewin_Props, FRAMEWIN_SKINFLEX_PI_ACTIVE);
Framewin_Props.Radius = 0;
FRAMEWIN_SetSkinFlexProps(&Framewin_Props, FRAMEWIN_SKINFLEX_PI_ACTIVE);
FRAMEWIN_GetSkinFlexProps(&Framewin_Props, FRAMEWIN_SKINFLEX_PI_INACTIVE);
Framewin_Props.Radius = 0;
FRAMEWIN_SetSkinFlexProps(&Framewin_Props, FRAMEWIN_SKINFLEX_PI_INACTIVE);
FRAMEWIN_SetDefaultSkin (_FRAMEWIN_DrawSkinFlex);
PROGBAR_SetDefaultSkin (PROGBAR_SKIN_FLEX);
BUTTON_SetDefaultSkin (BUTTON_SKIN_FLEX);
SCROLLBAR_SetDefaultSkin (SCROLLBAR_SKIN_FLEX);
SLIDER_SetDefaultSkin (SLIDER_SKIN_FLEX);
HEADER_SetDefaultSkin (HEADER_SKIN_FLEX);
GUI_SetTextMode (GUI_TM_TRANS);
GUIDEMO_Config(&_GUIDemoConfig);
#if GUIDEMO_USE_VNC
if (GUIDEMO_GetConfFlag(GUIDEMO_CF_USE_VNC)) {
_GUIDemoConfig.pGUI_VNC_X_StartServer(0, 0);
}if (GUIDEMO_GetConfFlag(GUIDEMO_CF_USE_VNC)) { ... }
/* ... */ #endif
#if GUIDEMO_USE_AUTO_BK
BitsPerPixel = LCD_GetBitsPerPixel();
if ((BitsPerPixel >= 16) && GUIDEMO_GetConfFlag(GUIDEMO_CF_USE_AUTO_BK)) {
NumFreeBytes = GUI_ALLOC_GetNumFreeBytes();
if (NumFreeBytes > NUMBYTES_NEEDED) {
_pfDrawBk = _DrawBkCircle;
}if (NumFreeBytes > NUMBYTES_NEEDED) { ... } else {
_pfDrawBk = _DrawBk;
}else { ... }
}if ((BitsPerPixel >= 16) && GUIDEMO_GetConfFlag(GUIDEMO_CF_USE_AUTO_BK)) { ... } else
#endif
{
_pfDrawBk = _DrawBkSimple;
}else { ... }
GUIDEMO_SetDrawLogo(1);
while (1) {
_Main();
}while (1) { ... }
}{ ... }