mirror of
https://github.com/libretro/ppsspp.git
synced 2024-11-27 10:20:49 +00:00
Qt: Return correct refresh rate.
Although, should probably update it if the screen changes, meh.
This commit is contained in:
parent
9d96e6579c
commit
82b6cda5ef
@ -11,6 +11,7 @@
|
||||
#include <QDesktopWidget>
|
||||
#include <QDesktopServices>
|
||||
#include <QLocale>
|
||||
#include <QScreen>
|
||||
#include <QThread>
|
||||
|
||||
#include "ext/glslang/glslang/Public/ShaderLang.h"
|
||||
@ -34,6 +35,7 @@
|
||||
#include <string.h>
|
||||
|
||||
MainUI *emugl = NULL;
|
||||
static int refreshRate = 60000;
|
||||
|
||||
#ifdef SDL
|
||||
extern void mixaudio(void *userdata, Uint8 *stream, int len) {
|
||||
@ -67,7 +69,7 @@ int System_GetPropertyInt(SystemProperty prop) {
|
||||
case SYSPROP_AUDIO_SAMPLE_RATE:
|
||||
return 44100;
|
||||
case SYSPROP_DISPLAY_REFRESH_RATE:
|
||||
return 60000;
|
||||
return refreshRate;
|
||||
case SYSPROP_DEVICE_TYPE:
|
||||
#if defined(__ANDROID__)
|
||||
return DEVICE_TYPE_MOBILE;
|
||||
@ -514,6 +516,9 @@ int main(int argc, char *argv[])
|
||||
g_dpi_scale_real_y = g_dpi_scale_y;
|
||||
dp_xres = (int)(pixel_xres * g_dpi_scale_x);
|
||||
dp_yres = (int)(pixel_yres * g_dpi_scale_y);
|
||||
|
||||
refreshRate = (int)(a.primaryScreen()->refreshRate() * 1000);
|
||||
|
||||
std::string savegame_dir = ".";
|
||||
std::string external_dir = ".";
|
||||
#if QT_VERSION > QT_VERSION_CHECK(5, 0, 0)
|
||||
|
Loading…
Reference in New Issue
Block a user