summaryrefslogtreecommitdiff
path: root/noncore/tools/formatter
Unidiff
Diffstat (limited to 'noncore/tools/formatter') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/tools/formatter/formatter.cpp2
-rw-r--r--noncore/tools/formatter/formatter.h3
-rw-r--r--noncore/tools/formatter/formatter.pro4
-rw-r--r--noncore/tools/formatter/main.cpp10
4 files changed, 6 insertions, 13 deletions
diff --git a/noncore/tools/formatter/formatter.cpp b/noncore/tools/formatter/formatter.cpp
index 49f6355..a8dd11c 100644
--- a/noncore/tools/formatter/formatter.cpp
+++ b/noncore/tools/formatter/formatter.cpp
@@ -45,25 +45,25 @@
45#include <stdio.h> 45#include <stdio.h>
46#include <stdlib.h> 46#include <stdlib.h>
47#include <sys/vfs.h> 47#include <sys/vfs.h>
48#include <mntent.h> 48#include <mntent.h>
49#include <string.h> 49#include <string.h>
50#include <errno.h> 50#include <errno.h>
51 51
52#define BLANK ' ' 52#define BLANK ' '
53#define DELIMITER '#' 53#define DELIMITER '#'
54 54
55/* 55/*
56 Blah blah blah blah */ 56 Blah blah blah blah */
57FormatterApp::FormatterApp( QWidget* parent, const char* name, bool , WFlags fl ) 57FormatterApp::FormatterApp( QWidget* parent, const char* name, WFlags fl, bool modal )
58 : QMainWindow( parent, name, fl ) 58 : QMainWindow( parent, name, fl )
59// : QDialog( parent, name, modal, fl ) 59// : QDialog( parent, name, modal, fl )
60{ 60{
61 if ( !name ) 61 if ( !name )
62 setName( "FormatterApp" ); 62 setName( "FormatterApp" );
63 connect( qApp,SIGNAL( aboutToQuit()),SLOT( cleanUp()) ); 63 connect( qApp,SIGNAL( aboutToQuit()),SLOT( cleanUp()) );
64 64
65 setCaption( tr( "Formatter" ) ); 65 setCaption( tr( "Formatter" ) );
66 FormatterAppLayout = new QGridLayout( this ); 66 FormatterAppLayout = new QGridLayout( this );
67 FormatterAppLayout->setSpacing( 2); 67 FormatterAppLayout->setSpacing( 2);
68 FormatterAppLayout->setMargin( 2 ); 68 FormatterAppLayout->setMargin( 2 );
69 69
diff --git a/noncore/tools/formatter/formatter.h b/noncore/tools/formatter/formatter.h
index 960a68a..faf0b30 100644
--- a/noncore/tools/formatter/formatter.h
+++ b/noncore/tools/formatter/formatter.h
@@ -21,25 +21,26 @@ class QLabel;
21class QLineEdit; 21class QLineEdit;
22class QPushButton; 22class QPushButton;
23class QTabWidget; 23class QTabWidget;
24class QWidget; 24class QWidget;
25class QStringList; 25class QStringList;
26 26
27class FormatterApp : public QMainWindow 27class FormatterApp : public QMainWindow
28//public QDialog 28//public QDialog
29{ 29{
30 Q_OBJECT 30 Q_OBJECT
31 31
32public: 32public:
33 FormatterApp( QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0 ); 33 static QString appName() { return QString::fromLatin1("formatter"); }
34 FormatterApp( QWidget* parent = 0, const char* name = 0, WFlags fl = 0, bool modal = FALSE );
34 ~FormatterApp(); 35 ~FormatterApp();
35 36
36 QTabWidget *TabWidget; 37 QTabWidget *TabWidget;
37 QWidget *tab, *tab_2;; 38 QWidget *tab, *tab_2;;
38 QLabel *TextLabel1, *TextLabel2, *TextLabel3, *TextLabel4, *TextLabel5; 39 QLabel *TextLabel1, *TextLabel2, *TextLabel3, *TextLabel4, *TextLabel5;
39 QComboBox *storageComboBox, *fileSystemsCombo, *deviceComboBox; 40 QComboBox *storageComboBox, *fileSystemsCombo, *deviceComboBox;
40 QPushButton *formatPushButton, *editPushButton, *fsckButton; 41 QPushButton *formatPushButton, *editPushButton, *fsckButton;
41 QLineEdit* mountPointLineEdit; 42 QLineEdit* mountPointLineEdit;
42 QStringList fileSystemTypeList, fsList, deviceList; 43 QStringList fileSystemTypeList, fsList, deviceList;
43protected: 44protected:
44 QGridLayout *FormatterAppLayout, *tabLayout, *tabLayout_2; 45 QGridLayout *FormatterAppLayout, *tabLayout, *tabLayout_2;
45 QString getFileSystemType(const QString &); 46 QString getFileSystemType(const QString &);
diff --git a/noncore/tools/formatter/formatter.pro b/noncore/tools/formatter/formatter.pro
index baf6ace..17aab57 100644
--- a/noncore/tools/formatter/formatter.pro
+++ b/noncore/tools/formatter/formatter.pro
@@ -1,18 +1,16 @@
1TEMPLATE = app 1CONFIG += qt warn_on release quick-app
2CONFIG += qt warn_on release
3HEADERS = formatter.h inputDialog.h output.h 2HEADERS = formatter.h inputDialog.h output.h
4SOURCES = formatter.cpp inputDialog.cpp output.cpp main.cpp 3SOURCES = formatter.cpp inputDialog.cpp output.cpp main.cpp
5TARGET = formatter 4TARGET = formatter
6DESTDIR = $(OPIEDIR)/bin
7INCLUDEPATH += $(OPIEDIR)/include 5INCLUDEPATH += $(OPIEDIR)/include
8DEPENDPATH += $(OPIEDIR)/include 6DEPENDPATH += $(OPIEDIR)/include
9LIBS += -lqpe 7LIBS += -lqpe
10 8
11TRANSLATIONS = ../../../i18n/de/formatter.ts \ 9TRANSLATIONS = ../../../i18n/de/formatter.ts \
12 ../../../i18n/nl/formatter.ts \ 10 ../../../i18n/nl/formatter.ts \
13 ../../../i18n/da/formatter.ts \ 11 ../../../i18n/da/formatter.ts \
14 ../../../i18n/xx/formatter.ts \ 12 ../../../i18n/xx/formatter.ts \
15 ../../../i18n/en/formatter.ts \ 13 ../../../i18n/en/formatter.ts \
16 ../../../i18n/es/formatter.ts \ 14 ../../../i18n/es/formatter.ts \
17 ../../../i18n/fr/formatter.ts \ 15 ../../../i18n/fr/formatter.ts \
18 ../../../i18n/hu/formatter.ts \ 16 ../../../i18n/hu/formatter.ts \
diff --git a/noncore/tools/formatter/main.cpp b/noncore/tools/formatter/main.cpp
index f67c9f2..6228e55 100644
--- a/noncore/tools/formatter/main.cpp
+++ b/noncore/tools/formatter/main.cpp
@@ -5,21 +5,15 @@
5 begin : March 10, 2002 5 begin : March 10, 2002
6 copyright : (C) 2002 by llornkcor 6 copyright : (C) 2002 by llornkcor
7 email : ljp@llornkcor.com 7 email : ljp@llornkcor.com
8 * This program is free software; you can redistribute it and/or modify * 8 * This program is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU General Public License as published by * 9 * it under the terms of the GNU General Public License as published by *
10 * the Free Software Foundation; either version 2 of the License, or * 10 * the Free Software Foundation; either version 2 of the License, or *
11 * (at your option) any later version. * 11 * (at your option) any later version. *
12 ***************************************************************************/ 12 ***************************************************************************/
13#include <qpe/qpeapplication.h> 13#include <qpe/qpeapplication.h>
14 14
15#include "formatter.h" 15#include "formatter.h"
16 16
17int main(int argc, char *argv[]) 17#include <opie/oapplicationfactory.h>
18{
19 QPEApplication a(argc, argv);
20
21 FormatterApp formatterApp;
22 a.showMainWidget( &formatterApp);
23 return a.exec();
24}
25 18
19OPIE_EXPORT_APP( OApplicationFactory<FormatterApp> )