summaryrefslogtreecommitdiff
path: root/core/pim/today/todayconfig.cpp
Unidiff
Diffstat (limited to 'core/pim/today/todayconfig.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/today/todayconfig.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/core/pim/today/todayconfig.cpp b/core/pim/today/todayconfig.cpp
index a6f53e1..4f0877c 100644
--- a/core/pim/today/todayconfig.cpp
+++ b/core/pim/today/todayconfig.cpp
@@ -1,80 +1,81 @@
1/* 1/*
2 * todayconfig.cpp 2 * todayconfig.cpp
3 * 3 *
4 * copyright : (c) 2002, 2003, 2004 by Maximilian Reiß 4 * copyright : (c) 2002, 2003, 2004 by Maximilian Reiß
5 * email : harlekin@handhelds.org 5 * email : harlekin@handhelds.org
6 * 6 *
7 */ 7 */
8/*************************************************************************** 8/***************************************************************************
9 * * 9 * *
10 * This program is free software; you can redistribute it and/or modify * 10 * This program is free software; you can redistribute it and/or modify *
11 * it under the terms of the GNU General Public License as published by * 11 * it under the terms of the GNU General Public License as published by *
12 * the Free Software Foundation; either version 2 of the License, or * 12 * the Free Software Foundation; either version 2 of the License, or *
13 * (at your option) any later version. * 13 * (at your option) any later version. *
14 * * 14 * *
15 ***************************************************************************/ 15 ***************************************************************************/
16 16
17#include "todayconfig.h" 17#include "todayconfig.h"
18 18
19#include <qpe/config.h> 19#include <qpe/config.h>
20#include <qpe/resource.h> 20#include <qpe/resource.h>
21#include <qpe/qcopenvelope_qws.h> 21#include <qpe/qcopenvelope_qws.h>
22#include <qpe/qpeapplication.h> 22#include <qpe/qpeapplication.h>
23 23
24#include <qcheckbox.h> 24#include <qcheckbox.h>
25#include <qlabel.h> 25#include <qlabel.h>
26#include <qspinbox.h> 26#include <qspinbox.h>
27#include <qlayout.h> 27#include <qlayout.h>
28#include <qheader.h> 28#include <qheader.h>
29#include <qvbox.h> 29#include <qvbox.h>
30#include <qtoolbutton.h> 30#include <qtoolbutton.h>
31#include <qwhatsthis.h> 31#include <qwhatsthis.h>
32 32
33using namespace Opie::Ui;
33class ToolButton : public QToolButton { 34class ToolButton : public QToolButton {
34 35
35public: 36public:
36 ToolButton( QWidget *parent, const char *name, const QString& icon, QObject *handler, const QString& slot, bool t = FALSE ) 37 ToolButton( QWidget *parent, const char *name, const QString& icon, QObject *handler, const QString& slot, bool t = FALSE )
37 : QToolButton( parent, name ) { 38 : QToolButton( parent, name ) {
38 setPixmap( Resource::loadPixmap( icon ) ); 39 setPixmap( Resource::loadPixmap( icon ) );
39 setAutoRaise( TRUE ); 40 setAutoRaise( TRUE );
40 setFocusPolicy( QWidget::NoFocus ); 41 setFocusPolicy( QWidget::NoFocus );
41 setToggleButton( t ); 42 setToggleButton( t );
42 connect( this, t ? SIGNAL( toggled(bool) ) : SIGNAL( clicked() ), handler, slot ); 43 connect( this, t ? SIGNAL( toggled(bool) ) : SIGNAL( clicked() ), handler, slot );
43 } 44 }
44}; 45};
45 46
46 47
47/** 48/**
48 * The class has currently quite some duplicate code. 49 * The class has currently quite some duplicate code.
49 * By that way it would be real easy to have it as seperate app in settings tab 50 * By that way it would be real easy to have it as seperate app in settings tab
50 * 51 *
51 */ 52 */
52TodayConfig::TodayConfig( QWidget* parent, const char* name, bool modal ) 53TodayConfig::TodayConfig( QWidget* parent, const char* name, bool modal )
53 : QDialog( parent, name, modal, WStyle_ContextHelp ) { 54 : QDialog( parent, name, modal, WStyle_ContextHelp ) {
54 55
55 setCaption( tr( "Today Config" ) ); 56 setCaption( tr( "Today Config" ) );
56 57
57 QVBoxLayout *layout = new QVBoxLayout( this ); 58 QVBoxLayout *layout = new QVBoxLayout( this );
58 TabWidget3 = new OTabWidget ( this, "tabwidget", OTabWidget::Global, OTabWidget::Bottom ); 59 TabWidget3 = new OTabWidget ( this, "tabwidget", OTabWidget::Global, OTabWidget::Bottom );
59 layout->addWidget( TabWidget3 ); 60 layout->addWidget( TabWidget3 );
60 61
61 tab_2 = new QWidget( TabWidget3, "tab_2" ); 62 tab_2 = new QWidget( TabWidget3, "tab_2" );
62 QVBoxLayout *tab2Layout = new QVBoxLayout( tab_2, 4 ,4 ); 63 QVBoxLayout *tab2Layout = new QVBoxLayout( tab_2, 4 ,4 );
63 QLabel *l = new QLabel( tr( "Load which plugins in what order:" ), tab_2 ); 64 QLabel *l = new QLabel( tr( "Load which plugins in what order:" ), tab_2 );
64 tab2Layout->addWidget( l ); 65 tab2Layout->addWidget( l );
65 QHBox *hbox1 = new QHBox( tab_2 ); 66 QHBox *hbox1 = new QHBox( tab_2 );
66 m_appletListView = new QListView( hbox1 ); 67 m_appletListView = new QListView( hbox1 );
67 m_appletListView->addColumn( "PluginList" ); 68 m_appletListView->addColumn( "PluginList" );
68 m_appletListView->header()->hide(); 69 m_appletListView->header()->hide();
69 m_appletListView->setSorting( -1 ); 70 m_appletListView->setSorting( -1 );
70 QWhatsThis::add( m_appletListView, tr( "Check a checkbox to activate/deactivate a plugin or use the arrow buttons on the right to change the appearance order" ) ); 71 QWhatsThis::add( m_appletListView, tr( "Check a checkbox to activate/deactivate a plugin or use the arrow buttons on the right to change the appearance order" ) );
71 QVBox *vbox1 = new QVBox( hbox1 ); 72 QVBox *vbox1 = new QVBox( hbox1 );
72 new ToolButton( vbox1, tr( "Move Up" ), "up", this , SLOT( moveSelectedUp() ) ); 73 new ToolButton( vbox1, tr( "Move Up" ), "up", this , SLOT( moveSelectedUp() ) );
73 new ToolButton( vbox1, tr( "Move Down" ), "down", this , SLOT( moveSelectedDown() ) ); 74 new ToolButton( vbox1, tr( "Move Down" ), "down", this , SLOT( moveSelectedDown() ) );
74 tab2Layout->addWidget( hbox1 ); 75 tab2Layout->addWidget( hbox1 );
75 TabWidget3->addTab( tab_2, "pass", tr( "active/order" ) ); 76 TabWidget3->addTab( tab_2, "pass", tr( "active/order" ) );
76 77
77 // Misc tab 78 // Misc tab
78 tab_3 = new QWidget( TabWidget3, "tab_3" ); 79 tab_3 = new QWidget( TabWidget3, "tab_3" );
79 QVBoxLayout *tab3Layout = new QVBoxLayout( tab_3 ); 80 QVBoxLayout *tab3Layout = new QVBoxLayout( tab_3 );
80 81