+ switchPlain();
+}
+
+void TopicWidget::on_topicLineEdit_returnPressed() {
+ emit topicChanged(ui.topicLineEdit->text());
+ switchPlain();
+}
+
+void TopicWidget::on_topicButton_clicked() {
+ switchEditable();
+}
+
+void TopicWidget::switchEditable() {
+ ui.topicButton->hide();
+ ui.topicLineEdit->show();
+ ui.topicLineEdit->setFocus();
+}
+
+void TopicWidget::switchPlain() {
+ ui.topicLineEdit->hide();
+ ui.topicButton->show();
+ ui.topicLineEdit->setText(_topic);