tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

changelog_archive.md (168835B)



layout: page title: Changelog Archive permalink: /changelog/archive


0.56.4

0.56.3

* Disabled periodic device event polling.

0.56.2

* Added endOfMenuAlwaysVisible property/parameter to BrowserMenuBuilder constructor and to BrowserMenu.show function. When is set to true makes sure the bottom of the menu is always visible, this allows use cases like #3211.

0.56.1

* FxaAccountManager will is now able to complete re-authentication flow after encountering an auth problem (e.g. password change) * FxaAccountManager will now attempt to automatically recover from a certain class of temporary auth problems. * FirefoxAccount grew a new method: checkAuthorizationStatusAsync, used to facilitate above flows. * It is no longer necessary to pass in the "profile" scope to FxaAccountManager, as it will always obtain it regardless. Specifying that scope has no effect. * ⚠️ This is a breaking change: FirefoxAccount methods that used to take Array<String> of scopes now take Set<String> of scopes.

0.56.0

* Switch FxA sample to production servers, fix pairing.

* FxaAccountManager will is now able to complete re-authentication flow after encountering an auth problem (e.g. password change) * FxaAccountManager will now attempt to automatically recover from a certain class of temporary auth problems. * FirefoxAccount grew a new method: checkAuthorizationStatusAsync, used to facilitate above flows. * It is no longer necessary to pass in the "profile" scope to FxaAccountManager, as it will always obtain it regardless. Specifying that scope has no effect. * ⚠️ This is a breaking change: FirefoxAccount methods that used to take Array<String> of scopes now take Set<String> of scopes.

* New domain autocomplete providers ShippedDomainsProvider and CustomDomainsProvider that should be used instead of deprecated DomainAutoCompleteProvider.

* The length limit on labels in labeled metrics has been increased from 30 to 61 characters. See 1556684. * Timespan metrics have a new API for setting the timespan directly: sumRawNanos and setRawNanos.

* Fixed multiple potential leaks in ObserverRegistry (used internally by many classes in other components like SessionManager, EngineSession and others).

* Fixed possible NullPointerException when disk cache is written to concurrently.

* Crash reports sent to Sentry now contain optional environment information, if a parameter is passed.

* ⚠️ This is a breaking change: Added url parameter to Session.Observer.onLoadRequest().

* ⚠️ This is a breaking change: Removed Drawable.toBitmap() in favour of the Android Core KTX version. * ⚠️ This is a breaking change: Removed Context.systemService() in favour of the Android Core KTX version.

* Added Session.hasParentSession to indicate whether a Session was opened from a parent Session such as opening a new tab from a link context menu ("Open in new tab").

* Add a flag to allow the app to not detect an external app if the user has told android to use the browser as default. * Turn off interception of web links.

0.55.0

* SearchEngineManager.load() is deprecated. Use SearchEngineManager.loadAsync() instead.

* Fixed a bug where overscroll effects would appear on the overflow menu. * Added enter and exit animations.

* Added handler for onWebAppManifestLoaded to update session.webAppManifest. * Moved WebAppManifest to concept-engine.

* Added onWebAppManifestLoaded to EngineSession, called when the engine finds a web app manifest. * Added WebAppManifest from browser-session.

* ⚠️ This is a breaking behavior change: API changes to facilitate error handling; new method on AccountObserver interface. * Added onAuthenticationProblems observer method, used for indicating that account needs to re-authenticate (e.g. after a password change). * FxaAccountManager gained a new method, accountNeedsReauth, that could be used for the same purpose. * DeviceConstellation methods that returned Deferred<Unit> now return Deferred<Boolean>, with a success flag. * OAuthAccount methods that returned Deferred values now have an Async suffix in their names. * OAuthAccount and DeviceConstellation methods that returned Deferred<T> (for some T) now return Deferred<T?>, where null means failure. * FirefoxAccount, FirefoxDeviceConstellation and FirefoxDeviceManager now handle all expected FxAException. * Fixes device name not changing in FxaDeviceConstellation after setDeviceNameAsync is called.

* Added EngineView.canScrollVerticallyUp() for pull to refresh. * Added engine API to clear browsing data.

* recordVisit and recordObservation will no longer throw when processing invalid URLs.

`kotlin // Clear all browsing data engine.clearData(BrowsingData.all())

// Clear all caches engine.clearData(BrowsingData.allCaches())

// Clear cookies only for the provided host engine.clearData(BrowsingData.select(BrowsingData.COOKIES), host = "mozilla.org") `

* Added EngineView.canScrollVerticallyUp() for pull to refresh.

* This component now has a hard dependency on the new universal GeckoView build that is no longer architecture specific (ARM, x86, ..). With that apps no longer need to specify the GeckoView build themselves and synchronize the used version with Android Components. Additionally apps can now make use of APK splits or Android App Bundles (AAB).

* Disabling telemetry through setUploadEnabled now clears all metrics (except firstrundate) immediately. * The string length limit for StringMetricType was raised from 50 to 100 characters.

* Added SwipeRefreshFeature which adds pull to refresh to browsers.

* Added option to remove all collections and their tabs: TabCollectionStorage.removeAllCollections().

* Added RecordingDevicesNotificationFeature to show an ongoing notification while recording devices (camera, microphone) are used by web content.

* 🆕 Added a new component for supporting push notifications.

* 🆕 Added a new component for Firebase Cloud Messaging push support.

`kotlin class FirebasePush : AbstractFirebasePushService() `

* In your Manifest you need to make the service visible:

`xml <service android:name=".FirebasePush"> <intent-filter> <action android:name="com.google.firebase.MESSAGING_EVENT" /> </intent-filter> </service> `

* Fixed a bug that caused the Sync Manager to crash on initial startup cases.

* 🆕 Added a new component for Autopush messaging support.

`kotlin class Application { override fun onCreate() { PushProcessor.install(services.push) } }

class Services { val push by lazy { val config = PushConfig( senderId = "my-app", serverHost = "push.services.mozilla.com", serviceType = ServiceType.FCM, protocol = Protocol.HTTPS )

// You need to use a supported push service (Firebase is one of them). val pushService = FirebasePush()

AutoPushFeature(context, pushService, config).also { it.initialize() } } }

class MyActivity { override fun onCreate() { services.push.registerForSubscriptions(object : PushSubscriptionObserver { override fun onSubscriptionAvailable(subscription: AutoPushSubscription) { } })

services.push.registerForPushMessages(PushType.Services, object: Bus.Observer<PushType, String> { override fun onEvent(type: PushType, message: String) { } }) } } `

* Checkout the component documentation for more details.

* Added Context.hasCamera() to check if the device has a camera.

0.54.0

* Merge day! * browser-engine-gecko-release: GeckoView 67.0 * browser-engine-gecko-beta: GeckoView 68.0 * browser-engine-gecko-nightly: GeckoView 69.0

* Added PocketEndpointRaw and PocketJSONParser for low-level access.

* Added BrowserMenuHighlightableItem. Its highlight property allows you to set the background and an image that appears on the right.

* Find in Page Bar now displays 0/0 for no matches found with new attr findInPageNoMatchesTextColor

* Fixed a bug where menu actions would not work for all Custom Tab sessions.

* Added testContext property for retrieving application context from tests.

* Added AllSessionsObserver helper that automatically subscribes and unsubscribes to all Session instances that get added/removed.

* Added Build object that contains information about the current Android Components build (like version number and git hash).

* Crash reports sent to Sentry now contain additional tags about the used Android Components version and setup (prefixed with "ac.").

* Fixed an issue where SuggestionProvider.onInputChanged() was called before SuggestionProvider.onInputStarted(). * Added ability for SuggestionProvider to return an initial list of suggestions from onInputStarted(). * Modified ClipboardSuggestionProvider to already return a suggestions from onInputStarted() if the clipboard contains a URL.

* 🆕 New component: to detect and open links in other non-browser apps. * Use cases to parse intent:// URLs, query the package manager for activities and generate Play store URLs.

* Added EngineSession.Observer.onRecordingStateChanged() to get list of recording devices currently used by web content.

* Added helper for providing unique stable Int notification ids based on a String tag to avoid id conflicts between components and app code.

`kotlin // Get a unique id for the provided tag val id = NotificationIds.getIdForTag(context, "mozac.my.feature")

// Extension methods for showing and cancelling notifications NotificationManagerCompat .from(context) .notify(context, "mozac.my.feature", notification)

NotificationManagerCompat .from(context) .cancel(context, "mozac.my.feature") `

0.53.0

* Added new policies for Safe Browsing: TrackingProtectionPolicy.SAFE_BROWSING_MALWARE, TrackingProtectionPolicy.SAFE_BROWSING_UNWANTED, TrackingProtectionPolicy.SAFE_BROWSING_PHISHING, TrackingProtectionPolicy.SAFE_BROWSING_HARMFUL and TrackingProtectionPolicy.SAFE_BROWSING_ALL. * Added a new policy category : trackingProtectionPolicy.recommended() contains all the recommended policies categories. It blocks ads, analytics, social, test trackers, plus all the safe browsing policies.

* ⚠️ This is a breaking behavior change: built-in WebView's on-screen zoom controls are hidden by default.

* Added disk cache for icons.

* Added EngineViewBottomBehavior: A CoordinatorLayout.Behavior implementation to be used with [EngineView] when placing a toolbar at the bottom of the screen. This implementation will update the vertical clipping of the EngineView so that bottom-aligned web content will be drawn above the browser toolbar. * New use case SettingsUseCases.UpdateTrackingProtectionUseCase: Updates Tracking Protection for the engine and all open sessions.

* Now input type file are working.

* Fixed a bug where the title and icon of a Session was cleared too early.

* Added ability to provide a custom SnackbarDelegate to show a customized Snackbar.

0.52.0

* ⚠️ This requires using the 1.3.30 Kotlin gradle plugin or higher.

* 🆕 New component: Feature implementation for saving, restoring and organizing collections of tabs.

* 🆕 New component/feature that provides reader mode functionality. To see a complete and working example of how to integrate this new component, check out the ReaderViewIntegration class in our Sample Browser. `kotlin val readerViewFeature = ReaderViewFeature(context, engine, sessionManager, controlsView) { available -> // This lambda is invoked to indicate whether or not reader view is available // for the page loaded by the selected session (for the current tab) }

// To activate reader view readerViewFeature.showReaderView()

// To deactivate reader view readerViewFeature.hideReaderView()

// To show the appearance (font, color scheme) controls readerViewFeature.showControls()

// To hide the appearance (font, color scheme) controls readerViewFeature.hideControls() `

* Fix disappearing title in Custom Tab toolbar.

* Added ability to configure default (checked/unchecked) state for "Remember decision" checkbox. Provide dialogConfig into SitePermissionsFeature for this. Checkbox is checked by default. * ⚠️ This is a breaking API change: anchorView property has been removed if you want to change the position of the prompts use the promptsStyling property. * Added new property context. It must be provided in the constructor. * Do not save new site permissions in private sessions. * Added sessionId property for adding site permissions on custom tabs. * Allow prompts styling via PromptsStyling `kotlin data class PromptsStyling( val gravity: Int, val shouldWidthMatchParent: Boolean = false, @ColorRes val positiveButtonBackgroundColor: Int? = null, @ColorRes val positiveButtonTextColor: Int? = null ) `

* Fix session not being removed when the close button was clicked.

* ⚠️ This is a breaking API change: Custom pings must be explicitly registered with Glean at startup time. See components/service/glean/docs/pings/custom.md for more information.

* Added an optional shouldAutoComplete boolean to setText which is currently used by updateUrl in EditToolbar.

* Modified EditToolbar's updateUrl function to take a shouldAutoComplete boolean. By default a call to this function does not autocomplete. Generally you want to disable autocomplete when calling updateUrl if the text is a search term. See editMode in BrowserToolbar and setText in InlineAutocompleteEditText for more information.

* Added support for Authentication dialogs on SystemEngineView.

