chore: use DDE for current desktop name

使用DDE作为当前桌面环境的名称

log:
This commit is contained in:
tsic404 2023-03-06 14:28:12 +08:00 committed by deepin-bot[bot]
parent 7a8f2c835a
commit 8f88b6bec5

View File

@ -152,7 +152,9 @@ bool IsSaveMode()
int main(int argc, char *argv[])
{
if (QString(getenv("XDG_CURRENT_DESKTOP")).compare("deepin", Qt::CaseInsensitive) == 0) {
QString currentDesktop = QString(getenv("XDG_CURRENT_DESKTOP"));
if (currentDesktop.compare("DDE", Qt::CaseInsensitive) == 0 ||
currentDesktop.compare("deepin", Qt::CaseInsensitive) == 0) {
qDebug() << "Warning: force enable D_DXCB_FORCE_NO_TITLEBAR now!";
setenv("D_DXCB_FORCE_NO_TITLEBAR", "1", 1);
}