| 1324 | Point ViewNode::convertParentVisualToSelfVisual(const Point& parentDirectionDependentVisual) const { |
| 1325 | auto directionDependentVisual = parentDirectionDependentVisual; |
| 1326 | directionDependentVisual -= getDirectionDependentTransform(); |
| 1327 | if (isInScrollMode()) { |
| 1328 | directionDependentVisual += _scrollState->getDirectionDependentContentOffset(); |
| 1329 | } |
| 1330 | return directionDependentVisual; |
| 1331 | } |
| 1332 | |
| 1333 | Point ViewNode::convertSelfVisualToRootVisual(const Point& selfDirectionDependentVisual) const { |
| 1334 | auto rootDirectionDependentVisual = selfDirectionDependentVisual; |
| 1335 | const auto* current = this; |
| 1336 | while (current != nullptr) { |
| 1337 | rootDirectionDependentVisual = current->convertSelfVisualToParentVisual(rootDirectionDependentVisual); |