* Added suspendMediaWhenInactive setting to control whether media should be suspended when the session is inactive. The default is false. `kotlin // To provide a default when creating the engine: GeckoEngine(runtime, DefaultSettings(suspendMediaWhenInactive = true))

// To change the value for a specific session: engineSession.settings.suspendMediaWhenInactive = true `

* ⚠️ This is a breaking API change: * OAuthAccount now has a new deviceConstellation method. * FxaAccountManager's constructor now takes a DeviceTuple parameter. * Added integration with FxA devices and device events. * First supported event type is Send Tab. * It's now possible to receive and send tabs from/to devices in the DeviceConstellation. * samples-sync application provides a detailed integration example of these new APIs. * Brief example: `kotlin val deviceConstellationObserver = object : DeviceConstellationObserver { override fun onDevicesUpdate(constellation: ConstellationState) { // Process the following: // constellation.currentDevice // constellation.otherDevices } } val deviceEventsObserver = object : DeviceEventsObserver { override fun onEvents(events: List<DeviceEvent>) { events.filter { it is DeviceEvent.TabReceived }.forEach { val tabReceivedEvent = it as DeviceEvent.TabReceived // process received tab(s). } } } val accountObserver = object : AccountObserver { // ... other methods ... override fun onAuthenticated(account: OAuthAccount) { account.deviceConstellation().registerDeviceObserver( observer = deviceConstellationObserver, owner = this@MainActivity, autoPause = true ) } } val accountManager = FxaAccountManager( this, Config.release(CLIENTID, REDIRECTURL), arrayOf("profile", "https://identity.mozilla.com/apps/oldsync"), DeviceTuple( name = "Doc Example App", type = DeviceType.MOBILE, capabilities = listOf(DeviceCapability.SEND_TAB) ), syncManager ) accountManager.register(accountObserver, owner = this, autoPause = true) accountManager.registerForDeviceEvents(deviceEventsObserver, owner = this, autoPause = true) `

* ⚠️ This is a breaking API change: * PromptFeature constructor adds an optional sessionId. This should use the custom tab session id if available.

* Added SessionManager.runWithSessionIdOrSelected(sessionId: String?) run function block on a session ID. If the session does not exist, then uses the selected session.

0.51.0

* Fixed an issue where new suggestions would leave you scrolled to the middle of the list

* Added %backButton% replacement for buttons that need the text "Go Back" instead of "Try Again"

* Fixed an issue causing Session.searchTerms getting cleared to early. Now the search terms will stay assigned to the Session until a new request, triggered by a user interaction like clicking a link, started loading (ignoring redirects). * Added setting of desktop view port when requesting desktop site

* Added fact emitting. * Bugfix to call with app-contributed pending intents from menu items and action buttons. * Added ability to decide where menu items requested by the launching app should be inserted into the combined menu by setting menuItemIndex

* ⚠️ This is a breaking API change: Timespan and timing distribution metrics now have a thread-safe API. See adding-new-metrics.md for more information. * A method for sending metrics on custom pings has been added. See docs/pings/custom.md for more information.

* Add boolean allowAutoplayMedia setting. * ⚠️ This is a breaking API change: * Added new method to HistoryTrackingDelegate interface: shouldStoreUri(uri: String): Boolean. * VisitType is now part of HistoryTrackingDelegate's onVisited method signature

* HistoryDelegate now implements a blocklist of URI schemas.

* Implement allowAutoplayMedia in terms of autoplayDefault. * ⚠️ This is a breaking API change * Added API for bidirectional messaging between Android and installed web extensions: `kotlin engine.installWebExtension(EXTENSIONID, EXTENSIONURL, onSuccess = { installedExt -> it } )

val messageHandler = object : MessageHandler { override fun onPortConnected(port: Port) { // Called when a port was connected as a result of a // browser.runtime.connectNative call in JavaScript. // The port can be used to send messages to the web extension: port.postMessage(jsonObject) }

override fun onPortDisconnected(port: Port) { // Called when the port was disconnected or the corresponding session closed. }

override fun onPortMessage(message: Any, port: Port) { // Called when a message was received on the provided port as a // result of a call to port.postMessage in JavaScript. }

override fun onMessage(message: Any, source: EngineSession?): Any { // Called when a message was received as a result of a // browser.runtime.sendNativeMessage call in JavaScript. } }

// To listen to message events from content scripts call: installedExt.registerContentMessageHandler(session, EXTENSION_ID, messageHandler)

// To listen to message events from background scripts call: installedExt.registerBackgroundMessageHandler(EXTENSION_ID, messageHandler) `

* Added an in-memory caching mechanism reducing disk/network loads.

* Add TabThumbnailView to Tabs Tray show the top of the thumbnail and fill up the width of the tile. * Added swipe gesture support with a TabTouchCallback for the TabsTray.

* ⚠️ This is a breaking API change * Added new method getVisitsPaginated; use it to paginate history. * Added excludeTypes param to getDetailedVisits; use it to query only subsets of history. * Added new getBookmarksWithUrl method for checking if a site is already bookmarked * Added new getBookmark method for obtaining the details of a single bookmark by GUID

* PlacesBookmarksStorage now supports synchronization!

* Add URLStringUtils to unify parsing of strings that may be URLs.

- Add URLStringUtils isURLLike() and toNormalizedURL(). - Update the implementation for String.isUrl() and String.toNormalizedUrl() to the new one above.

* ⚠️ This is a breaking API change * OAuthAccount now has a new method registerPersistenceCallback.

* FxaAccountManager is now using a state persistence callback to keep FxA account state up-to-date as it changes.

0.50.0

* Added titleView to DisplayToolbar which displays the title of the page. Various options are able to modified such as titleTextSize, titleColor, and displayTitle. In custom tabs, the URL will now only display the hostname. * Changed UrlRenderConfiguration to include a RenderStyle parameter where you can specify how the URL renders

* Added extension property Uri.isHttpOrHttps.

* ⚠️ This is a breaking API change: Creating a BrowserIcons instance requires a Client object (from concept-fetch) now.

* Added new content blocking category for fingerprinting: TrackingProtectionPolicy.FINGERPRINTING.

* Find in Page now emits facts

* Added BookmarksStorageSuggestionProvider

* Adds browserToolbarProgressBarGravity attr with options top and bottom (default). * Adds the ability to long click the urlView

* ⚠️ This is a breaking API change: The technically public, but not intended for public use, part of the glean API has been renamed from mozilla.components.service.glean.metrics to mozilla.components.service.glean.private. * ⚠️ This is a breaking API change: Labeled metrics are now their own distinct metric types in the metrics.yaml file. For example, for a labeled counter, rather than using type: counter and labeled: true, use type: labeled_counter. See bugzilla 1540725.

* Adds automaticLanguageAdjustment setting, which should hint to implementations to send language specific headers to websites. Implementation in browser-engine-gecko-nightly.

* The service no longer accepts a successPath option. Instead the service uses the OAuth redirectUri.

* Added optional callback to Consumable to get invoked once value gets consumed:

`kotlin val consumable = Consumable.from(42) { // Value got consumed. } `

0.49.0

* Clicking on a context menu item now emits a fact

* DefaultSuggestionViewHolder now centers titles if no description is provided by the suggestion.

* Added automaticFontSizeAdjustment engine setting for automatic font size adjustment, in line with system accessibility settings. The default is true. `kotlin GeckoEngine(runtime, DefaultSettings(automaticFontSizeAdjustment = true)) `

* Added optional icon parameter to SearchSuggestionProvider

* 🆕 New component/feature that provides functionality for scanning QR codes.

`kotlin val qrFeature = QrFeature( context, fragmentManager = supportFragmentManager, onNeedToRequestPermissions = { permissions -> requestPermissions(this, permissions, REQUESTCODECAMERA_PERMISSIONS) }, onScanResult = { qrScanResult -> // qrScanResult is a String (e.g. a URL) returned by the QR scanner } ) // When ready to scan simply call qrFeature.scan() `

* ⚠️ This is a breaking API change! for non-component implementations of HistoryStorage. * HistoryStorage got new API: deleteVisit.

* Imported list.json and search plugins from Fennec from 2019-03-29. * Added support for searchDefault and searchOrder. * ⚠️ This is a breaking API change: SearchEngineProvider.loadSearchEngines returns a new data class SearchEngineList (was List<SearchEngine>).

* Implementations of concept-storage/HistoryStorage expose newly added deleteVisit.

* Add TalkBack support for page load status. * Added option to add "edit actions" that will show up next to the URL in edit mode. * Added option to set a listener for clicks on the site security indicator (globe / lock icon). * The toolbar now emits a fact COMMIT when the user has edited the URL. More information.

* Added new TrackingProtectionPolicy category for blocking cryptocurrency miners (TrackingProtectionPolicy.CRYPTOMINING).

* Added Intent.toSafeIntent(). * Added MotionEvent.use {} (like AutoCloseable.use {}). * Added Bitmap.arePixelsAllTheSame(). * Added Context.appName returns the name (label) of the application or the package name as a fallback.

* Added support for interceptors. Interceptors are a powerful mechanism to monitor, modify, retry, redirect or record requests as well as responses going through a Client. See the concept-fetch README for example implementations of interceptors.

* browser-engine-gecko-nightly: EngineSession.Observer.onCrashStateChange() gets invoked if the content process of a session crashed. Internally a new GeckoSession will be created. By default this new session will just render a white page (about:blank) and not recover the last state. This prevents crash loops and let's the app decide (and show UI) when to restore. Calling EngineSession.recoverFromCrash() will try to restore the last known state from before the crash. * browser-session: Session.crashed now exposes if a Session has crashed. * feature-session: New use case: SessionUseCases.CrashRecoveryUseCase.

0.48.0

* Merge day! * browser-engine-gecko-release: GeckoView 66.0 * browser-engine-gecko-beta: GeckoView 67.0 * browser-engine-gecko-nightly: GeckoView 68.0

* Session now exposes a list of Media instances representing playable media on the currently displayed page (see concept-engine).

* Added Media class representing a playable media element on the the currently displayed page. Consumers can subscribe to Media instances in order to receive updates whenever the state of a Media object changes. Currently only the "playback state" is exposed. Consumers can control playback through the attached Media.Controller instance.

* ⚠️ This is a breaking API change!: Headers.Common was renamed to Headers.Names. * Added Headers.Values.

* Access an article's text-to-speech listen metadata via PocketListenEndpoint.getListenArticleMetadata. * ⚠️ This is a breaking API change!: PocketGlobalVideoRecommendation.id is now a Long instead of an Int

* GeckoEngine will throw a RuntimeException if the GeckoRuntime shuts down unsolicited.

* SearchSuggestionProvider and AwesomeBarFeature now allow setting a search suggestion limit.

* ⚠️ This is a breaking API change!: FindInPageFeature constructor now takes an EngineView instance. * Blur controlled EngineView for better screen reader accessibility. * Announce result count for screen reader users.

* Added ViewMatchers that take Boolean arguments instead of requiring inversion via the not Matcher: e.g. hasFocus(false) instead of not(hasFocus()) * Added ViewInteraction extension functions like assertHasFocus(Boolean) for short-hand. * Added Matchers.maybeInvertMatcher to optionally apply not based on the Boolean argument * Added ViewInteraction.click() extension function for short-hand.

* ⚠️ This is a breaking API change!: Configuration now accepts a Lazy<Client> to make sure the HTTP client (lib) is initialized lazily. `kotlin val config = Configuration(httpClient = lazy { GeckoViewFetchClient(context, GeckoRuntime()) }) Glean.initialize(context, config) `

* Added API to start an FxA pairing flow. See FirefoxAccountsAuthFeature.beginPairingAuthentication and FxaAccountsManager.beingAuthentication respectively.

* ⚠️ This is a breaking API change! for non-component implementations of HistoryStorage. * HistoryStorage got new APIs: deleteEverything, deleteVisitsSince, deleteVisitsBetween, deleteVisitsFor, prune and runMaintenance. * Added BookmarksStorage for handling the saving, searching, and management of browser bookmarks.

* Implementations of concept-storage/HistoryStorage expose the newly added APIs.

