diff options
author | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2024-01-22 22:31:51 +0200 |
---|---|---|
committer | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2024-01-22 22:31:51 +0200 |
commit | 67934c103800bae50c2ec1977758d40fa8e4e507 (patch) | |
tree | 77a44eb54a75a35bd10f3c63be588889b697e451 /examples/corelib/bindableproperties/subscription/user.h | |
parent | 694575a59b5370afc494fbf700eee8db1d1ec091 (diff) | |
parent | ca128e25119c0b259d083567c796bfa67b100a42 (diff) |
Merge remote-tracking branch 'origin/tqtc/lts-6.2.8' into tqtc/lts-6.2-opensource
Conflicts solved in a file:
src/corelib/io/qstandardpaths_android.cpp
Change-Id: Ie8cef36c1379679ca358df50c56b3c25aa15c5d6
Diffstat (limited to 'examples/corelib/bindableproperties/subscription/user.h')
-rw-r--r-- | examples/corelib/bindableproperties/subscription/user.h | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/examples/corelib/bindableproperties/subscription/user.h b/examples/corelib/bindableproperties/subscription/user.h index 8c9ebb1009..223e660f62 100644 --- a/examples/corelib/bindableproperties/subscription/user.h +++ b/examples/corelib/bindableproperties/subscription/user.h @@ -51,6 +51,7 @@ #ifndef USER_H #define USER_H +#include <QLocale> #include <QObject> //! [user-class] @@ -60,13 +61,9 @@ class User : public QObject Q_OBJECT public: - enum Country { - None, - Finland, - Germany, - Norway, - }; + using Country = QLocale::Territory; +public: Country country() const { return m_country; } void setCountry(Country country); @@ -78,8 +75,8 @@ signals: void ageChanged(); private: - Country m_country = Country::None; - int m_age = 0; + Country m_country { QLocale::AnyTerritory }; + int m_age { 0 }; }; //! [user-class] |