2020-04-04 14:27:02 +02:00
|
|
|
#ifndef __MENU_H__
|
|
|
|
#define __MENU_H__
|
|
|
|
|
|
|
|
#include "../cpp_foundation/XStringW.h"
|
|
|
|
#include "../gui/menu_items/menu_items.h"
|
2020-02-29 08:30:21 +01:00
|
|
|
|
2020-03-03 21:44:07 +01:00
|
|
|
//VOID AddMenuInfoLine(IN REFIT_MENU_SCREEN *Screen, IN CONST CHAR16 *InfoLine);
|
|
|
|
//VOID AddMenuInfo(IN REFIT_MENU_SCREEN *SubScreen, IN CONST CHAR16 *Line);
|
|
|
|
//VOID AddMenuEntry(IN REFIT_MENU_SCREEN *Screen, IN REFIT_MENU_ENTRY *Entry, bool freeIt);
|
|
|
|
//VOID AddMenuCheck(REFIT_MENU_SCREEN *SubScreen, CONST CHAR8 *Text, UINTN Bit, INTN ItemNum);
|
|
|
|
//VOID FreeMenu(IN REFIT_MENU_SCREEN *Screen);
|
|
|
|
//UINTN RunMenu(IN REFIT_MENU_SCREEN *Screen, OUT REFIT_ABSTRACT_MENU_ENTRY **ChosenEntry);
|
|
|
|
//UINTN RunMainMenu(IN REFIT_MENU_SCREEN *Screen, IN INTN DefaultSelection, OUT REFIT_ABSTRACT_MENU_ENTRY **ChosenEntry);
|
2020-03-27 06:54:41 +01:00
|
|
|
|
2020-04-04 14:27:02 +02:00
|
|
|
extern EG_IMAGE* ScrollbarImage;
|
|
|
|
extern EG_IMAGE* UpButtonImage;
|
|
|
|
extern EG_IMAGE* DownButtonImage;
|
|
|
|
extern EG_IMAGE* ScrollbarBackgroundImage;
|
|
|
|
extern EG_IMAGE* BarStartImage;
|
|
|
|
extern EG_IMAGE* BarEndImage;
|
|
|
|
extern EG_IMAGE* ScrollStartImage;
|
|
|
|
extern EG_IMAGE* ScrollEndImage;
|
|
|
|
|
|
|
|
extern EG_RECT UpButton;
|
|
|
|
extern EG_RECT DownButton;
|
|
|
|
extern EG_RECT BarStart;
|
|
|
|
extern EG_RECT BarEnd;
|
|
|
|
extern EG_RECT ScrollbarBackground;
|
|
|
|
extern EG_RECT Scrollbar;
|
|
|
|
extern EG_RECT ScrollStart;
|
|
|
|
extern EG_RECT ScrollEnd;
|
|
|
|
extern EG_RECT ScrollTotal;
|
|
|
|
extern EG_RECT ScrollbarOldPointerPlace;
|
|
|
|
extern EG_RECT ScrollbarNewPointerPlace;
|
|
|
|
|
|
|
|
extern INTN LayoutAnimMoveForMenuX;
|
|
|
|
extern INTN LayoutMainMenuHeight;
|
|
|
|
|
|
|
|
|
|
|
|
extern INTN ScrollWidth;
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-05 06:35:55 +02:00
|
|
|
#if !USE_XTHEME
|
2020-04-05 16:04:39 +02:00
|
|
|
VOID InitBar(VOID);
|
2020-04-04 14:27:02 +02:00
|
|
|
VOID FillRectAreaOfScreen(IN INTN XPos, IN INTN YPos, IN INTN Width, IN INTN Height, IN EG_PIXEL *Color, IN UINT8 XAlign);
|
|
|
|
VOID InitSelection(VOID);
|
2020-04-05 16:04:39 +02:00
|
|
|
#endif
|
2020-04-04 14:27:02 +02:00
|
|
|
|
|
|
|
|
2020-03-05 04:37:21 +01:00
|
|
|
VOID OptionsMenu(OUT REFIT_ABSTRACT_MENU_ENTRY **ChosenEntry);
|
2020-02-29 08:30:21 +01:00
|
|
|
VOID FreeScrollBar(VOID);
|
2020-03-26 21:32:31 +01:00
|
|
|
#if USE_XTHEME
|
2020-04-01 14:57:32 +02:00
|
|
|
//it will be REFIT_SCREEN MEMBER, others as well?
|
2020-03-26 21:32:31 +01:00
|
|
|
#else
|
2020-02-29 08:30:21 +01:00
|
|
|
INTN DrawTextXY(IN CONST CHAR16 *Text, IN INTN XPos, IN INTN YPos, IN UINT8 XAlign);
|
2020-03-27 06:54:41 +01:00
|
|
|
VOID DrawMenuText(IN CONST CHAR16 *Text, IN INTN SelectedWidth, IN INTN XPos, IN INTN YPos, IN INTN Cursor);
|
2020-04-04 14:27:02 +02:00
|
|
|
VOID DrawMainMenuEntry(REFIT_ABSTRACT_MENU_ENTRY *Entry, BOOLEAN selected, INTN XPos, INTN YPos);
|
2020-02-29 08:30:21 +01:00
|
|
|
VOID DrawBCSText(IN CONST CHAR16 *Text, IN INTN XPos, IN INTN YPos, IN UINT8 XAlign);
|
2020-04-05 16:04:39 +02:00
|
|
|
VOID DrawTextCorner(UINTN TextC, UINT8 Align);
|
|
|
|
#endif
|
2020-02-29 08:30:21 +01:00
|
|
|
|
2020-03-03 21:44:07 +01:00
|
|
|
UINT64 TimeDiff(UINT64 t0, UINT64 t1); //double in Platform.h
|
|
|
|
|
2020-04-04 14:27:02 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|