DesktopModeSettings

Per-site "open in desktop mode" preference, consumed by the browser. Callers pass a raw page url; the implementation derives the site key (eTLD+1, or the raw host when there is no registrable domain — IPs, localhost) internally, so call sites cannot disagree on the key.

Functions

Link copied to clipboard
abstract fun forgetDesktopMode(url: String)

Forget the desktop-mode preference for the site at url.

Link copied to clipboard
abstract suspend fun isDesktopModeRemembered(url: String): Boolean

Correct from the very first navigation: reads the in-memory cache and, only during the brief window before the cache is primed at startup, falls back to a direct DB read so a remembered site never loads in mobile mode by accident.

Link copied to clipboard

Synchronous, best-effort read for callers that cannot suspend. May be momentarily stale only during the startup priming window. It self-corrects on the next navigation event.

Link copied to clipboard
abstract fun rememberDesktopMode(url: String)

Remember that the site at url should always open in desktop mode.