[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-bindings
Subject: Re: [Kde-bindings] Qt, Qyoto buttons work intermediately
From: Richard Dale <rdale () foton ! es>
Date: 2010-02-14 10:32:32
Message-ID: 201002141032.33653.rdale () foton ! es
[Download RAW message or body]
On Sunday 14 February 2010 05:46:03 am linuxoidoz@yahoo.com.au wrote:
> Don't know if this is a Qyoto bug or I'm doing something wrong. When I
> build my project and click buttons sometimes they work, sometimes they
> don't. If I rebuild it, then they might start working or stop. Really
> strange.
>
> I have these functions:
>
> QObject.Connect(btnSource, Qt.SIGNAL("clicked()"), MainWindow,
> Qt.SLOT("GetSource(MainWindow)")); QObject.Connect(btnAbout,
> Qt.SIGNAL("clicked()"), MainWindow, Qt.SLOT("ShowAbout(MainWindow)"));
>
> [Q_SLOT]
> private void ShowAbout(QMainWindow win) {
> QMessageBox.About(win, "About", "About Project");
> }
>
> [Q_SLOT]
> private void GetSource(QMainWindow win) {
> fileDialog = new QFileDialog(win);
> string folderPath = "";
> folderPath = fileDialog.Directory().ToString();
> }
>
>
> The ShowAbout sometimes shows the message, sometimes it doesn't, the
> GetSource never works. What am I doing wrong? Thank you.
You are connecting to Qt.SLOT("GetSource(MainWindow)") which should be
Qt.SLOT("GetSource(QMainWindow)"), and Qt.SLOT("ShowAbout(MainWindow)") which
should be Qt.SLOT("ShowAbout(QMainWindow)").
-- Richard
_______________________________________________
Kde-bindings mailing list
Kde-bindings@kde.org
https://mail.kde.org/mailman/listinfo/kde-bindings
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic