Changeset View
Changeset View
Standalone View
Standalone View
cursor.cpp
Show First 20 Lines • Show All 80 Lines • ▼ Show 20 Line(s) | 79 | if (!themeName.isEmpty() && ok) { | |||
---|---|---|---|---|---|
81 | return; | 81 | return; | ||
82 | } | 82 | } | ||
83 | // didn't get from environment variables, read from config file | 83 | // didn't get from environment variables, read from config file | ||
84 | loadThemeFromKConfig(); | 84 | loadThemeFromKConfig(); | ||
85 | } | 85 | } | ||
86 | 86 | | |||
87 | void Cursor::loadThemeFromKConfig() | 87 | void Cursor::loadThemeFromKConfig() | ||
88 | { | 88 | { | ||
89 | KConfigGroup mousecfg(KSharedConfig::openConfig("kcminputrc", KConfig::NoGlobals), "Mouse"); | 89 | KConfigGroup mousecfg(kwinApp()->inputConfig(), "Mouse"); | ||
90 | const QString themeName = mousecfg.readEntry("cursorTheme", "default"); | 90 | const QString themeName = mousecfg.readEntry("cursorTheme", "default"); | ||
91 | bool ok = false; | 91 | bool ok = false; | ||
92 | uint themeSize = mousecfg.readEntry("cursorSize", QString("24")).toUInt(&ok); | 92 | uint themeSize = mousecfg.readEntry("cursorSize", QString("24")).toUInt(&ok); | ||
93 | if (!ok) { | 93 | if (!ok) { | ||
94 | themeSize = 24; | 94 | themeSize = 24; | ||
95 | } | 95 | } | ||
96 | updateTheme(themeName, themeSize); | 96 | updateTheme(themeName, themeSize); | ||
97 | } | 97 | } | ||
▲ Show 20 Lines • Show All 347 Lines • Show Last 20 Lines |