summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/settings/citytime/opie-citytime.control2
-rw-r--r--core/settings/citytime/zonemap.cpp10
2 files changed, 7 insertions, 5 deletions
diff --git a/core/settings/citytime/opie-citytime.control b/core/settings/citytime/opie-citytime.control
index 03fa555..71ee7d0 100644
--- a/core/settings/citytime/opie-citytime.control
+++ b/core/settings/citytime/opie-citytime.control
@@ -1,10 +1,10 @@
Package: opie-citytime
Files: plugins/application/libcitytime.so* bin/citytime apps/Settings/citytime.desktop pics/citytime
Priority: optional
Section: opie/settings
Maintainer: Maximilian Reiss <harlekin@handhelds.org>
Architecture: arm
-Depends: task-opie-minimal
+Depends: task-opie-minimal, libopiecore2
Description: Time-zone / world clock settings
The time-zone manager for the Opie environment.
Version: $QPE_VERSION$EXTRAVERSION
diff --git a/core/settings/citytime/zonemap.cpp b/core/settings/citytime/zonemap.cpp
index e4a25ef..7edc45f 100644
--- a/core/settings/citytime/zonemap.cpp
+++ b/core/settings/citytime/zonemap.cpp
@@ -15,27 +15,28 @@
**
** Contact info@trolltech.com if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
// changes by Maximilian Reiss <harlekin@handhelds.org>
#include "sun.h"
#include "zonemap.h"
/* OPIE */
-#include <qpe/resource.h>
-#include <qpe/qpeapplication.h>
#include <opie2/odebug.h>
+#include <opie2/oresource.h>
+
+#include <qpe/qpeapplication.h>
/* QT */
#include <qfile.h>
#include <qlabel.h>
#include <qmessagebox.h>
#include <qtextstream.h>
#include <qtimer.h>
#include <qtoolbutton.h>
#include <qlayout.h>
#include <qhbox.h>
#include <qlistview.h>
#include <qwhatsthis.h>
@@ -151,27 +152,28 @@ ZoneMap::ZoneMap( QWidget *parent, const char* name )
bZoom( FALSE ),
bIllum( TRUE ),
cursor( 0 )
{
viewport()->setFocusPolicy( StrongFocus );
// set mouse tracking so we can use the mouse move event
zones.setAutoDelete( true );
// get the map loaded
// just set the current image to point
pixCurr = new QPixmap();
- QPixmap pixZoom = Resource::loadPixmap( "mag" );
+ QPixmap pixZoom = Opie::Core::OResource::loadPixmap( "mag", Opie::Core::OResource::SmallIcon );
cmdZoom = new QToolButton( this, "Zoom command" );
+ cmdZoom->setUsesBigPixmap( qApp->desktop()->size().width() > 330 );
cmdZoom->setPixmap( pixZoom );
cmdZoom->setToggleButton( true );
cmdZoom->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0,
(QSizePolicy::SizeType)0,
cmdZoom->sizePolicy().hasHeightForWidth() ) );
cmdZoom->setMaximumSize( cmdZoom->sizeHint() );
// probably don't need this, but just in case...
cmdZoom->move( width() - cmdZoom->width(), height() - cmdZoom->height() );
lblCity = new QLabel( tr( "CITY" ), this, "City Label" );
@@ -593,25 +595,25 @@ static inline void darken( QImage *pImage, int start, int stop, int row )
// assume that the image is similar to the one we have...
colors = pImage->numColors() / 2;
p = pImage->scanLine( row );
for ( j = start; j <= stop; j++ ) {
if ( p[j] < colors )
p[j] += colors;
}
}
void ZoneMap::makeMap( int w, int h )
{
- QImage imgOrig = Resource::loadImage( strMAP );
+ QImage imgOrig = Opie::Core::OResource::loadImage( strMAP );
if ( imgOrig.isNull() ) {
QMessageBox::warning( this,
tr( "Couldn't Find Map" ),
tr( "<p>Couldn't load map: %1, exiting")
.arg( strMAP ) );
exit(-1);
}
// set up the color table for darkening...
imgOrig = imgOrig.convertDepth( 8 );
int numColors = imgOrig.numColors();
// double the colors