* Implementations of concept-storage/BookmarksStorage expose the newly added APIs.

0.47.0

* Added Session.webAppManifest to expose the Web App Manifest of the currently visible page. This functionality will only be available in GeckoView-flavored concept-engine implementations. * Added WebAppManifestParser to create WebAppManifest from JSON.

* Added TwoStateButton in BrowserMenuItemToolbar that will change resources based on the isInPrimaryState lambda and added ability to disable the button with optional disableInSecondaryState argument.

* Adds onCancelEditing to onEditListener in BrowserToolbar which is fired when a back button press occurs while the keyboard is displayed. This is especially useful if you want to call activity.onBackPressed() to navigate away rather than just dismiss the keyboard. Its return value is used to determine if displayMode will switch from edit to view.

* 🆕 New component which describes sync-related interfaces, such as SyncManager, SyncableStore, SyncStatusObserver and others.

* ⚠️ This is a breaking API change!: Removed sync-related interfaces. See concept-sync. * HistoryStorage interface has a new method: getDetailedVisits(start, end) -> List<VisitInfo>. It provides detailed information about page visits (title, visit type, timestamp, etc).

* Added implementations for the new getDetailedVisits API from concept-storage.

* ⚠️ This is a breaking API change! Complete overhaul of this component. * Added BackgroundSyncManager, a WorkManager-based implementation of the SyncManager defined in concept-sync. * An instance of a SyncManager is an entry point for interacting with background data synchronization. * See component's README for usage details.

* ⚠️ This is a breaking API change: The `captureThumbnail` function has been moved to `EngineView`. From now on for taking screenshots automatically you will have to opt-in by using ThumbnailsFeature. The decision was made to reduce overhead memory consumption for apps that are not using screenshots. Find more info in feature-session and a practical example can be found in the sample-browser project.

* Saving, restoring and removing SessionBundle instances need to happen on a worker thread now (off the main thread). * The actual session state is now saved on the file system outside of the internally used SQLite database.

* Added File.truncateDirectory() to remove all files (and sub directories) in a directory. * Added Activity.applyOrientation(manifest: WebAppManifest) extension method for applying orientation modes #2291. * Added Context.isMainProcess and Context.runOnlyInMainProcess(block: () -> Unit) to detect when you're running on the main process.

      // true if we are running in the main process otherwise false .
      val isMainProcess = context.isMainProcess()

      context.runOnlyInMainProcess {
            /* This function is only going to run if we are
                in the main process, otherwise it won't be executed.  */
       }

* 🆕 New component that provides functionality for supporting Progressive Web Apps (PWA).

* Adds support for the picture-in-picture mode in PictureInPictureFeature.

* Changed how Rust Places database connections are maintained, based on new reader/writer APIs.

* Access the list of global video recommendations via PocketEndpoint.getGlobalVideoRecommendations.

* Added common HTTP header constants in Headers.Common. This collection is incomplete: add your own!

0.46.0

* Adds ability to remove SuggestionProviders with removeProviders and removeAllProviders

* ⚠️ This is a breaking API change!: Removed redundant BrowserMenuImageText contentDescription * Adds textSize parameter to SimpleBrowserMenuItem

* ⚠️ This is a breaking API change: the `Response` properties .success and .clientError were renamed to .isSuccess and isClientError respectively to match Java conventions.

* Fixing bug #2265. In some occasions, when trying to download a file, the download failed and the download notification shows "Unsuccessful download".

* Adds default search engine var to SearchEngineManager * Adds optional SearchEngine to invoke() in SearchUseCases

* A new client-side experiments SDK for running segmenting user populations to run multi-branch experiments on them. This component is going to replace service-fretboard. The SDK is currently in development and the component is not ready to be used yet.

* Adding a decoder for decoding ICO files see #2040.

* 🆕 New component to interact with the Pocket APIs.

0.45.0

* 0.18.0 release notes

* Added API to install web extensions:

`kotlin val borderify = WebExtension("borderify", "resource://android/assets/extensions/borderify/") engine.installWebExtension(borderify) { ext, throwable -> Log.log(Log.Priority.ERROR, "MyApp", throwable, "Failed to install ${ext.id}") } `

* Added newPrivateTabSearch NewTabSearchUseCase

* Added ability to color parts of the domain (e.g. registrable domain) by providing a UrlRenderConfiguration:

`kotlin ToolbarFeature( // ... ToolbarFeature.UrlRenderConfiguration( publicSuffixList, // Use a shared global instance registrableDomainColor = 0xFFFF0000.toInt(), urlColor = 0xFF00FF00.toInt() ) `

* BrowserToolbar cancelView is now clearView with new text clearing behavior and color attribute updated from browserToolbarCancelColor to browserToolbarClearColor

* ⚠️ This is a breaking API change: AwesomeBar.Suggestion instances must now declare the provider that created them.

* BrowserAwesomeBar is now replacing suggestions "in-place" if their ids match. Additionally BrowserAwesomeBar now automatically scrolls to the top whenever the entered text changes.

* Now returns false in onBackPressed() if feature is not initialized

* 🆕 New component to be used for helpers used in instrumented (on device) tests (src/androidTest). This component complements support-test which is focused on helpers used in local unit tests (src/test). * Added helper LiveData.awaitValue() which subscribes to the LiveData object and blocks until a value was observed. Returns the value or throws an InterruptedException if no value was observed (customizable timeout).

* Added optional since parameter to SessionBundleStorage.bundles() and SessionBundleStorage.bundlesPaged().

0.44.0

* Added option to set background color by overriding mozac_browser_menu_background color resource.

`xml <color name="mozacbrowsermenubackground">DESIREDCOLOR</color> ` OR `xml <style name="Mozac.Browser.Menu" parent="" tools:ignore="UnusedResources"> <item name="cardBackgroundColor">YOUR_COLOR</item> </style> `

* Added option to style SimpleBrowserMenuItem and BrowserMenuImageText with textColorResource.

* Added option to configure fading edge length by using browserToolbarFadingEdgeSize XML attribute. * Added BrowserToolbar attribute browserToolbarCancelColor to color the cancel icon.

* ToolbarPresenter now handles situations where no Session is selected.

* Intent processor now lets you set isPrivate which will open process intents as private tabs

* ⚠️ This is a breaking API change! * Now makes use of our concept-fetch module when communicating with the server. This allows applications to specify which HTTP client library to use e.g. apps already using GeckoView can now specify that the GeckoViewFetchClient should be used. As a consequence, the fetch client instance now needs to be provided when creating a KintoExperimentSource.

`kotlin val fretboard = Fretboard( KintoExperimentSource( baseUrl, bucketName, collectionName, // Specify that the GV-based fetch client should be used. GeckoViewFetchClient(context) ), experimentStorage ) `

* Added SessionBundleStorage.autoClose(): When "auto close" is enabled the currently active SessionBundle will automatically be closed and a new SessionBundle will be started if the bundle lifetime expires while the app is in the background.

* Fixed an issue that caused autofill to not work with those components.

* 🆕 A feature for showing site permission request prompts. For more info take a look at the docs.

* Added SelectionAwareSessionObserver.observeIdOrSelected(sessionId: String?) to observe the session based on a session ID. If the session does not exist, then observe the selected session.

0.43.0

* Added support for JavaScript confirm alerts on WebView.

* 🆕 New component for loading and storing website icons (like Favicons). * Supports generating a "fallback" icon if no icon could be loaded.

* Added API to specify whether or not cookies should be sent with a request. This can be controlled using the cookiePolicy parameter when creating a Request.

`kotlin // Do not send cookies with this request client.fetch(Request(url, cookiePolicy = CookiePolicy.OMIT)).use { response -> val body = response.body.string() } ` * Added flag to specify whether or not caches should be used. This can be controlled with the useCaches parameter when creating a Request.

`kotlin // Force a network request (do not use cached responses) client.fetch(Request(url, useCaches = false)).use { response -> val body = response.body.string() } `

* ⚠️ This is a breaking API change! * Now makes use of our concept-fetch module when fetching search suggestions. This allows applications to specify which HTTP client library to use e.g. apps already using GeckoView can now specify that the GeckoViewFetchClient should be used. As a consequence, the fetch client instance now needs to be provided when adding a search provider.

`kotlin AwesomeBarFeature(layout.awesomeBar, layout.toolbar, layout.engineView) .addHistoryProvider(components.historyStorage, components.sessionUseCases.loadUrl) .addSessionProvider(components.sessionManager, components.tabsUseCases.selectTab) .addSearchProvider( components.searchEngineManager.getDefaultSearchEngine(requireContext()), components.searchUseCases.defaultSearch, // Specify that the GV-based fetch client should be used. GeckoViewFetchClient(context)) `

* Added DoorhangerPrompt - a builder for creating a prompt Doorhanger providing a way to present decisions to users.

* Ignoring schemes that are not https or http #issue 554

* Added Uri.hostWithoutCommonPrefixes to return the host with common prefixes removed:

`kotlin "https://www.mozilla.org" .toUri() .hostWithoutCommonPrefixes // mozilla.org

"https://mobile.twitter.com/home" .toUri() .hostWithoutCommonPrefixes // twitter.com

"https://m.facebook.com/" .toUri() .hostWithoutCommonPrefixes `

ℹ️ Note that this method only strips common prefixes like "www", "m" or "mobile". If you are interested in extracting something like the eTLD from a host then use PublicSuffixList of the lib-publicsuffixlist component.

* Added String.toUri() as a shorthand for Uri.parse() and in addition to other to*() methods already available in the Kotlin Standard Library.

* Added Browsers utility class for collecting and analyzing information about installed browser applications.

* SessionStorage and SessionBundleStorage now save and restore the title of Session objects. * SessionManager.restore() now allows passing in empty snapshots.

* Empty snapshots are no longer saved in the database: * If no restored bundle exists then no new bundle is saved for an empty snapshot. * If there is an active bundle then the bundle will be removed instead of updated with the empty snapshot.

* ⚠️ This is a breaking API change: The interface of the "URL commit listener" changed from (String) -> Unit to (String) -> Boolean. If the function returns true then the toolbar will automatically switch to "display mode". If no function is set or if the function returns false the toolbar remains in "edit mode". * Added private field (Boolean): Enables/Disables private mode. In private mode the IME should not update any personalized data such as typing history and personalized language model based on what the user typed. * The background and foreground color of the autocomplete suggestion can now be styled:

`xml <mozilla.components.browser.toolbar.BrowserToolbar ... app:browserToolbarSuggestionBackgroundColor="#ffffcc00" app:browserToolbarSuggestionForegroundColor="#ffff4444"/> `

0.42.0

* Now also serves as an implementation of concept-fetch by providing the new GeckoViewFetchClient. This allows applications to rely on Gecko's networking capabilities when issuing HTTP requests, even outside the browser view (GeckoView).

* Added support for JavaScript Confirm dialogs.

* Fixed an issue causing EngineViewPresenter to render a selected Session even though it was configured to show a fixed Session. This issue caused a crash (IllegalStateException: Display already acquired) in the Reference Browser when a "Custom Tab" and the "Browser" tried to render the same Session. * Fixed an issue where back and forward button handling would not take place on the session whose ID was provided.

* Added SearchUseCases.NewTabSearchUseCase and interface SearchUseCase (implemented by DefaultSearchUseCase and NewTabSearchUseCase).

* Added support for JavaScript prompt alerts on WebView.

* Fixed an issue causing the closeListener to be invoked even when the current session isn't a Custom Tab. * Fixed an issue with the image resources in the toolbar were not tinted when an app provided a light colour for the background.

* Added ViewBoundFeatureWrapper for wrapping LifecycleAwareFeature references that will automatically be cleared if the provided View gets detached. This is helpful for fragments that want to keep a reference to a LifecycleAwareFeature (e.g. to be able call onBackPressed()) that itself has strong references to View objects. In cases where the fragment gets detached (e.g. to be added to the backstack) and the View gets detached (and destroyed) the wrapper will automatically stop the LifecycleAwareFeature and clear all references.. * Added generic BackHandler interface for fragments, features and other components that want to handle 'back' button presses.

