summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKent Hansen <khansen@trolltech.com>2009-07-13 11:51:45 +0200
committerKent Hansen <khansen@trolltech.com>2009-07-13 11:54:09 +0200
commit21b47ee2aafe41f1c04a964687f7d66546f38f34 (patch)
tree46447b99839fb8c7a28a35c4794b83b8e85856b7
parent5f8402ecf451c91fbc521159c3a83a0e84d740c8 (diff)
make Calendar and Screenshot examples work again
the qscript connect() function throws an error when attempting to connect to an overloaded signal, so we need to disambiguate.
-rw-r--r--examples/CalendarWidget.qs16
-rw-r--r--examples/Screenshot.qs2
2 files changed, 9 insertions, 9 deletions
diff --git a/examples/CalendarWidget.qs b/examples/CalendarWidget.qs
index 9f9f876..dcacf54 100644
--- a/examples/CalendarWidget.qs
+++ b/examples/CalendarWidget.qs
@@ -226,13 +226,13 @@ CalendarWidget.prototype.createGeneralOptionsGroupBox = function() {
this.verticalHeaderLabel = new QLabel(tr("&Vertical header:"));
this.verticalHeaderLabel.setBuddy(this.verticalHeaderCombo);
- this.localeCombo.currentIndexChanged.connect(this, this.localeChanged);
- this.firstDayCombo.currentIndexChanged.connect(this, this.firstDayChanged);
- this.selectionModeCombo.currentIndexChanged.connect(this, this.selectionModeChanged);
+ this.localeCombo['currentIndexChanged(int)'].connect(this, this.localeChanged);
+ this.firstDayCombo['currentIndexChanged(int)'].connect(this, this.firstDayChanged);
+ this.selectionModeCombo['currentIndexChanged(int)'].connect(this, this.selectionModeChanged);
this.gridCheckBox.toggled.connect(this, this.calendar.setGridVisible);
this.navigationCheckBox.toggled.connect(this, this.calendar.setNavigationBarVisible);
- this.horizontalHeaderCombo.currentIndexChanged.connect(this, this.horizontalHeaderChanged);
- this.verticalHeaderCombo.currentIndexChanged.connect(this, "verticalHeaderChanged");
+ this.horizontalHeaderCombo['currentIndexChanged(int)'].connect(this, this.horizontalHeaderChanged);
+ this.verticalHeaderCombo['currentIndexChanged(int)'].connect(this, "verticalHeaderChanged");
var checkBoxLayout = new QHBoxLayout();
checkBoxLayout.addWidget(this.gridCheckBox, 0, Qt.AlignmentFlag(1)); //FIXME
@@ -334,9 +334,9 @@ CalendarWidget.prototype.createTextFormatsGroupBox = function() {
this.mayFirstCheckBox = new QCheckBox(tr("May &1 in red"));
- this.weekdayColorCombo.currentIndexChanged.connect(this, this.weekdayFormatChanged);
- this.weekendColorCombo.currentIndexChanged.connect(this, this.weekendFormatChanged);
- this.headerTextFormatCombo.currentIndexChanged.connect(this, this.reformatHeaders);
+ this.weekdayColorCombo['currentIndexChanged(int)'].connect(this, this.weekdayFormatChanged);
+ this.weekendColorCombo['currentIndexChanged(int)'].connect(this, this.weekendFormatChanged);
+ this.headerTextFormatCombo['currentIndexChanged(int)'].connect(this, this.reformatHeaders);
this.firstFridayCheckBox.toggled.connect(this, this.reformatCalendarPage);
this.mayFirstCheckBox.toggled.connect(this, this.reformatCalendarPage);
diff --git a/examples/Screenshot.qs b/examples/Screenshot.qs
index ead2a32..4503851 100644
--- a/examples/Screenshot.qs
+++ b/examples/Screenshot.qs
@@ -111,7 +111,7 @@ Screenshot.prototype.createOptionsGroupBox = function() {
this.delaySpinBox = new QSpinBox();
this.delaySpinBox.suffix = tr(" s");
this.delaySpinBox.maximum = 60;
- this.delaySpinBox.valueChanged.connect(this, this.updateCheckBox);
+ this.delaySpinBox['valueChanged(int)'].connect(this, this.updateCheckBox);
this.delaySpinBoxLabel = new QLabel(tr("Screenshot Delay:"));