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:51:45 +0200
commitd4ebd66dff9ceb845ae1ed7845b48cd87b19385b (patch)
treee5ec1e7fbb97bda64a648e6d29d67c9602a96226
parent89bce8b298412002f89a500b77d8fe69be4e6611 (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:"));