[locale] Debugging support for Location

- code formatting
 - provide an operator << for debugging TZ widget
This commit is contained in:
Adriaan de Groot 2019-01-07 18:34:25 +01:00
parent 3ff480eaa9
commit bc398756f5

View File

@ -38,11 +38,13 @@
class LocaleGlobal
{
public:
struct Locale {
struct Locale
{
QString description, locale;
};
struct Location {
struct Location
{
QString region, zone, country;
double latitude, longitude;
static QString pretty( const QString& s );
@ -62,4 +64,9 @@ private:
static double getRightGeoLocation( QString str );
};
inline QDebug& operator <<( QDebug& s, const LocaleGlobal::Location& l )
{
return s << l.region << '/' << l.zone << '(' << l.country << ") @N" << l.latitude << 'E' << l.longitude;
}
#endif // LOCALEGLOBAL_H