mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-11 05:26:24 +02:00
Fix minor rendering glitch in PPSSPP's menus on iOS
This commit is contained in:
1 parent
d7de08c4ff
commit
5e501fa9fc
7 files changed
+26
-9
No files matched your search
+4
-4
@@ -544,7 +544,7 @@ void InfoItem::Draw(UIContext &dc) {
|
||||
dc.SetFontStyle(dc.theme->uiFont);
|
||||
dc.DrawText(text_.c_str(), bounds_.x + paddingX, bounds_.centerY(), style.fgColor, ALIGN_VCENTER);
|
||||
dc.DrawText(rightText_.c_str(), bounds_.x2() - paddingX, bounds_.centerY(), style.fgColor, ALIGN_VCENTER | ALIGN_RIGHT);
|
||||
// dc.Draw()->DrawImageStretch(dc.theme->whiteImage, bounds_.x, bounds_.y, bounds_.x2(), bounds_.y + 2, dc.theme->itemDownStyle.bgColor);
|
||||
// dc.Draw()->DrawImageCenterTexel(dc.theme->whiteImage, bounds_.x, bounds_.y, bounds_.x2(), bounds_.y + 2, dc.theme->itemDownStyle.bgColor);
|
||||
}
|
||||
|
||||
ItemHeader::ItemHeader(const std::string &text, LayoutParams *layoutParams)
|
||||
@@ -556,7 +556,7 @@ ItemHeader::ItemHeader(const std::string &text, LayoutParams *layoutParams)
|
||||
void ItemHeader::Draw(UIContext &dc) {
|
||||
dc.SetFontStyle(dc.theme->uiFontSmall);
|
||||
dc.DrawText(text_.c_str(), bounds_.x + 4, bounds_.centerY(), dc.theme->headerStyle.fgColor, ALIGN_LEFT | ALIGN_VCENTER);
|
||||
dc.Draw()->DrawImageStretch(dc.theme->whiteImage, bounds_.x, bounds_.y2()-2, bounds_.x2(), bounds_.y2(), dc.theme->headerStyle.fgColor);
|
||||
dc.Draw()->DrawImageCenterTexel(dc.theme->whiteImage, bounds_.x, bounds_.y2()-2, bounds_.x2(), bounds_.y2(), dc.theme->headerStyle.fgColor);
|
||||
}
|
||||
|
||||
void ItemHeader::GetContentDimensionsBySpec(const UIContext &dc, MeasureSpec horiz, MeasureSpec vert, float &w, float &h) const {
|
||||
@@ -593,7 +593,7 @@ void PopupHeader::Draw(UIContext &dc) {
|
||||
}
|
||||
|
||||
dc.DrawText(text_.c_str(), bounds_.x + tx, bounds_.centerY(), dc.theme->popupTitle.fgColor, ALIGN_LEFT | ALIGN_VCENTER);
|
||||
dc.Draw()->DrawImageStretch(dc.theme->whiteImage, bounds_.x, bounds_.y2()-2, bounds_.x2(), bounds_.y2(), dc.theme->popupTitle.fgColor);
|
||||
dc.Draw()->DrawImageCenterTexel(dc.theme->whiteImage, bounds_.x, bounds_.y2()-2, bounds_.x2(), bounds_.y2(), dc.theme->popupTitle.fgColor);
|
||||
|
||||
if (availableWidth < tw) {
|
||||
dc.PopScissor();
|
||||
@@ -1032,7 +1032,7 @@ void ProgressBar::GetContentDimensions(const UIContext &dc, float &w, float &h)
|
||||
void ProgressBar::Draw(UIContext &dc) {
|
||||
char temp[32];
|
||||
sprintf(temp, "%i%%", (int)(progress_ * 100.0f));
|
||||
dc.Draw()->DrawImageStretch(dc.theme->whiteImage, bounds_.x, bounds_.y, bounds_.x + bounds_.w * progress_, bounds_.y2(), 0xc0c0c0c0);
|
||||
dc.Draw()->DrawImageCenterTexel(dc.theme->whiteImage, bounds_.x, bounds_.y, bounds_.x + bounds_.w * progress_, bounds_.y2(), 0xc0c0c0c0);
|
||||
dc.SetFontStyle(dc.theme->uiFont);
|
||||
dc.DrawTextRect(temp, bounds_, 0xFFFFFFFF, ALIGN_CENTER);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user