* 🆕 New component: A Doorhanger is a floating heads-up popup that can be anchored to a view. They are presented to notify the user of something that is important (e.g. a content permission request).

* 🆕 New component: A feature that will subscribe to the selected session, and will provide an UI for all the incoming appPermission and contentPermission request.

0.41.0

* 0.15.0 release notes

* Tweaked NestedGeckoView to "stick" to AppBar in nested scroll, like other Android apps. This is possible after a fix in APZ gesture detection.

* Added BrowserToolbar attributes to color the menu.

`xml <mozilla.components.browser.toolbar.BrowserToolbar android:id="@+id/toolbar" android:layoutwidth="matchparent" android:layout_height="56dp" android:background="#aaaaaa" app:browserToolbarMenuColor="@color/photonBlue50" app:browserToolbarInsecureColor="@color/photonRed50" app:browserToolbarSecureColor="@color/photonGreen50" /> `

* Fixed Context Menus feature to work with Custom Tabs by passing in the session ID when applicable.

* Added a temporary workaround for Custom Tab intents not being recognized when using the Jetifier tool.

* ⚠️ This is a breaking API change! * The required permissions are now passed to the onNeedToRequestPermissions callback.

`kotlin downloadsFeature = DownloadsFeature( requireContext(), sessionManager = components.sessionManager, fragmentManager = childFragmentManager, onNeedToRequestPermissions = { permissions -> requestPermissions(permissions, REQUESTCODEDOWNLOAD_PERMISSIONS) } ) `

* Removed the onPermissionsGranted method in favour of onPermissionsResult which handles both granted and denied permissions. This method should be invoked from onRequestPermissionsResult:

`kotlin override fun onRequestPermissionsResult(requestCode: Int, permissions: Array<String>, grantResults: IntArray) { when (requestCode) { REQUESTCODEDOWNLOAD_PERMISSIONS -> downloadsFeature.onPermissionsResult(permissions, grantResults) } } `

* Fixed Downloads feature to work with Custom Tabs by passing in the session ID when applicable.

* feature-prompts * ⚠️ This is a breaking API change! * These change are similar to the ones for feature-downloads above and aim to provide a consistent way of handling permission requests. * The required permissions are now passed to the onNeedToRequestPermissions callback.

`kotlin promptFeature = PromptFeature( fragment = this, sessionManager = components.sessionManager, fragmentManager = requireFragmentManager(), onNeedToRequestPermissions = { permissions -> requestPermissions(permissions, REQUESTCODEPROMPT_PERMISSIONS) } ) `

* Renamed onRequestsPermissionsResult to onPermissionResult and allow applications to specify the permission request code. This method should be invoked from onRequestPermissionsResult:

`kotlin override fun onRequestPermissionsResult(requestCode: Int, permissions: Array<String>, grantResults: IntArray) { when (requestCode) { REQUESTCODEDOWNLOAD_PERMISSIONS -> downloadsFeature.onPermissionsResult(permissions, grantResults) } } `

* The component is now performing haptic feedback when showing a context menu.

* After "Merge Day" and the release of Firefox 65 we updated our gecko-based components to follow the new upstream versions: * browser-engine-gecko: 65.0 * browser-engine-gecko-beta: 66.0 * browser-engine-gecko-nightly: 67.0

* Toolbar URL autocompletion is now performed off the UI thread.

* ⚠️ This is a breaking API change! * HistoryAutocompleteResult now includes an input field.

* ⚠️ This is a breaking API change! * DomainAutocompleteResult now includes an input field.

0.40.0

* Added Lifecycle.addObservers to observe the lifecycle for multiple classes.

`kotlin override fun onViewCreated(view: View, savedInstanceState: Bundle?) { lifecycle.addObservers( fullscreenFeature, sessionFeature, customTabsToolbarFeature ) } `

* Added ability to show one item per search suggestion (#1779) * Added ability to define custom hooks to be invoked when editing starts or is completed.

* Added ability to let consumers define the layouting of suggestions by implementing SuggestionLayout in order to control layout inflation and view binding.

`kotlin // Create a ViewHolder for your custom layout. class CustomViewHolder(view: View) : SuggestionViewHolder(view) { private val textView = view.findViewById<TextView>(R.id.text)

override fun bind( suggestion: AwesomeBar.Suggestion, selectionListener: () -> Unit ) { textView.text = suggestion.title textView.setOnClickListener { suggestion.onSuggestionClicked?.invoke() selectionListener.invoke() } } }

// Create a custom SuggestionLayout for controlling view inflation class CustomSuggestionLayout : SuggestionLayout { override fun getLayoutResource(suggestion: AwesomeBar.Suggestion): Int { return android.R.layout.simplelistitem_1 }

override fun createViewHolder(awesomeBar: BrowserAwesomeBar, view: View, layoutId: Int): SuggestionViewHolder { return CustomViewHolder(view) } } `

* Added ability to transform suggestions returned by provider (adding data, removing data, filtering suggestions, ...)

`kotlin awesomeBar.transformer = object : SuggestionTransformer { override fun transform( provider: AwesomeBar.SuggestionProvider, suggestions: List<AwesomeBar.Suggestion> ): List<AwesomeBar.Suggestion> { return suggestions.map { suggestion -> suggestion.copy(title = "Awesome!") } } }

// Use the custom layout with a BrowserAwesomeBar instance awesomeBar.layout = CustomSuggestionLayout() `

* The public suffix list shipping with this component is now updated automatically in the repository every day (if there are changes). * Fixed an issue when comparing domain labels against the public suffix list (#1777)

* Added support for Pop-up windows dialog.

* Preventing JavaScript confirm() and prompt() until providing proper implementation #1816.

* SessionUseCases and SearchUseCases now take an optional onNoSession: String -> Session lambda parameter. This function will be invoked when executing a use case that requires a (selected) Session and no such session is available. This makes using the use cases and feature components usable in browsers that may not always have sessions. The default implementation creates a new Session and adds it to the SessionManager.

* 🆕 New component: This component allows consumers of megazorded Rust libraries produced by application-services to redirect their log output to the base component's log system as follows: `kotlin import mozilla.components.support.rustlog.RustLog import mozilla.components.support.base.log.Log // In onCreate, any time after MyMegazordClass.init() RustLog.enable() // Note: By default this is enabled at level DEBUG, which can be adjusted. // (It is recommended you do this for performance if you adjust // Log.logLevel). RustLog.setMaxLevel(Log.Priority.INFO) // You can also enable "trace logs", which may include PII // (but can assist debugging) as follows. It is recommended // you not do this in builds you distribute to users. RustLog.setMaxLevel(Log.Priority.DEBUG, true) ` * This is pointless to do when not using a megazord. * Megazording is required due to each dynamically loaded Rust library having its own internal/private version of the Rust logging framework. When megazording, this is still true, but there's only a single dynamically loaded library, and so it's redirected properly. (This could probably be worked around, but it would take a great effort, and given that we expect most production use of these libraries will be using megazords, we accepted this limitation) * This would be very annoying during initial development (and debugging the sample apps), so by default, we'll log (directly, e.g. not through the base component logger) to logcat when not megazorded. * Note that you must call MyMegazordClass.init() before any uses of this class.

* Important: Users consuming megazords must also update the application-services gradle plugin to version 0.3.0.

* 🆕 A new feature component for finding text in a web page. Documentation.

* Added FxaAccountManager, which encapsulates a lower level accounts API and provides an observable interface for consumers that wish to be notified of account and profile changes. * Background-worker friendly. `kotlin // Long-lived instance, pinned on an application. val accountManager = FxaAccountManager(context, Config.release(CLIENTID, REDIRECTURL), arrayOf("profile")) launch { accountManager.init() }

// Somewhere in a fragment that cares about account state... accountManager.register(object : AccountObserver { override fun onLoggedOut() { ... }

override fun onAuthenticated(account: FirefoxAccountShaped) { ... }

override fun onProfileUpdated(profile: Profile) { ... }

override fun onError(error: FxaException) { ... } }

// Reacting to a "sign-in" user action: launch { val authUrl = try { accountManager.beginAuthentication().await() } catch (error: FxaException) { // ... display error ui... return@launch } openWebView(authUrl) }

`

* Added a new FirefoxAccountsAuthFeature, which ties together the FxaAccountManager with a session manager via feature-tabs.

* Fixing bug that allowed text behind the security icon being selectable. Issue #448

0.39.0

* Added ClipboardSuggestionProvider - An AwesomeBar.SuggestionProvider implementation that returns a suggestions for an URL in the clipboard (if there's any).

* Added support for Window.prompt. * Fixing Issue #1771. Supporting single choice items with sub-menus group.

* The GeckoView Nightly dependency is now updated to the latest version automatically in cases where no code changes are required.

* Added docs for customizing BrowserMenu. * Added BrowserMenuDivider. For customization take a look at the docs. * Added BrowserMenuImageText for show an icon next to text in menus. * Added support for showing a menu with DOWN and UP orientation (e.g. for supporting menus in bottom toolbars).

* Added support for enabling tracking protection for specific session type: `kotlin val engine = GeckoEngine(runtime, DefaultSettings( trackingProtectionPolicy = TrackingProtectionPolicy.all().forPrivateSessionsOnly()) ) `

* Added BrowserToolbarBottomBehavior - a CoordinatorLayout.Behavior implementation to be used when placing BrowserToolbar at the bottom of the screen. This behavior will: * Show/Hide the BrowserToolbar automatically when scrolling vertically. * On showing a [Snackbar] position it above the BrowserToolbar. * Snap the BrowserToolbar to be hidden or visible when the user stops scrolling.

* 🆕 A new component/library for reading and using the public suffix list. Details can be found in our docs.

0.38.0

Milestone, API reference

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10, Coroutines: 1.0.1) * GeckoView (Nightly: 66.0.20190111093148 🔺, Beta: 65.0.20181211223337, Release: 64.0.20181214004633) * Mozilla App Services (FxA: 0.13.3 🔺, Sync Logins: 0.13.3 🔺, Places: 0.13.3 🔺) * 0.13.0 release notes * 0.13.1 release notes * 0.13.2 release notes * 0.13.3 release notes * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

* Improve URL toolbar autocompletion matching.

* Improving tab selection algorithm, when removing the selected tab. * Saving the state when the app goes to the background no longer blocks the UI thread.

* Added support for JavaScript alerts on SystemEngineView. * Improving use of internal Webview.

* Added a close button to a custom tab with back button handling.

* Added support for Authentication dialogs. * Added support for datetime-local and time pickers. * Added support for input type color fields.

* BrowserMenuItemToolbar now allows overriding the visible lambda.

* Updated underlying library from 0.12.1 to 0.13.3, see the release notes for 0.13.0 for further details on the most substantial changes. (#1690) * sync-logins: Added a new wipeLocal method, for clearing all local data. * sync-logins: Removed reset because it served a nonexistent use case, callers almost certainly want wipeLocal or wipe instead. * sync-logins: Added ensureLocked and ensureUnlocked for cases where checking isLocked is inconvenient or requires additional locking. * sync-logins: Allow storage to be unlocked using a ByteArray instead of a String. * firefox-accounts: Network errors will now be reported as instances of FxaException.Network, instead of FxaException.Unspecified. * history (concept-storage): PII is no longer logged during syncing (or any other time).

0.37.0

Milestone, API reference

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10, Coroutines: 1.0.1) * GeckoView (Nightly: 66.0.20181217093726, Beta: 65.0.20181211223337, Release: 64.0.20181214004633) * Mozilla App Services (FxA: 0.12.1, Sync Logins: 0.12.1, Places: 0.12.1) * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

* Added a new feature CustomTabsToolbarFeature which will handle setting up the BrowserToolbar with the configurations available in that session:

`kotlin CustomTabsToolbarFeature( sessionManager, browserToolbar, sessionId ).also { lifecycle.addObserver(it) } ` Note: this constructor API is still a work-in-progress and will change as more Custom Tabs support is added to it next release.

* Fixed a bug where a third-party app (like Gmail or Slack) could crash when calling warmup().

* 🆕 New component that saves the state of sessions (SessionManager.Snapshot) in grouped bundles (e.g. by time).

* Added new "pocket event" ping builder (#1606) * Added ability to get ping builder by type from Telemetry instance. * ⚠️ This is a breaking change! <br/> HttpURLConnectionTelemetryClient was removed. service-telemetry is now using *concept-fetch* which allows consumers to use a unified http client. There are two options available currently: lib-fetch-httpurlconnection (Based on HttpURLConnection) and lib-fetch-okhttp (Based on OkHttp).

`Kotlin // Using HttpURLConnection: val client = new TelemetryClient(HttpURLConnectionClient())

// Using OkHttp: val client = TelemetryClient(OkHttpClient())

val telemetry = Telemetry(configuration, storage, client, scheduler) `

* Updated search plugins (#1563)

* Fixed a bug where pressing backspace could skip a character (#1489).

* Fixed a bug where a third-party app (like Gmail or Slack) could crash when calling warmup().

* Added ability to notify observers when desktop mode changes (onDesktopModeChange)

* Added new BrowserMenuSwitch for using switch widgets inside the menu.

* Added extension method Bitmap.withRoundedCorners(cornerRadiusPx: Float)

* Introduced LifecycleAwareFeature for writing features that depend on a lifecycle.

0.36.1

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10, Coroutines: 1.0.1) * GeckoView (Nightly: 66.0.20181217093726, Beta: 65.0.20181211223337, Release: 64.0.20181214004633) * Mozilla App Services (FxA: 0.12.1, Sync Logins: 0.12.1, Places: 0.12.1) * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

* Fixed a bug where a third-party app (like Gmail or Slack) could crash when calling warmup().

0.36.0

Milestone, API reference

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10, Coroutines: 1.0.1) * GeckoView (Nightly: 66.0.20181217093726, Beta: 65.0.20181211223337, Release: 64.0.20181214004633) * Mozilla App Services (FxA: 0.12.1, Sync Logins: 0.12.1, Places: 0.12.1) * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

* Added a use case for exiting fullscreen mode.

`kotlin val sessionUseCases = SessionUseCases(sessionManager) if (isFullScreenMode) { sessionUseCases.exitFullscreen.invoke() } `

* We also added a FullScreenFeature that manages fullscreen support.

`kotlin val fullScreenFeature = FullScreenFeature(sessionManaager, sessionUseCases) { enabled -> if (enabled) { // Make custom views hide. } else { // Make custom views unhide. } }

override fun onBackPressed() : Boolean { // Handling back presses when in fullscreen mode return fullScreenFeature.onBackPressed() } `

* Added support for opening speculative connections for a likely future navigation to a URL (mayLaunchUrl)

* Added support for file picker requests.

There some requests that are not handled with dialogs, instead they are delegated to other apps to perform the request, an example is a file picker request. As a result, now you have to override onActivityResult on your Activity or Fragment and forward its calls to promptFeature.onActivityResult.

Additionally, there are requests that need some permission to be granted before they can be performed, like file pickers that need access to read the selected files. Like onActivityResult you need to override onRequestPermissionsResult and forward its calls to promptFeature.onRequestPermissionsResult.

* The "urlBoxView" is now drawn behind the site security icon (in addition to the URL and the page actions)

0.35.1

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10, Coroutines: 1.0.1) * GeckoView (Nightly: 66.0.20181217093726, Beta: 65.0.20181211223337, Release: 64.0.20181214004633) * Mozilla App Services (FxA: 0.12.1 🔺, Sync Logins: 0.12.1 🔺, Places: 0.12.1 🔺) * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

0.35.0

Milestone, API reference

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10, Coroutines: 1.0.1) * GeckoView (Nightly: 66.0.20181217093726 🔺, Beta: 65.0.20181211223337 🔺, Release: 64.0.20181214004633 🔺) * Mozilla App Services (FxA: 0.11.5, Sync Logins: 0.11.5, Places: 0.11.5) * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

* Localized strings for de, es, fr, it, ja, ko, zh-rCN, zh-rTW.

* Added support for warming up the browser process asynchronously. * ⚠️ This is a breaking change * CustomTabsService has been renamed to AbstractCustomTabsService and is now an abstract class in order to allow apps to inject the Engine they are using. An app that wants to support custom tabs will need to create its own class and reference it in the manifest:

`kotlin class CustomTabsService : AbstractCustomTabsService() { override val engine: Engine by lazy { components.engine } } `

* Added support for alerts dialogs. * Added support for date picker dialogs.

* Added support to remove all or specific types of tabs to the TabsUseCases.

`kotlin // Remove all tabs tabsUseCases.removeAllTabs.invoke() // Remove all regular tabs tabsUseCases.removeAllTabsOfType.invoke(private = false) // Remove all private tabs tabsUseCases.removeAllTabsOfType.invoke(private = true) `

New extension function toDate that converts a string to a Date object from a formatter input. `kotlin val date = "2019-11-28".toDate("yyyy-MM-dd") `

* Add setting to enable testing mode which is used in engine-gecko to set FULL_ACCESSIBILITY_TREE to true. This allows access to the full DOM tree for testing purposes.

`kotlin // Turn testing mode on by default when the engine is created val engine = GeckoEngine(runtime, DefaultSettings(testingModeEnabled=true))

// Or turn testing mode on at a later point engine.settings.testingModeEnabled = true `

* The existing userAgentString setting is now supported by engine-gecko-beta and engine-gecko-nightly.

* Added a HistoryTrackingDelegate implementation, which previously lived in feature-storage.

* Removed! See feature-session instead.

* Added in-memory browsing history as one of the AwesomeBar data providers.

* Simplified error handling. Errors are wrapped in a SyncResult, exceptions are no longer thrown. * FirefoxSyncFeature's constructor now takes a map of Syncable instances. That is, the internal list of Syncables is no longer mutable. * sync is now a suspend function. Callers are expected to manage scoping themselves. * Ability to observe "sync is running" and "sync is idle" events vs SyncStatusObserver interface. * Ability to query for current sync state (running or idle). * See included sample-sync-history application for example usage of these observers.

0.34.2

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10, Coroutines: 1.0.1) * GeckoView (Nightly: 65.0.20181129095546, Beta: 64.0.20181022150107, Release: 63.0.20181018182531) * Mozilla App Services (FxA: 0.11.5 🔺, Sync Logins: 0.11.5 🔺, Places: 0.11.5 🔺) * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

