summaryrefslogtreecommitdiff
path: root/noncore/settings/appearance2
Unidiff
Diffstat (limited to 'noncore/settings/appearance2') (more/less context) (show whitespace changes)
-rw-r--r--noncore/settings/appearance2/appearance.cpp4
-rw-r--r--noncore/settings/appearance2/appearance.h1
-rw-r--r--noncore/settings/appearance2/appearance2.pro8
-rw-r--r--noncore/settings/appearance2/main.cpp12
4 files changed, 6 insertions, 19 deletions
diff --git a/noncore/settings/appearance2/appearance.cpp b/noncore/settings/appearance2/appearance.cpp
index 00128d3..9e5eede 100644
--- a/noncore/settings/appearance2/appearance.cpp
+++ b/noncore/settings/appearance2/appearance.cpp
@@ -555,28 +555,24 @@ void Appearance::accept ( )
555 fl |= ( it-> noFont ( ) ? 0x02 : 0 ); 555 fl |= ( it-> noFont ( ) ? 0x02 : 0 );
556 fl |= ( it-> noDeco ( ) ? 0x04 : 0 ); 556 fl |= ( it-> noDeco ( ) ? 0x04 : 0 );
557 exceptstr = QString::number ( fl, 32 ); 557 exceptstr = QString::number ( fl, 32 );
558 exceptstr.append( it-> pattern ( )); 558 exceptstr.append( it-> pattern ( ));
559 sl << exceptstr; 559 sl << exceptstr;
560 } 560 }
561 config. writeEntry ( "NoStyle", sl, ';' ); 561 config. writeEntry ( "NoStyle", sl, ';' );
562 config. writeEntry ( "ForceStyle", m_force-> isChecked ( )); 562 config. writeEntry ( "ForceStyle", m_force-> isChecked ( ));
563 563
564 config. write ( ); // need to flush the config info first 564 config. write ( ); // need to flush the config info first
565 Global::applyStyle ( ); 565 Global::applyStyle ( );
566 566
567 if ( QMessageBox::warning ( this, tr( "Restart" ), tr( "Do you want to restart %1 now?" ). arg ( ODevice::inst ( )-> system ( ) == System_Zaurus ? "Qtopia" : "Opie" ), tr( "Yes" ), tr( "No" ), 0, 0, 1 ) == 0 ) {
568 QCopEnvelope e( "QPE/System", "restart()" );
569 }
570
571 QDialog::accept ( ); 567 QDialog::accept ( );
572} 568}
573 569
574void Appearance::done ( int r ) 570void Appearance::done ( int r )
575{ 571{
576 QDialog::done ( r ); 572 QDialog::done ( r );
577 close ( ); 573 close ( );
578} 574}
579 575
580 576
581void Appearance::styleClicked ( int index ) 577void Appearance::styleClicked ( int index )
582{ 578{
diff --git a/noncore/settings/appearance2/appearance.h b/noncore/settings/appearance2/appearance.h
index da9e976..51e9636 100644
--- a/noncore/settings/appearance2/appearance.h
+++ b/noncore/settings/appearance2/appearance.h
@@ -46,24 +46,25 @@ class SampleWindow;
46class OFontSelector; 46class OFontSelector;
47class QListView; 47class QListView;
48class QListViewItem; 48class QListViewItem;
49class Config; 49class Config;
50 50
51class Appearance : public QDialog 51class Appearance : public QDialog
52{ 52{
53 Q_OBJECT 53 Q_OBJECT
54 54
55public: 55public:
56 Appearance( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 ); 56 Appearance( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
57 ~Appearance(); 57 ~Appearance();
58 static QString appName() { return QString::fromLatin1("appearance"); }
58 59
59protected: 60protected:
60 virtual void accept ( ); 61 virtual void accept ( );
61 virtual void done ( int r ); 62 virtual void done ( int r );
62 63
63protected slots: 64protected slots:
64 void styleClicked ( int ); 65 void styleClicked ( int );
65 void styleSettingsClicked ( ); 66 void styleSettingsClicked ( );
66 void decoClicked ( int ); 67 void decoClicked ( int );
67 void fontClicked ( const QFont & ); 68 void fontClicked ( const QFont & );
68 void colorClicked ( int ); 69 void colorClicked ( int );
69 70
diff --git a/noncore/settings/appearance2/appearance2.pro b/noncore/settings/appearance2/appearance2.pro
index e37536d..145de2f 100644
--- a/noncore/settings/appearance2/appearance2.pro
+++ b/noncore/settings/appearance2/appearance2.pro
@@ -1,33 +1,31 @@
1TEMPLATE = app 1CONFIG = qt warn_on release quick-app
2CONFIG = qt warn_on release
3DESTDIR = $(OPIEDIR)/bin
4HEADERS = appearance.h editScheme.h sample.h 2HEADERS = appearance.h editScheme.h sample.h
5SOURCES = appearance.cpp editScheme.cpp main.cpp sample.cpp 3SOURCES = appearance.cpp editScheme.cpp main.cpp sample.cpp
6INCLUDEPATH += $(OPIEDIR)/include 4INCLUDEPATH += $(OPIEDIR)/include
7DEPENDPATH += ../$(OPIEDIR)/include 5DEPENDPATH += ../$(OPIEDIR)/include
8LIBS += -lqpe -lopie 6LIBS += -lqpe -lopie
9TARGET = appearance
10INCLUDEPATH += $(OPIEDIR)/include 7INCLUDEPATH += $(OPIEDIR)/include
11DEPENDPATH += $(OPIEDIR)/include 8DEPENDPATH += $(OPIEDIR)/include
12 9
10 TARGET = appearance
11
13TRANSLATIONS = ../../../i18n/de/appearance.ts \ 12TRANSLATIONS = ../../../i18n/de/appearance.ts \
14 ../../../i18n/nl/appearance.ts \ 13 ../../../i18n/nl/appearance.ts \
15 ../../../i18n/xx/appearance.ts \ 14 ../../../i18n/xx/appearance.ts \
16 ../../../i18n/en/appearance.ts \ 15 ../../../i18n/en/appearance.ts \
17 ../../../i18n/es/appearance.ts \ 16 ../../../i18n/es/appearance.ts \
18 ../../../i18n/fr/appearance.ts \ 17 ../../../i18n/fr/appearance.ts \
19 ../../../i18n/hu/appearance.ts \ 18 ../../../i18n/hu/appearance.ts \
20 ../../../i18n/ja/appearance.ts \ 19 ../../../i18n/ja/appearance.ts \
21 ../../../i18n/ko/appearance.ts \ 20 ../../../i18n/ko/appearance.ts \
22 ../../../i18n/no/appearance.ts \ 21 ../../../i18n/no/appearance.ts \
23 ../../../i18n/pl/appearance.ts \ 22 ../../../i18n/pl/appearance.ts \
24 ../../../i18n/pt/appearance.ts \ 23 ../../../i18n/pt/appearance.ts \
25 ../../../i18n/pt_BR/appearance.ts \ 24 ../../../i18n/pt_BR/appearance.ts \
26 ../../../i18n/sl/appearance.ts \ 25 ../../../i18n/sl/appearance.ts \
27 ../../../i18n/zh_CN/appearance.ts \ 26 ../../../i18n/zh_CN/appearance.ts \
28 ../../../i18n/zh_TW/appearance.ts \ 27 ../../../i18n/zh_TW/appearance.ts \
29 ../../../i18n/da/appearance.ts 28 ../../../i18n/da/appearance.ts
30 29
31 30
32
33include ( $(OPIEDIR)/include.pro ) 31include ( $(OPIEDIR)/include.pro )
diff --git a/noncore/settings/appearance2/main.cpp b/noncore/settings/appearance2/main.cpp
index ad24cf3..5595429 100644
--- a/noncore/settings/appearance2/main.cpp
+++ b/noncore/settings/appearance2/main.cpp
@@ -19,24 +19,16 @@
19 :     =  ...= . :.=- You should have received a copy of the GNU 19 :     =  ...= . :.=- You should have received a copy of the GNU
20 -.   .:....=;==+<; General Public License along with this file; 20 -.   .:....=;==+<; General Public License along with this file;
21  -_. . .   )=.  = see the file COPYING. If not, write to the 21  -_. . .   )=.  = see the file COPYING. If not, write to the
22    --        :-=` Free Software Foundation, Inc., 22    --        :-=` Free Software Foundation, Inc.,
23 59 Temple Place - Suite 330, 23 59 Temple Place - Suite 330,
24 Boston, MA 02111-1307, USA. 24 Boston, MA 02111-1307, USA.
25 25
26*/ 26*/
27 27
28#include "appearance.h" 28#include "appearance.h"
29 29
30#include <qpe/qpeapplication.h> 30#include <qpe/qpeapplication.h>
31#include <opie/oapplicationfactory.h>
31 32
32 33
33int main ( int argc, char **argv ) 34OPIE_EXPORT_APP( OApplicationFactory<Appearance> )
34{
35 QPEApplication app ( argc, argv );
36
37 Appearance m;
38 app. showMainDocumentWidget ( &m );
39
40 return app. exec ( );
41}
42