Better (but unsorted) Java detection
This commit is contained in:
@@ -3,21 +3,28 @@
|
||||
#include <QTimer>
|
||||
#include <memory>
|
||||
|
||||
class JavaChecker;
|
||||
|
||||
struct JavaCheckResult
|
||||
{
|
||||
QString path;
|
||||
QString mojangPlatform;
|
||||
QString realPlatform;
|
||||
QString javaVersion;
|
||||
bool valid = false;
|
||||
bool is_64bit = false;
|
||||
};
|
||||
typedef std::shared_ptr<QProcess> QProcessPtr;
|
||||
|
||||
typedef std::shared_ptr<QProcess> QProcessPtr;
|
||||
typedef std::shared_ptr<JavaChecker> JavaCheckerPtr;
|
||||
class JavaChecker : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit JavaChecker(QObject *parent = 0);
|
||||
void performCheck(QString path);
|
||||
void performCheck();
|
||||
|
||||
QString path;
|
||||
|
||||
signals:
|
||||
void checkFinished(JavaCheckResult result);
|
||||
|
Reference in New Issue
Block a user