- // Declare the class variables.
- private lateinit var editBookmarkDatabaseViewListener: EditBookmarkDatabaseViewListener
-
- // Declare the class views.
- private lateinit var webpageFavoriteIconRadioButton: RadioButton
- private lateinit var nameEditText: EditText
- private lateinit var urlEditText: EditText
- private lateinit var folderSpinner: Spinner
- private lateinit var displayOrderEditText: EditText
- private lateinit var saveButton: Button
-
- // The public interface is used to send information back to the parent activity.
- interface EditBookmarkDatabaseViewListener {
- fun onSaveBookmark(dialogFragment: DialogFragment, selectedBookmarkDatabaseId: Int, favoriteIconBitmap: Bitmap)
- }
-
- override fun onAttach(context: Context) {
- // Run the default commands.
- super.onAttach(context)
-
- // Get a handle for edit bookmark database view listener from the launching context.
- editBookmarkDatabaseViewListener = context as EditBookmarkDatabaseViewListener
- }
-