Add InstantReplaces::Custom
This commit is contained in:
parent
30a82625a8
commit
c63139f7e7
2 changed files with 12 additions and 0 deletions
|
|
@ -959,6 +959,17 @@ const InstantReplaces &InstantReplaces::TextOnly() {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const InstantReplaces &InstantReplaces::Custom() {
|
||||||
|
static const auto result = [] {
|
||||||
|
auto result = InstantReplaces();
|
||||||
|
for (auto i = customReplacesMap.constBegin(), e = customReplacesMap.constEnd(); i != e; ++i) {
|
||||||
|
result.add(i.key(), i.value());
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}();
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
FlatInput::FlatInput(
|
FlatInput::FlatInput(
|
||||||
QWidget *parent,
|
QWidget *parent,
|
||||||
const style::FlatInput &st,
|
const style::FlatInput &st,
|
||||||
|
|
|
||||||
|
|
@ -43,6 +43,7 @@ struct InstantReplaces {
|
||||||
|
|
||||||
static const InstantReplaces &Default();
|
static const InstantReplaces &Default();
|
||||||
static const InstantReplaces &TextOnly();
|
static const InstantReplaces &TextOnly();
|
||||||
|
static const InstantReplaces &Custom();
|
||||||
|
|
||||||
int maxLength = 0;
|
int maxLength = 0;
|
||||||
Node reverseMap;
|
Node reverseMap;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue