config: return windowrulev2 layerrulev2 error messages (#12847)
This commit is contained in:
parent
6fce2d7288
commit
9817553c66
1 changed files with 16 additions and 0 deletions
|
|
@ -399,6 +399,12 @@ static Hyprlang::CParseResult handleWindowrule(const char* c, const char* v) {
|
|||
return result;
|
||||
}
|
||||
|
||||
static Hyprlang::CParseResult handleWindowrulev2(const char* c, const char* v) {
|
||||
Hyprlang::CParseResult res;
|
||||
res.setError("windowrulev2 is deprecated. Correct syntax can be found on the wiki.");
|
||||
return res;
|
||||
}
|
||||
|
||||
static Hyprlang::CParseResult handleLayerrule(const char* c, const char* v) {
|
||||
const std::string VALUE = v;
|
||||
const std::string COMMAND = c;
|
||||
|
|
@ -411,6 +417,12 @@ static Hyprlang::CParseResult handleLayerrule(const char* c, const char* v) {
|
|||
return result;
|
||||
}
|
||||
|
||||
static Hyprlang::CParseResult handleLayerrulev2(const char* c, const char* v) {
|
||||
Hyprlang::CParseResult res;
|
||||
res.setError("layerrulev2 doesn't exist. Correct syntax can be found on the wiki.");
|
||||
return res;
|
||||
}
|
||||
|
||||
void CConfigManager::registerConfigVar(const char* name, const Hyprlang::INT& val) {
|
||||
m_configValueNumber++;
|
||||
m_config->addConfigValue(name, val);
|
||||
|
|
@ -871,6 +883,10 @@ CConfigManager::CConfigManager() {
|
|||
m_config->registerHandler(&::handleGesture, "gesture", {true});
|
||||
m_config->registerHandler(&::handleEnv, "env", {true});
|
||||
|
||||
// windowrulev2 and layerrulev2 errors
|
||||
m_config->registerHandler(&::handleWindowrulev2, "windowrulev2", {false});
|
||||
m_config->registerHandler(&::handleLayerrulev2, "layerrulev2", {false});
|
||||
|
||||
// pluginza
|
||||
m_config->addSpecialCategory("plugin", {nullptr, true});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue