reimplement dlog
use `DLogHelper` instead of `CuteMessageLogger` `LoggerTimingHelper`
keep CuteMessage symbol for compatibility (fix undefined symbol: _ZNK3Dtk4Core17CuteMessageLogger5writeEPKcz)
cmake -DDVERSION=6.0.0 to build libdtk6core
install qdbusxml2cpp-fix to DCore/bin to avoid conficts
do not build doc when build dtk6
remove Core5Compat depends
DVERSION ==> DTK_VERSION
tools install to CMAKE_INSTALL_LIBEXECDIR
* BUILD_VERSION should be a string, not a boolean option;
* Should use CMAKE_INSTALL_PREFIX as DSG_PREFIX_PATH in test,
CMAKE_PREFIX_PATH might be a list. And there's difference between
two variables;
* Trim some trailing spaces.
Log: fix wrong use of option and wrong macro
All application can use same configuration by generic
configuration.
Loading cache file can fallback to noappid's directory when not
using appid or not find cache file.
one application writes configuration.
```c++
auto config = DConfig::createGeneric(FileName);
config->setValue("common-configuration", true);
```
other applications read configration can give appid or not to
get the configuration.
Set empty string for DBus caller when using acquireManager.
Log: 配置策略支持应用无关配置,缓存精准匹配到meta是否使用appid
Influence: none
Change-Id: I78b331f9c455617d5dfea6df087b1f4828390974
Add adjust for linux when compile.
Add `D_DSG_APP_DATA_FALLBACK` macro when packaging.
see the commit: 7b13e5c4b8
Log: none
Influence: none
Change-Id: Ie047dbd2d8158ed5242dfb5bcc7fa4e02ee1d925
1. Add DTextEncoding class, provides encoding detection and encoding conversion.
2. Add interface unit test cases, example and comment document.
3. DTextEncoding dynamically loads libuchardet.so and libicuuc.so to support
extended text encodings.
Log: Add DTextEncoding class.
Influence: Add build dependencies libuchardet-dev and libicu-dev.
use better optionname and use test , make test link to -lgcov , then
coverage can be caculated. And use ctest , the cmake command to run
tests
fix test-recoverage bash scipts
Log: option name changed , use ctest command, fix test-recoverage script
Use DCapManager class to unify privilege management on
whether to open files or not.
By registering a special file engine, the scope of action
after registration is global unless called the unregister
function manually.
By default, the application can still access some directories
and files with permissions after it is started, but when it
access files beyond the scope of these directories, it will
not get any information.
The default directory includes: Home path; Cache path; DSG path
XDG path etc.
Log:
Influence: null
Change-Id: I0fed6051addc56001b382fc34f73b046c0e4aca2
In the not supported for DSG_APP_DATA environment, we can't get a valid
directory for the global config, then falied when saving data. In order
not to lose data, we can only fallback to storing it to the user
directory.
Also, allows to specify a fallback directory for DSG_APP_DATA on
compile, in order to never fallback to the user directory.
Log:
Add invalid check for all DConfig's method(avoid null pointer dereference).
fallback to FileBackend when DBusBackend can't be created.
set correct environment value in unit test.
Log:
Influence: all application crash when dconfig is invalid but still
call other method expect isValid.
Change-Id: I7395f44518989cb14a09306fcfd4db380608a24e
DSettingsBackend::doSetOption is executing when `DSettings` has
been destroyed, because `doSetOption` is connected in `QueuedConnection`
way, this would be ensure `backendWriteThread`'seventloop is exited
when `DSetting` destoryed.
we ensure `DSettings` is released before `SettingBackend`, so that
`SettingBackend`'s slot would be executed when `DSetting` destoryed.
we also should ensure `SettinBackend` is thread safely, because os
`DSettings` has backendWriteThread to execute doSetOption, and getOption,
is execute in main thread.
remove link of libdtkcore in qmake, because we compile it's source code
in unit test.
Log:
Influence: none
Change-Id: I35fcb8dff2145aec74255889dbd84b5a0525bffb
Add invalid check for all DConfig's method(avoid null pointer dereference).
fallback to FileBackend when DBusBackend can't be created.
set correct environment value in unit test.
Log:
Influence: all application crash when dconfig is invalid but still
call other method expect isValid.
Change-Id: I7395f44518989cb14a09306fcfd4db380608a24e
for application meta path loads order change from
/usr/share/dsg/apps/${appid}/confgis to
/usr/share/dsg/configs/${appid} or /usr/share/dsg/configs;
replace DStandardPaths::paths to DStandardPaths::path.
modify saved path。
Log:
Influence: all application's configuration would not be loaded
unless updating dtkcommon and it's application package.
Change-Id: Ia8212618fd2d4a5ecf67f05aad32a92d934ea01d
add reset function;
add Dconfig construct containing appId, to keep compatible,we use
a static function to avoid ambiguous, construct function calls
no appid's. it is useful to access other application's configure
timely in DBusBackend.
Log:
Influence: user can access other application's configure and
reset value for the key.
Change-Id: Id707a96ba1216b406b5c6f724ba5d715cfb053db