mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-05 02:35:29 +02:00
UI: Make InfoView focusable, make it possible to make TextView focusable.
This commit is contained in:
1 parent
bf4a5f0352
commit
98083c8985
2 files changed
+16
-2
No files matched your search
@@ -414,7 +414,13 @@ void Choice::Draw(UIContext &dc) {
|
||||
|
||||
void InfoItem::Draw(UIContext &dc) {
|
||||
Item::Draw(dc);
|
||||
if (HasFocus()) {
|
||||
UI::Style style = dc.theme->itemFocusedStyle;
|
||||
style.background.color &= 0x7fffffff;
|
||||
dc.FillRect(style.background, bounds_);
|
||||
}
|
||||
int paddingX = 12;
|
||||
|
||||
dc.SetFontStyle(dc.theme->uiFont);
|
||||
dc.DrawText(text_.c_str(), bounds_.x + paddingX, bounds_.centerY(), 0xFFFFFFFF, ALIGN_VCENTER);
|
||||
dc.DrawText(rightText_.c_str(), bounds_.x2() - paddingX, bounds_.centerY(), 0xFFFFFFFF, ALIGN_VCENTER | ALIGN_RIGHT);
|
||||
|
||||
Reference in new issue
Block a user