mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-23 13:30:02 +00:00
UI: Maintain aspect better on screenshots.
In case they are on a thin screen or something.
This commit is contained in:
parent
3bba9df133
commit
d1c9da6a9a
@ -175,7 +175,7 @@ protected:
|
||||
UI::LinearLayout *content = new UI::LinearLayout(UI::ORIENT_VERTICAL);
|
||||
parent->Add(content);
|
||||
UI::Margins contentMargins(10, 0);
|
||||
content->Add(new AsyncImageFileView(filename_, UI::IS_DEFAULT, nullptr, new UI::LinearLayoutParams(480, 272, contentMargins)))->SetCanBeFocused(false);
|
||||
content->Add(new AsyncImageFileView(filename_, UI::IS_KEEP_ASPECT, nullptr, new UI::LinearLayoutParams(480, 272, contentMargins)))->SetCanBeFocused(false);
|
||||
}
|
||||
|
||||
private:
|
||||
|
@ -101,7 +101,7 @@ public:
|
||||
std::string image_path = ReplaceAll(savePath_, ".ppst", ".jpg");
|
||||
if (File::Exists(image_path)) {
|
||||
PrioritizedWorkQueue *wq = g_gameInfoCache->WorkQueue();
|
||||
toprow->Add(new AsyncImageFileView(image_path, IS_DEFAULT, wq, new LinearLayoutParams(480, 272, Margins(10, 0))));
|
||||
toprow->Add(new AsyncImageFileView(image_path, IS_KEEP_ASPECT, wq, new LinearLayoutParams(480, 272, Margins(10, 0))));
|
||||
} else {
|
||||
toprow->Add(new TextView(sa->T("No screenshot"), new LinearLayoutParams(Margins(10, 5))))->SetTextColor(textStyle.fgColor);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user