• Skip to content
  • Skip to link menu
KDE 3.5 API Reference
  • KDE API Reference
  • API Reference
  • Sitemap
  • Contact Us
 

kstars

locationdialog.h

Go to the documentation of this file.
00001 /***************************************************************************
00002                           locationdialog.h  -  K Desktop Planetarium
00003                              -------------------
00004     begin                : Sun Feb 11 2001
00005     copyright            : (C) 2001 by Jason Harris
00006     email                : jharris@30doradus.org
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018 #ifndef LOCATIONDIALOG_H
00019 #define LOCATIONDIALOG_H
00020 
00043 #include <kdialogbase.h>
00044 #include "geolocation.h"
00045 
00046 class QVBoxLayout;
00047 class QHBoxLayout;
00048 class QGridLayout;
00049 class QGroupBox;
00050 class QLabel;
00051 class QListBox;
00052 class QListBoxItem;
00053 class QPushButton;
00054 class QComboBox;
00055 class KLineEdit;
00056 class MapCanvas;
00057 class dmsBox;
00058 
00059 class LocationDialog : public KDialogBase {
00060     Q_OBJECT
00061 
00062 public: 
00067     LocationDialog( QWidget* parent = 0 );
00071     ~LocationDialog();
00072 
00078   void initCityList( void );
00079 
00082     GeoLocation* selectedCity() const { return SelectedCity; }
00083     
00086     QPtrList<GeoLocation>* filteredList() { return &filteredCityList; }
00087     
00092     void findCitiesNear( int longitude, int latitude );
00093 
00096     QString selectedCityName( void ) const { return SelectedCity->translatedName(); }
00097 
00100     QString selectedProvinceName( void ) const { return SelectedCity->translatedProvince(); }
00101 
00104     QString selectedCountryName( void ) const { return SelectedCity->translatedCountry(); }
00105 
00108     bool addCityEnabled();
00109 
00110 public slots:
00116   void filterCity( void );
00117 
00122     void changeCity( void );
00123 
00128     void addCity( void );
00129 
00130     void clearFields( void );
00131     void showTZRules( void );
00132     void nameChanged( void );
00133     void dataChanged( void );
00134 //  void prepareToAccept( void );
00135     void slotOk();
00136 
00137 private:
00141     bool checkLongLat( void );
00142     
00143     bool dataModified, nameModified, bCityAdded;
00144     QGridLayout *glay, *glay2;
00145     QHBoxLayout *hlay, *hlayCoord, *hlayTZ, *hlayButtons, *hlay3;
00146     QVBoxLayout *RootLay, *CityLay, *CoordLay, *vlay;
00147     QGroupBox *CityBox, *CoordBox;
00148     QLabel *CityFiltLabel, *ProvinceFiltLabel, *CountryFiltLabel;
00149     QLabel *NewCityLabel, *NewProvinceLabel, *NewCountryLabel;
00150     QLabel *LongLabel, *LatLabel, *CountLabel;
00151     QLabel *TZLabel, *TZRuleLabel;
00152     KLineEdit *NewCityName, *NewProvinceName, *NewCountryName;
00153     KLineEdit *CityFilter, *ProvinceFilter, *CountryFilter;
00154     dmsBox *NewLong, *NewLat;
00155     QComboBox *TZBox, *TZRuleBox;
00156     QPushButton *AddCityButton, *ClearFields, *ShowTZRules;
00157     MapCanvas *MapView;
00158     QListBox *GeoBox;
00159 
00160     GeoLocation *SelectedCity;
00161     QPtrList<GeoLocation> filteredCityList;
00162 };
00163 
00164 #endif

kstars

Skip menu "kstars"
  • Main Page
  • Modules
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

API Reference

Skip menu "API Reference"
  • keduca
  • kstars
Generated for API Reference by doxygen 1.5.9
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal