summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-sheet/textdlg.cpp
Unidiff
Diffstat (limited to 'noncore/apps/opie-sheet/textdlg.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-sheet/textdlg.cpp62
1 files changed, 40 insertions, 22 deletions
diff --git a/noncore/apps/opie-sheet/textdlg.cpp b/noncore/apps/opie-sheet/textdlg.cpp
index 34cec29..020b9ae 100644
--- a/noncore/apps/opie-sheet/textdlg.cpp
+++ b/noncore/apps/opie-sheet/textdlg.cpp
@@ -1,11 +1,30 @@
1/*************************************************************************** 1/*
2 * * 2 =. This file is part of the Opie Project
3 * This program is free software; you can redistribute it and/or modify * 3 .=l. Copyright (C) 2004 Opie Developer Team <opie-devel@handhelds.org>
4 * it under the terms of the GNU General Public License as published by * 4 .>+-=
5 * the Free Software Foundation; either version 2 of the License, or * 5 _;:, .> :=|. This program is free software; you can
6 * (at your option) any later version. * 6.> <`_, > . <= redistribute it and/or modify it under
7 * * 7:`=1 )Y*s>-.-- : the terms of the GNU General Public
8 ***************************************************************************/ 8.="- .-=="i, .._ License as published by the Free Software
9 - . .-<_> .<> Foundation; either version 2 of the License,
10 ._= =} : or (at your option) any later version.
11 .%`+i> _;_.
12 .i_,=:_. -<s. This program is distributed in the hope that
13 + . -:. = it will be useful, but WITHOUT ANY WARRANTY;
14 : .. .:, . . . without even the implied warranty of
15 =_ + =;=|` MERCHANTABILITY or FITNESS FOR A
16 _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU
17..}^=.= = ; Library General Public License for more
18++= -. .` .: details.
19 : = ...= . :.=-
20 -. .:....=;==+<; You should have received a copy of the GNU
21 -_. . . )=. = Library General Public License along with
22 -- :-=` this library; see the file COPYING.LIB.
23 If not, write to the Free Software Foundation,
24 Inc., 59 Temple Place - Suite 330,
25 Boston, MA 02111-1307, USA.
26
27*/
9 28
10/* 29/*
11 * Opie Sheet (formerly Sheet/Qt) 30 * Opie Sheet (formerly Sheet/Qt)
@@ -15,33 +34,32 @@
15#include "textdlg.h" 34#include "textdlg.h"
16 35
17TextDialog::TextDialog(QWidget *parent) 36TextDialog::TextDialog(QWidget *parent)
18 :QDialog(parent, 0, TRUE) 37 :QDialog(parent, 0, TRUE)
19{ 38{
20 edit=new QLineEdit(this); 39 edit=new QLineEdit(this);
21 edit->setGeometry(90, 10, 100, 25); 40 edit->setGeometry(90, 10, 100, 25);
22 41
23 label=new QLabel(this); 42 label=new QLabel(this);
24 label->setGeometry(10, 10, 70, 25); 43 label->setGeometry(10, 10, 70, 25);
25 label->setBuddy(edit); 44 label->setBuddy(edit);
26 45
27 resize(200, 45); 46 resize(200, 45);
28} 47}
29 48
30TextDialog::~TextDialog() 49TextDialog::~TextDialog()
31{ 50{}
32}
33 51
34int TextDialog::exec(const QString &caption, const QString &text, 52int TextDialog::exec(const QString &caption, const QString &text,
35 const QString &value) 53 const QString &value)
36{ 54{
37 setCaption(caption); 55 setCaption(caption);
38 label->setText(text); 56 label->setText(text);
39 edit->setText(value); 57 edit->setText(value);
40 58
41 return QDialog::exec(); 59 return QDialog::exec();
42} 60}
43 61
44QString TextDialog::getValue() 62QString TextDialog::getValue()
45{ 63{
46 return edit->text(); 64 return edit->text();
47} 65}