From 8bd9d0af64fdddc6e77861ca8b74b15a8fc549a4 Mon Sep 17 00:00:00 2001
From: inso <insomniak.fr@gmail.com>
Date: Tue, 20 Feb 2018 13:23:19 +0000
Subject: [PATCH] Add qt installer noninteractive

---
 qt-installer-noninteractive.qs | 56 ++++++++++++++++++++++++++++++++++
 1 file changed, 56 insertions(+)
 create mode 100644 qt-installer-noninteractive.qs

diff --git a/qt-installer-noninteractive.qs b/qt-installer-noninteractive.qs
new file mode 100644
index 0000000..1e943f4
--- /dev/null
+++ b/qt-installer-noninteractive.qs
@@ -0,0 +1,56 @@
+// Emacs mode hint: -*- mode: JavaScript -*-
+
+function Controller() {
+    installer.autoRejectMessageBoxes();
+    installer.installationFinished.connect(function() {
+        gui.clickButton(buttons.NextButton);
+    })
+}
+
+Controller.prototype.WelcomePageCallback = function() {
+    gui.clickButton(buttons.NextButton);
+}
+
+Controller.prototype.CredentialsPageCallback = function() {
+    gui.clickButton(buttons.NextButton);
+}
+
+Controller.prototype.IntroductionPageCallback = function() {
+    gui.clickButton(buttons.NextButton);
+}
+
+Controller.prototype.TargetDirectoryPageCallback = function()
+{
+    gui.currentPageWidget().TargetDirectoryLineEdit.setText("/tmp/qt/5.8");
+    gui.clickButton(buttons.NextButton);
+}
+
+Controller.prototype.ComponentSelectionPageCallback = function() {
+    //var widget = gui.currentPageWidget();
+
+    //widget.selectAll();
+
+    gui.clickButton(buttons.NextButton);
+}
+
+Controller.prototype.LicenseAgreementPageCallback = function() {
+    gui.currentPageWidget().AcceptLicenseRadioButton.setChecked(true);
+    gui.clickButton(buttons.NextButton);
+}
+
+Controller.prototype.StartMenuDirectoryPageCallback = function() {
+    gui.clickButton(buttons.NextButton);
+}
+
+Controller.prototype.ReadyForInstallationPageCallback = function()
+{
+    gui.clickButton(buttons.NextButton);
+}
+
+Controller.prototype.FinishedPageCallback = function() {
+var checkBoxForm = gui.currentPageWidget().LaunchQtCreatorCheckBoxForm
+if (checkBoxForm && checkBoxForm.launchQtCreatorCheckBox) {
+    checkBoxForm.launchQtCreatorCheckBox.checked = false;
+}
+    gui.clickButton(buttons.FinishButton);
+}
-- 
GitLab