android-components / mozilla.components.browser.tabstray / TabViewHolder

TabViewHolder

class TabViewHolder : ViewHolder, Observer (source)

A RecyclerView ViewHolder implementation for “tab” items.

Constructors

Name Summary
<init> TabViewHolder(itemView: <ERROR CLASS>, tabsTray: BrowserTabsTray)
A RecyclerView ViewHolder implementation for “tab” items.

Functions

Name Summary
bind fun bind(session: Session, isSelected: Boolean, observable: Observable<Observer>): Unit
Displays the data of the given session and notifies the given observable about events.
onUrlChanged fun onUrlChanged(session: Session, url: String): Unit
unbind fun unbind(): Unit
The attached view no longer needs to display any data.

Inherited Functions

Name Summary
onAppPermissionRequested open fun onAppPermissionRequested(session: Session, permissionRequest: PermissionRequest): Boolean
onContentPermissionRequested open fun onContentPermissionRequested(session: Session, permissionRequest: PermissionRequest): Boolean
onCrashStateChanged open fun onCrashStateChanged(session: Session, crashed: Boolean): Unit
onCustomTabConfigChanged open fun onCustomTabConfigChanged(session: Session, customTabConfig: CustomTabConfig?): Unit
onDesktopModeChanged open fun onDesktopModeChanged(session: Session, enabled: Boolean): Unit
onFindResult open fun onFindResult(session: Session, result: FindResult): Unit
onFullScreenChanged open fun onFullScreenChanged(session: Session, enabled: Boolean): Unit
onLaunchIntentRequest open fun onLaunchIntentRequest(session: Session, url: String, appIntent: <ERROR CLASS>?): Unit
onLoadRequest open fun onLoadRequest(session: Session, url: String, triggeredByRedirect: Boolean, triggeredByWebContent: Boolean): Unit
onLoadingStateChanged open fun onLoadingStateChanged(session: Session, loading: Boolean): Unit
onLongPress open fun onLongPress(session: Session, hitResult: HitResult): Boolean
onMediaAdded open fun onMediaAdded(session: Session, media: List<Media>, added: Media): Unit
onMediaRemoved open fun onMediaRemoved(session: Session, media: List<Media>, removed: Media): Unit
onNavigationStateChanged open fun onNavigationStateChanged(session: Session, canGoBack: Boolean, canGoForward: Boolean): Unit
onProgress open fun onProgress(session: Session, progress: Int): Unit
onReaderModeChanged open fun onReaderModeChanged(session: Session, enabled: Boolean): Unit
onReaderableStateUpdated open fun onReaderableStateUpdated(session: Session, readerable: Boolean): Unit
onRecordingDevicesChanged open fun onRecordingDevicesChanged(session: Session, devices: List<RecordingDevice>): Unit
onSearch open fun onSearch(session: Session, searchTerms: String): Unit
onSecurityChanged open fun onSecurityChanged(session: Session, securityInfo: SecurityInfo): Unit
onThumbnailChanged open fun onThumbnailChanged(session: Session, bitmap: <ERROR CLASS>?): Unit
onTitleChanged open fun onTitleChanged(session: Session, title: String): Unit
onTrackerBlocked open fun onTrackerBlocked(session: Session, tracker: Tracker, all: List<Tracker>): Unit
onTrackerBlockingEnabledChanged open fun onTrackerBlockingEnabledChanged(session: Session, blockingEnabled: Boolean): Unit
onTrackerLoaded open fun onTrackerLoaded(session: Session, tracker: Tracker, all: List<Tracker>): Unit
onWebAppManifestChanged open fun onWebAppManifestChanged(session: Session, manifest: WebAppManifest?): Unit

Extension Functions

Name Summary
loadResourceAsString fun Any.loadResourceAsString(path: String): String
Loads a file from the resources folder and returns its content as a string object.