0.34.1

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10, Coroutines: 1.0.1) * GeckoView (Nightly: 65.0.20181129095546 🔺, Beta: 64.0.20181022150107, Release: 63.0.20181018182531) * Mozilla App Services (FxA: 0.11.2, Sync Logins: 0.11.2, Places: 0.11.2) * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

* Updated GeckoView dependency.

0.34.0

Milestone, API reference

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10, Coroutines: 1.0.1) * GeckoView (Nightly: 65.0.20181123100059, Beta: 64.0.20181022150107, Release: 63.0.20181018182531) * Mozilla App Services (FxA: 0.11.2 🔺, Sync Logins: 0.11.2 🔺, Places: 0.11.2 🔺) * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

* Added support for observing history events and providing visited URLs (HistoryTrackingDelegate).

* Fixed a crash when calling SystemEngineSession.saveState() from a non-UI thread.

* Added ability for search suggestions to span multiple rows.

* Fixed rendering issue when displaying site security icons.

* 🆕 New component: A component that will subscribe to the selected session and will handle all the common prompt dialogs from web content.

`kotlin val promptFeature = PromptFeature(sessionManager,fragmentManager)

//It will start listing for new prompt requests for web content. promptFeature.start()

//It will stop listing for future prompt requests for web content. promptFeature.stop() `

* Added functionality to observe window requests from the browser engine. These requests can be observed on the session directly using onOpenWindowRequest and onCloseWindowRequest, but we also provide a feature class, which will automatically open and close the corresponding window:

`Kotlin windowFeature = WindowFeature(engine, sessionManager)

override fun onStart() { windowFeature.start() }

override fun onStop() { windowFeature.stop() }

`

In addition, to observe window requests the new engine setting supportMultipleWindows has to be set to true:

`Kotlin val engine = SystemEngine(context, DefaultSettings( supportMultipleWindows = true ) ) `

* Added a new interface, SyncableStore<AuthType>, which allows a storage layer to be used with feature-sync. * Added a SyncableStore<SyncAuthInfo> implementation for browser-storage-sync * Added a SyncableStore<SyncUnlockInfo> implementation for services-logins-sync.

* 🆕 New component: A component which orchestrates synchronization of groups of similar SyncableStore objects using a FirefoxAccount. * Here is an example of configuring and synchronizing a places-backed HistoryStorage (provided by browser-storage-sync component):

`Kotlin val historyStorage = PlacesHistoryStorage(context) val featureSync = FirefoxSyncFeature(Dispatchers.IO + job) { authInfo -> SyncAuthInfo( fxaAccessToken = authInfo.fxaAccessToken, kid = authInfo.kid, syncKey = authInfo.syncKey, tokenserverURL = authInfo.tokenServerUrl ) }.also { it.addSyncable("placesHistory", historyStorage) } val syncResult = featureSync.sync().await() assert(syncResults["placesHistory"]!!.status is SyncOk) `

* ⚠️ This is a breaking change * We've simplified the API to provide the FxA configuration:

`Kotlin // Before Config.custom(CONFIG_URL).await().use { config -> FirefoxAccount(config, CLIENTID, REDIRECTURL) }

// Now val config = Config(CONFIGURL, CLIENTID, REDIRECT_URL) FirefoxAccount(config) `

A full working example can be found here.

0.33.0

Milestone, API reference

* Android (SDK: 28, Support Libraries: 28.0.0) * Kotlin (Stdlib: 1.3.10 🔺, Coroutines: 1.0.1) * GeckoView (Nightly: 65.0.20181123100059 🔺, Beta: 64.0.20181022150107, Release: 63.0.20181018182531) * Mozilla App Services (FxA: 0.10.0, Sync Logins: 0.10.0, Places: 0.10.0) * Third Party Libs (Sentry: 1.7.14, Okhttp: 3.12.0)

* 🆕 New component: A component for displaying context menus when long-pressing web content.

* Toolbar concept got a new setAutocompleteListener method. * Added AutocompleteDelegate concept which allows tying together autocomplete results with a UI presenter.

* ⚠️ This is a breaking change * Renamed getDomainSuggestion to getAutocompleteSuggestion, which now returns a HistoryAutocompleteResult.

* 🆕 Added new ToolbarAutocompleteFeature:

`Kotlin toolbarAutocompleteFeature = ToolbarAutocompleteFeature(toolbar).apply { this.addHistoryStorageProvider(components.historyStorage) this.addDomainProvider(components.shippedDomainsProvider) } `

* Converted these samples to use the new ToolbarAutocompleteFeature.

* Introducing CoordinateScrollingFeature a new feature to coordinate scrolling behavior between an EngineView and the view that you specify. For a full example take a look at its usages in Sample Browser.

* Added a filter to TabsFeature to allow you to choose which sessions to show in the TabsTray. This is particularly useful if you want to filter out private tabs based on some UI interaction:

`kotlin val tabsFeature = TabsFeature( tabsTray, sessionManager, closeTabsTray = closeTabs() ) tabsFeature.filterTabs { it.private } `

* Fixing bug #1333. This issue didn't allow to use a GeckoEngineSession after sending a crash report.

0.32.2

API reference

* Android (SDK: 28 🔺, Support Libraries: 28.0.0 🔺) * Kotlin (Stdlib: 1.3.0, Coroutines: 1.0.1) * GeckoView (Nightly: 65.0.20181116100120 🔺, Beta: 64.0.20181022150107, Release: 63.0.20181018182531) * Mozilla App Services (FxA: 0.10.0 🔺, Sync Logins: 0.10.0 🔺, Places: 0.10.0 🔺)

* Fixed problem handling backspaces as described in Issue 1489

