From d773cc196eb63618fe0c426d4eafd7fe8ec69873 Mon Sep 17 00:00:00 2001
From: Richard Maudsley <richard.maudsley@isode.com>
Date: Thu, 23 Jan 2014 09:31:03 +0000
Subject: Fixed UI label description error.

Change-Id: I02fe9eaa34bea59f97803285c989a1e106472274

diff --git a/Swift/QtUI/QtHighlightEditor.cpp b/Swift/QtUI/QtHighlightEditor.cpp
index fcc0ef8..2221336 100644
--- a/Swift/QtUI/QtHighlightEditor.cpp
+++ b/Swift/QtUI/QtHighlightEditor.cpp
@@ -64,7 +64,7 @@ QtHighlightEditor::QtHighlightEditor(QtSettingsProvider* settings, QWidget* pare
 	connect(jid_, SIGNAL(textChanged(const QString&)), SLOT(widgetClick()));
 	connect(ui_.keywordRadio, SIGNAL(clicked()), SLOT(widgetClick()));
 	connect(ui_.keyword, SIGNAL(textChanged(const QString&)), SLOT(widgetClick()));
-	connect(ui_.matchWholeWords, SIGNAL(clicked()), SLOT(widgetClick()));
+	connect(ui_.matchPartialWords, SIGNAL(clicked()), SLOT(widgetClick()));
 	connect(ui_.matchCase, SIGNAL(clicked()), SLOT(widgetClick()));
 	connect(ui_.noColorRadio, SIGNAL(clicked()), SLOT(widgetClick()));
 	connect(ui_.defaultColorRadio, SIGNAL(clicked()), SLOT(widgetClick()));
@@ -321,11 +321,11 @@ void QtHighlightEditor::setChildWidgetStates()
 
 	if (ui_.keywordRadio->isChecked()) {
 		ui_.keyword->setEnabled(true);
-		ui_.matchWholeWords->setEnabled(true);
+		ui_.matchPartialWords->setEnabled(true);
 		ui_.matchCase->setEnabled(true);
 	} else {
 		ui_.keyword->setEnabled(false);
-		ui_.matchWholeWords->setEnabled(false);
+		ui_.matchPartialWords->setEnabled(false);
 		ui_.matchCase->setEnabled(false);
 	}
 
@@ -358,7 +358,7 @@ void QtHighlightEditor::disableDialog()
 	ui_.dummySenderName->setEnabled(false);
 	ui_.keywordRadio->setEnabled(false);
 	ui_.keyword->setEnabled(false);
-	ui_.matchWholeWords->setEnabled(false);
+	ui_.matchPartialWords->setEnabled(false);
 	ui_.matchCase->setEnabled(false);
 	ui_.noColorRadio->setEnabled(false);
 	ui_.defaultColorRadio->setEnabled(false);
@@ -448,7 +448,7 @@ HighlightRule QtHighlightEditor::ruleFromDialog()
 	}
 
 	rule.setNickIsKeyword(ui_.nickIsKeyword->isChecked());
-	rule.setMatchWholeWords(ui_.matchWholeWords->isChecked());
+	rule.setMatchWholeWords(!ui_.matchPartialWords->isChecked());
 	rule.setMatchCase(ui_.matchCase->isChecked());
 
 	HighlightAction& action = rule.getAction();
@@ -497,7 +497,7 @@ void QtHighlightEditor::ruleToDialog(const HighlightRule& rule)
 	ui_.allMsgRadio->setChecked(true); /* this is the default radio button */
 	jid_->setText("");
 	ui_.keyword->setText("");
-	ui_.matchWholeWords->setChecked(false);
+	ui_.matchPartialWords->setChecked(false);
 	ui_.matchCase->setChecked(false);
 
 	ui_.nickIsKeyword->setEnabled(true);
@@ -517,7 +517,7 @@ void QtHighlightEditor::ruleToDialog(const HighlightRule& rule)
 	if (!keywords.empty()) {
 		ui_.keywordRadio->setChecked(true);
 		ui_.keyword->setText(P2QSTRING(keywords[0]));
-		ui_.matchWholeWords->setChecked(rule.getMatchWholeWords());
+		ui_.matchPartialWords->setChecked(!rule.getMatchWholeWords());
 		ui_.matchCase->setChecked(rule.getMatchCase());
 	}
 
diff --git a/Swift/QtUI/QtHighlightEditor.ui b/Swift/QtUI/QtHighlightEditor.ui
index ad93ef9..e2fed46 100644
--- a/Swift/QtUI/QtHighlightEditor.ui
+++ b/Swift/QtUI/QtHighlightEditor.ui
@@ -216,7 +216,7 @@
                <widget class="QLineEdit" name="keyword"/>
               </item>
               <item>
-               <widget class="QCheckBox" name="matchWholeWords">
+               <widget class="QCheckBox" name="matchPartialWords">
                 <property name="text">
                  <string>Match keyword within longer words</string>
                 </property>
-- 
cgit v0.10.2-6-g49f6