All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.app.cash.redwood.layout.testing.MutableSpacer.kt Maven / Gradle / Ivy

There is a newer version: 0.14.0
Show newest version
@file:Suppress("DEPRECATION", "OVERRIDE_DEPRECATION")

package app.cash.redwood.layout.testing

import app.cash.redwood.Modifier
import app.cash.redwood.layout.widget.Spacer
import app.cash.redwood.testing.WidgetValue
import app.cash.redwood.ui.Dp
import kotlin.Suppress

internal class MutableSpacer : Spacer {
  override val `value`: WidgetValue
    get() = SpacerValue(
      modifier = modifier,
      width = width!!,
      height = height!!,
    )

  override var modifier: Modifier = Modifier

  private var width: Dp? = null

  private var height: Dp? = null

  override fun width(width: Dp) {
    this.width = width
  }

  override fun height(height: Dp) {
    this.height = height
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy