diff --git a/kcmkwin/kwinrules/detectwidget.cpp b/kcmkwin/kwinrules/detectwidget.cpp
index dd3b6a3e1f..541407661e 100644
--- a/kcmkwin/kwinrules/detectwidget.cpp
+++ b/kcmkwin/kwinrules/detectwidget.cpp
@@ -85,7 +85,6 @@ void DetectDialog::readWindow(WId w)
| NET::ToolbarMask | NET::MenuMask | NET::DialogMask | NET::OverrideMask | NET::TopMenuMask
| NET::UtilityMask | NET::SplashMask);
title = info.name();
- extrarole = ""; // TODO
machine = info.clientMachine();
executeDialog();
}
@@ -116,7 +115,6 @@ void DetectDialog::executeDialog()
else
widget->type_label->setText(i18n(types[ type ]));
widget->title_label->setText(title);
- widget->extrarole_label->setText(extrarole);
widget->machine_label->setText(machine);
widget->adjustSize();
adjustSize();
diff --git a/kcmkwin/kwinrules/detectwidget.ui b/kcmkwin/kwinrules/detectwidget.ui
index 8647a86a64..ab7c6313b8 100644
--- a/kcmkwin/kwinrules/detectwidget.ui
+++ b/kcmkwin/kwinrules/detectwidget.ui
@@ -124,29 +124,6 @@
-
-
-
- Extra role:
-
-
- Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
-
-
- false
-
-
-
- -
-
-
-
-
-
- false
-
-
-
- -
Machine:
@@ -159,7 +136,7 @@
- -
+
-
@@ -169,7 +146,7 @@
- -
+
-
Match Strategy
@@ -221,7 +198,7 @@
- -
+
-
Qt::Vertical
diff --git a/kcmkwin/kwinrules/main.cpp b/kcmkwin/kwinrules/main.cpp
index 4f41b51f1e..598bd3f7d1 100644
--- a/kcmkwin/kwinrules/main.cpp
+++ b/kcmkwin/kwinrules/main.cpp
@@ -79,7 +79,6 @@ static Rules* findRule(const QList< Rules* >& rules, Window wid, bool whole_app)
| NET::ToolbarMask | NET::MenuMask | NET::DialogMask | NET::OverrideMask | NET::TopMenuMask
| NET::UtilityMask | NET::SplashMask);
QString title = info.name();
-// QCString extrarole = ""; // TODO
QByteArray machine = info.clientMachine().toLower();
Rules* best_match = NULL;
int match_quality = 0;
@@ -145,7 +144,6 @@ static Rules* findRule(const QList< Rules* >& rules, Window wid, bool whole_app)
ret->titlematch = Rules::UnimportantMatch;
ret->clientmachine = machine; // set, but make unimportant
ret->clientmachinematch = Rules::UnimportantMatch;
- ret->extrarolematch = Rules::UnimportantMatch;
ret->windowrolematch = Rules::UnimportantMatch;
if (wmclass_name == wmclass_class) {
ret->wmclasscomplete = false;
@@ -168,8 +166,6 @@ static Rules* findRule(const QList< Rules* >& rules, Window wid, bool whole_app)
ret->titlematch = Rules::UnimportantMatch;
ret->clientmachine = machine; // set, but make unimportant
ret->clientmachinematch = Rules::UnimportantMatch;
-// ret->extrarole = extra; TODO
- ret->extrarolematch = Rules::UnimportantMatch;
if (!role.isEmpty()
&& role != "unknown" && role != "unnamed") { // Qt sets this if not specified
ret->windowrole = role;
diff --git a/kcmkwin/kwinrules/ruleswidget.cpp b/kcmkwin/kwinrules/ruleswidget.cpp
index ac9ed86154..6630bed631 100644
--- a/kcmkwin/kwinrules/ruleswidget.cpp
+++ b/kcmkwin/kwinrules/ruleswidget.cpp
@@ -117,8 +117,13 @@ RulesWidget::RulesWidget(QWidget* parent)
SETUP(blockcompositing, force);
connect (title_match, SIGNAL(currentIndexChanged(int)), SLOT(titleMatchChanged()));
- connect (extra_match, SIGNAL(currentIndexChanged(int)), SLOT(extraMatchChanged()));
connect (machine_match, SIGNAL(currentIndexChanged(int)), SLOT(machineMatchChanged()));
+ connect (shortcut_edit, SIGNAL(clicked()), SLOT(shortcutEditClicked()));
+
+ edit_reg_wmclass->hide();
+ edit_reg_role->hide();
+ edit_reg_title->hide();
+ edit_reg_machine->hide();
int i;
for (i = 1;
@@ -412,9 +417,6 @@ void RulesWidget::setRules(Rules* rules)
title->setText(rules->title);
title_match->setCurrentIndex(rules->titlematch);
titleMatchChanged();
- extra->setText(rules->extrarole);
- extra_match->setCurrentIndex(rules->extrarolematch);
- extraMatchChanged();
machine->setText(rules->clientmachine);
machine_match->setCurrentIndex(rules->clientmachinematch);
machineMatchChanged();
@@ -510,8 +512,6 @@ Rules* RulesWidget::rules() const
}
rules->title = title->text();
rules->titlematch = static_cast< Rules::StringMatch >(title_match->currentIndex());
- rules->extrarole = extra->text().toUtf8();
- rules->extrarolematch = static_cast< Rules::StringMatch >(extra_match->currentIndex());
rules->clientmachine = machine->text().toUtf8();
rules->clientmachinematch = static_cast< Rules::StringMatch >(machine_match->currentIndex());
LINEEDIT_SET_RULE(position, strToPosition);
@@ -568,7 +568,6 @@ Rules* RulesWidget::rules() const
STRING_MATCH_COMBO(wmclass)
STRING_MATCH_COMBO(role)
STRING_MATCH_COMBO(title)
-STRING_MATCH_COMBO(extra)
STRING_MATCH_COMBO(machine)
#undef STRING_MATCH_COMBO
diff --git a/kcmkwin/kwinrules/ruleswidget.h b/kcmkwin/kwinrules/ruleswidget.h
index cb7b1f9195..224a5744b2 100644
--- a/kcmkwin/kwinrules/ruleswidget.h
+++ b/kcmkwin/kwinrules/ruleswidget.h
@@ -50,7 +50,6 @@ protected slots:
void wmclassMatchChanged();
void roleMatchChanged();
void titleMatchChanged();
- void extraMatchChanged();
void machineMatchChanged();
void shortcutEditClicked();
private slots:
diff --git a/kcmkwin/kwinrules/ruleswidgetbase.ui b/kcmkwin/kwinrules/ruleswidgetbase.ui
index 95a4c948a4..974ae6d946 100644
--- a/kcmkwin/kwinrules/ruleswidgetbase.ui
+++ b/kcmkwin/kwinrules/ruleswidgetbase.ui
@@ -226,59 +226,6 @@
-
-
-
- Extra role:
-
-
- Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
-
-
- false
-
-
- extra
-
-
-
- -
-
-
-
-
- Unimportant
-
-
- -
-
- Exact Match
-
-
- -
-
- Substring Match
-
-
- -
-
- Regular Expression
-
-
-
-
- -
-
-
- false
-
-
- Edit
-
-
-
-
-
-
- -
&Machine (hostname):
@@ -294,7 +241,7 @@
- -
+
-
-
@@ -318,7 +265,7 @@
- -
+
-
false
@@ -331,7 +278,7 @@
- -
+
-
Qt::Vertical
@@ -344,11 +291,8 @@
- -
-
-
-
-
+
-
@@ -2048,20 +1992,6 @@ like your complete screen area.
- -
-
-
- Qt::Horizontal
-
-
-
- -
-
-
- &Moving/resizing
-
-
-
-
@@ -2353,45 +2283,6 @@ while it's active!
- -
-
-
- false
-
-
-
-
- Opaque
-
-
- -
-
- Transparent
-
-
-
-
- -
-
-
- false
-
-
-
-
- Do Not Affect
-
-
- -
-
- Force
-
-
- -
-
- Force Temporarily
-
-
-
-
-
@@ -2511,6 +2402,59 @@ but this may sometimes fail or superact.
+ -
+
+
+ Qt::Horizontal
+
+
+
+ -
+
+
+ false
+
+
-
+
+ Do Not Affect
+
+
+ -
+
+ Force
+
+
+ -
+
+ Force Temporarily
+
+
+
+
+ -
+
+
+ false
+
+
-
+
+ Opaque
+
+
+ -
+
+ Transparent
+
+
+
+
+ -
+
+
+ &Moving/resizing
+
+
+
@@ -2519,9 +2463,9 @@ but this may sometimes fail or superact.
- KPushButton
- QPushButton
-
+ KComboBox
+ QComboBox
+
KLineEdit
@@ -2529,9 +2473,9 @@ but this may sometimes fail or superact.
- KComboBox
- QComboBox
-
+ KPushButton
+ QPushButton
+
KRestrictedLine
@@ -2558,9 +2502,6 @@ but this may sometimes fail or superact.
title_match
title
edit_reg_title
- extra_match
- extra
- edit_reg_extra
machine_match
machine
edit_reg_machine
diff --git a/rules.cpp b/rules.cpp
index d188202d69..52b32fefb0 100644
--- a/rules.cpp
+++ b/rules.cpp
@@ -41,7 +41,6 @@ Rules::Rules()
, wmclasscomplete(UnimportantMatch)
, windowrolematch(UnimportantMatch)
, titlematch(UnimportantMatch)
- , extrarolematch(UnimportantMatch)
, clientmachinematch(UnimportantMatch)
, types(NET::AllTypesMask)
, placementrule(UnusedForceRule)
@@ -137,7 +136,6 @@ void Rules::readFromCfg(const KConfigGroup& cfg)
wmclasscomplete = cfg.readEntry("wmclasscomplete" , false);
READ_MATCH_STRING(windowrole, .toLower().toLatin1());
READ_MATCH_STRING(title,);
- READ_MATCH_STRING(extrarole, .toLower().toLatin1());
READ_MATCH_STRING(clientmachine, .toLower().toLatin1());
types = cfg.readEntry("types", uint(NET::AllTypesMask));
READ_FORCE_RULE2(placement, QString(), Placement::policyFromString, false);
@@ -234,7 +232,6 @@ void Rules::write(KConfigGroup& cfg) const
cfg.writeEntry("wmclasscomplete", wmclasscomplete);
WRITE_MATCH_STRING(windowrole, (const char*), false);
WRITE_MATCH_STRING(title, , false);
- WRITE_MATCH_STRING(extrarole, (const char*), false);
WRITE_MATCH_STRING(clientmachine, (const char*), false);
if (types != NET::AllTypesMask)
cfg.writeEntry("types", uint(types));
@@ -423,7 +420,6 @@ bool Rules::match(const Client* c) const
return false;
if (!matchTitle(c->caption(false)))
return false;
- // TODO extrarole
if (!matchClientMachine(c->wmClientMachine(false)))
return false;
return true;
diff --git a/rules.h b/rules.h
index 9cda1cac65..0f988eeb06 100644
--- a/rules.h
+++ b/rules.h
@@ -195,8 +195,6 @@ private:
StringMatch windowrolematch;
QString title;
StringMatch titlematch;
- QByteArray extrarole;
- StringMatch extrarolematch;
QByteArray clientmachine;
StringMatch clientmachinematch;
unsigned long types; // types for matching