* Updated search codes (see Issue 1563 for details)

0.32.1

API reference

* Android (SDK: 28 🔺, Support Libraries: 28.0.0 🔺) * Kotlin (Stdlib: 1.3.0, Coroutines: 1.0.1) * GeckoView (Nightly: 65.0.20181116100120 🔺, Beta: 64.0.20181022150107, Release: 63.0.20181018182531) * Mozilla App Services (FxA: 0.10.0 🔺, Sync Logins: 0.10.0 🔺, Places: 0.10.0 🔺)

* Fixed concurrency problem and related crash described in Issue 1624

0.32.0

Milestone, API reference

* Android (SDK: 28 🔺, Support Libraries: 28.0.0 🔺) * Kotlin (Stdlib: 1.3.0, Coroutines: 1.0.1) * GeckoView (Nightly: 65.0.20181116100120 🔺, Beta: 64.0.20181022150107, Release: 63.0.20181018182531) * Mozilla App Services (FxA: 0.10.0 🔺, Sync Logins: 0.10.0 🔺, Places: 0.10.0 🔺)

* Deprecated DomainAutoCompleteProvider in favour of CustomDomainsProvider and ShippedDomainsProvider.

* The state of the "Send crash report" checkbox is now getting saved and restored once the dialog is shown again. * The crash reporter can now sends reports if the prompt is closed by pressing the back button.

* 🆕 New component: concept-fetch implementation using HttpURLConnection.

* 🆕 New component: concept-fetch implementation using OkHttp.

* Replace DefaultSessionStorage with a new configurable implementation called SessionStorage:

`kotlin SessionStorage().autoSave(sessionManager) .periodicallyInForeground(interval = 30, unit = TimeUnit.SECONDS) .whenGoingToBackground() .whenSessionsChange() `

0.31.0

Milestone, API reference

* Android (SDK: 27, Support Libraries: 27.1.1) * Kotlin (Stdlib: 1.3.0 🔺, Coroutines: 1.0.1 🔺) * GeckoView (Nightly: 65.0.20181107100135 🔺, Beta: 64.0.20181022150107, Release: 63.0.20181018182531)

* Added a getDomainSuggestion method to HistoryStorage which is intended to power awesomebar-like functionality. * Added basic implementations of getDomainSuggestion to existing storage components.

* ⚠️ This is a breaking change * Added functionality to observe permission requests from the browser engine. We have now removed the workaround that automatically granted permission to play protected (DRM) media. Permission requests can be observed via the browser session:

`Kotlin // Grant permission to all DRM content permissionObserver = object : SelectionAwareSessionObserver(sessionManager) { override fun onContentPermissionRequested(session: Session, permissionRequest: PermissionRequest): Boolean = permissionRequest.grantIf { it is Permission.ContentProtectedMediaId } }

override fun onStart() { // Observe permission requests on selected sessions permissionObserver.observeSelected() }

override fun onStop() { permissionObserver.stop() }

`

* ⚠️ This is a breaking change * Web font blocking is now controlled by an engine setting only. TrackingProtectionPolicy.WEBFONTS was removed:

`Kotlin // Disable web fonts by default SystemEngine(runtime, DefaultSettings(webFontsEnabled = false)) `

* 🆕 New component for providing custom tabs functionality. CustomTabsService was moved from browser-session to this new component.

* Various colors of the Awesome Bar can now be styled:

`XML <mozilla.components.browser.awesomebar.BrowserAwesomeBar .. mozac:awesomeBarTitleTextColor="#ffffff" mozac:awesomeBarDescriptionTextColor="#dddddd" mozac:awesomeBarChipTextColor="#ffffff" mozac:awesomeBarChipBackgroundColor="#444444" /> `

* Added support for displaying the site security indicator (lock/globe icon).

* 🆕 New component defining an abstract definition of an HTTP client for fetching resources. Later releases will come with components implementing this concept using HttpURLConnection, OkHttp and Necko/GeckoView. Eventually all HTTP client code in the components will be replaced with concept-fetch and consumers can decide what HTTP client implementation components should use.

* Integrated crash reporting with `lib-crash`. * Added awesome bar with `browser-awesomebar`. * Toolbar is hiding automatically now when scrolling web content. * Added "Sync Now" button to preferences (without functionality in this release) * Updated theme colors.

0.30.0

Milestone, API reference

* Android (SDK: 27, Support Libraries: 27.1.1) * Kotlin (Stdlib: 1.2.71, Coroutines: 0.30.2) * GeckoView (Nightly: 65.0.20181023100123, Beta: 64.0.20181022150107, Release: 63.0.20181018182531)

* ⚠️ These are a breaking API changes * Added a getSuggestions method to HistoryStorage, which is intended to power search, autocompletion, etc. * Added a cleanup method to HistoryStorage, which is intended to allow signaling to implementations to cleanup any allocated resources. * HistoryStorage methods recordVisit and recordObservation are now suspend. * HistoryStorage methods getVisited() and getVisited(uris) now return Deferred.

* Added an in-memory implementation of concept-storage.

* Added an implementation of concept-storage which is backed by the Rust Places library provided by application-services.

* ⚠️ This is a breaking API change * The FxaResult type served as a custom promise-like type to support older versions of Java. We have now removed this type and switched to Kotlin's Deferred instead. We've also made sure all required types are Closeable:

`kotlin // Before Config.custom(CONFIG_URL).then { config: Config -> account = FirefoxAccount(config, CLIENTID, REDIRECTURL) }

// Now val account = async { Config.custom(CONFIG_URL).await().use { config -> FirefoxAccount(config, CLIENTID, REDIRECTURL) } } ` In case error handling is needed, the new API will also become easier to work with: `kotlin // Before account.beginOAuthFlow(scopes, wantsKeys).then({ url -> showLoginScreen(url) }, { exception -> handleException(exception) })

// Now async { try { account.beginOAuthFlow(scopes, wantsKeys).await() } catch (e: FxaException) { handleException(e) } }

`

Adding support for using SystemEngineView and GeckoEngineView in a CoordinatorLayout. This allows to create nice transitions like hiding the toolbar when scrolls.

* Fixed an issue where a custom tab Session? could get selected after removing the currently selected Session.

* Added TwoStateButton that will change drawables based on the isEnabled listener. This is particularly useful for having a reload/cancel button.

`kotlin var isLoading: Boolean // updated by some state change. BrowserToolbar.TwoStateButton( reloadDrawable, "reload button", cancelDrawable, "cancel button", { isLoading } ) { /* On-click listener */ } ` * ⚠️ These are a breaking API changes: BrowserToolbar APIs for Button and ToggleButton have also been updated to accept Drawable instead of resource IDs.

`kotlin // Before BrowserToolbar.Button(R.drawable.image, "image description") { // perform an action on click. }

// Now val imageDrawable: Drawable = Drawable() BrowserToolbar.Button(imageDrawable, "image description") { // perform an action on click. }

// Before BrowserToolbar.ToggleButton( R.drawable.image, R.drawable.image_selected, "image description", "image selected description") { // perform an action on click. }

// Now val imageDrawable: Drawable = Drawable() val imageSelectedDrawable: Drawable = Drawable() BrowserToolbar.ToggleButton( imageDrawable, imageSelectedDrawable, "image description", "image selected description") { // perform an action on click. } `

* 🆕 New component: An abstract definition of an awesome bar component.

* 🆕 New component: A customizable Awesome Bar implementation for browsers.A

* 🆕 New component: A component that connects a concept-awesomebar implementation to a concept-toolbar implementation and provides implementations of various suggestion providers.

0.29.0

Milestone, API reference

* Android (SDK: 27, Support Libraries: 27.1.1) * Kotlin (Stdlib: 1.2.71 🔺, Coroutines: 0.30.2 🔺) * GeckoView (Nightly: 65.0.20181023100123 🔺, Beta: 64.0.20181022150107 🔺, Release: 63.0.20181018182531 🔺)

* Added new listener to get notified when the user is editing the URL: `kotlin toolbar.setOnEditListener(object : Toolbar.OnEditListener { override fun onTextChanged(text: String) { // Fired whenever the user changes the text in the address bar. }

override fun onStartEditing() { // Fired when the toolbar switches to edit mode. }

override fun onStopEditing() { // Fired when the toolbar switches back to display mode. } }) ` * Added new toolbar APIs: `kotlin val toolbar = BrowserToolbar(context) toolbar.textColor: Int = getColor(R.color.photonRed50) toolbar.hintColor: Int = getColor(R.color.photonGreen50) toolbar.textSize: Float = 12f toolbar.typeface: Typeface = Typeface.createFromFile("fonts/foo.tff") ` These attributes are also available in XML (except for typeface):

`xml <mozilla.components.browser.toolbar.BrowserToolbar android:id="@+id/toolbar" app:browserToolbarTextColor="#ff0000" app:browserToolbarHintColor="#00ff00" app:browserToolbarTextSize="12sp" android:layoutwidth="matchparent" android:layoutheight="wrapcontent"/> `

* API improvement for more flexibility to create a BrowserToolbar.Button, and BrowserToolbar.ToggleButton, now you can provide a custom padding: `kotlin val padding = Padding(start = 16, top = 16, end = 16, bottom = 16) val button = BrowserToolbar.Button(mozacicback, "Forward", padding = padding) {} var toggle = BrowserToolbar.ToggleButton(mozacicpin, mozacicpin_filled, "Pin", "Unpin", padding = padding) {} `

* API improvement for more flexibility to create a Toolbar.ActionToggleButton, Toolbar.ActionButton, Toolbar.ActionSpace and Toolbar.ActionImage, now you can provide a custom padding: `kotlin val padding = Padding(start = 16, top = 16, end = 16, bottom = 16) var toggle = Toolbar.ActionToggleButton(0, mozacicpin_filled, "Pin", "Unpin", padding = padding) {} val button = Toolbar.ActionButton(mozacicback, "Forward", padding = padding) {} val space = Toolbar.ActionSpace(pxToDp(128), padding = padding) val image = Toolbar.ActionImage(brand, padding = padding) `

* A new class add for representing an Android Padding. `kotlin val padding = Padding(16, 24, 32, 40) val (start, top, end, bottom) = padding `

* A new extension function that allows you to set Padding object to a View. `kotlin val padding = Padding(16, 24, 32, 40) val view = View(context) view.setPadding(padding) `

* RequestInterceptor was enhanced to support loading an alternative URL. :warning: This is a breaking change for the `RequestInterceptor` method signature! `kotlin // To provide alternative content the new InterceptionResponse.Content type needs to be used requestInterceptor = object : RequestInterceptor { override fun onLoadRequest(session: EngineSession, uri: String): InterceptionResponse? { return when (uri) { "sample:about" -> InterceptionResponse.Content("<h1>I am the sample browser</h1>") else -> null } } } // To provide an alternative URL the new InterceptionResponse.Url type needs to be used requestInterceptor = object : RequestInterceptor { override fun onLoadRequest(session: EngineSession, uri: String): InterceptionResponse? { return when (uri) { "sample:about" -> InterceptionResponse.Url("sample:aboutNew") else -> null } } } `

* Added a new concept for describing an interface for storing browser data. First iteration includes a description of HistoryStorage.

* Added a first iteration of feature-storage, which includes HistoryTrackingFeature that ties together concept-storage and concept-engine and allows engines to track history visits and page meta information. It does so by implementing HistoryTrackingDelegate defined by concept-engine. Before adding a first session to the engine, initialize the history tracking feature: `kotlin val historyTrackingFeature = HistoryTrackingFeature( components.engine, components.historyStorage ) ` Once the feature has been initialized, history will be tracked for all subsequently added sessions.

* Updated the sample browser to track browsing history using an in-memory history storage implementation (how much is actually tracked in practice depends on which engine is being used. As of this release, only SystemEngine provides a full set of necessary APIs).

* Added option to display additional message in prompt and define the theme to be used: `kotlin CrashReporter( promptConfiguration = CrashReporter.PromptConfiguration( // ..

// An additional message that will be shown in the prompt message = "We are very sorry!"

// Use a custom theme for the prompt (Extend Theme.Mozac.CrashReporter) theme = android.R.style.ThemeHoloDialog ) // .. ).install(applicationContext) ` * Showing the crash prompt won't play the default activity animation anymore. * Added a new sample app samples-crash to show and test crash reporter integration.

* TabsToolbarFeature is now adding a TabCounter from the ui-tabcounter component to the toolbar.

* New component for evaluating Javascript Expression Language (JEXL) expressions. This implementation is based on Mozjexl used at Mozilla, specifically as a part of SHIELD and Normandy. In a future version of Fretboard JEXL will allow more complex rules for experiments. For more see documentation.

* Added option to send list of experiments in event pings: Telemetry.recordExperiments(Map<String, Boolean> experiments) * Fixed an issue where DebugLogClient didn't use the provided log tag.

* Fixed an issue where for some locales a MissingResourceException would occur.

* Playback of protected media (DRM) is now granted automatically.

* Updated components to follow merge day: (Nightly: 65.0, Beta: 64.0, Release: 63.0)

0.28.0

Release date: 2018-10-23

Milestone, API reference

⚠️ Note: This and upcoming releases are only available from maven.mozilla.org.

* Android (SDK: 27, Support Libraries: 27.1.1) * Kotlin (Stdlib: 1.2.61, Coroutines: 0.23.4) * GeckoView * Nightly: 64.0.20181004100221 * Beta: 63.0b3 (0269319281578bff4e01d77a21350bf91ba08620) * Release: 62.0 (9cbae12a3fff404ed2c12070ad475424d0ae869f)

* Added HistoryTrackingDelegate interface for integrating engine implementations with history storage backends. Intended to be used via engine settings.

* Download.fileName cannot be null anymore. All engine implementations are guaranteed to return a proposed file name for Downloads now.

* Added support for HistoryTrackingDelegate, if it's specified in engine settings.

* Added a new experimental Engine implementation based on the Servo Browser Engine.

* Sessions can have a parent Session now. A Session with a parent will be added after the parent Session. On removal of a selected Session the parent Session can be selected automatically if desired: `kotlin val parent = Session("https://www.mozilla.org") val session = Session("https://www.mozilla.org/en-US/firefox/")

sessionManager.add(parent) sessionManager.add(session, parent = parent)

sessionManager.remove(session, selectParentIfExists = true) `

* It's now possible to request a SessionsSnapshot from the SessionManager, which encapsulates currently active sessions, their order and state, and which session is the selected one. Private and Custom Tab sessions are omitted from the snapshot. A new public restore method allows restoring a SessionsSnapshot. `kotlin val snapshot = sessionManager.createSnapshot() // ... persist snapshot somewhere, perhaps using the DefaultSessionStorage sessionManager.restore(snapshot) ` * restore follows a different observer notification pattern from regular add flow. See method documentation for details. A new onSessionsRestored notification is now available.

* Coupled with the SessionManager changes, the SessionStorage API has been changed to operate over SessionsSnapshot. New API no longer operates over a SessionManager, and instead reads/writes snapshots which may used together with the SessionManager (see above). An explicit clear method is provided for wiping SessionStorage. * DefaultSessionStorage now uses a new storage format internally, which allows maintaining session ordering and preserves session parent information.

* Added translation annotations to our error page strings. Translated strings will follow in a future release.

* A new client-side telemetry SDK for collecting metrics and sending them to Mozilla's telemetry service. This component is going to eventually replace service-telemetry. The SDK is currently in development and the component is not ready to be used yet.

* The Keystore class and its encryptBytes() and decryptBytes() methods are now open to simplify mocking in unit tests.

* The TabCounter class is now open and can get extended.

* Now you're able to provide a dialog before a download starts and customize it to your wish. Take a look at the updated docs.

0.27.0

Release date: 2018-10-16

Milestone, API reference

* Android (SDK: 27, Support Libraries: 27.1.1) * Kotlin (Stdlib: 1.2.61, Coroutines: 0.23.4) * GeckoView * Nightly: 64.0.20181004100221 🔺 * Beta: 63.0b3 (0269319281578bff4e01d77a21350bf91ba08620) * Release: 62.0 (9cbae12a3fff404ed2c12070ad475424d0ae869f)

* Fixed a bug where SystemEngineSession#exitFullScreenMode didn't invoke the internal callback to exit the fullscreen mode. * A new field defaultUserAgent was added to SystemEngine for testing purposes. This is to circumvent calls to WebSettings.getDefaultUserAgent which fails with a NullPointerException in Robolectric. If the SystemEngine is used in Robolectric tests the following code will be needed: `kotlin @Before fun setup() { SystemEngine.defaultUserAgent = "test-ua-string" } `

* Enabled Java 8 support to meet upstream GeckoView requirements. Apps using this component need to enable Java 8 support as well: `Groovy android { ... compileOptions { sourceCompatibility JavaVersion.VERSION18 targetCompatibility JavaVersion.VERSION18 } } `

* Fixed an issue where a locale change at runtime would not update the search engines.

* Added reusable functionality for observing sessions, which also support observering the currently selected session, even if it changes. `kotlin class MyFeaturePresenter( private val sessionManager: SessionManager ) : SelectionAwareSessionObserver(sessionManager) {

fun start() { // Always observe changes to the selected session even if the selection changes super.observeSelected()

// To observe changes to a specific session the following method can be used: // super.observeFixed(session) }

override fun onUrlChanged(session: Session, url: String) { // URL of selected session changed }

override fun onProgress(session: Session, progress: Int) { // Progress of selected session changed }

// More observer functions... } `

* Added more detailed documentation in the README.

* A new components for apps that want to process downloads, for more examples take a look at here.

* A new generic crash reporter component that can report crashes to multiple services (documentation).

* Added new helper method to run a block of code with a different StrictMode policy: `kotlin StrictMode.allowThreadDiskReads().resetAfter { // In this block disk reads are not triggering a strict mode violation } ` * Added a new helper for checking if you have permission to do something or not: `kotlin var isGranted = context.isPermissionGranted(INTERNET) if (isGranted) { //You can proceed } else { //Request permission } `

* Added a new helper for granting permissions in Robolectric tests: `kotlin val context = RuntimeEnvironment.application var isGranted = context.isPermissionGranted(INTERNET)

assertFalse(isGranted) //False permission is not granted yet.

grantPermission(INTERNET) // Now you have permission.

isGranted = context.isPermissionGranted(INTERNET)

assertTrue(isGranted) // True :D `

0.26.0

Release date: 2018-10-05

Milestone, API reference

* Android (SDK: 27, Support Libraries: 27.1.1) * Kotlin (Stdlib: 1.2.61, Coroutines: 0.23.4) * GeckoView * Nightly: 64.0.20180905100117 * Beta: 63.0b3 (0269319281578bff4e01d77a21350bf91ba08620) * Release: 62.0 (9cbae12a3fff404ed2c12070ad475424d0ae869f)

* Additionally all artifacts published now use an artifact name that matches the gradle module name (e.g. browser-toolbar instead of just toolbar). * All artifacts are published with the group id org.mozilla.components (org.mozilla.photon is not being used anymore). * For a smooth transition all artifacts still get published on JCenter with the old group ids and artifact ids. In the near future releases will only be published on maven.mozilla.org. Old releases will remain on JCenter and not get removed.

* Removed microsoftonline.com from the global and localized domain lists. No content is being served from that domain. Only subdomains like login.microsoftonline.com are used.

* Added error page support for multiple error types. `kotlin override fun onErrorRequest( session: EngineSession, errorType: ErrorType, // This used to be an Int uri: String? ): RequestInterceptor.ErrorResponse? { // Create an error page. val errorPage = ErrorPages.createErrorPage(context, errorType) // Return it to the request interceptor to take care of default error cases. return RequestInterceptor.ErrorResponse(errorPage) } ` * :warning: This is a breaking change for the `RequestInterceptor#onErrorRequest` method signature!

* Added a setting for enabling remote debugging. * Creating an Engine requires a Context now. `kotlin val geckoEngine = GeckoEngine(context) val systemEngine = SystemEngine(context) `

* The user agent string now defaults to WebView's default, if not provided, and to the user's default, if provided. It can also be read and changed: `kotlin // Using WebView's default val engine = SystemEngine(context)

// Using customized WebView default val engine = SystemEngine(context) engine.settings.userAgentString = buildUserAgentString(engine.settings.userAgentString)

// Using custom default val engine = SystemEngine(context, DefaultSettings(userAgentString = "foo")) ` * The tracking protection policy can now be set, both as a default and at any time later. `kotlin // Set the default tracking protection policy val engine = SystemEngine(context, DefaultSettings( trackingProtectionPolicy = TrackingProtectionPolicy.all()) )

// Change the tracking protection policy engine.settings.trackingProtectionPolicy = TrackingProtectionPolicy.select( TrackingProtectionPolicy.AD, TrackingProtectionPolicy.SOCIAL ) `

* Creating a GeckoEngine requires a Context now. Providing a GeckoRuntime is now optional.

* Fixed an issue that caused a Custom Tab Session to get selected if it is the first session getting added. * Observer instances that get attached to a LifecycleOwner can now automatically pause and resume observing whenever the lifecycle pauses and resumes. This behavior is off by default and can be enabled by using the autoPause parameter when registering the Observer. `kotlin sessionManager.register( observer = object : SessionManager.Observer { // ... }, owner = lifecycleOwner, autoPause = true ) ` * Added an optional callback to provide a default Session whenever SessionManager is empty: `kotlin val sessionManager = SessionManager( engine, defaultSession = { Session("https://www.mozilla.org") } ) `

* Added Telemetry.getClientId() to let consumers read the client ID. * Telemetry.recordSessionEnd() now takes an optional callback to be executed upon failure - instead of throwing IllegalStateException.

* Added ValuesProvider.getClientId() to let consumers specify the client ID to be used for bucketing the client. By default fretboard will generate and save an internal UUID used for bucketing. By specifying the client ID consumers can use the same ID for telemetry and bucketing. * Update jobs scheduled with WorkManagerSyncScheduler will now automatically retry if the configuration couldn't get updated. * The update interval of WorkManagerSyncScheduler can now be configured. * Fixed an issue when reading a corrupt experiments file from disk. * Added a workaround for HttpURLConnection throwing ArrayIndexOutOfBoundsException.

* Fixed an issue causing desyncs between the soft keyboard and InlineAutocompleteEditText.

* Showcasing new pairing flow which allows connecting new devices to existing accounts using a QR code.

0.25.1 (2018-09-27)

Milestone, API reference

* Android * SDK: 27 * Support Libraries: 27.1.1 * Kotlin * Standard library: 1.2.61 * Coroutines: 0.23.4 * GeckoView * Nightly: 64.0.20180905100117 * Beta: 63.0b3 (0269319281578bff4e01d77a21350bf91ba08620) * Release: 62.0 (9cbae12a3fff404ed2c12070ad475424d0ae869f)

0.25 (2018-09-26)

Milestone, API reference

* Android * SDK: 27 * Support Libraries: 27.1.1 * Kotlin * Standard library: 1.2.61 * Coroutines: 0.23.4 * GeckoView * Nightly: 64.0.20180905100117 * Beta: 63.0b3 (0269319281578bff4e01d77a21350bf91ba08620) * Release: 62.0 (9cbae12a3fff404ed2c12070ad475424d0ae869f)

* Fixed a bug in FlatFileExperimentStorage that caused updated experiment configurations not being saved to disk. * Added WorkManager implementation for updating experiment configurations in the background (See WorkManagerSyncScheduler). * Experiment.id is not accessible by component consumers anymore.

* URL changes are now reported earlier; when the URL of the main frame changes. * Fixed an issue where fullscreen mode would only take up part of the screen. * Fixed a crash that could happen when loading invalid URLs. * RequestInterceptor.onErrorRequest() can return custom error page content to be displayed now (the original URL that caused the error will be preserved).

0.24 (2018-09-21)

Milestone, API reference

