summaryrefslogtreecommitdiff
path: root/libopie2/opiecore/device/odevice_yopy.cpp
authordrw <drw>2005-04-05 23:01:28 (UTC)
committer drw <drw>2005-04-05 23:01:28 (UTC)
commit2b0e27b45eb9ff5563f786c5e45d53db49afb9f9 (patch) (unidiff)
treee5dfb23aa8e0e3778b5fa1f5633f6511789f41f2 /libopie2/opiecore/device/odevice_yopy.cpp
parent2a9ee3ea1d8d978b735f0ce3f2e54a15e37c87b3 (diff)
downloadopie-2b0e27b45eb9ff5563f786c5e45d53db49afb9f9.zip
opie-2b0e27b45eb9ff5563f786c5e45d53db49afb9f9.tar.gz
opie-2b0e27b45eb9ff5563f786c5e45d53db49afb9f9.tar.bz2
Use OResource for loading images
Diffstat (limited to 'libopie2/opiecore/device/odevice_yopy.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opiecore/device/odevice_yopy.cpp58
1 files changed, 30 insertions, 28 deletions
diff --git a/libopie2/opiecore/device/odevice_yopy.cpp b/libopie2/opiecore/device/odevice_yopy.cpp
index 8f22514..f81e452 100644
--- a/libopie2/opiecore/device/odevice_yopy.cpp
+++ b/libopie2/opiecore/device/odevice_yopy.cpp
@@ -1,30 +1,31 @@
1/* 1/*
2                This file is part of the Opie Project 2                 This file is part of the Opie Project
3             Copyright (C) The Opie Team <opie-devel@handhelds.org> 3
4 =. 4 Copyright (C)2002-2005 The Opie Team <opie-devel@handhelds.org>
5 .=l. 5 =.
6          .>+-= 6 .=l.
7_;:,     .>    :=|. This program is free software; you can 7           .>+-=
8.> <`_,   >  .   <= redistribute it and/or modify it under 8 _;:,     .>    :=|. This program is free software; you can
9:`=1 )Y*s>-.--   : the terms of the GNU Library General Public 9.> <`_,   >  .   <= redistribute it and/or modify it under
10.="- .-=="i,     .._ License as published by the Free Software 10:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
11- .   .-<_>     .<> Foundation; either version 2 of the License, 11.="- .-=="i,     .._ License as published by the Free Software
12    ._= =}       : or (at your option) any later version. 12 - .   .-<_>     .<> Foundation; either version 2 of the License,
13   .%`+i>       _;_. 13     ._= =}       : or (at your option) any later version.
14   .i_,=:_.      -<s. This program is distributed in the hope that 14    .%`+i>       _;_.
15    +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY; 15    .i_,=:_.      -<s. This program is distributed in the hope that
16   : ..    .:,     . . . without even the implied warranty of 16     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
17   =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A 17 : ..    .:,     . . . without even the implied warranty of
18 _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU 18    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
19..}^=.=       =       ; Library General Public License for more 19  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
20++=   -.     .`     .: details. 20..}^=.=       =       ; Library General Public License for more
21:     =  ...= . :.=- 21++=   -.     .`     .: details.
22-.   .:....=;==+<; You should have received a copy of the GNU 22:     =  ...= . :.=-
23 -_. . .   )=.  = Library General Public License along with 23 -.   .:....=;==+<; You should have received a copy of the GNU
24   --        :-=` this library; see the file COPYING.LIB. 24  -_. . .   )=.  = Library General Public License along with
25 If not, write to the Free Software Foundation, 25    --        :-=` this library; see the file COPYING.LIB.
26 Inc., 59 Temple Place - Suite 330, 26 If not, write to the Free Software Foundation,
27 Boston, MA 02111-1307, USA. 27 Inc., 59 Temple Place - Suite 330,
28 Boston, MA 02111-1307, USA.
28*/ 29*/
29 30
30#include "odevice_yopy.h" 31#include "odevice_yopy.h"
@@ -37,10 +38,11 @@ _;:,     .>    :=|. This program is free software; you can
37 38
38/* OPIE */ 39/* OPIE */
39#include <qpe/config.h> 40#include <qpe/config.h>
40#include <qpe/resource.h>
41#include <qpe/sound.h> 41#include <qpe/sound.h>
42#include <qpe/qcopenvelope_qws.h> 42#include <qpe/qcopenvelope_qws.h>
43 43
44#include <opie2/oresource.h>
45
44/* STD */ 46/* STD */
45#include <fcntl.h> 47#include <fcntl.h>
46#include <math.h> 48#include <math.h>
@@ -100,7 +102,7 @@ void Yopy::initButtons()
100 102
101 b. setKeycode ( ib->code ); 103 b. setKeycode ( ib->code );
102 b. setUserText ( QObject::tr ( "Button", ib->utext ) ); 104 b. setUserText ( QObject::tr ( "Button", ib->utext ) );
103 b. setPixmap ( Resource::loadPixmap ( ib->pix ) ); 105 b. setPixmap ( OResource::loadPixmap ( ib->pix ) );
104 b. setFactoryPresetPressedAction 106 b. setFactoryPresetPressedAction
105 ( OQCopMessage( makeChannel( ib->fpressedservice ), ib->fpressedaction ) ); 107 ( OQCopMessage( makeChannel( ib->fpressedservice ), ib->fpressedaction ) );
106 b. setFactoryPresetHeldAction 108 b. setFactoryPresetHeldAction