mirror of
https://github.com/KDE/krfb
synced 2026-07-01 07:31:16 -07:00
KRandom -> QRandomGenerator
KRandom is now deprecated
This commit is contained in:
@@ -8,7 +8,7 @@ set (RELEASE_SERVICE_VERSION "${RELEASE_SERVICE_VERSION_MAJOR}.${RELEASE_SERVICE
|
||||
|
||||
project(krfb VERSION ${RELEASE_SERVICE_VERSION})
|
||||
|
||||
set(QT_MIN_VERSION 5.6.0)
|
||||
set(QT_MIN_VERSION 5.10.0)
|
||||
set(KF5_MIN_VERSION 5.31.0)
|
||||
|
||||
find_package(ECM ${KF5_MIN_VERSION} NO_MODULE REQUIRED)
|
||||
|
||||
@@ -26,10 +26,10 @@
|
||||
#include <QApplication>
|
||||
#include <QHostInfo>
|
||||
#include <QDebug>
|
||||
#include <QRandomGenerator>
|
||||
|
||||
#include <KLocalizedString>
|
||||
#include <KUser>
|
||||
#include <KRandom>
|
||||
#include <KStringHandler>
|
||||
#include <KWallet/KWallet>
|
||||
|
||||
@@ -213,7 +213,7 @@ QString InvitationsRfbServer::readableRandomString(int length)
|
||||
{
|
||||
QString str;
|
||||
while (length) {
|
||||
int r = KRandom::random() % 62;
|
||||
int r = QRandomGenerator::global()->bounded(62);
|
||||
r += 48;
|
||||
if (r > 57) {
|
||||
r += 7;
|
||||
|
||||
Reference in New Issue
Block a user