author | mickeyl <mickeyl> | 2003-10-29 16:45:13 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2003-10-29 16:45:13 (UTC) |
commit | e8697a4281f7a265b69e6bf5253383c73a38626b (patch) (unidiff) | |
tree | 040470f8f5c90c0d72ff5f01a272143571842078 /noncore/tools/calculator | |
parent | d5d9b307e950d9038215e4d63e64bc9cd5d85352 (diff) | |
download | opie-e8697a4281f7a265b69e6bf5253383c73a38626b.zip opie-e8697a4281f7a265b69e6bf5253383c73a38626b.tar.gz opie-e8697a4281f7a265b69e6bf5253383c73a38626b.tar.bz2 |
merge noncore/tools/*
-rw-r--r-- | noncore/tools/calculator/calculator.pro | 4 | ||||
-rw-r--r-- | noncore/tools/calculator/calculatorimpl.cpp | 56 | ||||
-rw-r--r-- | noncore/tools/calculator/calculatorimpl.h | 4 | ||||
-rw-r--r-- | noncore/tools/calculator/main.cpp | 13 |
4 files changed, 60 insertions, 17 deletions
diff --git a/noncore/tools/calculator/calculator.pro b/noncore/tools/calculator/calculator.pro index 0fe5bb2..8a5fcfe 100644 --- a/noncore/tools/calculator/calculator.pro +++ b/noncore/tools/calculator/calculator.pro | |||
@@ -1,4 +1,2 @@ | |||
1 | DESTDIR = $(OPIEDIR)/bin | 1 | CONFIG = qt warn_on release quick-app |
2 | TEMPLATE= app | ||
3 | CONFIG = qt warn_on release | ||
4 | HEADERS = calculatorimpl.h | 2 | HEADERS = calculatorimpl.h |
diff --git a/noncore/tools/calculator/calculatorimpl.cpp b/noncore/tools/calculator/calculatorimpl.cpp index 8d11132..163b4da 100644 --- a/noncore/tools/calculator/calculatorimpl.cpp +++ b/noncore/tools/calculator/calculatorimpl.cpp | |||
@@ -120,2 +120,54 @@ CalculatorImpl::CalculatorImpl( QWidget * parent, const char * name, | |||
120 | 120 | ||
121 | // translation trick mode - with this stuff parsed in from a file is translatable | ||
122 | QObject::tr("Standard"); | ||
123 | QObject::tr("Weight"); | ||
124 | QObject::tr("Distance"); | ||
125 | QObject::tr("Area"); | ||
126 | QObject::tr("Temperatures"); | ||
127 | QObject::tr("Volume"); | ||
128 | QObject::tr("acres"); | ||
129 | QObject::tr("°C"); | ||
130 | QObject::tr("carats"); | ||
131 | QObject::tr("cm"); | ||
132 | QObject::tr("cu cm"); | ||
133 | QObject::tr("cu ft"); | ||
134 | QObject::tr("cu in"); | ||
135 | QObject::tr("°F"); | ||
136 | QObject::tr("fl oz (US)"); | ||
137 | QObject::tr("ft"); | ||
138 | QObject::tr("g"); | ||
139 | QObject::tr("gal (US)"); | ||
140 | QObject::tr("hectares"); | ||
141 | QObject::tr("in"); | ||
142 | QObject::tr("kg"); | ||
143 | QObject::tr("km"); | ||
144 | QObject::tr("l"); | ||
145 | QObject::tr("lb"); | ||
146 | QObject::tr("Lg tons"); | ||
147 | QObject::tr("m"); | ||
148 | QObject::tr("mg"); | ||
149 | QObject::tr("mi"); | ||
150 | QObject::tr("ml"); | ||
151 | QObject::tr("mm"); | ||
152 | QObject::tr("naut. mi"); | ||
153 | QObject::tr("oz"); | ||
154 | QObject::tr("points"); | ||
155 | QObject::tr("pt"); | ||
156 | QObject::tr("qt"); | ||
157 | QObject::tr("sq cm"); | ||
158 | QObject::tr("sq ft"); | ||
159 | QObject::tr("sq in"); | ||
160 | QObject::tr("sq km"); | ||
161 | QObject::tr("sq m"); | ||
162 | QObject::tr("sq mi"); | ||
163 | QObject::tr("sq mm"); | ||
164 | QObject::tr("sq yd"); | ||
165 | QObject::tr("st"); | ||
166 | QObject::tr("St tons"); | ||
167 | QObject::tr("tblspoon"); | ||
168 | QObject::tr("teaspoons"); | ||
169 | QObject::tr("tonnes"); | ||
170 | QObject::tr("yd"); | ||
171 | |||
172 | |||
121 | //bgr_command.insert( PushButtonFunction); | 173 | //bgr_command.insert( PushButtonFunction); |
@@ -210,3 +262,3 @@ CalculatorImpl::CalculatorImpl( QWidget * parent, const char * name, | |||
210 | if ( line.contains("STARTTYPE") ) { | 262 | if ( line.contains("STARTTYPE") ) { |
211 | captions << line.remove(0,10); | 263 | captions << tr( line.remove(0,10) ); |
212 | ComboBoxFunction->insertItem(captions.last()); | 264 | ComboBoxFunction->insertItem(captions.last()); |
@@ -215,3 +267,3 @@ CalculatorImpl::CalculatorImpl( QWidget * parent, const char * name, | |||
215 | if ( line.contains("NAME") ) { | 267 | if ( line.contains("NAME") ) { |
216 | faces << line.remove(0,5); | 268 | faces << tr( line.remove(0,5) ); |
217 | line2 = ts2.readLine(); | 269 | line2 = ts2.readLine(); |
diff --git a/noncore/tools/calculator/calculatorimpl.h b/noncore/tools/calculator/calculatorimpl.h index f0180c9..06ec829 100644 --- a/noncore/tools/calculator/calculatorimpl.h +++ b/noncore/tools/calculator/calculatorimpl.h | |||
@@ -75,3 +75,5 @@ public: | |||
75 | CalculatorImpl( QWidget * parent = 0, const char * name = 0, | 75 | CalculatorImpl( QWidget * parent = 0, const char * name = 0, |
76 | WFlags f = 0 ); | 76 | WFlags f = 0 ); |
77 | static QString appName() { return QString::fromLatin1("calculator"); } | ||
78 | |||
77 | 79 | ||
diff --git a/noncore/tools/calculator/main.cpp b/noncore/tools/calculator/main.cpp index 74cd5d3..c4d00b1 100644 --- a/noncore/tools/calculator/main.cpp +++ b/noncore/tools/calculator/main.cpp | |||
@@ -23,13 +23,4 @@ | |||
23 | #include <qpe/qpeapplication.h> | 23 | #include <qpe/qpeapplication.h> |
24 | #include <opie/oapplicationfactory.h> | ||
24 | 25 | ||
25 | int main( int argc, char ** argv ) | 26 | OPIE_EXPORT_APP( OApplicationFactory<CalculatorImpl> ) |
26 | { | ||
27 | QPEApplication a( argc, argv ); | ||
28 | |||
29 | CalculatorImpl mw; | ||
30 | QPEApplication::setInputMethodHint( &mw, QPEApplication::AlwaysOff ); | ||
31 | mw.setCaption( CalculatorImpl::tr("Calculator") ); | ||
32 | a.showMainWidget( &mw ); | ||
33 | |||
34 | return a.exec(); | ||
35 | } | ||