| 383 | } |
| 384 | |
| 385 | void updateCanvasImpl() |
| 386 | { |
| 387 | clearCanvas(); |
| 388 | |
| 389 | // проходим по всем нодам и перерисовываем связи |
| 390 | for (auto& mNode : mNodes) |
| 391 | { |
| 392 | EnumeratorConnection node_point = mNode->getConnectionEnumerator(); |
| 393 | while (node_point.next()) |
| 394 | { |
| 395 | const MyGUI::IntCoord& coord_from = node_point->getAbsoluteCoord(); |
| 396 | EnumeratorConnection connect_point = node_point->getConnectionEnumerator(); |
| 397 | while (connect_point.next()) |
| 398 | { |
| 399 | const MyGUI::IntCoord& coord_to = connect_point->getAbsoluteCoord(); |
| 400 | |
| 401 | ConnectionInfo info( |
| 402 | coord_from.point() - mCanvas->getAbsolutePosition() + |
| 403 | MyGUI::IntPoint(coord_from.width / 2, coord_from.height / 2), |
| 404 | coord_to.point() - mCanvas->getAbsolutePosition() + |
| 405 | MyGUI::IntPoint(coord_to.width / 2, coord_to.height / 2), |
| 406 | MyGUI::Colour::White, |
| 407 | node_point->getOffset(), |
| 408 | connect_point->getOffset()); |
| 409 | |
| 410 | drawCurve(info); |
| 411 | } |
| 412 | } |
| 413 | } |
| 414 | |
| 415 | // ниточка для драга |
| 416 | if (mIsDrug) |
| 417 | drawCurve(mDrugLine); |
| 418 | } |
| 419 | |
| 420 | void connectPoint(BaseGraphConnection* _connection) |
| 421 | { |
nothing calls this directly
no test coverage detected