diff --git a/rEFIt_UEFI/libeg/XTheme.cpp b/rEFIt_UEFI/libeg/XTheme.cpp new file mode 100644 index 000000000..b5f2a32ca --- /dev/null +++ b/rEFIt_UEFI/libeg/XTheme.cpp @@ -0,0 +1,5 @@ +/* + * a class to keep definitions for all theme settings + */ + +class XTheme; diff --git a/rEFIt_UEFI/libeg/XTheme.h b/rEFIt_UEFI/libeg/XTheme.h new file mode 100644 index 000000000..a330bf6ed --- /dev/null +++ b/rEFIt_UEFI/libeg/XTheme.h @@ -0,0 +1,73 @@ +#if !defined(__XTHEME_H__) +#define __XTHEME_H__ + +#include "../cpp_foundation/XToolsCommon.h" +#include "../cpp_foundation/XObjArray.h" +#include "../cpp_foundation/XStringW.h" +#include "libeg.h" +#include "XImage.h" + +class Icon +{ +public: + CONST CHAR8 Name; //for example "os_moja", "vol_internal" + XImage Image; +}; + +class XTheme +{ +public: + XObjArray Icons; + + UINTN DisableFlags; + UINTN HideBadges; + UINTN HideUIFlags; + BOOLEAN TextOnly; + FONT_TYPE Font; + INTN CharWidth; + UINTN SelectionColor; + XStringW FontFileName; + XStringW Theme; + XStringW BannerFileName; + XStringW SelectionSmallFileName; + XStringW SelectionBigFileName; + XStringW SelectionIndicatorName; + XStringW DefaultSelection; + XStringW BackgroundName; + SCALING BackgroundScale; + UINTN BackgroundSharp; + BOOLEAN BackgroundDark; + BOOLEAN CustomIcons; + BOOLEAN SelectionOnTop; + BOOLEAN BootCampStyle; + INTN BadgeOffsetX; + INTN BadgeOffsetY; + INTN BadgeScale; + INTN ThemeDesignWidth; + INTN ThemeDesignHeight; + INTN BannerPosX; + INTN BannerPosY; + INTN BannerEdgeHorizontal; + INTN BannerEdgeVertical; + INTN BannerNudgeX; + INTN BannerNudgeY; + BOOLEAN VerticalLayout; + BOOLEAN NonSelectedGrey; + INTN MainEntriesSize; + INTN TileXSpace; + INTN TileYSpace; + INTN IconFormat; + BOOLEAN Proportional; + BOOLEAN ShowOptimus; + BOOLEAN DarkEmbedded; + BOOLEAN TypeSVG; + INTN Codepage; + INTN CodepageSize; + float Scale; + float CentreShift; + +protected: + //internal layout variables instead of globals in menu.cpp + +}; +#endif \ No newline at end of file diff --git a/rEFIt_UEFI/libeg/libeg.h b/rEFIt_UEFI/libeg/libeg.h index 28173accd..b20b24333 100644 --- a/rEFIt_UEFI/libeg/libeg.h +++ b/rEFIt_UEFI/libeg/libeg.h @@ -142,6 +142,14 @@ extern "C" { /* types */ +typedef enum { + imNone, + imScale, + imCrop, + imTile + +} SCALING; + typedef enum { FONT_ALFA, FONT_GRAY, diff --git a/rEFIt_UEFI/refit/lib.h b/rEFIt_UEFI/refit/lib.h index 18d5e0346..7c4068ec0 100644 --- a/rEFIt_UEFI/refit/lib.h +++ b/rEFIt_UEFI/refit/lib.h @@ -402,13 +402,6 @@ extern INTN ScrollbarYMovement; #define HDBADGES_SHOW (1<<1) #define HDBADGES_INLINE (1<<2) -typedef enum { - imNone, - imScale, - imCrop, - imTile - -} SCALING; typedef struct { INTN Timeout;