Diffstat (limited to 'core/settings/citytime/zonemap.h') (more/less context) (show whitespace changes)
-rw-r--r-- | core/settings/citytime/zonemap.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/core/settings/citytime/zonemap.h b/core/settings/citytime/zonemap.h index c9c2035..ea0142b 100644 --- a/core/settings/citytime/zonemap.h +++ b/core/settings/citytime/zonemap.h @@ -31,13 +31,14 @@ extern const int iCITYOFFSET; class QImage; class QComboBox; class QLabel; class QTimer; class QToolButton; - +class QListViewItem; +class QListView; class ZoneField { public: ZoneField( const QString & ); @@ -60,12 +61,13 @@ class ZoneMap : public QScrollView { Q_OBJECT public: ZoneMap( QWidget *parent = 0, const char *name = 0 ); ~ZoneMap(); void showZones( void ) const; + QWidget* selectionWidget( QWidget* parent ); // convert between the pixels on the image and the coordinates in the // database inline bool zoneToWin( int zoneX, int zoneY, int &winX, int &winY ) const; inline bool winToZone( int winX, int winY, int &zoneX, int &zoneY ) const; public slots: @@ -84,12 +86,15 @@ protected: virtual void viewportMousePressEvent( QMouseEvent *event ); virtual void viewportMouseReleaseEvent( QMouseEvent *event ); virtual void keyPressEvent( QKeyEvent * ); virtual void resizeEvent( QResizeEvent *); virtual void drawContents( QPainter *p, int cx, int cy, int cw, int ch ); +private slots: + void slotGetCities( QListViewItem * ); + void slotCitySelected( QListViewItem * ); private: ZoneField *findCityNear( ZoneField *city, int key ); void showCity( ZoneField *city ); void drawCities( QPainter *p ); // put all the cities on the map (ugly) void drawCity( QPainter *p, const ZoneField *pCity ); // draw the given city on the map void readZones( void ); // Read in the zone information from the file @@ -101,12 +106,15 @@ private: QTimer* tHide; // the timer to hide the "tool tip" ZoneField *pLast; // the last known good city that was found... ZoneField *pRepaint; // save the location to maximize the repaint... QList<ZoneField> zones; // a linked list to hold all this information StylusNormalizer norm; + QListView *cityView; + QString selectedCont; + //the True width and height of the map... int wImg; int hImg; // the pixel points that correspond to (0, 0); int ox; int oy; |