aboutsummaryrefslogtreecommitdiffstats
path: root/src/jalv_qt.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/jalv_qt.cpp')
-rw-r--r--src/jalv_qt.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/jalv_qt.cpp b/src/jalv_qt.cpp
index 80141f2..5084c03 100644
--- a/src/jalv_qt.cpp
+++ b/src/jalv_qt.cpp
@@ -31,6 +31,7 @@
# include <QMainWindow>
# include <QMenu>
# include <QMenuBar>
+# include <QScreen>
# include <QScrollArea>
# include <QStyle>
# include <QTimer>
@@ -673,6 +674,16 @@ jalv_discover_ui(Jalv* jalv)
return true;
}
+float
+jalv_ui_refresh_rate(Jalv* jalv)
+{
+#if QT_VERSION >= 0x050000
+ return (float)QGuiApplication::primaryScreen()->refreshRate();
+#else
+ return 30.0f;
+#endif
+}
+
int
jalv_open_ui(Jalv* jalv)
{