From 2391cfd9c79b87b3b00a4bb4a1d76981debb4486 Mon Sep 17 00:00:00 2001 From: drw Date: Sun, 24 Apr 2005 21:32:37 +0000 Subject: Resource -> OResource --- (limited to 'core/applets') diff --git a/core/applets/restartapplet2/opie-restartapplet2.control b/core/applets/restartapplet2/opie-restartapplet2.control index cec3b19..9cc8dac 100644 --- a/core/applets/restartapplet2/opie-restartapplet2.control +++ b/core/applets/restartapplet2/opie-restartapplet2.control @@ -4,7 +4,7 @@ Priority: optional Section: opie/applets Maintainer: L.J. Potter Architecture: arm -Depends: task-opie-minimal +Depends: task-opie-minimal, libopiecore2 Description: Restart Applet A simple opie menu applet to restart the Opie environment Version: $QPE_VERSION$EXTRAVERSION diff --git a/core/applets/restartapplet2/restart.cpp b/core/applets/restartapplet2/restart.cpp index eda0005..42d814a 100644 --- a/core/applets/restartapplet2/restart.cpp +++ b/core/applets/restartapplet2/restart.cpp @@ -2,42 +2,12 @@ #include "restart.h" +#include + #include #include -#include #include -/* XPM */ -static char *restart_xpm[] = { -"16 16 11 1", -" c None", -". c #000000", -"+ c #DCDCDC", -"@ c #A0A0A0", -"# c #C3C3C3", -"$ c #808080", -"% c #FFA858", -"& c #FFDCA8", -"* c #FFFFC0", -"= c #FFFFFF", -"- c #585858", -" .. ", -" .. .++. .. ", -" .+@.@##@.@+. ", -" .@+$@%%@$+@. ", -" .$%%&%&%$. ", -" ..+@%&$$%&@+.. ", -".+#@%&%@@&*%@#+.", -".$@+$&*&&=*$+@$.", -" .--+$&*=&$+--. ", -" .$#++$$++#$. ", -" .@=$-$++$-$=@. ", -" .+@-..@@..-@+. ", -" ... .+=. ... ", -" .-$. ", -" .. ", -" "}; - RestartApplet::RestartApplet ( ) : QObject ( 0, "RestartApplet" ) { @@ -64,12 +34,8 @@ QString RestartApplet::text ( ) const QIconSet RestartApplet::icon ( ) const { - QPixmap pix; - QImage img = ( const char** ) restart_xpm ;//Resource::loadImage ( "Run" ); - - if ( !img. isNull ( )) - pix.convertFromImage( img.smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ) ); - return pix; + QPixmap pix = Opie::Core::OResource::loadPixmap( "exec", Opie::Core::OResource::SmallIcon ); + return pix; } QPopupMenu *RestartApplet::popup ( QWidget * ) const diff --git a/core/applets/restartapplet2/restartapplet.pro b/core/applets/restartapplet2/restartapplet.pro index 60d34f2..d3c408d 100644 --- a/core/applets/restartapplet2/restartapplet.pro +++ b/core/applets/restartapplet2/restartapplet.pro @@ -6,7 +6,7 @@ TARGET = restartapplet2 DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include -LIBS += -lqpe +LIBS += -lqpe -lopiecore2 VERSION = 1.0.0 MOC_DIR=opieobj OBJECTS_DIR=opieobj diff --git a/core/applets/rotateapplet/rotate.cpp b/core/applets/rotateapplet/rotate.cpp index d13c2c0..9abbde8 100644 --- a/core/applets/rotateapplet/rotate.cpp +++ b/core/applets/rotateapplet/rotate.cpp @@ -1,28 +1,30 @@ /* - This file is part of the OPIE Project +                 This file is part of the Opie Project + Copyright (C) 2003 Maximilian Reiss Copyright (C) 2003 Greg Gilbert -               =. Copyright (C) 2004 Michael Lauer -             .=l. -           .>+-= - _;:,     .>    :=|. This library is free software; you can -.> <,   >  .   <= redistribute it and/or modify it under -:=1 )Y*s>-.--   : the terms of the GNU Library General Public -.="- .-=="i,     .._ License as published by the Free Software - - .   .-<_>     .<> Foundation; either version 2 of the License, -     ._= =}       : or (at your option) any later version. -    .%+i>       _;_. -    .i_,=:_.      -: PARTICULAR PURPOSE. See the GNU -..}^=.=       =       ; Library General Public License for more -++=   -.     .     .: details. - :     =  ...= . :.=- - -.   .:....=;==+<; You should have received a copy of the GNU -  -_. . .   )=.  = Library General Public License along with -    --        :-= this library; see the file COPYING.LIB. + Copyright (C) 2004 Michael Lauer + =. + .=l. +           .>+-= + _;:,     .>    :=|. This program is free software; you can +.> <`_,   >  .   <= redistribute it and/or modify it under + :`=1 )Y*s>-.--   : the terms of the GNU Library General Public +.="- .-=="i,     .._ License as published by the Free Software + - .   .-<_>     .<> Foundation; either version 2 of the License, +     ._= =}       : or (at your option) any later version. +    .%`+i>       _;_. +    .i_,=:_.      -`: PARTICULAR PURPOSE. See the GNU +..}^=.=       =       ; Library General Public License for more +++=   -.     .`     .: details. + :     =  ...= . :.=- + -.   .:....=;==+<; You should have received a copy of the GNU +  -_. . .   )=.  = Library General Public License along with +    --        :-=` this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. @@ -33,11 +35,12 @@ /* OPIE */ #include #include +#include + #include #include #include #include -#include using namespace Opie::Core; /* STD */ @@ -139,10 +142,7 @@ QString RotateApplet::tr( const char* s, const char* p ) const QIconSet RotateApplet::icon() const { - QPixmap pix; - QImage img = Resource::loadImage( "Rotation" ); - if ( !img.isNull() ) - pix.convertFromImage( img.smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ) ); + QPixmap pix = Opie::Core::OResource::loadPixmap( "Rotation", Opie::Core::OResource::SmallIcon ); return pix; } diff --git a/core/applets/vtapplet/opie-vtapplet.control b/core/applets/vtapplet/opie-vtapplet.control index a1662f1..ae504a9 100644 --- a/core/applets/vtapplet/opie-vtapplet.control +++ b/core/applets/vtapplet/opie-vtapplet.control @@ -4,6 +4,6 @@ Priority: optional Section: opie/applets Maintainer: Opie Team Architecture: arm -Depends: task-opie-minimal +Depends: task-opie-minimal, libopiecore2 Description: Switch to another virtual terminal Version: $QPE_VERSION$EXTRAVERSION diff --git a/core/applets/vtapplet/vt.cpp b/core/applets/vtapplet/vt.cpp index ae89635..0d4e657 100644 --- a/core/applets/vtapplet/vt.cpp +++ b/core/applets/vtapplet/vt.cpp @@ -15,8 +15,10 @@ /* OPIE */ #include +#include + #include -#include + using namespace Opie::Core; /* QT */ @@ -68,11 +70,7 @@ QString VTApplet::tr( const char* s, const char* p ) const QIconSet VTApplet::icon ( ) const { - QPixmap pix; - QImage img = Resource::loadImage ( "terminal" ); - - if ( !img. isNull ( )) - pix.convertFromImage( img.smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ) ); + QPixmap pix = Opie::Core::OResource::loadPixmap( "terminal", Opie::Core::OResource::SmallIcon ); return pix; } diff --git a/core/applets/vtapplet/vtapplet.pro b/core/applets/vtapplet/vtapplet.pro index 6c4873c..912af58 100644 --- a/core/applets/vtapplet/vtapplet.pro +++ b/core/applets/vtapplet/vtapplet.pro @@ -6,7 +6,7 @@ TARGET = vtapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include -LIBS += -lqpe +LIBS += -lqpe -lopiecore2 VERSION = 1.0.0 include( $(OPIEDIR)/include.pro ) -- cgit v0.9.0.2