mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-18 13:30:34 +01:00
Diagram editor : add dock widget for edit the current selection.
For the moment only work with element git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@3943 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -62,10 +62,15 @@ ElementSelectorWidget::~ElementSelectorWidget()
|
||||
* @param elmt
|
||||
*/
|
||||
void ElementSelectorWidget::showElement(Element *elmt) {
|
||||
if (showed_element) showed_element->setHighlighted(false);
|
||||
if (showed_element)
|
||||
{
|
||||
disconnect(showed_element, SIGNAL(destroyed()), this, SLOT(showedElementWasDeleted()));
|
||||
showed_element->setHighlighted(false);
|
||||
}
|
||||
elmt->diagram()->showMe();
|
||||
elmt->setHighlighted(true);
|
||||
showed_element = elmt;
|
||||
connect(showed_element, SIGNAL(destroyed()), this, SLOT(showedElementWasDeleted()));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -224,6 +229,14 @@ void ElementSelectorWidget::showElementFromList(const int i) {
|
||||
showElement(elements_list.at(i));
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief ElementSelectorWidget::showedElementWasDeleted
|
||||
* Set to nullptr the current showed element when he was deleted
|
||||
*/
|
||||
void ElementSelectorWidget::showedElementWasDeleted() {
|
||||
showed_element = nullptr;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief ElementSelectorWidget::filter
|
||||
* @return A stringlist with all available value
|
||||
|
||||
Reference in New Issue
Block a user