summaryrefslogtreecommitdiff
path: root/core/launcher/documentlist.cpp
authormickeyl <mickeyl>2005-07-03 22:13:00 (UTC)
committer mickeyl <mickeyl>2005-07-03 22:13:00 (UTC)
commit2cabd9ad4b49eefccdf99ad59550c76546b473c9 (patch) (unidiff)
tree00bab275ac356aecc5a39b86ca22ce172d01f622 /core/launcher/documentlist.cpp
parent47011752d4457a1055894479e5bf855e100fddac (diff)
downloadopie-2cabd9ad4b49eefccdf99ad59550c76546b473c9.zip
opie-2cabd9ad4b49eefccdf99ad59550c76546b473c9.tar.gz
opie-2cabd9ad4b49eefccdf99ad59550c76546b473c9.tar.bz2
Resource -> OResource
This is a large diff and I'd appreciate some additional pairs of eyes checking it
Diffstat (limited to 'core/launcher/documentlist.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/launcher/documentlist.cpp72
1 files changed, 37 insertions, 35 deletions
diff --git a/core/launcher/documentlist.cpp b/core/launcher/documentlist.cpp
index b8bf4e0..fd385d6 100644
--- a/core/launcher/documentlist.cpp
+++ b/core/launcher/documentlist.cpp
@@ -1,20 +1,28 @@
1/********************************************************************** 1/*
2** Copyright (C) 2000-2002 Trolltech AS. All rights reserved. 2                 This file is part of the Opie Project
3** 3 =. (C) 2000-2002 Trolltech AS
4** This file is part of the Qtopia Environment. 4 .=l. (C) 2002-2005 The Opie Team <opie-devel@handhelds.org>
5** 5           .>+-=
6** This file may be distributed and/or modified under the terms of the 6 _;:,     .>    :=|. This program is free software; you can
7** GNU General Public License version 2 as published by the Free Software 7.> <`_,   >  .   <= redistribute it and/or modify it under
8** Foundation and appearing in the file LICENSE.GPL included in the 8 :`=1 )Y*s>-.--   : the terms of the GNU Library General Public
9** packaging of this file. 9.="- .-=="i,     .._ License as published by the Free Software
10** 10 - .   .-<_>     .<> Foundation; version 2 of the License.
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11     ._= =}       :
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12    .%`+i>       _;_.
13** 13    .i_,=:_.      -<s. This program is distributed in the hope that
14** See http://www.trolltech.com/gpl/ for GPL licensing information. 14     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
15** 15 : ..    .:,     . . . without even the implied warranty of
16** Contact info@trolltech.com if any conditions of this licensing are 16    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
17** not clear to you. 17  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
18** 18..}^=.=       =       ; Library General Public License for more
19**********************************************************************/ 19++=   -.     .`     .: details.
20 :     =  ...= . :.=-
21 -.   .:....=;==+<; You should have received a copy of the GNU
22  -_. . .   )=.  = Library General Public License along with
23    --        :-=` this library; see the file COPYING.LIB.
24 If not, write to the Free Software Foundation,
25 Inc., 59 Temple Place - Suite 330,
26 Boston, MA 02111-1307, USA.
27*/
20#include "documentlist.h" 28#include "documentlist.h"
@@ -26,5 +34,5 @@
26#include <opie2/odebug.h> 34#include <opie2/odebug.h>
35#include <opie2/oresource.h>
27#include <qtopia/config.h> 36#include <qtopia/config.h>
28#include <qtopia/mimetype.h> 37#include <qtopia/mimetype.h>
29#include <qtopia/resource.h>
30#include <qtopia/private/categories.h> 38#include <qtopia/private/categories.h>
@@ -234,11 +242,9 @@ void DocumentList::reloadAppLnks()
234 242
235 if (pm.isNull()) { 243 if (pm.isNull())
236 QImage img( Resource::loadImage( "UnknownDocument" ) ); 244 {
237 pm = img.smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ); 245 pm = OResource::loadImage( "UnknownDocument", OResource::SmallIcon );
238 bgPm = img.smoothScale( AppLnk::bigIconSize(), AppLnk::bigIconSize() ); 246 bgPm = OResource::loadImage( "UnknownDocument", OResource::BigIcon );
239 } 247 }
240 248
241 //odebug << "adding type " << (*ittypes) << "" << oendl; 249 //FIXME our current launcher expects docs tab to be last
242
243 // ### our current launcher expects docs tab to be last
244 d->serverGui->typeAdded( *ittypes, name.isNull() ? (*ittypes) : name, pm, bgPm ); 250 d->serverGui->typeAdded( *ittypes, name.isNull() ? (*ittypes) : name, pm, bgPm );
@@ -249,3 +255,2 @@ void DocumentList::reloadAppLnks()
249 for ( QStringList::Iterator ittypes=prevTypeList.begin(); ittypes!=prevTypeList.end(); ++ittypes) { 255 for ( QStringList::Iterator ittypes=prevTypeList.begin(); ittypes!=prevTypeList.end(); ++ittypes) {
250 //odebug << "removing type " << (*ittypes) << "" << oendl;
251 d->serverGui->typeRemoved(*ittypes); 256 d->serverGui->typeRemoved(*ittypes);
@@ -359,10 +364,8 @@ void DocumentList::DiffAppLnks()
359 364
360 if (pm.isNull()) { 365 if (pm.isNull())
361 QImage img( Resource::loadImage( "UnknownDocument" ) ); 366 {
362 pm = img.smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ); 367 pm = OResource::loadImage( "UnknownDocument", OResource::SmallIcon );
363 bgPm = img.smoothScale( AppLnk::bigIconSize(), AppLnk::bigIconSize() ); 368 bgPm = OResource::loadImage( "UnknownDocument", OResource::BigIcon );
364 } 369 }
365 370
366 odebug << "adding type " << (*ittypes) << "" << oendl;
367
368 // ### our current launcher expects docs tab to be last 371 // ### our current launcher expects docs tab to be last
@@ -374,3 +377,2 @@ void DocumentList::DiffAppLnks()
374 for ( QStringList::Iterator ittypes=prevTypeList.begin(); ittypes!=prevTypeList.end(); ++ittypes) { 377 for ( QStringList::Iterator ittypes=prevTypeList.begin(); ittypes!=prevTypeList.end(); ++ittypes) {
375 odebug << "removing type " << (*ittypes) << "" << oendl;
376 d->serverGui->typeRemoved(*ittypes); 378 d->serverGui->typeRemoved(*ittypes);