Kstars
locationdialog.cpp
57 QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel);
96 connect(source, SIGNAL(positionUpdated(QGeoPositionInfo)), this, SLOT(positionUpdated(QGeoPositionInfo)));
97 connect(source, SIGNAL(error(QGeoPositionInfoSource::Error)), this, SLOT(positionUpdateError(QGeoPositionInfoSource::Error)));
115 connect(nam, SIGNAL(finished(QNetworkReply*)), this, SLOT(processLocationNameData(QNetworkReply*)));
144 //Sort the list of Cities alphabetically...note that filteredCityList may now have a different ordering!
148 i18np("One city matches search criteria", "%1 cities match search criteria", ld->GeoBox->count()));
208 i18np("One city matches search criteria", "%1 cities match search criteria", ld->GeoBox->count()));
341 if ( KMessageBox::questionYesNo( 0, message, i18n( "Override Existing Data?" ), KGuiItem(i18n("Override Data")), KGuiItem(i18n("Do Not Override"))) == KMessageBox::No )
346 QString dbfile = QDir(KSPaths::writableLocation(QStandardPaths::AppLocalDataLocation)).filePath("mycitydb.sqlite");
390 add_query.prepare("INSERT INTO city(Name, Province, Country, Latitude, Longitude, TZ, TZRule, Elevation) "
407 g = new GeoLocation(lng, lat, name, province, country, TZ, &KStarsData::Instance()->Rulebook[TZrule], Elevation);
417 update_query.prepare("UPDATE city SET Name = :newName, Province = :newProvince, Country = :newCountry, "
418 "Latitude = :Latitude, Longitude = :Longitude, TZ = :TZ, TZRule = :TZRule, Elevation = :Elevation WHERE "
453 delete_query.prepare("DELETE FROM city WHERE Name = :Name AND Province = :Province AND Country = :Country");
514 i18np("One city matches search criteria", "%1 cities match search criteria", ld->GeoBox->count()));
553 // JM 2017-09-16: No, let's not assume it is 0. User have to explicitly set TZ so avoid mistakes.
616 ld->UpdateButton->setEnabled(SelectedCity->isReadOnly() == false && !ld->NewCityName->text().isEmpty() &&
674 connect(nam, SIGNAL(finished(QNetworkReply*)), this, SLOT(processLocationNameData(QNetworkReply*)));
696 val.toArray()[0].toObject()["address_components"].toArray()[2].toObject()["long_name"].toString();
698 val.toArray()[0].toObject()["address_components"].toArray()[3].toObject()["long_name"].toString();
700 val.toArray()[0].toObject()["address_components"].toArray()[4].toObject()["long_name"].toString();
Contains all relevant information for specifying a location on Earth: City Name, State/Province name,...
Definition geolocation.h:28
void setProvince(const QString &n)
Set Province name according to argument.
Definition geolocation.h:237
void setCountry(const QString &n)
Set Country name according to argument.
Definition geolocation.h:245
const QMap< QString, TimeZoneRule > & getRulebook() const
Return map for daylight saving rules.
Definition kstarsdata.h:262
void enqueueFilterCity()
Filter by city / province / country only after a few milliseconds.
Definition locationdialog.cpp:162
bool updateCity()
When the "Update City" QPushButton is clicked, update the city information in the user's custom city ...
Definition locationdialog.cpp:276
void filterCity()
When text is entered in the City/Province/Country Filter KLineEdits, the List of cities is trimmed to...
Definition locationdialog.cpp:175
void findCitiesNear(int longitude, int latitude)
Show only cities within 3 degrees of point specified by arguments.
Definition locationdialog.cpp:494
bool addCity()
When the "Add new city" QPushButton is clicked, add the manually-entered city information to the user...
Definition locationdialog.cpp:271
bool removeCity()
When the "Remove City" QPushButton is clicked, remove the city information from the user's custom cit...
Definition locationdialog.cpp:284
void changeCity()
When the selected city in the QListBox changes, repaint the MapCanvas so that the crosshairs icon app...
Definition locationdialog.cpp:216
This class provides the information needed to determine whether Daylight Savings Time (DST; a....
Definition timezonerule.h:48
const QString toDMSString(const bool forceSign=false, const bool machineReadable=false, const bool highPrecision=false) const
Definition dms.cpp:287
QString i18np(const char *singular, const char *plural, const TYPE &arg...)
QString i18nc(const char *context, const char *text, const TYPE &arg...)
QString i18n(const char *text, const TYPE &arg...)
KSERVICE_EXPORT KService::List query(FilterFunc filterFunc)
void error(QWidget *parent, const QString &text, const QString &title, const KGuiItem &buttonOk, Options options=Notify)
KI18NLOCALEDATA_EXPORT KCountry country(const char *ianaId)
void addWidget(QWidget *widget, int stretch, Qt::Alignment alignment)
QDialog(QWidget *parent, Qt::WindowFlags f)
virtual void accept()
void accepted()
void finished(int result)
virtual void reject()
void rejected()
QString filePath(const QString &fileName) const const
bool exists() const const
SatellitePositioningMethods
QGeoPositionInfoSource * createDefaultSource(QObject *parent)
QJsonDocument fromJson(const QByteArray &json, QJsonParseError *error)
bool isObject() const const
QJsonObject object() const const
bool contains(QLatin1StringView key) const const
QJsonArray toArray() const const
void append(QList< T > &&value)
bool isEmpty() const const
bool removeOne(const AT &t)
value_type takeFirst()
QString toString(QDate date, FormatType format) const const
QMetaObject::Connection connect(const QObject *sender, PointerToMemberFunction signal, Functor functor)
QSqlDatabase database(const QString &connectionName, bool open)
AppLocalDataLocation
bool isEmpty() const const
QString number(double n, char format, int precision)
bool startsWith(QChar c, Qt::CaseSensitivity cs) const const
CaseInsensitive
Tool
Start
void setEnabled(bool)
height
void repaint()
void setFocus()
void setLayout(QLayout *layout)
void show()
void resize(const QSize &)
void setWindowFlags(Qt::WindowFlags type)
void setWindowTitle(const QString &)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:19:02 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:19:02 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.