diff options
| author | Edward Welbourne <edward.welbourne@qt.io> | 2024-02-26 16:11:31 +0100 |
|---|---|---|
| committer | Edward Welbourne <edward.welbourne@qt.io> | 2024-05-16 16:51:15 +0200 |
| commit | e813acbb02501ae43d3faf56f43c0d4104a979bc (patch) | |
| tree | 19e23910536d532342e0593a43be865ed2b39dce /src/sql/kernel/qsqldatabase.cpp | |
| parent | f3bf304de734957ba5c396a6aa0a64d21dda055a (diff) | |
Rework QTZP::displayName() to use locale and data() more
We should only use the isoOffsetFormat() version of offset name for
QLocale::C - while other locales may coincide with it, we don't know
so shouldn't just assume. Add a query for whether a locale is the one
used by the backend for the abbreviation in its data() and, when it
is, use that abbreviation as short name. The TZ backend was searching
its transitions for help with the abbreviation; we can do that also in
the base-class, so introduce a data(TimeType) that will search
transition history (if available) for a suitable transition from which
to take the abbreviation (when appropriate).
This shall make displayName() return an empty string in various cases
where it did not, before; this is more honest than returning a string
that's inappropriate for the locale for which it was meant to be
answering.
Task-number: QTBUG-114914
Task-number: QTBUG-115158
Task-number: QTBUG-122448
Change-Id: I523229def63aafcd2009b8406b2c3d13f7c01d9c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/sql/kernel/qsqldatabase.cpp')
0 files changed, 0 insertions, 0 deletions
