mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-25 15:45:38 +00:00
Added support for more imageSource types to the Grid view style.
This commit is contained in:
parent
a6c3cb9798
commit
3355d6f208
|
@ -241,8 +241,16 @@ const std::string GridGameListView::getImagePath(FileData* file)
|
|||
|
||||
if (src == ImageSource::IMAGE)
|
||||
return file->getImagePath();
|
||||
else if (src == ImageSource::MIXIMAGE)
|
||||
return file->getMiximagePath();
|
||||
else if (src == ImageSource::SCREENSHOT)
|
||||
return file->getScreenshotPath();
|
||||
else if (src == ImageSource::COVER)
|
||||
return file->getCoverPath();
|
||||
else if (src == ImageSource::MARQUEE)
|
||||
return file->getMarqueePath();
|
||||
else if (src == ImageSource::BOX3D)
|
||||
return file->get3DBoxPath();
|
||||
|
||||
// If no thumbnail was found, then use the image media type.
|
||||
if (file->getThumbnailPath() == "")
|
||||
|
|
|
@ -25,7 +25,11 @@ enum ScrollDirection {
|
|||
enum ImageSource {
|
||||
THUMBNAIL,
|
||||
IMAGE,
|
||||
MARQUEE
|
||||
MIXIMAGE,
|
||||
SCREENSHOT,
|
||||
COVER,
|
||||
MARQUEE,
|
||||
BOX3D
|
||||
};
|
||||
|
||||
struct ImageGridData {
|
||||
|
@ -287,8 +291,16 @@ void ImageGridComponent<T>::applyTheme(const std::shared_ptr<ThemeData>& theme,
|
|||
auto direction = elem->get<std::string>("imageSource");
|
||||
if (direction == "image")
|
||||
mImageSource = IMAGE;
|
||||
else if (direction == "miximage")
|
||||
mImageSource = MIXIMAGE;
|
||||
else if (direction == "screenshot")
|
||||
mImageSource = SCREENSHOT;
|
||||
else if (direction == "cover")
|
||||
mImageSource = COVER;
|
||||
else if (direction == "marquee")
|
||||
mImageSource = MARQUEE;
|
||||
else if (direction == "3dbox")
|
||||
mImageSource = BOX3D;
|
||||
else
|
||||
mImageSource = THUMBNAIL;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue