Commit 4d452a77 authored by Flavio TARSETTI's avatar Flavio TARSETTI
Browse files

[widget] added dirty flag signal and updated description label

parent 71baf4b3
......@@ -23,8 +23,9 @@
# #
###############################################################################
from PyQt5.QtCore import pyqtSignal
from PyQt5.QtWidgets import QLineEdit
from PyQt5.QtWidgets import QLabel
from PyQt5.QtWidgets import QWidget
from PyQt5.QtWidgets import QFormLayout
......@@ -32,16 +33,17 @@ from PyQt5.QtWidgets import QFormLayout
class DescriptionWidget(QWidget):
"""Class representing the short description of a beat object"""
data_changed = pyqtSignal()
def __init__(self, parent=None):
"""Constructor"""
super(DescriptionWidget, self).__init__(parent)
self.form_label = QLabel("Short Description:")
self.form_description = QLineEdit()
layout = QFormLayout(self)
layout.addRow(self.form_label, self.form_description)
layout.addRow(self.tr("Short Description:"), self.form_description)
@property
def short_description(self):
......@@ -52,3 +54,4 @@ class DescriptionWidget(QWidget):
@short_description.setter
def short_description(self, name):
self.form_description.setText(name)
self.data_changed.emit()
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment