| 4408 | }; |
| 4409 | |
| 4410 | void Clay_ApplyTransitionedPropertiesToElement(Clay_LayoutElement* currentElement, Clay_TransitionProperty properties, Clay_TransitionData currentTransitionData, Clay_BoundingBox* boundingBox, bool reparented) { |
| 4411 | if (properties & CLAY_TRANSITION_PROPERTY_WIDTH) { |
| 4412 | if (!reparented) { |
| 4413 | currentElement->dimensions.width = currentTransitionData.boundingBox.width; |
| 4414 | currentElement->config.layout.sizing.width = CLAY_SIZING_FIXED(currentTransitionData.boundingBox.width); |
| 4415 | } else { |
| 4416 | boundingBox->width = currentTransitionData.boundingBox.width; |
| 4417 | } |
| 4418 | } |
| 4419 | if (properties & CLAY_TRANSITION_PROPERTY_HEIGHT) { |
| 4420 | if (!reparented) { |
| 4421 | currentElement->dimensions.height = currentTransitionData.boundingBox.height; |
| 4422 | currentElement->config.layout.sizing.height = CLAY_SIZING_FIXED(currentTransitionData.boundingBox.height); |
| 4423 | } else { |
| 4424 | boundingBox->height = currentTransitionData.boundingBox.height; |
| 4425 | } |
| 4426 | } |
| 4427 | if (properties & CLAY_TRANSITION_PROPERTY_X) { |
| 4428 | boundingBox->x = currentTransitionData.boundingBox.x; |
| 4429 | } |
| 4430 | if (properties & CLAY_TRANSITION_PROPERTY_Y) { |
| 4431 | boundingBox->y = currentTransitionData.boundingBox.y; |
| 4432 | } |
| 4433 | if (properties & CLAY_TRANSITION_PROPERTY_OVERLAY_COLOR) { |
| 4434 | currentElement->config.overlayColor = currentTransitionData.overlayColor; |
| 4435 | } |
| 4436 | if (properties & CLAY_TRANSITION_PROPERTY_BACKGROUND_COLOR) { |
| 4437 | currentElement->config.backgroundColor = currentTransitionData.backgroundColor; |
| 4438 | } |
| 4439 | if (properties & CLAY_TRANSITION_PROPERTY_BORDER_COLOR) { |
| 4440 | currentElement->config.border.color = currentTransitionData.borderColor; |
| 4441 | } |
| 4442 | if (properties & CLAY_TRANSITION_PROPERTY_BORDER_WIDTH) { |
| 4443 | currentElement->config.border.width = currentTransitionData.borderWidth; |
| 4444 | } |
| 4445 | } |
| 4446 | |
| 4447 | CLAY_WASM_EXPORT("Clay_EndLayout") |
| 4448 | Clay_RenderCommandArray Clay_EndLayout(float deltaTime) { |