a crashed program trying to restart itself is very unreliable,
especially program that uses KUniqueApplication instance. so, instead
all the information about the crash shall be written to a file on the
disk (in the temporary directory) and read by external kcrash KDED
module that will report the crash (possibily even upload the crash
details somewhere) and restart the program as necessarry.
this also opens up possibility for per-application configuration for
things such as the automatic restart feature but that shall be done by the
kcrash KDED module instead (parsing a config from a crashed program is
not a good idea)
KCrash::NoRestart will be unused but kept for future expansion
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
also adjust KLocalizedString test case, "Job" is no longer translated
string in the source code thus not in the french translation
on a side note there are KLocale tests all around - KLocalizedString, KIO
tests, etc. so perhaphs only quircks should be tested by the KLocale
specifiec tests
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
by using QLocale in KLocale and separating the date, time and numbers
conversion from translation KLocale actually gets extended locale
support from QLocale (which uses CLDR data v43 currently). translation
remains unaffected. for comparison here is the result of two function
calls the result of which should explain the whole change:
KLocale::allLanguagesList().size() = 669
KLocale::installedLanguages().size() = 68
the first number is locales Katie supports, the second being the
number of languages Katana is translated into
KSwitchLanguageDialog needs a rewrite but that is on the TODO
also copyrighting KCatalog to me because I rewrote it, for reference:
881b47b8ea
KCalendarSystem gets the middle finger - batteries not included for date
and time. extra calendar systems can, but are unlikely to be, supported
in the future
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
simplifies startup notification for example, external applications that
pass the "nofork" argument may fail (not uncommon to be passed to
konsole)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
kcfg files are resources much like .ui files - not ment to be installed,
used only to generate .cpp and .h files from them. they are not used at
runtime altough Plasma::ConfigLoader does use its format to load files
for configuration purposes (files named main.xml shipped by plasmoids)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
so that application event processing is not blocked by any
KToolInvocation method, the D-Bus service name and PID return arguments
are not used anyway so removing them
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
that way the UI will not freeze while the method is executed, beware
signals and slots if you connect it to one (or even more) tho
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
dead-lock may happen if QStandardPaths (which KStandardDirs uses and
thus KDebug indirectly) warns about something
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
much simpler and easier to maintain, also it will be proper D-Bus
service now with no sockets, process title hack and whatnot. KCrash
and startkde script (in kde-workspace repo) have to be adjusted for
it tho
note that the internal KIO scheduler already has the functionality to
put slaves on hold but now they will be started as detached process.
eventually they may become plugins (they are loaded as such by kioslave
program) without event loop dispatcher
fixes application startup notification (ASN) and cleanup issues
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
it has to be done only once (because it calls global static to translate),
does not have thread requirement (QCoreApplication locks when installing
or removing translator) and it checks if KGlobal has locale via
KGlobal::hasLocale() to ensure it is not attempting to call
KGlobal::locale() after KGlobal destruction
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
was non-operational code due to QT_NO_TRANSLATION being defined in the
kglobal source file for some reason, it has a huge impact on performance
ofcourse because anything Katie will attempt to translate will go trough it
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
note that there is no main thread requirement, KToolInvocation has one
signal (which is thread-safe) and KToolInvocation::klauncher() remains as
thread-safe as global static
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
if QStandardPaths::writableLocation() did not create the directories
KStandardDirs::locateLocal() or KStandardDirs::saveLocation() will
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>