- // Declare the class variables.
- private lateinit var createBookmarkFolderListener: CreateBookmarkFolderListener
-
- // The public interface is used to send information back to the parent activity.
- interface CreateBookmarkFolderListener {
- fun onCreateBookmarkFolder(dialogFragment: DialogFragment, favoriteIconBitmap: Bitmap)
- }
-
- override fun onAttach(context: Context) {
- // Run the default commands.
- super.onAttach(context)
-
- // Get a handle for the create bookmark folder listener from the launching context.
- createBookmarkFolderListener = context as CreateBookmarkFolderListener
- }
-