Diffstat (limited to 'noncore/tools/remote/recorddialog.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/tools/remote/recorddialog.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/noncore/tools/remote/recorddialog.cpp b/noncore/tools/remote/recorddialog.cpp index 1ce5472..a9c4c61 100644 --- a/noncore/tools/remote/recorddialog.cpp +++ b/noncore/tools/remote/recorddialog.cpp | |||
@@ -7,24 +7,26 @@ License as published by the Free Software Foundation; either version 2 of the Li | |||
7 | version. | 7 | version. |
8 | 8 | ||
9 | This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the | 9 | This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the |
10 | implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General | 10 | implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General |
11 | Public License for more details. | 11 | Public License for more details. |
12 | 12 | ||
13 | You should have received a copy of the GNU General Public License along with this program; if not, write to the Free | 13 | You should have received a copy of the GNU General Public License along with this program; if not, write to the Free |
14 | Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 14 | Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
15 | */ | 15 | */ |
16 | 16 | ||
17 | #include "recorddialog.h" | 17 | #include "recorddialog.h" |
18 | 18 | ||
19 | using namespace Opie::Core; | ||
20 | using namespace Opie::Core; | ||
19 | RecordDialog::RecordDialog(QWidget *parent, const char *name) | 21 | RecordDialog::RecordDialog(QWidget *parent, const char *name) |
20 | :QDialog(parent, name) | 22 | :QDialog(parent, name) |
21 | { | 23 | { |
22 | QVBoxLayout *layout = new QVBoxLayout(this); | 24 | QVBoxLayout *layout = new QVBoxLayout(this); |
23 | QHBoxLayout *hlayout = new QHBoxLayout(this); | 25 | QHBoxLayout *hlayout = new QHBoxLayout(this); |
24 | 26 | ||
25 | layout->insertSpacing(0,5); | 27 | layout->insertSpacing(0,5); |
26 | output = new QTextView("Please enter the name of the new remote, and press Return\n", 0, this, "output"); | 28 | output = new QTextView("Please enter the name of the new remote, and press Return\n", 0, this, "output"); |
27 | layout->insertWidget(-1, output); | 29 | layout->insertWidget(-1, output); |
28 | layout->insertSpacing(-1, 5); | 30 | layout->insertSpacing(-1, 5); |
29 | layout->insertLayout(-1, hlayout); | 31 | layout->insertLayout(-1, hlayout); |
30 | layout->insertSpacing(-1, 5); | 32 | layout->insertSpacing(-1, 5); |
@@ -40,27 +42,27 @@ RecordDialog::RecordDialog(QWidget *parent, const char *name) | |||
40 | connect(ret, SIGNAL(clicked()), this, SLOT(retPressed()) ); | 42 | connect(ret, SIGNAL(clicked()), this, SLOT(retPressed()) ); |
41 | where = 0; | 43 | where = 0; |
42 | 44 | ||
43 | record = new OProcess; | 45 | record = new OProcess; |
44 | } | 46 | } |
45 | 47 | ||
46 | void RecordDialog::retPressed() | 48 | void RecordDialog::retPressed() |
47 | { | 49 | { |
48 | printf("RecordDialog::retPressed: ret pressed\n"); | 50 | printf("RecordDialog::retPressed: ret pressed\n"); |
49 | 51 | ||
50 | if(where == 0) | 52 | if(where == 0) |
51 | { | 53 | { |
52 | connect(record, SIGNAL(receivedStdout(OProcess*,char*,int)), this, SLOT(incoming(OProcess*,char*,int)) ); | 54 | connect(record, SIGNAL(receivedStdout(Opie::Core::OProcess*,char*,int)), this, SLOT(incoming(Opie::Core::OProcess*,char*,int)) ); |
53 | connect(record, SIGNAL(receivedStderr(OProcess*,char*,int)), this, SLOT(incoming(OProcess*,char*,int)) ); | 55 | connect(record, SIGNAL(receivedStderr(Opie::Core::OProcess*,char*,int)), this, SLOT(incoming(Opie::Core::OProcess*,char*,int)) ); |
54 | connect(record, SIGNAL(processExited(OProcess*)), this, SLOT(done(OProcess*)) ); | 56 | connect(record, SIGNAL(processExited(Opie::Core::OProcess*)), this, SLOT(done(Opie::Core::OProcess*)) ); |
55 | printf("RecordDialog::retPressed: starting irrecord\n"); | 57 | printf("RecordDialog::retPressed: starting irrecord\n"); |
56 | QString file = "/tmp/" + input->text(); | 58 | QString file = "/tmp/" + input->text(); |
57 | *record<<"irrecord"<<file.latin1(); | 59 | *record<<"irrecord"<<file.latin1(); |
58 | if(!record->start(OProcess::NotifyOnExit, OProcess::AllOutput)) | 60 | if(!record->start(OProcess::NotifyOnExit, OProcess::AllOutput)) |
59 | { | 61 | { |
60 | QMessageBox *mb = new QMessageBox("Error!", | 62 | QMessageBox *mb = new QMessageBox("Error!", |
61 | "Could not start irrecord. You must<br>use an lirc ipkg that includes<br>irrecord", | 63 | "Could not start irrecord. You must<br>use an lirc ipkg that includes<br>irrecord", |
62 | QMessageBox::NoIcon, | 64 | QMessageBox::NoIcon, |
63 | QMessageBox::Ok, | 65 | QMessageBox::Ok, |
64 | QMessageBox::NoButton, | 66 | QMessageBox::NoButton, |
65 | QMessageBox::NoButton); | 67 | QMessageBox::NoButton); |
66 | mb->exec(); | 68 | mb->exec(); |