Changeset View
Changeset View
Standalone View
Standalone View
src/platformtheme/khintssettings.cpp
Show First 20 Lines • Show All 91 Lines • ▼ Show 20 Line(s) | 88 | { | |||
---|---|---|---|---|---|
92 | KConfigGroup cg(mKdeGlobals, "KDE"); | 92 | KConfigGroup cg(mKdeGlobals, "KDE"); | ||
93 | 93 | | |||
94 | if (mUsePortal) { | 94 | if (mUsePortal) { | ||
95 | updatePortalSetting(); | 95 | updatePortalSetting(); | ||
96 | } | 96 | } | ||
97 | 97 | | |||
98 | // try to extract the proper defaults file from a lookandfeel package | 98 | // try to extract the proper defaults file from a lookandfeel package | ||
99 | const QString looknfeel = readConfigValue(cg, QStringLiteral("LookAndFeelPackage"), defaultLookAndFeelPackage).toString(); | 99 | const QString looknfeel = readConfigValue(cg, QStringLiteral("LookAndFeelPackage"), defaultLookAndFeelPackage).toString(); | ||
100 | mDefaultLnfConfig = KSharedConfig::openConfig(QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("plasma/look-and-feel/") + looknfeel + QStringLiteral("/contents/defaults"))); | 100 | mDefaultLnfConfig = KSharedConfig::openConfig(QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("plasma/look-and-feel/") + defaultLookAndFeelPackage + QStringLiteral("/contents/defaults"))); | ||
101 | if (looknfeel != defaultLookAndFeelPackage) { | 101 | if (looknfeel != defaultLookAndFeelPackage) { | ||
102 | mLnfConfig = KSharedConfig::openConfig(QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("plasma/look-and-feel/") + defaultLookAndFeelPackage + QStringLiteral("/contents/defaults"))); | 102 | mLnfConfig = KSharedConfig::openConfig(QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("plasma/look-and-feel/") + looknfeel + QStringLiteral("/contents/defaults"))); | ||
103 | } | 103 | } | ||
104 | 104 | | |||
105 | const auto cursorBlinkRate = readConfigValue(cg, QStringLiteral("CursorBlinkRate"), 1000).toInt(); | 105 | const auto cursorBlinkRate = readConfigValue(cg, QStringLiteral("CursorBlinkRate"), 1000).toInt(); | ||
106 | m_hints[QPlatformTheme::CursorFlashTime] = cursorBlinkRate > 0 ? qBound(200, cursorBlinkRate, 2000) : 0; // 0 => no blinking | 106 | m_hints[QPlatformTheme::CursorFlashTime] = cursorBlinkRate > 0 ? qBound(200, cursorBlinkRate, 2000) : 0; // 0 => no blinking | ||
107 | m_hints[QPlatformTheme::MouseDoubleClickInterval] = readConfigValue(cg, QStringLiteral("DoubleClickInterval"), 400); | 107 | m_hints[QPlatformTheme::MouseDoubleClickInterval] = readConfigValue(cg, QStringLiteral("DoubleClickInterval"), 400); | ||
108 | m_hints[QPlatformTheme::StartDragDistance] = readConfigValue(cg, QStringLiteral("StartDragDist"), 10); | 108 | m_hints[QPlatformTheme::StartDragDistance] = readConfigValue(cg, QStringLiteral("StartDragDist"), 10); | ||
109 | m_hints[QPlatformTheme::StartDragTime] = readConfigValue(cg, QStringLiteral("StartDragTime"), 500); | 109 | m_hints[QPlatformTheme::StartDragTime] = readConfigValue(cg, QStringLiteral("StartDragTime"), 500); | ||
110 | 110 | | |||
▲ Show 20 Lines • Show All 411 Lines • Show Last 20 Lines |