mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-03-21 17:34:57 -05:00
Add option to set enabled state for partial match regex config
This commit is contained in:
parent
9a4d2935f8
commit
140dc9c6f4
|
|
@ -79,11 +79,12 @@ bool RegexConfig::Matches(const std::string &text,
|
|||
QString::fromStdString(expression));
|
||||
}
|
||||
|
||||
RegexConfig RegexConfig::PartialMatchRegexConfig()
|
||||
RegexConfig RegexConfig::PartialMatchRegexConfig(bool enabled)
|
||||
{
|
||||
RegexConfig conf;
|
||||
conf._partialMatch = true;
|
||||
return conf;
|
||||
RegexConfig regex;
|
||||
regex._partialMatch = true;
|
||||
regex._enable = enabled;
|
||||
return regex;
|
||||
}
|
||||
|
||||
RegexConfigWidget::RegexConfigWidget(QWidget *parent, bool showEnable)
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ public:
|
|||
EXPORT bool Matches(const std::string &text,
|
||||
const std::string &expression) const;
|
||||
|
||||
EXPORT static RegexConfig PartialMatchRegexConfig();
|
||||
EXPORT static RegexConfig PartialMatchRegexConfig(bool enabled = false);
|
||||
|
||||
private:
|
||||
bool _enable = false;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user