7796 Commits (740d723ec029feba142046a6d192669e2070f5a4)
 

Author SHA1 Message Date
Adriaan de Groot 51e743a67f [libcalamares] Give GlobalStorage a parent 4 years ago
Adriaan de Groot 4b7403d115 [localeq] Re-do with new Config
- remove stray and useless TODOs
- remove unnecessary empty overrides
- clean up includes
- drop all the code that is now in Config

Since the business logic (setting locations, maintaining GS, ...)
is all in the Config object, the ViewStep is remarkably simple:
hook up a UI to the Config, which in the case of QML is done
automatically.
4 years ago
Adriaan de Groot d90d451f42 [locale] Remove unnecessary includes 4 years ago
Adriaan de Groot 1f3cb32486 [locale] Apply coding style 4 years ago
Adriaan de Groot 824cb4d4b8 [locale] As the Page is constructed, it shouldn't change the location
- since the Page hooked up a model and changed the region-selection
  **after** connecting to signals, it would reset the location
  to Africa/Abijan (alphabetically the first timezone) during
  construction. Don't do that.
4 years ago
Adriaan de Groot 4f684be83d [locale] Avoid crashes in the map widget if there is no current location 4 years ago
Adriaan de Groot 42331f6e13 [locale] Move GeoIP lookup to config
- replace the weird synchronous-lookup-during-requirements-checking
  with a proper async lookup when the system is ready.
4 years ago
Adriaan de Groot a25d61077f [locale] Add GeoIP settings to Config
- this doesn't do the lookup **yet**
- while here, refactor setConfigurationMap so it reads like a story,
  with chunks bitten out into a handful of static inline void methods.
4 years ago
Adriaan de Groot f64a1eb16a [libcalamaresui] Document the signals from ModuleManager 4 years ago
Adriaan de Groot b607cf3f98 [locale] Get starting TZ in Config
- read the *region* and *zone* settings; this duplicates what
  the ViewStep does and is currently unused, but ..
- add new support for using the system's TZ (rather than
  the fixed values from *region* and *zone*). This complements
  GeoIP lookup.

This is the actual feature that started the long rewrite of
the Config object (so that all the business logic would be in
one place, usable for both widgets and QML).

FIXES #1381
4 years ago
Adriaan de Groot 781d76c9e5 [locale] Avoid nullptr if there is no location 4 years ago
Adriaan de Groot 0c9480aa3f [locale] Move more business logic to Config
- writing *localeConf* settings to GS can be done always when the
  formats are set, rather than special-cased. The code
  that handles the "special case" of no widget existing for the ViewStep
  overlooks the other crashes that happen then.
- Since Config knows what jobs to create, just ask it rather than
  keeping a copy.
4 years ago
Adriaan de Groot f6419d5de1 [locale] New setting *adjustLiveTimezone*
- allow finer-grained control over whether-or-not to adjust the
  timezone in the live system.
- handle some special cases at the point of loading-configuration.
- document the setting in locale.conf
- correct some documentation bugs
- adjust the YAML schema for locale.conf so it's legal YAML syntax
  **and** validates the current file.
4 years ago
Adriaan de Groot 995ebd5c83 [locale] Remove unused #includes 4 years ago
Adriaan de Groot 1de2210d29 [locale] Move the GS updating to the Config object
- since all locale changes need to be entered into GS anyway, this
  is something the Config object can do because it is the source
  of truth for locale settings.
- drop all the GS settings from the Page.
4 years ago
Adriaan de Groot f7c2e4a3e7 [locale] Sanitize Config signals and slots
- remove the weirdly-structured prettyStatus and similar:
  the Config object has human-readable status strings (three,
  for location, language, and LC-formats) which can be
  normal properties with signals.
- Implement prettyStatus in the view step by querying the Config.
4 years ago
Adriaan de Groot ef08ff6ac0 [locale] Move status strings from Page to Config
- the config knows the status and how to describe it,
  fetch the strings from there.
4 years ago
Adriaan de Groot 855b21a7db [locale] Remove redundant method
- configuration information lives in the Config object
4 years ago
Adriaan de Groot abc98cfa79 [locale] Simplify allocation, guard against crashes if the dialog is deleted. 4 years ago
Adriaan de Groot 66eacce654 [locale] Move localeconfiguration to Config object
- the language and LC settings migrate from page to config
- add API for explicitly setting language (which is then preserved
  when clicking new locations)
4 years ago
Adriaan de Groot a307217d83 [locale] Tidy LocaleConfiguration
- expand API documentation
- minor coding-style adjustments
4 years ago
Adriaan de Groot 81520bbbf9 [locale] Chase RAII conveniences
- several early-return paths would leave the TZ widget blocked
- use the zones data from config
4 years ago
Adriaan de Groot 0645a46b42 [libcalamares] Expand RAII conveniences 4 years ago
Adriaan de Groot 98f912f80a [locale] Drop LocalePage:;init
- setting the initial location is something the Config-object should do
- setting up the combo-boxes can be done in the constructor
4 years ago
Adriaan de Groot 726f882185 [locale] Move current-location to Config 4 years ago
Adriaan de Groot 5a6a9a0d45 [locale] Move job-creation to Config
- since Config knows what settings there are, it should create the
  jobs to run later -- not the Page.
