chore: 修复AM初次启动占用大量内存的问题
修复AM初次启动占用大量内存的问题 Log: Task: https://pms.uniontech.com/task-view-144887.html Influence: 正常启动 Change-Id: I6f76ee7101dd846d55f37cec949b9201bc331cd0
This commit is contained in:
@ -54,6 +54,7 @@ Dock::Dock(QObject *parent)
|
||||
registeModule("dock");
|
||||
|
||||
QString sessionType {getenv("XDG_SESSION_TYPE")};
|
||||
qInfo() << "sessionType=" << sessionType;
|
||||
if (sessionType.contains("wayland")) {
|
||||
// wayland env
|
||||
isWayland = true;
|
||||
@ -636,7 +637,7 @@ void Dock::smartHideModeTimerExpired()
|
||||
*/
|
||||
void Dock::initSettings()
|
||||
{
|
||||
SETTING->init();
|
||||
qInfo() << "init dock settings";
|
||||
forceQuitAppStatus = SETTING->getForceQuitAppMode();
|
||||
connect(SETTING, &DockSettings::hideModeChanged, this, [&](HideMode mode) {
|
||||
this->updateHideState(false);
|
||||
@ -668,7 +669,7 @@ void Dock::updateMenu()
|
||||
void Dock::initEntries()
|
||||
{
|
||||
initDockedApps();
|
||||
if (!isWaylandEnv())
|
||||
if (!isWayland)
|
||||
initClientList();
|
||||
}
|
||||
|
||||
|
@ -30,6 +30,7 @@ DockManager::DockManager(QObject *parent)
|
||||
: QObject(parent)
|
||||
, dock(new Dock(this))
|
||||
{
|
||||
qInfo() << "DockManager";
|
||||
adaptor = new DBusAdaptorDock(dock);
|
||||
QDBusConnection con = QDBusConnection::sessionBus();
|
||||
if (!con.registerService(dbusService)) {
|
||||
|
Reference in New Issue
Block a user