mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-17 20:50:34 +01:00
Minor improvement and remove some use of ElementsCollectionItem and ElementsDefinition
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@4407 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -16,8 +16,6 @@
|
||||
along with QElectroTech. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include "diagrameventaddelement.h"
|
||||
#include "elementscollectionitem.h"
|
||||
#include "qetapp.h"
|
||||
#include "integrationmoveelementshandler.h"
|
||||
#include "elementfactory.h"
|
||||
#include "diagram.h"
|
||||
@@ -39,8 +37,7 @@ DiagramEventAddElement::DiagramEventAddElement(ElementsLocation &location, Diagr
|
||||
m_element(nullptr)
|
||||
{
|
||||
//Check if there is an element at this location
|
||||
ElementsCollectionItem *item = QETApp::collectionItem(location);
|
||||
if (item)
|
||||
if (location.isElement() && location.exist())
|
||||
{
|
||||
//location is an element, we build it, if build fail,
|
||||
//m_running stay to false (by default), so this interface will be deleted at next event
|
||||
|
||||
Reference in New Issue
Block a user