Skip to content

Instantly share code, notes, and snippets.

@arriolac
Created October 10, 2023 17:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save arriolac/1c2e68575ff853f5451cb7e9f2ea4f58 to your computer and use it in GitHub Desktop.
Save arriolac/1c2e68575ff853f5451cb7e9f2ea4f58 to your computer and use it in GitHub Desktop.
// Copyright 2023 Google LLC.
// SPDX-License-Identifier: Apache-2.0
class DropDownCheckboxMenuView(context: Context) : View(context) {
/**
* The set of selected items in the menu
*/
fun setSelectedItems(items: Set<Int>) { /* ... */ }
/**
* Sets a listener to be invoked when items are toggled.
* When invoked, the caller can call `setSelectedItems` to reflect the updated
* set of selected items.
*/
fun setOnItemToggled(onItemToggled: (Boolean, Int) -> Unit) { /* ... */ }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment