Adriaan de Groot
5973dbf74c
[libcalamaresui] Shuffle code for QML slideshow
...
- Create widgets earlier
- Group layouting code
- Add retranslator only once, not on every activate
- Load QML only once, preferably at activation
2019-06-01 23:39:39 +02:00
Adriaan de Groot
cbe14bbf03
[libcalamaresui] Rename m_slideShow -> m_qmlShow
...
- It could be any QML, so it's not a slideshow per se.
- Minor prep-work for fixing up loading times.
2019-06-01 23:26:08 +02:00
Adriaan de Groot
75ce391e7e
[libcalamaresui] Add branding-aware function for loading image by name
2019-05-31 17:27:11 +02:00
Adriaan de Groot
1438729b72
[libcalamaresui] Do filename checks more sanely
...
- check directory exists before trying to open file from it
- re-use the componentDir already found for later tests.
2019-05-31 17:27:11 +02:00
Adriaan de Groot
95009a5222
[libcalamaresui] Fix disable-cancel behavior
...
- d78bc0c5
added an early `return false` when cancel is disabled,
before checking if we were at the last step; so last-step
didn't get any special handling.
- refactor so that last-step now gets special handling first,
**then** disable-cancel handling, and then the usual case.
2019-05-28 13:38:28 +02:00
Adriaan de Groot
2e39f24bb0
[libcalamaresui] Make sure finished() is processed once
...
- Avoid races which might double-delete the timer, or enter
the if twice (which would lead to duplicate emissions of
requirementsComplete and the associated UI glitches).
2019-05-27 17:15:49 +02:00
Adriaan de Groot
2b91608b82
[libcalamaresui] Avoid requirements-results UI duplication
...
If the requirements checking is **really fast**, e.g. you don't
have a check for internet connectivity, then the checks
might be done as fast as the 0-timeout single-shot timer,
which means that finished() is called once by the QFutureWatcher,
and then after that by the QTimer .. leading to two messages
"All requirements have been checked", but also twice
requirementsComplete being emitted, so you end up with two
results lists being added by the CheckerContainer.
Stop that by using the results-progress timer as an additional
flag: the first time everything is complete, delete that timer
and set the pointer back to nullptr.
2019-05-27 17:10:21 +02:00
Adriaan de Groot
f64e55f0dc
[libcalamaresui] Use meaningful asserts
...
- In debug mode, hitting assert(false) is meaningless,
- In release mode, the assert is optimized out.
- So assert the condition we're actually testing, for better messages.
2019-05-27 15:38:37 +02:00
Adriaan de Groot
976ad7e3e7
[libcalamaresui] Look up icons via theme
...
- Don't cache icons, because they could be changed via
the active desktop theme.
2019-05-27 15:35:56 +02:00
Adriaan de Groot
822bbaad9c
[libcalamaresui] Allow icon names in branding images
...
- It's ok to use path / filenames in images, but you can also
use icon names according to the FDO icon spec. This makes
sense for at least *productLogo*, possibly *productIcon*, but
not really for *productWelcome*.
2019-05-27 15:26:57 +02:00
Adriaan de Groot
cd38ded8d5
[libcalamaresui] Support os-release substitutions in images
...
- Branding images might want to use os-release data as well.
- Refactor a little to keep the number of #ifdefs the same;
an intermediate expand() lambda handles expansion (or not,
if it's not enabled).
FIXES #1153
2019-05-21 17:12:00 +02:00
Adriaan de Groot
18b111218a
[libcalamaresui] Sort includes in DebugWindow.cpp
2019-05-21 13:35:58 +02:00
Adriaan de Groot
ac941e6756
[libcalamares] Implement reload-stylesheet
...
- From the debug-window, clicking *reload stylesheet* does just
that, and applies the new stylesheet to the Calamares window.
- Remove stylesheet caching from the Branding class; we only
need the sheet once (on Calamares startup) or when updating
the stylesheet, which is seldom-enough that we don't need
to keep an extra copy around.
- To use, start Calamares, open the debug window, open stylesheet.qss
in an editor. Make changes, save, then click *reload stylesheet*.
SEE #1149
2019-05-21 13:21:47 +02:00
Adriaan de Groot
877cb0e999
[libcalamaresui] Debug-tool to dump widget tree
...
- Adds another tool to the debug window, which dumps (to the debug
log) a tree-like view of all the widgets in the application.
This can be used when writing stylesheets.
2019-05-21 13:07:34 +02:00
Adriaan de Groot
b5625fc14d
[libcalamares] Add a reload-stylesheet button
...
- This is a debugging-option to test stylesheet changes quickly.
- Right now, the stylesheet is cached, so it doesn't even work.
2019-05-21 12:52:50 +02:00
Adriaan de Groot
af73d90b7b
[libcalamaresui] Fix build with KOSRelease
...
- initialization of the hash was all wrong
- special-case ID_LIKE
- typo's
- link to CoreAddons
2019-05-20 22:54:54 +02:00
Adriaan de Groot
fbbbe63642
[libcalamaresui] WIP: Use KOSRelease and KMacroExpander in branding
...
- allows you to use -- at runtime -- values from os-release in the
branding file.
- WIP because the only machine I have with sufficiently new KF5
is the FreeBSD box.
2019-05-20 22:11:11 +02:00
Adriaan de Groot
92d0e71029
[libcalamaresui] one more refactor for string-loading
...
- Do the checking for IsMap inside loadStrings() and use
YAML::Exception to get to bail() (since we're already dealing
with exceptions here, no extra costs). This tidies up the code
somewhat.
2019-05-20 17:03:32 +02:00
Adriaan de Groot
667f78c016
[libcalamaresui] if there's a YAML exception in branding, bail
...
- all kinds of type errors result in bailing out, but a totally
broken branding file does not?
2019-05-20 17:03:28 +02:00
Adriaan de Groot
62328c9940
[libcalamaresui] images-strings loading fixed
...
- move the string-munge into a lambda and use the generic loadStrings()
2019-05-20 17:03:17 +02:00
Adriaan de Groot
544d905b2f
[libcalamaresui] WIP: refactor again
...
- the string-manipulation can be done through a lambda. That makes
handling *strings* and *styles* simple.
- still doesn't compile.
2019-05-20 17:03:17 +02:00
Adriaan de Groot
5a126816f4
[libcalamaresui] WIP: refactor copying strings from config to Branding
...
- this is mostly to make the constructor easier to read by
moving parts of the story to easily-understood methods.
- doesn't actually compile.
2019-05-20 17:03:08 +02:00
Adriaan de Groot
5bae7b7b52
[libcalamaresui] check for sufficiently-new KF5CoreAddons
...
- From 5.58, KOSRelease is available (not used yet, though)
2019-05-20 17:03:04 +02:00
Adriaan de Groot
a9f3b4050c
[libcalamaresui] don't over-complicate PythonQt library linking
2019-05-20 17:02:59 +02:00
Adriaan de Groot
f3bfc81e52
[libcalamares] Rename dontCancel to disableCancelDuringExec
...
- This way the name actually refers to what it does, rather
than being a somewhat ambiguous overload of disableCancel.
2019-05-14 08:30:34 -04:00
Adriaan de Groot
d4f4a40fa5
[libcalamaresui] Refactor quit-enabling
...
- Add signal for change-of-quit-enabledness
- Minor tidying
2019-05-14 13:43:07 +02:00
Adriaan de Groot
088fa5004c
[libcalamaresui] Disallow closing the window during execution
...
- If the disable-cancel-during-exec setting is on, and the user clicks
the window-close button, then disregard the close message.
2019-05-14 13:21:05 +02:00
Adriaan de Groot
ad4352b65c
[libcalamaresui] Make stepIsExecute() more general
...
- Checking if the **next** step is an execute-step is a little
weird, so make the API more general (and add the +1 to indexes
where it was using NextWillExecute before).
2019-05-14 13:18:51 +02:00
Adriaan de Groot
25099ae854
[libcalamaresui] Remove duplicate setEnabled
...
- If executing is set to true, then later setEnabled( !executing && ... )
fill be false, so we don't need to call setEnabled( false ) here as well.
2019-05-14 13:10:36 +02:00
Adriaan de Groot
d78bc0c5c5
[libcalamaresui] When disable-cancel is on, never confirm
...
- This function is also reached by clicking the window-close decoration.
2019-05-14 13:04:24 +02:00
Adriaan de Groot
8fcdbd5bd5
[libcalamaresui] Improve warning message
...
- Tell the packager / deployer that certain modules are missing
2019-05-12 16:29:50 +02:00
Arnaud Ferraris
bfd46276ad
[libcalamaresui] Fix sidebar label for setup mode
...
In the sidebar, the "Install" step should be named "Set Up" when in
setup mode, which will be more consistent with the other UI texts,
including button labels.
Signed-off-by: Arnaud Ferraris <arnaud.ferraris@collabora.com>
2019-05-08 12:29:01 +02:00
Adriaan de Groot
9331a25905
[libcalamares] Remove Typedefs.h
...
- This small header file contained a few unrelated typedefs.
Move those typedefs to the classes they relate to. This
**does** mean that some consumers need to #include something
else instead.
- Use type names more consistently.
Editorial: why are **pages** responsible for creating the jobs?
2019-05-07 09:51:23 -04:00
Adriaan de Groot
a99eccf19d
[libcalamaresui] Fix PythonQt code w/ moved enums
2019-05-07 08:47:33 -04:00
Adriaan de Groot
a482d7be44
[libcalamaresui] Don't expose build details in DebugWindow
...
- In a library class, don't include uic-generated headers inside
the public headers.
2019-05-07 07:48:40 -04:00
Adriaan de Groot
de2b85eabf
[libcalamaresui] Tidy the CMake bits
...
- Explain (briefly) what the library is for
- Explicitly add includes from the non-UI library
2019-05-07 07:48:40 -04:00
Adriaan de Groot
cdb613bf02
[libcalamares] Move module-related things into subdirectory
...
- Currently just moves a single enum, but this is prep-work for
moving the non-GUI parts of the module system into libcalamares,
to better support GUI-less operation.
2019-05-07 07:48:40 -04:00
Adriaan de Groot
169159f888
[libcalamaresui] Switch to enum classes for Type, Interface
...
- Somewhat gratuitous change, but brings more enums into modern style.
2019-05-07 06:33:31 -04:00
Adriaan de Groot
6b89ac8461
[libcalamaresui] Remove TODO
...
- I don't know what this would mean, so it's not a TODO any more.
2019-05-07 06:26:43 -04:00
Adriaan de Groot
8d0f076591
[libcalamares] Rename CalamaresUtils -> String
...
- The only remaining functions in the file are string-related, so
rename to match their purpose.
- Drop this include file from most places, since they don't actually
use the string functionality at all.
2019-04-29 06:49:16 -04:00
Adriaan de Groot
eaba696173
[libcalamares] Move the crash() function to the one place it's used
2019-04-29 06:49:16 -04:00
Adriaan de Groot
ac095d9ed0
[libcalamares] [libcalamaresui] [calamares] Adjust to moved Dirs.h
2019-04-29 06:49:16 -04:00
Adriaan de Groot
2907b48844
[libcalamaresui] Move RESPATH #define to the one place it's used
2019-04-29 06:14:21 -04:00
Adriaan de Groot
f076dd76ad
[libcalamares] Rename YamlUtils.h
...
- Since we have the utils/ filesystem namespace, and use CalamaresUtils::
as C++ namespace, simplify naming.
2019-04-29 06:14:21 -04:00
Adriaan de Groot
7149b80146
[libcalamares] Distinguish kinds of errors
...
- errors can now carry an integer what-am-I code apart from
the message; all errors have a code != 0 (and ok has code 0).
2019-04-28 14:34:39 -04:00
Adriaan de Groot
08e4090354
Merge remote-tracking branch 'origin/raurodse-branding'
...
FIXES #961
2019-04-23 16:41:22 -04:00
Adriaan de Groot
a216b5ca76
[libcalamaresui] Misplaced const
2019-04-22 00:18:28 +02:00
Adriaan de Groot
b7ddb39105
[libcalamaresui] Massage disable-cancel code
...
- Even when Cancel is hidden, also disable it (prevents DBUS
triggers, for instance),
- Re-enable it when exec is over, if it's disabled then.
- simplify code a little.
2019-04-21 17:32:05 +02:00
Adriaan de Groot
10727c7bd9
Merge pull request #1126 from feren/patch-3
...
Patch to add 'dont-cancel' setting to disable Cancel only during the installation phase
2019-04-21 17:02:21 +02:00
Adriaan de Groot
c44e221fb6
Merge branch 'issue-1107'
...
FIXES #1107
2019-04-19 16:27:19 +02:00
Adriaan de Groot
58aa9f4989
[libcalamares] Move LocaleLabel from libcalamaresui to libcalamares
...
- This isn't a UI-dependent class
- Doesn't make much sense in CalamaresUtilsGui either
2019-04-19 10:04:49 +02:00
Adriaan de Groot
242d756731
[libcalamaresui] Add convenience name() to LocaleLabel
2019-04-19 09:55:51 +02:00
Adriaan de Groot
bd0af4bb77
[libcalamaresui] Give LocaleLabel a default constructor
...
- Needed for use in containers
- While here refactor building the english label
2019-04-19 09:18:26 +02:00
Adriaan de Groot
cef2f50510
Reduce warnings about extra ;
...
- Trailing ; after Q_UNUSED
- Trailing ; after CALAMARES_RETRANSLATE
2019-04-18 12:06:09 +02:00
Adriaan de Groot
c83395ff6d
Reduce warnings for yaml-cpp
...
- Use only utils/YamlUtils.h to pull in yaml-cpp and supporting code.
- When compiling with clang, turn off warnings that the system header
for yaml-cpp would generate.
2019-04-18 12:06:09 +02:00
Adriaan de Groot
620940c75b
[libcalamaresui] Drop now-unused sortKey from LocaleLabel
...
- sortKey is unused
- add englishLabel for reverse-i18n
2019-04-16 23:49:27 +02:00
The feren OS Dev
a7ac046b3d
Update copyright headers
2019-04-16 18:27:51 +01:00
The feren OS Dev
825c92582a
Update ViewManager.cpp
2019-04-16 17:20:39 +01:00
Adriaan de Groot
5e951466df
[libcalamaresui] Sort languages by ISO code
...
- this puts the Englishes together, and is less confusing than
sorting with American first.
2019-04-16 15:38:06 +02:00
Adriaan de Groot
ef3b4c387c
[libcalamaresui] Remove unused AbstractPage
2019-04-15 09:20:08 -04:00
Adriaan de Groot
4fec6731ba
[calamares] [libcalamaresui] Improve includes
...
- avoid useless ../
- sort alphabetically and by kind
2019-04-15 09:20:08 -04:00
Adriaan de Groot
d6cf0617f6
[libcalamaresui] Make logging more consistent
2019-04-15 09:02:21 -04:00
Adriaan de Groot
e664370b28
[libcalamaresui] Use modern tr() annotation
2019-04-11 10:28:09 -04:00
Adriaan de Groot
5a95bf507f
[libcalamaresui] Improve WindowDimensions class
...
- Make sure the class knows its own suffixes
2019-04-11 15:14:31 +02:00
Adriaan de Groot
6560c194ad
[libcalamaresui] Reduce 0-for-nullptr warnings in 3rd party code
...
- replace = 0 with = nullptr to reduce warnings; not a meaningful
or copyrightable change.
2019-04-11 15:14:31 +02:00
Adriaan de Groot
1008a91eba
[libcalamaresui] Reduce warnings
...
- getting a (sensible) uint from an int is tougher than you might think
2019-04-11 15:14:31 +02:00
Adriaan de Groot
8dd22dcbbf
[libcalamaresui] bail() is a [[noreturn]] function
2019-04-11 15:14:31 +02:00
Adriaan de Groot
713370da55
Merge remote-tracking branch 'origin/issue-1100'
2019-04-11 11:47:00 +02:00
Adriaan de Groot
01f5ac22a0
CMake: use conventional method for setting version
...
- Using project() to set up the version is idiomatic for CMake
and more standardised than doing it by hand. Do retain the
RC flag, because that's used in other parts of versioning.
2019-04-04 15:58:07 +02:00
Adriaan de Groot
3a0bd254c0
[libcalamaresui] Adjust quit-messages to setup-mode
2019-04-01 06:16:37 -04:00
Adriaan de Groot
2b7832857c
[libcalamaresui] Simplify checking dependencies
...
- Avoid crash due to invalid iterator, when modules
are removed due to missing requirements.
- Simplify code, factor out the determination of
which required modules are missing.
2019-03-19 11:11:43 -04:00
Adriaan de Groot
5a8ed8583f
[libcalamaresui] Complain about missing config files
...
- When no config file is found, tell where it wasn't.
2019-03-19 05:42:28 -04:00
Adriaan de Groot
54ba0aaf13
[welcome] Use convenience function
...
- Introduce a hasDetails() for RequirementEntry, which is just
a short-cut, but makes code more readable.
2019-02-26 06:20:20 -05:00
Adriaan de Groot
8cf3c217f7
Merge branch 'requirements-checking'
2019-02-25 10:00:43 -05:00
Adriaan de Groot
c3d13e3451
[libcalamaresui] Add documentation to ViewStep methods
2019-02-25 08:15:01 -05:00
Adriaan de Groot
64ca9d0d5a
[libcalamaresui] Document multi-page support.
2019-02-25 08:11:03 -05:00
Adriaan de Groot
6071489788
[libcalamaresui] Provide default implementations of next() and back()
...
- These methods are used for multi-page view-steps, which are rare.
For all the others, just drop the empty implementation and defer
to the base class.
2019-02-25 07:49:10 -05:00
Adriaan de Groot
08565b5f17
[libcalamaresui] Remove the signal done() from ViewStep
...
- The signal is emitted, generally from next(), but not actually used.
2019-02-25 07:34:40 -05:00
Adriaan de Groot
40a7082bfc
[libcalamaresui] Handle no-requirements-to-check case
...
- If there's no requirements at all, none of the watchers
will call finished(), so do it once extra.
2019-02-25 07:15:51 -05:00
Adriaan de Groot
0ad115732e
[libcalamaresui] Report elapsed time as well.
...
- While waiting on modules, report the elapsed time in seconds
based on the number of progress-ticks that have passed.
2019-02-25 06:39:50 -05:00
Adriaan de Groot
5ddf7b980b
[libcalamaresui] Report progress also while waiting
...
- Ping the progress every 1.2 seconds, so the user sees more than
just the throbber.
2019-02-25 06:33:46 -05:00
Adriaan de Groot
ac652a2bc1
[libcalamaresui] Report module-name in italics
2019-02-25 04:19:05 -05:00
Adriaan de Groot
41fecf341b
[libcalamaresui] Avoid metatype warnings at runtime
...
- Register the types with the Qt type system. This is needed
because we're passing them as signal and slot parameters
across threads.
2019-02-24 15:57:36 -05:00
Adriaan de Groot
f1aa22d9e8
[libcalamaresui] Sort signals chronologically
2019-02-24 09:08:02 -05:00
Adriaan de Groot
b169281b69
[libcalamaresui] Use convenience type
2019-02-23 17:41:24 -05:00
Adriaan de Groot
6090a464f8
[libcalamaresui] Switch requirementschecking to threaded mode
...
- Use QFuture and QFutureWatcher to spawn threads that do the actual
checking of the requirements; collect results and report on
them as they come in.
2019-02-23 11:12:55 -05:00
Adriaan de Groot
c678cd80b4
[libcalamaresui] Refactor Requirements-Checking
...
- Move the actual checking into a separate object with some lifecycle-
management signals.
- Right now this is still single-threaded and blocking, so no net gain.
2019-02-20 05:48:15 -05:00
Adriaan de Groot
bbb9ff0cbf
[libcalamaresui] Remove useless #define
2019-02-18 10:19:06 -05:00
Adriaan de Groot
ff10e1301d
[libcalamaresui] Fix struct/class mismatch
2019-02-18 10:10:16 -05:00
Adriaan de Groot
5aa4e52452
[libcalamaresui] Improve debug-logging
2019-02-18 09:09:37 -05:00
Adriaan de Groot
d33752c66c
[libcalamaresui] Refactor Requirements classes
...
- improve naming of member variables
- expand documentation
2019-02-15 20:53:55 +01:00
Adriaan de Groot
43eae0bc47
Merge branch 'master' into requirements-checking
2019-02-15 00:32:45 +01:00
Adriaan de Groot
667c0594a4
Merge pull request #1074 from a-wai/disable-cancel-button
...
Add a settings.conf option to disable "Cancel" button
2019-01-24 21:05:38 +01:00
Arnaud Ferraris
db3d3a7d03
Add a settings.conf option to disable "Cancel" button
...
In some cases, e.g. when calamares is used as an "initial setup" tool,
we may want to user to go through all the configuration steps in order
to end up with a usable system.
Therefore, disabling the "Cancel" button can be useful in this case.
This commit adds an option to settings.conf which disables this button
when set to "true". If the option is not present in the settings file,
the default behavior ("Cancel" button enabled & visible) is enforced.
Signed-off-by: Arnaud Ferraris <arnaud.ferraris@collabora.com>
2019-01-23 15:56:07 +01:00
Adriaan de Groot
12665192ae
[libcalamaresui] Defend against missing config settings
2019-01-14 15:30:44 +01:00
Adriaan de Groot
ef94b1f689
[calamares] Support noexpand
...
- When in noexpand mode, just don't grow the window, and assume
widgets elsewhere will get scrollbars automatically.
2019-01-14 14:25:01 +01:00
Adriaan de Groot
866797a6c9
[calamares] Support starting fullscreen
2019-01-14 14:17:39 +01:00
Adriaan de Groot
80569a746f
[libcalamaresui] Relax validity check in branding
...
- A size of 64em has a value less than 1024, which is the minimum
size **in pixels**. The check doesn't make sense as-is and would
have to take the unit into account. Leave that to clients of
branding (e.g. CalamaresWindow, which already does this).
2019-01-14 13:42:41 +01:00
Adriaan de Groot
32ab377e43
[libcalamaresui] Record branding window-size
2019-01-14 12:06:04 +01:00
Adriaan de Groot
819a57e458
[libcalamaresui] Store resize configuration
...
- Use the named enums code for simplicity.
2019-01-11 17:35:06 +01:00
Adriaan de Groot
210965aca4
[libcalamaresui] Allow always-show-country setting in locale label
2018-12-14 13:20:32 +01:00
Adriaan de Groot
8790985fca
[libcalamaresui] Code-formatting, remove dead code
2018-12-14 11:33:13 +01:00
Adriaan de Groot
3dda9ab860
[libcalamaresui] LocaleLabel doesn't need to inherit QObject
...
- Use static QObject::tr instead.
2018-12-14 11:30:05 +01:00
Adriaan de Groot
1f4ac45bb5
[libcalamaresui] Cleanup locale-labeling code
...
- Support translations of the "language (country)" format instead
of forcing English parenthesis.
2018-12-14 11:22:47 +01:00
Adriaan de Groot
084f4d2445
[libcalamaresui] Refactor: move LocaleLabel to UI library
...
- This is prep-work for making locale labels consistent everywhere.
- While here, improve code documentation.
2018-12-14 10:52:55 +01:00
Adriaan de Groot
3b8d2835e0
[calamares] Use XDG_{DATA,CONFIG}_DIRS as appropriate
...
- Use DATA for the qml and branding directories (looks for qml/
and branding/<name>/ in those directories).
- Use CONFIG for the global settings and module settings (looks
for settings.conf and module/<name>/ in those directories).
FIXES #941
2018-10-08 10:28:30 -04:00
Adriaan de Groot
869357a89c
Merge branch 'master' into oem-resizer
2018-09-27 20:47:17 +02:00
Adriaan de Groot
d752223d0b
[libcalamaresui] When reporting failure, use full product name.
2018-09-24 17:58:22 +02:00
Adriaan de Groot
39a0d2315b
[calamares] Better config-loading diagnostics
...
- Be more verbose when things go wrong while loading module-
configuration files.
- Allow more forms of paths to be specified. In debug mode, this
is mostyle helpful for the module test-loader.
2018-09-20 07:39:43 -04:00
Adriaan de Groot
4602b30264
[libcalamaresui] Use PYTHONQT_INCLUDE_DIRS
...
- document new variable from the CMake module
- use it in libcalamaresui to simplify #include'ing the
header for the "all" extension.
Suggested by Denis Proskurin.
2018-09-03 06:26:26 -04:00
Adriaan de Groot
bf40f3bd23
Merge branch 'master' into requirements-checking
2018-08-10 12:02:57 -04:00
Adriaan de Groot
ae7700f2d7
[libcalamares] Refactor searching for module configurations
...
- Similar to the refactorings in Calamares proper, just split out
collecting the search paths into a static function. This makes
it a little easier to find places that will need expansion for
more-than-one-config-directory.
2018-07-10 04:12:24 -04:00
Adriaan de Groot
d66393f1ae
[libcalamares] Fix early failure mode
...
- There is more to failing out of loadModules() than just
emitting modulesFailed, so instead share the failure
code with the code after loading modules -- but don't load any.
2018-06-26 08:43:23 -04:00
Adriaan de Groot
08966ff933
[libcalamaresui] Check module dependencies
...
- Module dependency-checking is done in two phases:
first, catch any unknown modules that are listed
in *requiredModules* and bail out before loading
anything. Second, check that the modules required
by X occur before X in the sequence.
2018-06-26 08:32:36 -04:00
Adriaan de Groot
731594fb40
[libcalamaresui] Remove the requiredModules setting
...
- The value set in module.desc was never stored for use,
but isn't an attribute of the instance, either. It belongs
with the descriptor, in ModuleManager.
2018-06-26 08:18:00 -04:00
Raul Rodrigo Segura
f25d6b278d
add support onLeave and onActivate to pythonqt plugins
2018-06-21 13:21:48 +02:00
Adriaan de Groot
1a097f8c49
Style: run modulesystem through the style guide
2018-06-18 10:56:10 -04:00
Adriaan de Groot
58121abf06
[libcalamaresui] Wasted spaces
2018-06-18 10:44:28 -04:00
Adriaan de Groot
a64de3dbfe
[libcalamaresui] Assign the index to found
...
- Previous code assigns the result of the comparison to found,
instead of the index, resulting in the wrong configuration
map sent to each module.
2018-06-18 10:29:30 -04:00
Adriaan de Groot
374a9bdca6
Merge branch 'emergency-modules'
...
Introduce the notion of emergency modules and emergency jobs.
Initial use will probably center around the preservefiles module,
and possibly umount.
FIXES #928
2018-06-15 12:04:55 -04:00
Adriaan de Groot
8387d5d81f
[libcalamares] Allow emergency jobs
...
Any job can be an emergency job; emergency modules spawn
emergency jobs (but conversely, a non-emergency module
can spawn an emergency job explicitly).
2018-06-15 10:20:07 -04:00
Adriaan de Groot
3ed6f13fa8
[libcalamaresui] Adjust the emergency-ness of modules
...
A potentially emergency module is one that has EMERGENCY
(in CMake) or emergency: true (in module.desc) set.
Any such module must also set emergency: true in the
configuration of the module. This is to allow for
instances of a module that **don't** run as emergency
modules, alongside actual emergency ones.
2018-06-15 09:32:19 -04:00
Adriaan de Groot
def459a29d
[libcalamaresui] Read emergency setting from module.desc
...
- Read setting from the module descriptor
- Document optional settings
- Add EMERGENCY keyword to the CMake helper functions
2018-06-15 07:11:17 -04:00
Adriaan de Groot
dd8e53dc22
Copyright: update copyright lines on files touched in 2018
...
Contributions from:
Adriaan de Groot <groot@kde.org>
Gabriel Craciunescu <crazy@frugalware.org>
AlmAck <gluca86@gmail.com>
Andrius Štikonas <andrius@stikonas.eu>
Caio Carvalho <caiojcarvalho@gmail.com>
Raul Rodrigo Segura <raurodse@gmail.com>
2018-06-15 05:59:11 -04:00
Adriaan de Groot
2d7eea6d73
Merge branch 'master' into emergency-modules
2018-06-14 17:15:40 -04:00
Adriaan de Groot
290559f8c1
Merge pull request #986 from raurodse/configurationPythonQt
...
Add configuration values into pythonqt modules
2018-06-14 13:19:42 -04:00
Raul Rodrigo Segura
448c5eae16
style code
2018-06-14 16:33:58 +02:00
Adriaan de Groot
a8426730ca
[libcalamaresui] Improve wording of modules failure warning
2018-06-14 02:48:52 -04:00
Adriaan de Groot
97a45db4bf
[libcalamaresui] Reset font height when changing size
...
- defaultFontHeight() caches the result; clear cache
when changing the default size, even though this happens
only once in the current codebase.
2018-06-14 02:35:49 -04:00
Adriaan de Groot
bb5ac0326d
[libcalamaresui] Improve layout of "blank" view step
2018-06-14 02:33:03 -04:00
Adriaan de Groot
9918dfb95f
[libcalamaresui] Reporting on failures
...
- Provide information on failed modules
- Disallow further progress when configuration is borked
2018-06-13 13:41:38 -04:00
Adriaan de Groot
3e24c3c58f
[libcalamaresui] Provide standardised large font
2018-06-13 13:41:38 -04:00
Adriaan de Groot
8b406cac9b
[libcalamaresui] Improve module loading
...
- Add a TODO for allowing modules to come from somewhere other
than the module loader (this would allow "internal" modules
that are always present)
- Warnings are warnings
2018-06-13 04:37:52 -04:00
Raul Rodrigo Segura
d61b32aba6
Add configuration values into pythonqt modules
2018-06-12 13:44:28 +02:00
Adriaan de Groot
35124c149e
[libcalamaresui] Drop the 'goodbye' message
2018-06-11 13:35:12 -04:00
Adriaan de Groot
a40c36ef49
[libcalamaresui] Report on failed module loading
...
- Collect the failed modules, instead of bailing out on the first one
(this also prevents crashes caused by quit() called from a timer).
- Introduce a slot to report on failed module loading (no UI yet).
2018-06-11 05:59:56 -04:00
Adriaan de Groot
1999e4e5c2
[libcalamaresui] Error out consistently when module loading fails
...
- Some module-loading failures were ignored and produce only a
warning, instead of erroring out.
2018-06-08 18:14:51 -04:00
Adriaan de Groot
dccf6f16f5
[libcalamaresui] Lambdas are fun, but not always the solution
2018-06-08 17:56:23 -04:00
Adriaan de Groot
a626e52bf3
[libcalamares] Introduce more descriptive type name
2018-06-08 17:36:29 -04:00
Adriaan de Groot
b66d4856e7
[libcalamaresui] Use modern C++ for (auto)deleting failed modules
2018-05-30 07:51:23 -04:00
Adriaan de Groot
eddee7d76a
[libcalamaresui] No point in isLoaded() being virtual.
2018-05-29 03:38:17 -04:00
Adriaan de Groot
a04915e6fa
[libcalamaresui] Add 'emergency' concept to modules.
2018-05-29 03:37:37 -04:00
Adriaan de Groot
cdadc2f003
[libcalamares] Improve error logging during module loading
2018-05-24 06:47:13 -04:00
Adriaan de Groot
fdda0e14aa
[libcalamaresui] Improve explainYamlException
...
- overloads for common kinds of label
- improve error reporting when reading settings and branding files
2018-05-24 06:46:11 -04:00
Adriaan de Groot
e5ca8e091f
[libcalamaresui] Use refactored loadYaml
2018-05-24 06:46:11 -04:00
Adriaan de Groot
f26ac63c07
[libcalamaresui] Make Python code const
...
- This is always loaded into the Python context, so it may as well
be done only once.
2018-05-24 06:46:02 -04:00
Adriaan de Groot
2413180c67
Branding: update copyright notices
2018-05-22 05:47:14 -04:00
Adriaan de Groot
5bcfb32cf5
Branding: move the branding stylesheet to the Branding class
2018-05-22 05:43:59 -04:00
Adriaan de Groot
975004fc63
[libcalamaresui] Document accessors in Branding
...
- document accessors
- put all path and directory accessors together
- make simple accessors inline
- rename "pathprefix" to "directory" to be consistent with others
2018-05-22 05:28:00 -04:00
bill auger
b6673f6324
move thisModule->isLoaded assert to after it's warning message
2018-05-22 03:39:16 -04:00
Adriaan de Groot
2da09f7648
[libcalamaresui] Fix build
...
- Include all headers for types that need to be fully-defined
(e.g. return types). This guards against uses in contexts where
those headers have not been implicitly or previously included.
FIXES #948
2018-05-10 05:39:22 -04:00
Adriaan de Groot
4d459f7fc0
[libcalamares] Move non-UI stuff from libcalamaresui
...
- Settings is just a settings class, no UI involved, so
move to libcalamares where it can be used also from
system helpers.
- YAML utilities are useful at a lower level of the stack, too.
2018-04-05 04:31:13 -04:00
Adriaan de Groot
032b33f56f
[libcalamaresui] Improve logging.
...
- Put the (constant) 'Calamares will now quit' on its own debug line.
- Tell the user what the search paths are if a module is not found
(prompted by a mis-configuration in a Neon live image).
2018-04-04 11:25:28 -04:00
Adriaan de Groot
240efd30f1
[libcalamares] Add support for formatted, table-like output
...
- Use DebugRow for one-row-at-a-time output with continuations.
- Use DebugList for one-item-per-line with continuations.
- Use DebugMap for one-row-at-a-time output of a QVariantMap.
2018-03-30 17:18:45 -04:00
Adriaan de Groot
6bb72d173d
[libcalamares] Drop generic cLog()
...
- Use cWarning or cError() for errors
- Use cDebug(level) for other uses (but there aren't any)
2018-03-28 09:31:45 -04:00
Adriaan de Groot
3e30bb682e
[libcalamaresui] Use cError() for logging errors, not cLog()
2018-03-28 09:22:37 -04:00
Adriaan de Groot
f8bc195fb4
[libcalamaresui] Improve warning when branding has no translation
2018-03-09 07:21:16 -05:00
Adriaan de Groot
c7629182e4
Merge branch 'master' into requirements-checking
2018-03-06 17:06:35 +01:00
Adriaan de Groot
a72bdfac52
Merge branch 'master' into requirements-checking
2018-03-06 14:57:17 +01:00
Adriaan de Groot
09f30194d7
CMake: revert un-versioning of libcalamares*.so
...
The install-bits branch commit 83639b182b
dropped .so-versioning for libcalamares and the creation of the Python-
support symlink. This broke KDE Neon dev-unstable because the embedded
Python can no longer find libcalamares.
Installing unversioned .so's straight to LIBDIR is also not a good thing
(according to Debian), so revert to the original scheme with versioned
.so and a Python-support symlink.
Medium-term fix is to install unversioned straight into LIBDIR/calamares
and fix up the RPATH for the executable.
2018-03-01 12:37:52 +01:00
Adriaan de Groot
db0c1ffd6d
CMake: just install unversioned .so
...
- Applies to libcalamares and libcalamaresui.so, install with no
version, just the bare .so. Since Calamares doesn't do versioning
anyway, and its plugins should be re-compiled for any change,
putting them in lib as unversioned .so's should make Calamares
happy and silence lintian.
2018-02-21 09:52:56 -05:00
Adriaan de Groot
83639b182b
CMake: try installing outside of regular lib/
...
- Install unversioned libraries
- Install to lib/calamares instead of directly to lib/
2018-02-14 08:55:30 -05:00
Adriaan de Groot
958aee1d41
[libcalamaresui] Switch text on 'next' button
...
- If the next step will be an install-step (e.g. hit the optional
confirmation step) then change the text on the 'next' button to
'install'.
- Do a little refactoring to make that more pleasant.
FIXES #905
2018-02-13 08:11:11 -05:00
Adriaan de Groot
3ae126f589
[modules] Use cError() as well
...
- Switch KPMHelpers to using Calamares logging instead of qDebug()
2018-02-13 11:59:38 +01:00
Adriaan de Groot
60f440f72b
[libcalamaresui] Use new convenience logging methods
...
- Remove a few confusing Q_FUNCINFO
2018-02-12 11:58:34 -05:00
Adriaan de Groot
9c9486bb78
[libcalamares] When ViewManager is destroyed, reset instance pointer
2018-01-17 09:17:40 -05:00
Adriaan de Groot
845986d48f
[libcalamaresui] Mark virtual QObject destructors override
2018-01-17 09:17:40 -05:00
Adriaan de Groot
308441ee3a
Merge branch '3.1.x-stable'
2018-01-02 15:44:34 +01:00
Adriaan de Groot
41e6f0e06c
[calamares] Allow WM close button
...
- remove hide-close-button hack
- refactor code in viewmanager for confirming quit
- hook up confirm-and-quit to WM close button
- also works for alt-F4 and other quit methods
- while here, update copyright year
FIXES #870
2018-01-02 14:58:08 +01:00
Adriaan de Groot
762ad54344
Documentation: change http links to GitHub to https
2017-12-20 08:39:09 -05:00
Adriaan de Groot
b6fed964ce
[libcalamaresui] Defer requirements checking of ViewModules to their ViewSteps
2017-12-02 11:30:26 -05:00
Adriaan de Groot
27b921bde1
[libcalamaresui] Move requirements information out of welcome module.
...
- Move type and rename it; put in Calamares namespace
- Emit signals from the viewmanager as results come in
- Remove state changing from welcome view step based on its internal
requirements checking (for now this breaks progressing past the
welcome page)
- Log checking of the requirements
2017-12-02 10:59:33 -05:00
Adriaan de Groot
24e04645b6
[libcalamaresui] Stub requirements checking.
...
Introduce a method checkRequirements() into the module system so that
individual modules can do their own checking (as opposed to stuffing
it all into the welcome module).
2017-12-02 09:26:22 -05:00
Adriaan de Groot
5a07f6ef8a
Merge branch 'master' into requirements-checking
2017-11-29 09:02:07 -05:00
Adriaan de Groot
65cf28b716
[libcalamaresui] Provide access to the breeze SVGs
2017-11-20 09:04:26 -05:00
Adriaan de Groot
fbe1976c11
[libcalamaresui] Add breeze SVGs under LGPLv3
2017-11-20 08:59:10 -05:00
Adriaan de Groot
4d7f70a28f
[kcrash] Remove duplicate 'Tools' tab
2017-11-13 07:35:37 -05:00
Adriaan de Groot
e8e284f724
Merge remote-tracking branch 'origin/kcrash'
2017-11-13 13:18:53 +01:00
Adriaan de Groot
2d31e987c0
[libcalamaresui] Unrelated typedef for JobList
2017-11-03 11:02:06 -04:00
Adriaan de Groot
e09f179d76
Coverity: repair previous commit
2017-10-30 08:43:09 -04:00
Adriaan de Groot
a138eb501c
Coverity: fix issues reported in QJsonModel
...
- Also reported upstream, in the MIT-licensed version of same.
This is a re-hash of b348a45834
,
adding memory-leak prevention when load() is called.
2017-10-30 08:20:08 -04:00
Adriaan de Groot
fe0cb88d70
Linking: be a little more relaxed in linking to dependent libs
2017-10-24 12:56:02 -04:00
Adriaan de Groot
33f78b375d
Merge branch 'master' into kcrash
2017-09-27 09:52:01 -04:00
Adriaan de Groot
8917d153da
Drop the (inter-)module dependencies system.
...
- Was marked incomplete and unused; none of the existing modules
set any requirements, and the descriptors are not set up to
hold the requirements information anyway.
- Dependencies are generally through globalStorage values, or if
there are dependent jobs they should be created in-order by one
source (e.g. though a View or a subclass of CppJob which overrides
jobs() ).
- It is the responsibility of deployers to formulate a settings.conf
that includes all the required modules.
- A 'real' dependency system is going to lead to the introduction
of interface-definitions and a great deal of complexity, for a
use case that can be handled with careful deployment instead.
2017-09-27 05:34:06 -04:00
Adriaan de Groot
bd4ee9320d
Clang: warnings--, drop unused WindowFlags parameter
2017-09-26 11:51:11 +02:00
Adriaan de Groot
866d338894
Clang: warnings--
2017-09-25 16:28:08 +02:00
Adriaan de Groot
40c49bd50d
Clang: be more explicit about marking third-party code.
...
- This is only a partial solution to warnings caused by third-party
code, since #including the headers from other sources won't apply
the warning-suppressions.
- Flags are not applied when building the source as part of a larger
target, but are on re-building just one object (it seems -- CMake
issue to track down).
2017-09-21 04:53:09 -04:00
Adriaan de Groot
337903db09
Clang: reduce warnings about overriden destructors
2017-09-20 09:11:18 -04:00
Adriaan de Groot
b04a890798
Fix code using re-imported imageregistry
2017-09-19 16:49:14 +02:00
Adriaan de Groot
6010805935
Licensing: add header to imageregistry copyright
...
- mention that this is shipped as part of Calamares
- SPDX info
2017-09-19 16:26:26 +02:00
Adriaan de Groot
a65bc7d756
Licensing: re-import ImageRegistry
...
- include full license headers,
- copied from
- repo: https://github.com/tomahawk-player/tomahawk/
- rev: 00f602e10203b76fc28b4615868c567e6bd4ced4
- path: src/libtomahawk/utils/ImageRegistry.cpp
2017-09-19 16:26:26 +02:00
Adriaan de Groot
d23818b27c
Fix code using re-imported spinner
2017-09-19 16:26:26 +02:00
Adriaan de Groot
d2d59e6206
Licensing: add header to QtWaitingSpinner copyright
...
- mention that this is shipped as part of Calamares
- SPDX info
2017-09-19 16:26:26 +02:00
Adriaan de Groot
553a66b326
Licensing: re-import QtWaitingSpinner
...
- include full license headers,
- copied from
- repo: https://github.com/snowwlex/QtWaitingSpinner
- rev: bb8f8987ca19406dc75704eb382ab52e981b773f
This revision *does not build* because the files have been renamed.
2017-09-19 16:26:26 +02:00
Adriaan de Groot
24f26ee7c8
Licensing: add header to QJsonModel copyright
...
- mention that this is shipped as part of Calamares
- SPDX info
2017-09-19 16:26:23 +02:00
Adriaan de Groot
e5c0854e66
Licensing: re-import GPLv3 version of QJsonItem
...
- include full license headers,
- copied from
- repo: https://github.com/dridk/QJsonmodel
- rev: fbd4fb3b1c1311f69cd8ada9bbb7a89fd6fe171e
2017-09-19 15:57:46 +02:00
Adriaan de Groot
13807ceabf
Licensing: add self
...
- to all the files I've touched recently
- to (very incomplete) AUTHORS list
Licensing: add license info to top-level CMakeLists.txt
2017-09-19 15:57:25 +02:00
Adriaan de Groot
ddb6455365
Revert be2338ff0
(intended just to reduce warnings)
...
- keep the calamaresstyle formatting changes,
- drop shadowing and nullptr changes.
FIXES #805
2017-09-18 15:11:18 +02:00
Adriaan de Groot
ddf7b7fc90
CMake: remove superfluous indirection
2017-09-18 12:12:10 +02:00
Adriaan de Groot
c6297f1db5
Clang: warnings--
2017-09-14 06:34:31 -04:00
Adriaan de Groot
edb1dbaa6e
Clang: warnings--
2017-09-13 22:32:21 +02:00
Adriaan de Groot
da4fa6a63a
Fix link / library name
2017-09-13 19:03:56 +02:00
Adriaan de Groot
bd37572fd8
Clang: reduce warnings
2017-09-13 19:03:56 +02:00
Adriaan de Groot
be2338ff08
Clang: reduce warnings
2017-09-13 08:03:18 -04:00
Adriaan de Groot
cb57de2e65
Clang: float -> qreal where it matches Qt API
2017-09-11 11:07:32 +02:00
Adriaan de Groot
463615a1c0
Clang: don't shadow local variable names
2017-09-10 13:22:54 -04:00
Adriaan de Groot
764fb742ba
Clang: clean up documentation markup
2017-09-10 13:22:54 -04:00
Adriaan de Groot
bd3786ebeb
Clang: reduce warnings in various places
2017-09-10 13:22:32 -04:00
Adriaan de Groot
7e25909e18
YAML: refactor YAML-exception reporting
...
- both NetInstall (group data) and Locale (GeoIP) use network
data returned as a source of YAML data. Try to explain
parsing errors for both.
FIXES #786
2017-09-06 07:51:22 -04:00
Adriaan de Groot
6c5199c9cc
YAML: on error, report filename along with location
2017-09-06 05:10:33 -04:00
Adriaan de Groot
73a75e837b
Auto-resize the main window.
...
If the summary widget is large, it gets a scrollbar. This looks really
weird, so prefer to grow the installer window instead. Discussed with
@sitter and settled on this solution.
ViewSteps can signal the ViewManager that they need more space (in pixels),
which may or may not be honored.
FIXES #778
2017-09-05 10:51:54 -04:00
Adriaan de Groot
e26d5ab206
Don't leak memory for allocated modules
2017-08-31 04:13:52 -04:00
Adriaan de Groot
a718eb76cb
Docs: code-documentation about summary page
2017-08-08 07:54:38 -04:00
Adriaan de Groot
2fdccdf090
Merge branch 'simplify-module-desc'
2017-08-02 11:29:58 -04:00
Adriaan de Groot
e3008657c4
Modules: accept 'viewmodule' as alias of 'view', improve logging on error.
2017-08-02 11:05:32 -04:00
Adriaan de Groot
594bc37d67
Coverity: uninitialized member
2017-07-11 09:32:09 -04:00
Adriaan de Groot
10eaf06f60
Python: Be more descriptive when modules can't be loaded.
2017-07-05 06:30:23 -04:00
Adriaan de Groot
d3f624f818
FinishedPage: no modal pop-ups in a slot
...
Switch the failure popup to non-modal, and quit the application when
the pop-up is closed. This allows signals to be delivered to other
slots connected to JobQueue::failed.
2017-07-04 08:14:30 -04:00
Adriaan de Groot
44e6955f19
Feature: allow disable welcome-logo resizing
2017-07-04 04:30:08 -04:00
Adriaan de Groot
c4f955874d
QLabel::setPixmap() isn't virtual, don't make it so.
2017-07-04 03:36:42 -04:00
Adriaan de Groot
ee4e4dfccc
C++ trickery to make the code shorter to read.
2017-07-03 18:07:18 -04:00
Adriaan de Groot
43e7ea6265
Merge branch 'no-rcc'
2017-07-03 05:48:50 -04:00
Adriaan de Groot
9b3af4aac3
i18n: translate yes/no buttons, don't rely on Qt translations
2017-07-03 05:46:33 -04:00
Adriaan de Groot
61c0ab4534
Clang: fix the right conversions (thanks KKofler)
2017-06-29 06:18:52 -04:00
Adriaan de Groot
4561849c39
UI: add tooltip to Cancel / Quit button
...
Change 'Quit' at the end to 'Done', because we're done -- and Quit
is sometimes interpreted as cancelling. Tooltip for additional
explanation.
2017-06-28 07:48:51 -04:00
Adriaan de Groot
09b25ab3e9
Clang: make ViewManager instance a proper singleton.
2017-06-27 06:46:59 -04:00
Adriaan de Groot
6a3aa01564
Clang: reduce warnings
2017-06-27 06:11:26 -04:00
Adriaan de Groot
2add7f6f86
Clang: type-annotate float literal
2017-06-27 06:08:07 -04:00
Adriaan de Groot
3b5955900e
Coverity: explicit initialization
2017-06-27 06:05:26 -04:00
Adriaan de Groot
8ea14d7957
Release: add copyright to files I've touched
2017-06-21 08:27:10 -04:00
Adriaan de Groot
12a0edfa50
Clang: reduce warnings
2017-06-21 07:28:38 -04:00
Adriaan de Groot
2148538fac
Clang: reduce warnings
2017-06-21 07:28:38 -04:00
Adriaan de Groot
d9ea22a486
Screensize: refactor, move screen-size constants into global constexpr
...
Also drop the minimum size a tiny bit, to 1024x520.
2017-06-21 06:51:51 -04:00
Adriaan de Groot
ce6997d214
Coverity: fix some uninitialized members
2017-06-17 15:14:02 -04:00
Adriaan de Groot
f1cfde36d6
Allow different welcome message.
...
FIXES #592
2017-06-12 15:25:54 -04:00
Adriaan de Groot
14912d6c63
Merge branch 'master' of https://github.com/AOSC-Dev/calamares into AOSC-Dev-master
2017-06-08 04:54:06 -04:00
Adriaan de Groot
14cba59ab3
Logging: distinguish different failures in module instantiation.
2017-06-06 09:10:13 -04:00
Adriaan de Groot
367fe716b3
Configs: empty config files are ok.
...
The default umount.conf contains no keys -- so it isn't a map,
but it is a valid config file. Avoid the warning by accepting
empty files.
FIX 707
2017-06-02 16:10:08 +02:00
Teo Mrnjavac
17962179bd
Documentation++
2017-03-03 12:32:44 +01:00
Teo Mrnjavac
6c7cdb5f50
Documentation++
2017-03-01 13:35:06 +01:00
Teo Mrnjavac
99a1c2245f
Documentation++
2017-02-28 18:08:20 +01:00
Teo Mrnjavac
de3c94fc97
Useless debug is useless.
2017-02-28 18:08:20 +01:00
Teo Mrnjavac
f4696f22a1
Pass locale name to PythonQt module.
2016-12-16 17:03:13 +01:00
Teo Mrnjavac
0c36de68ff
Attach retranslator to base widget of ViewStep.
2016-12-16 17:03:13 +01:00
Teo Mrnjavac
d3845144bb
Start from empty str for entry point annotation.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
46787222c9
Fix ifdefs for WITH_PYTHONQT.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
ca7728cd34
Implement PythonQtViewStep::jobs as a wrapper for Python-provided jobs.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
d425f71fdb
Build it.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
aad1c536d1
New PythonQtJob class.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
f3fa124f8d
Set configuration map in PythonQt module.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
a3887d268a
Expose global_storage and utils as objects in PythonQt.calamares.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
864109fd4e
Build them.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
4648f5e8e0
Utils wrapper class, to expose libcalamares.utils under PythonQt.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
7791307e1e
Wrapper for GlobalStorage, to make it available through PythonQt.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
25613d1bef
Fix _calamares_module_basewidget check and improve readability.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
0f0a6ab18d
PythonQtViewStep has no decorator.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
9aefeed648
Expose PythonQt.calamares.global_storage.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
a54f217173
Use CalamaresUtils::lookupAndCall in PythonQtViewStep.
...
This is done to support both Pythonic and Qt style method names, i.e.
both "isNextEnabled" and "is_next_enabled" is ok in a Python module.
Also better documentation in PythonQtViewStep, and stub for
setConfigurationMap.
Finally, proper handling of PythonQtViewStep Python-facing basewidget:
with this change, a call to PQVS::widget() only triggers a widget
relayout if it's necessary, and leaves it alone otherwise.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
fb9d1fa339
Add PythonQtUtils.{h,cpp} with CalamaresUtils::lookupAndCall.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
9570bd94e8
Nor this.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
53f687587b
Add support for attaching a Python console in DebugWindow.
...
Also add support for showing module type/interface.
Also minor layout improvements.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
c618999418
Properly load new PythonQtViewModule.
...
Only initialize Python if it's not initialized yet.
Inject @calamares_module decorator to fetch the entry class.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
2736ad6e09
User-visible Type and Interface strings in Module.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
d526935001
Remove PythonQtConsoleViewStep, which was only there for testing.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
b4002a716a
New PythonQtViewStep.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
553062fc11
Fix build.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
8a90b89d25
Headers.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
0a5faa4888
PythonQtConsoleViewStep for testing purposes.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
2c3b56c803
Link against PythonQt; new PythonQtViewModule stub.
2016-12-16 17:03:00 +01:00
Teo Mrnjavac
e2b2d761c2
Do not LINK_PUBLIC by default.
2016-12-07 16:37:29 +01:00
Kevin Kofler
00d9f211f5
Add support for C++/Qt batch job plugins
...
These job plugins work similarly to view modules, with the following
differences:
* These jobs need to link only libcalamares, not libcalamaresui. For
this reason, PluginFactory was moved from libcalamaresui to
libcalamares. (It depends only on QtCore.)
* Instead of deriving from ViewModule, derive from CppJob (which is a
subclass of Job).
* Like process and Python jobs, a job plugin is a single job, whereas a
ViewModule can generate a whole list of jobs.
The CppJob and CppJobModule classes are new. In Module::fromDescriptor,
the combination type=job, intf=qtplugin is now supported and mapped to
CppJobModule.
2016-09-27 17:25:09 +02:00
Teo Mrnjavac
4662c9c877
Remove irrelevant debug output.
2016-09-19 12:34:45 +02:00
Andrius Štikonas
9f0ca042fe
Port away from most cases of Q_FOREACH to C++11 ranged for loop.
...
In order to avoid deep copies, Qt containers over which we iterate must be const
The remaining unported cases require qAsConst (Qt 5.7) or std::as_const (C++17)
2016-09-01 16:46:14 +01:00
Teo Mrnjavac
9d61420e4f
Added toolbox page to Debug interface, with deliberate crash feature.
2016-03-23 18:48:08 +01:00
Teo Mrnjavac
9928124195
Added toolbox page to Debug interface, with deliberate crash feature.
2016-03-16 11:44:20 +01:00
Teo Mrnjavac
1d8330f1eb
Handle missing setting gracefully.
2016-03-01 15:10:19 +01:00
Teo Mrnjavac
c1d1e7cb5a
Prevent memory leak on bad module dir (fix Coverity defect 114172).
2016-02-26 13:22:03 +01:00
Teo Mrnjavac
27b27644c4
Initialize all members (fix Coverity defect 114173).
2016-02-26 13:19:47 +01:00
Mingcong Bai
2d64110150
calamares: sidebarTextHighlight for branding
...
This commit adds support for distribution to define sidebarTextHighlight to their
branding.desc file, to control the left panel (sidebar) with highlight behind the
current step (isCurrent) text label.
2016-01-06 20:02:56 -07:00
Teo Mrnjavac
25e388aa29
Add CalamaresUtils::defaultFont()
2015-12-30 17:27:13 +01:00
Teo Mrnjavac
17f1f5f61f
Load those icons.
2015-12-30 17:27:13 +01:00
Teo Mrnjavac
d4117b333c
New icons for DeviceInfoWidget.
2015-12-30 17:27:13 +01:00
Teo Mrnjavac
351c69c300
Remove obsolete code.
...
CAL-340 #close
2015-12-30 17:27:02 +01:00
Teo Mrnjavac
0fa19cca68
Fix the last page fix.
2015-12-30 17:27:02 +01:00
Teo Mrnjavac
51d0d9f9b4
Disable next on last page.
2015-12-30 17:27:02 +01:00
Teo Mrnjavac
6de8158bec
It is a good idea to initialize pointer members in the ctor.
2015-12-30 17:27:02 +01:00
Teo Mrnjavac
5e87e01374
Refactor view module workflow in ViewManager.
2015-09-15 16:48:42 +02:00
Teo Mrnjavac
2a0eb9e481
Fix debug window.
2015-09-15 16:48:42 +02:00
Teo Mrnjavac
461ef79170
ViewStep should know their own instance keys.
2015-09-15 16:48:42 +02:00
Teo Mrnjavac
fb44fb97b6
Massive refactor of module loading, configuration, startup, management.
2015-09-15 16:48:42 +02:00
Teo Mrnjavac
c74c67805e
Remember to update CMakeLists.
2015-09-15 16:48:42 +02:00
Teo Mrnjavac
9042616a8a
Refactor configuration file loading to allow multiple instances.
2015-09-15 16:48:42 +02:00
Teo Mrnjavac
4f84e9ad14
InstallationViewStep is now ExecutionViewStep.
...
It also uses JobQueue directly.
2015-09-15 16:48:42 +02:00
Teo Mrnjavac
f836019f49
Add Calamares::PluginFactory to allow multiple instances of a Qt Plugin.
2015-09-15 16:48:41 +02:00
Teo Mrnjavac
3b56c5c9e8
Use safe QTimer::singleShot connection.
2015-09-15 16:48:41 +02:00
Teo Mrnjavac
42e465aa10
CalamaresUtils::System is now a class.
2015-09-15 16:48:41 +02:00
Teo Mrnjavac
2e3751ffa7
If dont-chroot is set, don't chroot target env calls.
2015-09-15 16:48:41 +02:00
Teo Mrnjavac
8064736580
Add clearLayout to CalamaresUtilsGui.
2015-09-14 16:51:04 +02:00
Teo Mrnjavac
1a39d2a6e1
Always provide this as context for a signal connection with a lambda.
2015-07-15 17:49:25 +02:00
Teo Mrnjavac
42316fe6dc
Do ask for confirmation if quitting during install phase.
2015-06-29 10:49:16 +02:00
Teo Mrnjavac
851f175ae7
Only load QML when the install page is activated.
2015-06-29 10:49:16 +02:00
Teo Mrnjavac
506e51598d
Do not dereference a nullptr.
2015-06-21 01:39:28 +02:00
Teo Mrnjavac
80c76c549f
New FixedAspectRatioLabel for pixmaps.
2015-06-20 01:04:54 +02:00
Teo Mrnjavac
75cf3f08c6
Add ProductWelcome image to Branding.
2015-06-20 00:18:14 +02:00
Teo Mrnjavac
bd7dd43c90
Hardcode Calamares logo in About.
...
CAL-241 #close
2015-06-16 02:38:07 +02:00
Teo Mrnjavac
11f5b729a8
Avoid dereferencing nullptr.
2015-06-14 01:10:50 +02:00
Teo Mrnjavac
df9daf8fec
Avoid accessing nullptr.
2015-06-14 01:02:50 +02:00
Teo Mrnjavac
233d759a00
Initialize all members even in private ctor.
2015-06-13 21:41:49 +02:00
Teo Mrnjavac
46dcb51f62
Initialize all members and make dtor virtual.
2015-06-13 21:32:34 +02:00
Teo Mrnjavac
8e16bea3d9
Remove unused members.
2015-06-13 21:32:06 +02:00
Teo Mrnjavac
b348a45834
Fix memory leak in QJsonModel.
2015-06-13 20:31:41 +02:00
Teo Mrnjavac
77e205e48a
Reload the slideshow on language change.
2015-05-07 16:12:19 +02:00
Teo Mrnjavac
375150347b
nullptr is better than 0
2015-05-07 16:11:23 +02:00
Teo Mrnjavac
09d7cd9de6
Add translationsPathPrefix to Branding.
2015-05-07 16:10:42 +02:00
Teo Mrnjavac
f8995bc8e5
Copyright header.
2015-04-13 14:58:34 +02:00
Teo Mrnjavac
a8b8a3a455
Show an "are you sure" prompt before install, if prompt-install is true.
2015-04-13 14:58:34 +02:00
Teo Mrnjavac
b86193824d
Read a prompt-install variable from settings.conf.
2015-04-13 14:58:34 +02:00
Teo Mrnjavac
24fc227e76
Retranslate navigation buttons.
2015-04-08 18:40:43 +02:00
Teo Mrnjavac
c9769dfd76
Add Disk and Partition icons to CalamaresUtils::defaultPixmap.
2015-04-03 11:57:01 +02:00
Teo Mrnjavac
9606b228d7
Add Disk and Partition icons to qrc.
2015-04-03 11:55:39 +02:00
Teo Mrnjavac
b095982830
Expose new partitioning icons in CalamaresUtils::defaultPixmap.
2015-04-02 14:03:12 +02:00
Teo Mrnjavac
cf49239419
Update libcalamaresui.qrc
2015-04-02 14:02:13 +02:00
Teo Mrnjavac
506b79ef2c
Add new icons to CalamaresUtils::defaultPixmap.
2015-04-02 12:49:40 +02:00
Teo Mrnjavac
e6f98393b8
Add icons to qrc.
2015-04-02 12:48:34 +02:00
Teo Mrnjavac
ec883e391d
Add different kinds of Url to Branding.
2015-04-02 12:29:31 +02:00
Teo Mrnjavac
bce6ec94fd
Add ProductUrl and ProductUrlText to Branding.
2015-04-01 18:03:17 +02:00
Teo Mrnjavac
19bcc887a8
Fix build with Qt 5.5 branch.
2015-03-27 11:59:44 +01:00
Teo Mrnjavac
cc5095781d
Branding::style is now ::styleString for clarity.
2015-03-19 18:03:55 +01:00
Teo Mrnjavac
9615691554
CalamaresStyle is no more. Look for color constants in Branding.
2015-03-19 18:03:55 +01:00
demmm
b982d751af
adding needed Branding.cpp section
...
builds, but segfaults on running
2015-03-19 18:03:55 +01:00
demmm
56afa45812
start of trial to add sidebar style options
...
use a new style section in branding.desc, doesn't build as is
2015-03-19 18:03:55 +01:00
demmm
d750885e75
Revert "add URL option in greeting page"
2015-03-19 10:44:34 -04:00
demmm
be29755230
add URL option in greeting page
...
URL is a variable set in branding.desc, distros cna link to a Known Issues page
text for the URL is also possible to set in branding, known issues is default
advantage is any text possible as distros see fit
disadvantage, not part of translated strings
if most agree, Known Issues can be set as hard coded text, not in branding.desc
2015-03-19 10:32:14 -04:00
Teo Mrnjavac
c2a0845738
Debug window title.
2015-03-11 12:42:08 +01:00
Teo Mrnjavac
5951208c1b
Add Modules page to DebugWindow.
2015-03-10 19:51:08 +01:00
Teo Mrnjavac
dda7ea211d
Make ModuleManager accessible from outside CalamaresApplication.
2015-03-10 19:51:08 +01:00
Teo Mrnjavac
4e2e964503
Return configurationMap from Module.
2015-03-10 19:51:08 +01:00
Teo Mrnjavac
8a60abdfc9
Add JobQueue list to DebugWindow
2015-03-10 19:51:08 +01:00
Teo Mrnjavac
3ce8abcb78
Expand all items in the GlobalStorage debug tree.
2015-03-10 19:51:08 +01:00
Teo Mrnjavac
8729b6a25f
Update the debug view every time GlobalStorage changes.
2015-03-10 19:51:08 +01:00
Teo Mrnjavac
060983279f
Add a QTreeView for GlobalStorage contents to DebugWindow.
...
Not real time yet.
2015-03-10 19:51:08 +01:00
Teo Mrnjavac
9249d6e165
Add QJsonModel.
2015-03-10 19:51:08 +01:00
Teo Mrnjavac
00565d0f12
Stubs for DebugWindow.
2015-03-10 19:51:08 +01:00
Gormogon
e2d05cb9f2
Align Pointers
2015-02-25 19:57:19 -05:00
Teo Mrnjavac
2782328036
Fix phase handling in ViewManager, to allow adding a Finished page.
2015-01-29 22:46:08 +01:00
Teo Mrnjavac
20bc34029d
Copyright.
2015-01-29 22:46:07 +01:00
Teo Mrnjavac
a670de3035
Add currentPhase to ModuleManager.
2015-01-29 22:46:07 +01:00
Teo Mrnjavac
171248ad4f
Add isBackEnabled checks to all ViewSteps.
2015-01-29 22:46:07 +01:00
Teo Mrnjavac
de406cef22
The Quit button is now Cancel, except on the last page.
2015-01-28 15:26:23 +01:00
Teo Mrnjavac
50a413d3c2
Only set the slideshow if the branding component has one.
2015-01-23 20:27:27 +01:00