- this doesn't work yet, because the Config does **not** know what
  the selected timezone is yet.
4 years ago
Adriaan de Groot 8c21b59853 [locale] Remove unused localegen (moved to Config earlier) 4 years ago
Adriaan de Groot f0cac7d669 [locale] Hook tz widget up to the Config's data 4 years ago
Adriaan de Groot 4d5ff6d5c4 [locale] Make the Page use the region model from Config 4 years ago
Adriaan de Groot 88d1d255f6 [locale] Add regions & zones models to Config
- The models are constant pointers, even if their contents aren't.
- Make the top-level (region) model point to the global TZ list.
4 years ago
Adriaan de Groot e8282f27a3 Docs: update RELEASE.md with some GPG-info and remove old steps 4 years ago
Adriaan de Groot 51b7ec875f [locale] Don't need own copy of zones list 4 years ago
Adriaan de Groot 439f828d9b [locale] Document TZ widget 4 years ago
Adriaan de Groot 931ce20f30 [locale] Reduce API surface
- getLocationPosition doesn't need to be a method, since it calls out
  to a static function of TimeZoneImageList anyway.
4 years ago
Adriaan de Groot 25ba1bb767 [locale] Remove localeGenLines from page
- the Config object took over loading of the string list
- expose the list as a property
- drop loading code from the page.
4 years ago
Adriaan de Groot 338635146f [locale] Hand the Config object also to the page 4 years ago
Adriaan de Groot b6b5c44996 [locale] Load supported locales in Config 4 years ago
Adriaan de Groot 8119c7e72a [locale] Reset Config object
The Config object wasn't being used at all in the locale module;
reset it to empty and start using it in locale, so that
configuration functionality can be added to it as-needed,
and with the necessary refactoring built-in.
4 years ago
Adriaan de Groot 0d5db2dd06 [localeq] Config-handling is a total bodge-job, disable 4 years ago
Calamares CI e1c85340e4 i18n: [calamares] Automatic merge of Transifex translations
FIXES #1455
4 years ago
Adriaan de Groot 4e4ffde604 Changes: post-release housekeeping 4 years ago
Adriaan de Groot 724b92ee60 [partition] Drop documentation of vanished parameter 4 years ago
Calamares CI 92a27a2c2d i18n: [python] Automatic merge of Transifex translations 4 years ago
Calamares CI f5ada5e9ef i18n: [desktop] Automatic merge of Transifex translations 4 years ago
Calamares CI 97bdb9b4f7 i18n: [calamares] Automatic merge of Transifex translations 4 years ago
Adriaan de Groot cfb0bebe0e Changes: pre-release housekeeping 4 years ago
Adriaan de Groot e1f4224bed [libcalamaresui] Fix slideshowAPI loading
In 022045ae05 a regression was introduced: if no *slideshowAPI*
is specified in the branding file, Calamares refuses to start, with
a YAML failure.

Before the refactoring, we had `YAML::Node doc` and looked up
the *slideshowAPI* in it with `doc["slideshowAPI"]`. After the
refactoring, we had `const YAML::Node& doc`. The `const` makes
all the difference:
 - subscripting a non-existent key in a mutable Node silently
   returns a Null node (and possibly inserts the key);
 - subscripting a non-existent key in a const Node returns an
   invalid or undefined node.

Calling IsNull() or IsScalar() on a Null node works: the functions
return a bool. Calling them on an invalid node throws an exception.

So in the **const** case, this code can throws an exception that it
doesn't in the non-const case:
    `doc[ "slideshowAPI" ].IsScalar()`

- Massage the code to check for validity before checking for scalar
- Add a `get()` that produces more useful exception types when
  looking up an invalid key
- Use `get()` to lookup the slideshow node just once.
4 years ago
Adriaan de Groot a58d59d86c [libcalamares] Minor documentation on Yaml.* 4 years ago
Adriaan de Groot da1cc7c3a5 [libcalamaresui] Don't clear the map when inserting strings
- the documentation doesn't say the map is cleared, and the one
  place this function is used doesn't need that either.
- make type of config explicit
4 years ago
Adriaan de Groot a91edfef89 [netinstall] auto-resize the columns
- previously, the first column (name) was sized to show the
  names **that were visible at startup**, which fails when
  there are long names hidden in groups that are not expanded
  immediately.
- change the columns to resize according to the contents; this makes
  the descriptions jump to the right as the name column gets wider.

FIXES #1448
4 years ago