mirror of
https://github.com/moonlight-stream/moonlight-ios.git
synced 2026-06-17 14:11:35 +00:00
Only display the native resolution dialog if the user has just chosen native resolution. Make the dialog a little nicer too.
This commit is contained in:
@@ -65,9 +65,14 @@ static NSString* bitrateFormat = @"Bitrate: %.1f Mbps";
|
|||||||
height = [UIScreen mainScreen].bounds.size.height * [UIScreen mainScreen].scale;
|
height = [UIScreen mainScreen].bounds.size.height * [UIScreen mainScreen].scale;
|
||||||
width = [UIScreen mainScreen].bounds.size.width * [UIScreen mainScreen].scale;
|
width = [UIScreen mainScreen].bounds.size.width * [UIScreen mainScreen].scale;
|
||||||
|
|
||||||
UIAlertController *alertResolution = [UIAlertController alertControllerWithTitle:@"Native resolution" message:[NSString stringWithFormat:@"You must select the following resolution in the game settings: %lix%li", (long)width, (long)height] preferredStyle:UIAlertControllerStyleAlert];
|
// Check if this setting differs from the previous value
|
||||||
[alertResolution addAction:[UIAlertAction actionWithTitle:@"Ok" style:UIAlertActionStyleCancel handler:nil]];
|
Settings* oldSettings = [dataMan retrieveSettings];
|
||||||
[self presentViewController:alertResolution animated:YES completion:nil];
|
if ([oldSettings.width intValue] != width || [oldSettings.height intValue] != height)
|
||||||
|
{
|
||||||
|
UIAlertController *alertResolution = [UIAlertController alertControllerWithTitle:@"Native resolution" message:[NSString stringWithFormat:@"For best results, select the following resolution in the game settings: %lix%li", (long)width, (long)height] preferredStyle:UIAlertControllerStyleAlert];
|
||||||
|
[alertResolution addAction:[UIAlertAction actionWithTitle:@"Ok" style:UIAlertActionStyleCancel handler:nil]];
|
||||||
|
[self presentViewController:alertResolution animated:YES completion:nil];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user