Debian Codegraph @

Installer/config/control.js

raw symbols SCIP
1 function func() {
2
3 }
4 function Controller() {
5 var widget = gui.pageById(QInstaller.Introduction); // get the introduction wizard page
6 if (widget != null){
7 widget.packageManagerCoreTypeChanged.connect(onPackageManagerCoreTypeChanged);
8 }
9 }
10
11 Controller.prototype.IntroductionPageCallback = function(){
12 var widget = gui.currentPageWidget();
13 if (widget != null) {
14 //Prevent add or remove package button from showing up by setting it's text to "", disabling it, and hiding it.
15 console.log(Object.getOwnPropertyNames(widget));
16 widget.findChild("PackageManagerRadioButton").visible = false;
17 widget.findChild("PackageManagerRadioButton").enabled = false;
18 widget.findChild("PackageManagerRadioButton").text = "";
19 widget.findChild("UninstallerRadioButton").text = "Uninstall Pep8"
20 widget.findChild("UpdaterRadioButton").text = "Update Pep8"
21 }
22
23 }
24
25 Controller.prototype.LicenseAgreementPageCallback = function(){
26 var widget = gui.currentPageWidget();
27 if (widget != null) {
28 //Stub out code to allow changing default of license agreement.
29 //Helpful in debug to change to true.
30 widget.AcceptLicenseRadioButton.checked = false;
31 }
32 }
33
34 Controller.prototype.FinishedPageCallback = function(){
35 }
36
37 onPackageManagerCoreTypeChanged = function(){
38
39
40 var widget = gui.pageById(QInstaller.Introduction);
41 if (widget != null) {
42 //Any time any event comes in, the PackageManagerRadioButton tries to re-enable itself.
43 //So, every time a new button is clicked, make sure that PackageManagerRadioButton wasn't re-enabled.
44 widget.findChild("PackageManagerRadioButton").visible = false;
45 if(widget.findChild("PackageManagerRadioButton").checked==true){
46 //If somehow PackageManagerRadioButton got checked, uncheck it and default to uninstall
47 widget.findChild("UninstallerRadioButton").checked = true;
48 }
49 }
50 }