* Android * SDK: 27 * Support Libraries: 27.1.1 * Kotlin * Standard library: 1.2.61 * Coroutines: 0.23.4 * GeckoView * Nightly: 64.0.20180905100117 * Beta: 63.0b3 (0269319281578bff4e01d77a21350bf91ba08620) * Release: 62.0 (9cbae12a3fff404ed2c12070ad475424d0ae869f)

* Added a component using AndroidKeyStore to protect user data. `kotlin // Create a Keystore and generate a key val keystore: Keystore = Keystore("samples-dataprotect") keystore.generateKey()

// Encrypt data val plainText = "plain text data".toByteArray(StandardCharsets.UTF_8) val encrypted = keystore.encryptBytes(plain)

// Decrypt data val samePlainText = keystore.decryptBytes(encrypted) `

* SystemEngineSession now provides a way to capture a screenshot of the actual content of the web page just by calling captureThumbnail

* Session exposes a new property called thumbnail and its internal observer also exposes a new listener onThumbnailChanged.

`Kotlin session.register(object : Session.Observer { fun onThumbnailChanged(session: Session, bitmap: Bitmap?) { // Do Something } }) `

* SessionManager lets you notify it when the OS is under low memory condition by calling to its new function onLowMemory.

* Now on BrowserTabsTray every tab gets is own thumbnail :)

* Now you can easily query if the OS is under low memory conditions, just by using isOSOnLowMemory() extension function on Context.

`Kotlin val shouldReduceMemoryUsage = context.isOSOnLowMemory()

if (shouldReduceMemoryUsage) { //Deallocate some heavy objects } `

* View.dp is nowResource.pxtoDp.

`Kotlin // Before toolbar.dp(104)

// Now toolbar.resources.pxToDp(104) `

* Updated to show the new features related to tab thumbnails. Be aware that this feature is only available for systemEngine and you have to switch to the build variant systemEngine*.

0.23 (2018-09-13)

Milestone, API reference

* Android * SDK: 27 * Support Libraries: 27.1.1 * Kotlin * Standard library: 1.2.61 * Coroutines: 0.23.4 * GeckoView * Nightly: 64.0.20180905100117 * Beta: 63.0b3 (0269319281578bff4e01d77a21350bf91ba08620) * Release: 62.0 (9cbae12a3fff404ed2c12070ad475424d0ae869f)

* Added support for fullscreen mode and the ability to exit it programmatically if needed. `Kotlin session.register(object : Session.Observer { fun onFullScreenChange(enabled: Boolean) { if (enabled) { // .. sessionManager.getEngineSession().exitFullScreenMode() } } }) `

* We've extended support for intercepting requests to also include intercepting of errors `Kotlin val interceptor = object : RequestInterceptor { override fun onErrorRequest( session: EngineSession, errorCode: Int, uri: String? ) { engineSession.loadData("<html><body>Couldn't load $uri!</body></html>") } } // GeckoEngine (beta/nightly) and SystemEngine support request interceptors. GeckoEngine(runtime, DefaultSettings(requestInterceptor = interceptor)) `

* Added functionality to clear all browsing data `Kotlin sessionManager.getEngineSession().clearData() ` * onNavigationStateChange is now called earlier (when the title of a web page is available) to allow for faster toolbar updates.

`Kotlin // Triggering a search if the provided EXTRA_TEXT is not a URL val searchHandler: TextSearchHandler = { searchTerm, session -> searchUseCases.defaultSearch.invoke(searchTerm, session) }

// Handles both ACTIONVIEW and ACTIONSEND intents val intentProcessor = SessionIntentProcessor( sessionUseCases, sessionManager, textSearchHandler = searchHandler ) intentProcessor.process(intent) `

0.22 (2018-09-07)

Milestone, API reference

* Android * SDK: 27 * Support Libraries: 27.1.1 * Kotlin * Standard library: 1.2.61 * Coroutines: 0.23.4 * GeckoView * Nightly: 64.0.20180905100117 🔺 * Beta: 63.0b3 (0269319281578bff4e01d77a21350bf91ba08620) 🔺 * Release: 62.0 (9cbae12a3fff404ed2c12070ad475424d0ae869f) 🔺

* EngineView now exposes lifecycle methods with default implementations. A LifecycleObserver implementation is provided which forwards events to EngineView instances. `kotlin lifecycle.addObserver(EngineView.LifecycleObserver(view)) ` * Added engine setting for blocking web fonts: `kotlin GeckoEngine(runtime, DefaultSettings(webFontsEnabled = false)) ` * setDesktopMode() was renamed to toggleDesktopMode().

`Kotlin session.register(object : Session.Observer { fun onDesktopModeChange(enabled: Boolean) { // .. } }) `

* Fretboard now has synchronous methods for adding and clearing overrides: setOverrideNow(), clearOverrideNow, clearAllOverridesNow. * Access to Experiment.id is now deprecated and is scheduled to be removed in a future release (target: 0.24). The id is an implementation detail of the underlying storage service and was not meant to be exposed to apps.

0.21 (2018-08-31)

Milestone, API reference

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.61 🔺 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180830111743 🔺 * Beta: 62.0b21 (7ce198bb7ce027d450af3f69a609896671adfab8) 🔺 * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

`Kotlin // DefaultSettings can be set on GeckoEngine and SystemEngine. GeckoEngine(runtime, DefaultSettings( trackingProtectionPolicy = TrackingProtectionPolicy.all(), javascriptEnabled = false)) `

* Added support for intercepting request and injecting custom content. This can be used for internal pages (e.g. focus:about, firefox:home) and error pages. `Kotlin // GeckoEngine (beta/nightly) and SystemEngine support request interceptors. GeckoEngine(runtime, DefaultSettings( requestInterceptor = object : RequestInterceptor { override fun onLoadRequest(session: EngineSession, uri: String): RequestInterceptor.InterceptionResponse? { return when (uri) { "sample:about" -> RequestInterceptor.InterceptionResponse("<h1>I am the sample browser</h1>") else -> null } } } ) ` * Added APIs to support "find in page". `Kotlin // Finds and highlights all occurrences of "hello" engineSession.findAll("hello")

// Finds and highlights the next or previous match engineSession.findNext(forward = true)

// Clears the highlighted results engineSession.clearFindMatches()

// The current state of "Find in page" can be observed on a Session object: session.register(object : Session.Observer { fun onFindResult(session: Session, result: FindResult) { // ... } }) `

`Kotlin engineSession.setDesktopMode(true, reload = true) `

`Kotlin session.register(object : Session.Observer { fun onLongPress(session: Session, hitResult: HitResult): Boolean { // HitResult is a sealed class representing the different types of content that can be long pressed. // ...

// Returning true will "consume" the event. If no observer consumes the event then it will be // set on the Session object to be consumed at a later time. return true } }) `

`Kotlin expectException(IllegalStateException::class) { // Do something that should throw IllegalStateException.. } `

0.20 (2018-08-24)

Milestone, API reference

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.60 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180820100132 🔺 * Beta: 62.0b15 (7ce198bb7ce027d450af3f69a609896671adfab8) * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

0.19.1 (2018-08-20)

Milestone, API reference

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.60 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180810100129 (2018.08.10, d999fb858fb2c007c5be4af72bce419c63c69b8e) * Beta: 62.0b15 (7ce198bb7ce027d450af3f69a609896671adfab8) * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

0.19 (2018-08-17)

Milestone, API reference

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.60 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180810100129 (2018.08.10, d999fb858fb2c007c5be4af72bce419c63c69b8e) * Beta: 62.0b15 (7ce198bb7ce027d450af3f69a609896671adfab8) * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

0.18 (2018-08-10)

Milestone, API reference

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.60 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180810100129 (2018.08.10, d999fb858fb2c007c5be4af72bce419c63c69b8e) 🔺 * Beta: 62.0b15 (7ce198bb7ce027d450af3f69a609896671adfab8) 🔺 * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

0.17 (2018-08-03)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.60 🔺 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180801100114 (2018.08.01, af6a7edf0069549543f2fba6a8ee3ea251b20829) 🔺 * Beta: 62.0b13 (dd92dec96711e60a8c6a49ebe584fa23a453a292) 🔺 * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

0.16.1 (2018-07-26)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.51 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180724100046 (2018.07.24, 1e5fa52a612e8985e12212d1950a732954e00e45) * Beta: 62.0b9 (d7ab2f3df0840cdb8557659afd46f61afa310379) * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

0.16 (2018-07-25)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.51 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180724100046 (2018.07.24, 1e5fa52a612e8985e12212d1950a732954e00e45) * Beta: 62.0b9 (d7ab2f3df0840cdb8557659afd46f61afa310379) * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

0.15 (2018-07-20)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.51 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180704100138 (2018.07.04, 1c235a552c32ba6c97e6030c497c49f72c7d48a8) * Beta: 62.0b5 (801112336847960bbb9a018695cf09ea437dc137) * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

0.14 (2018-07-13)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.51 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180704100138 (2018.07.04, 1c235a552c32ba6c97e6030c497c49f72c7d48a8) * Beta: 62.0b5 (801112336847960bbb9a018695cf09ea437dc137) * Release: 61.0 (785d242a5b01d5f1094882aa2144d8e5e2791e06)

0.13 (2018-07-06)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.51 * Kotlin coroutines 0.23.4 * GeckoView * Nightly: 63.0.20180704100138 (2018.07.04, 1c235a552c32ba6c97e6030c497c49f72c7d48a8) * Beta: 62.0b5 * Release: 61.0

* InlineAutocompleteEditText: onAutocomplete was renamed to applyAutocompleteResult * Toolbar: setOnUrlChangeListener was renamed to setOnUrlCommitListener

0.12 (2018-06-29)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.50 * Kotlin coroutines 0.23.3 * GeckoView Nightly * date: 2018.06.27 * version: 63.0.20180627100018 * revision: 1c235a552c32ba6c97e6030c497c49f72c7d48a8

0.11 (2018-06-22)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.41 * Kotlin coroutines 0.22.5 * GeckoView Nightly * date: 2018.06.21 * version: 62.0.20180621100051 * revision: e834d23a292972ab4250a8be00e6740c43e41db2

0.10 (2018-06-14)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.41 * Kotlin coroutines 0.22.5 * GeckoView Nightly * date: 2018.05.16 * version: 62.0.20180516100458 * revision: dedd25bfd2794eaba95225361f82c701e49c9339

0.9 (2018-06-06)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.41 * Kotlin coroutines 0.22.5 * GeckoView Nightly * date: 2018.05.16 * version: 62.0.20180516100458 * revision: dedd25bfd2794eaba95225361f82c701e49c9339

0.8 (2018-05-30)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.41 * Kotlin coroutines 0.22.5 * GeckoView Nightly * date: 2018.05.16 * version: 62.0.20180516100458 * revision: dedd25bfd2794eaba95225361f82c701e49c9339

0.7 (2018-05-24)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.41 * Kotlin coroutines 0.22.5 * GeckoView Nightly * date: 2018.05.16 * version: 62.0.20180516100458 * revision: dedd25bfd2794eaba95225361f82c701e49c9339

0.6 (2018-05-16)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.41 * Kotlin coroutines 0.22.5 * GeckoView Nightly * date: 2018.05.16 * version: 62.0.20180516100458 * revision: dedd25bfd2794eaba95225361f82c701e49c9339

0.5.1 (2018-05-03)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.41 * Kotlin coroutines 0.22.5 * GeckoView Nightly * date: 2018.04.10 * version: 61.0.20180410100334 * revision: a8061a09cd7064a8783ca9e67979d77fb52e001e

0.5 (2018-05-02)

Due to a packaging bug this release is not usable. Please use 0.5.1 instead.

0.4 (2018-04-19)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.31 * Kotlin coroutines 0.22.5

0.3 (2018-04-05)

* Android support libraries 27.1.1 * Kotlin Standard library 1.2.30 * Kotlin coroutines 0.19.3

0.2.2 (2018-03-27)

* Android support libraries 27.1.0 * Kotlin Standard library 1.2.30