summaryrefslogtreecommitdiff
path: root/core/pim/today/todayconfig.cpp
Unidiff
Diffstat (limited to 'core/pim/today/todayconfig.cpp') (more/less context) (show whitespace changes)
-rw-r--r--core/pim/today/todayconfig.cpp47
1 files changed, 31 insertions, 16 deletions
diff --git a/core/pim/today/todayconfig.cpp b/core/pim/today/todayconfig.cpp
index 864c708..04a16e1 100644
--- a/core/pim/today/todayconfig.cpp
+++ b/core/pim/today/todayconfig.cpp
@@ -1,29 +1,43 @@
1/* 1/*
2 * todayconfig.cpp 2                 This file is part of the Opie Project
3 * 3
4 * copyright : (c) 2002, 2003, 2004 by Maximilian Reiß 4 Copyright (C) Maximilian Reiss <harlekin@handhelds.org>
5 * email : harlekin@handhelds.org 5 =.
6 * 6 .=l.
7           .>+-=
8 _;:,     .>    :=|. This program is free software; you can
9.> <`_,   >  .   <= redistribute it and/or modify it under
10:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
11.="- .-=="i,     .._ License as published by the Free Software
12 - .   .-<_>     .<> Foundation; either version 2 of the License,
13     ._= =}       : or (at your option) any later version.
14    .%`+i>       _;_.
15    .i_,=:_.      -<s. This program is distributed in the hope that
16     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
17    : ..    .:,     . . . without even the implied warranty of
18    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
19  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
20..}^=.=       =       ; Library General Public License for more
21++=   -.     .`     .: details.
22 :     =  ...= . :.=-
23 -.   .:....=;==+<; You should have received a copy of the GNU
24  -_. . .   )=.  = Library General Public License along with
25    --        :-=` this library; see the file COPYING.LIB.
26 If not, write to the Free Software Foundation,
27 Inc., 59 Temple Place - Suite 330,
28 Boston, MA 02111-1307, USA.
7 */ 29 */
8/***************************************************************************
9 * *
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 *
12 * the Free Software Foundation; either version 2 of the License, or *
13 * (at your option) any later version. *
14 * *
15 ***************************************************************************/
16 30
17#include "todayconfig.h" 31#include "todayconfig.h"
18 32
19#include <opie2/oconfig.h> 33#include <opie2/oconfig.h>
20#include <opie2/opluginloader.h> 34#include <opie2/opluginloader.h>
35#include <opie2/oresource.h>
21#include <opie2/todayplugininterface.h> 36#include <opie2/todayplugininterface.h>
22 37
23#include <qpe/resource.h>
24#include <qpe/qcopenvelope_qws.h> 38#include <qpe/qcopenvelope_qws.h>
25#include <qpe/qpeapplication.h> 39#include <qpe/qpeapplication.h>
26 40
27#include <qcheckbox.h> 41#include <qcheckbox.h>
28#include <qlabel.h> 42#include <qlabel.h>
29#include <qspinbox.h> 43#include <qspinbox.h>
@@ -41,13 +55,14 @@ using Opie::Core::OPluginItem;
41 55
42class ToolButton : public QToolButton { 56class ToolButton : public QToolButton {
43 57
44public: 58public:
45 ToolButton( QWidget *parent, const char *name, const QString& icon, QObject *handler, const QString& slot, bool t = FALSE ) 59 ToolButton( QWidget *parent, const char *name, const QString& icon, QObject *handler, const QString& slot, bool t = FALSE )
46: QToolButton( parent, name ) { 60: QToolButton( parent, name ) {
47 setPixmap( Resource::loadPixmap( icon ) ); 61 setUsesBigPixmap( true );
62 setPixmap( Opie::Core::OResource::loadPixmap( icon, Opie::Core::OResource::SmallIcon ) );
48 setAutoRaise( TRUE ); 63 setAutoRaise( TRUE );
49 setFocusPolicy( QWidget::NoFocus ); 64 setFocusPolicy( QWidget::NoFocus );
50 setToggleButton( t ); 65 setToggleButton( t );
51 connect( this, t ? SIGNAL( toggled(bool) ) : SIGNAL( clicked() ), handler, slot ); 66 connect( this, t ? SIGNAL( toggled(bool) ) : SIGNAL( clicked() ), handler, slot );
52 } 67 }
53}; 68};
@@ -239,13 +254,13 @@ void TodayConfig::moveSelectedDown() {
239 */ 254 */
240void TodayConfig::pluginManagement( OPluginItem plugItem ) { 255void TodayConfig::pluginManagement( OPluginItem plugItem ) {
241 256
242 QCheckListItem *item = new QCheckListItem( m_appletListView, plugItem.name(), QCheckListItem::CheckBox ); 257 QCheckListItem *item = new QCheckListItem( m_appletListView, plugItem.name(), QCheckListItem::CheckBox );
243 258
244 TodayPluginInterface* iface = m_pluginLoader->load<TodayPluginInterface>( plugItem, IID_TodayPluginInterface ); 259 TodayPluginInterface* iface = m_pluginLoader->load<TodayPluginInterface>( plugItem, IID_TodayPluginInterface );
245 QPixmap icon = Resource::loadPixmap( iface->guiPart()->pixmapNameWidget() ); 260 QPixmap icon = Opie::Core::OResource::loadPixmap( iface->guiPart()->pixmapNameWidget(), Opie::Core::OResource::SmallIcon );
246 if ( !icon.isNull() ) { 261 if ( !icon.isNull() ) {
247 item->setPixmap( 0, icon ); 262 item->setPixmap( 0, icon );
248 } 263 }
249 item->setOn( plugItem.isEnabled() ); 264 item->setOn( plugItem.isEnabled() );
250 previousItem = item; 265 previousItem = item;
251} 266}