Skip to content

Disable the button if location is not available #2982

@github-actions

Description

@github-actions

// TODO: Disable the button is location is not available.
// Issue URL: https://github.com/google/ground-android/issues/2982


  override fun onCreateActionButtons() {
    addSkipButton()
    addUndoButton()
    // TODO: Disable the button is location is not available.
    // Issue URL: https://github.com/google/ground-android/issues/2982
    addButton(ButtonAction.DROP_PIN)
      .setOnClickListener { viewModel.dropPin() }
      .setOnValueChanged { button, value -> button.showIfTrue(value.isNullOrEmpty()) }

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions