[qet] [3998] Element info widget: check box "show" work in live edit mode |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/qet Archives
]
Revision: 3998
Author: blacksun
Date: 2015-06-05 10:54:14 +0200 (Fri, 05 Jun 2015)
Log Message:
-----------
Element info widget: check box "show" work in live edit mode
Modified Paths:
--------------
trunk/sources/ui/elementinfopartwidget.cpp
trunk/sources/ui/elementinfopartwidget.h
trunk/sources/ui/elementinfowidget.cpp
Modified: trunk/sources/ui/elementinfopartwidget.cpp
===================================================================
--- trunk/sources/ui/elementinfopartwidget.cpp 2015-05-31 23:17:29 UTC (rev 3997)
+++ trunk/sources/ui/elementinfopartwidget.cpp 2015-06-05 08:54:14 UTC (rev 3998)
@@ -35,9 +35,9 @@
ui->label_->setText(translated_key);
if(key == "label") ui->checkBox->setChecked(true);
- connect(ui->line_edit, &QLineEdit::textEdited, this, &ElementInfoPartWidget::textEdited);
+ connect(ui->line_edit, &QLineEdit::textEdited, this, &ElementInfoPartWidget::textEdited);
connect(ui->line_edit, &QLineEdit::textChanged, this, &ElementInfoPartWidget::textChanged);
-
+ connect(ui->checkBox, &QCheckBox::clicked, this, &ElementInfoPartWidget::showClicked);
}
/**
Modified: trunk/sources/ui/elementinfopartwidget.h
===================================================================
--- trunk/sources/ui/elementinfopartwidget.h 2015-05-31 23:17:29 UTC (rev 3997)
+++ trunk/sources/ui/elementinfopartwidget.h 2015-06-05 08:54:14 UTC (rev 3998)
@@ -42,8 +42,9 @@
void setFocusTolineEdit();
signals:
- void textEdited (const QString & text);
- void textChanged(const QString & text);
+ void textEdited (const QString & text);
+ void textChanged (const QString & text);
+ void showClicked (bool checked);
//ATTRIBUTES
private:
Modified: trunk/sources/ui/elementinfowidget.cpp
===================================================================
--- trunk/sources/ui/elementinfowidget.cpp 2015-05-31 23:17:29 UTC (rev 3997)
+++ trunk/sources/ui/elementinfowidget.cpp 2015-06-05 08:54:14 UTC (rev 3998)
@@ -151,7 +151,10 @@
void ElementInfoWidget::enableLiveEdit()
{
foreach (ElementInfoPartWidget *eipw, m_eipw_list)
+ {
connect(eipw, &ElementInfoPartWidget::textChanged, this, &ElementInfoWidget::apply);
+ connect(eipw, &ElementInfoPartWidget::showClicked, this, &ElementInfoWidget::apply);
+ }
}
/**
@@ -161,7 +164,10 @@
void ElementInfoWidget::disableLiveEdit()
{
foreach (ElementInfoPartWidget *eipw, m_eipw_list)
+ {
disconnect(eipw, &ElementInfoPartWidget::textChanged, this, &ElementInfoWidget::apply);
+ disconnect(eipw, &ElementInfoPartWidget::showClicked, this, &ElementInfoWidget::apply);
+ }
}
/**