mirror of
https://github.com/PCSX2/pcsx2.git
synced 2026-11-15 18:50:32 +01:00
FSUI: Centre disc/exe icon in game list selected preview
The ImGui::Image path was missing the centring logic when drawing svg icons. Covers where already correctly centred.
This commit is contained in:
1 parent
e37f8a6521
commit
e64fbb2f0e
1 file changed
+6
@@ -7009,6 +7009,9 @@ void FullscreenUI::DrawGameCover(const GameList::Entry* entry, const ImVec2& siz
|
||||
const ImVec2 image_square(min_size, min_size);
|
||||
GSTexture* const icon_texture = GetTextureForGameListEntryType(entry->type, image_square);
|
||||
|
||||
const ImRect image_rect(CenterImage(size, image_square));
|
||||
|
||||
ImGui::SetCursorPos(origin + image_rect.Min);
|
||||
DrawSvgTexture(icon_texture, image_square);
|
||||
}
|
||||
// Pretend the image we drew was the the size passed to us
|
||||
@@ -7050,6 +7053,9 @@ void FullscreenUI::DrawFallbackCover(const ImVec2& size)
|
||||
const ImVec2 image_square(min_size, min_size);
|
||||
GSTexture* const icon_texture = GetTextureForGameListEntryType(GameList::EntryType::PS2Disc, image_square);
|
||||
|
||||
const ImRect image_rect(CenterImage(size, image_square));
|
||||
|
||||
ImGui::SetCursorPos(origin + image_rect.Min);
|
||||
DrawSvgTexture(icon_texture, image_square);
|
||||
|
||||
// Pretend the image we drew was the the size passed to us
|
||||
|
||||
Reference in new issue
Block a user