mirror of
https://bitbucket.org/smil3y/kde-workspace.git
synced 2025-02-23 10:22:49 +00:00
kwin: minor KWin::Client::setShortcut() optimization
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
d16f960eaa
commit
0b0b9261e5
2 changed files with 4 additions and 3 deletions
|
@ -175,8 +175,9 @@ void ThumbnailAsideEffect::arrange()
|
|||
|
||||
void ThumbnailAsideEffect::repaintAll()
|
||||
{
|
||||
foreach (const Data & d, windows)
|
||||
foreach (const Data & d, windows) {
|
||||
effects->addRepaint(d.rect);
|
||||
}
|
||||
}
|
||||
|
||||
bool ThumbnailAsideEffect::isActive() const
|
||||
|
|
|
@ -1784,7 +1784,7 @@ void Client::setShortcut(const QString& _cut)
|
|||
}
|
||||
QList< KShortcut > keys;
|
||||
QStringList groups = cut.split(" - ");
|
||||
foreach (const QString it, groups) {
|
||||
foreach (const QString &it, groups) {
|
||||
QRegExp reg("(.*\\+)\\((.*)\\)");
|
||||
if (reg.indexIn(it) > -1) {
|
||||
QString base = reg.cap(1);
|
||||
|
@ -1804,7 +1804,7 @@ void Client::setShortcut(const QString& _cut)
|
|||
}
|
||||
}
|
||||
}
|
||||
foreach (const KShortcut it, keys) {
|
||||
foreach (const KShortcut &it, keys) {
|
||||
if (_shortcut == it) // current one is in the list
|
||||
return;
|
||||
if (workspace()->shortcutAvailable(it, this)) {
|
||||
|
|
Loading…
Add table
Reference in a new issue