mirror of
https://github.com/CloverHackyColor/CloverBootloader.git
synced 2025-01-04 18:17:41 +01:00
Add back full paths possibility to custom entries
This commit is contained in:
parent
d76962691b
commit
31079aea32
@ -1851,8 +1851,7 @@ FillinCustomEntry (
|
|||||||
Entry->ImagePath = NULL;
|
Entry->ImagePath = NULL;
|
||||||
}
|
}
|
||||||
if (!Entry->Image.isEmpty()) {
|
if (!Entry->Image.isEmpty()) {
|
||||||
XImage EmptyImage;
|
Entry->Image.setEmpty();
|
||||||
Entry->Image = EmptyImage;
|
|
||||||
}
|
}
|
||||||
if (Prop->type == kTagTypeString) {
|
if (Prop->type == kTagTypeString) {
|
||||||
Entry->ImagePath = PoolPrint (L"%a", Prop->string);
|
Entry->ImagePath = PoolPrint (L"%a", Prop->string);
|
||||||
@ -1874,8 +1873,7 @@ FillinCustomEntry (
|
|||||||
Entry->DriveImagePath = NULL;
|
Entry->DriveImagePath = NULL;
|
||||||
}
|
}
|
||||||
if (!Entry->DriveImage.isEmpty()) {
|
if (!Entry->DriveImage.isEmpty()) {
|
||||||
XImage EmptyImage;
|
Entry->DriveImage.setEmpty();
|
||||||
Entry->DriveImage = EmptyImage;
|
|
||||||
}
|
}
|
||||||
if (Prop->type == kTagTypeString) {
|
if (Prop->type == kTagTypeString) {
|
||||||
Entry->DriveImagePath = PoolPrint (L"%a", Prop->string);
|
Entry->DriveImagePath = PoolPrint (L"%a", Prop->string);
|
||||||
|
@ -1784,6 +1784,15 @@ STATIC VOID AddCustomEntry(IN UINTN CustomIndex,
|
|||||||
Image.LoadXImage(ThemeX.ThemeDir, Custom->ImagePath);
|
Image.LoadXImage(ThemeX.ThemeDir, Custom->ImagePath);
|
||||||
if (Image.isEmpty()) {
|
if (Image.isEmpty()) {
|
||||||
Image.LoadXImage(ThemeX.ThemeDir, XStringW() + L"os_"_XSW + Custom->ImagePath);
|
Image.LoadXImage(ThemeX.ThemeDir, XStringW() + L"os_"_XSW + Custom->ImagePath);
|
||||||
|
if (Image.isEmpty()) {
|
||||||
|
Image.LoadXImage(SelfDir, Custom->ImagePath);
|
||||||
|
if (Image.isEmpty()) {
|
||||||
|
Image.LoadXImage(SelfRootDir, Custom->ImagePath);
|
||||||
|
if (Image.isEmpty()) {
|
||||||
|
Image.LoadXImage(Volume->RootDir, Custom->ImagePath);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1791,6 +1800,15 @@ STATIC VOID AddCustomEntry(IN UINTN CustomIndex,
|
|||||||
DriveImage = Custom->DriveImage;
|
DriveImage = Custom->DriveImage;
|
||||||
if (DriveImage.isEmpty() && Custom->DriveImagePath) {
|
if (DriveImage.isEmpty() && Custom->DriveImagePath) {
|
||||||
DriveImage.LoadXImage(ThemeX.ThemeDir, Custom->DriveImagePath);
|
DriveImage.LoadXImage(ThemeX.ThemeDir, Custom->DriveImagePath);
|
||||||
|
if (DriveImage.isEmpty()) {
|
||||||
|
DriveImage.LoadXImage(SelfDir, Custom->ImagePath);
|
||||||
|
if (DriveImage.isEmpty()) {
|
||||||
|
DriveImage.LoadXImage(SelfRootDir, Custom->ImagePath);
|
||||||
|
if (DriveImage.isEmpty()) {
|
||||||
|
DriveImage.LoadXImage(Volume->RootDir, Custom->ImagePath);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
do
|
do
|
||||||
|
Loading…
Reference in New Issue
Block a user