src/tools/selecttool.cpp

changeset 185
a38a0eb007b0
parent 163
36ea1a8aee33
equal deleted inserted replaced
184:35bbfad4d0f4 185:a38a0eb007b0
16 { 16 {
17 static const QString result = tr("Select elements from the model."); 17 static const QString result = tr("Select elements from the model.");
18 return result; 18 return result;
19 } 19 }
20 20
21 bool SelectTool::mouseClick(Document* document, Canvas* canvas, QMouseEvent* event) 21 bool SelectTool::mouseClick(Canvas* canvas, QMouseEvent* event)
22 { 22 {
23 if (event->button() == Qt::LeftButton) 23 if (event->button() == Qt::LeftButton)
24 { 24 {
25 static_cast<void>(document);
26 const ldraw::id_t highlighted = canvas->getHighlightedObject(); 25 const ldraw::id_t highlighted = canvas->getHighlightedObject();
27 canvas->clearSelection(); 26 canvas->clearSelection();
28 if (highlighted != ldraw::NULL_ID) 27 if (highlighted != ldraw::NULL_ID)
29 { 28 {
30 canvas->addToSelection(highlighted); 29 canvas->addToSelection(highlighted);

mercurial