Commit Graph

93 Commits

Author SHA1 Message Date
MozLando
a3a15bd33e [components] Merge https://github.com/mozilla-mobile/android-components/pull/7277
7277: https://github.com/mozilla-mobile/android-components/issues/5178 last used tabs property r=jonalmeida a=Vishwa-Mozilla



Co-authored-by: Vishwa Patel <vpatel@mozilla.com>
2020-07-07 17:34:25 +00:00
MozLando
55adb5960a [components] Merge https://github.com/mozilla-mobile/android-components/pull/7365
7365: For https://github.com/mozilla-mobile/android-components/issues/7364 - Adds sessionId to DownloadState and populates it in DowloadFeature r=csadilek a=codrut-topliceanu



Co-authored-by: codrut.topliceanu <codrut.topliceanu@softvision.ro>
2020-06-16 10:59:46 +00:00
codrut.topliceanu
87dd6aa502 [components] For https://github.com/mozilla-mobile/android-components/issues/7364 - Adds sessionId to DownloadState and populates it in ContentStateReducer 2020-06-15 12:35:29 +03:00
Vishwa Patel
5c10808304 [components] Close https://github.com/mozilla-mobile/android-components/issues/5178: Adding last used/accessed property to tabs 2020-06-15 00:33:10 -04:00
Tiger Oakes
74d8035254 [components] Move PIP to BrowserStore 2020-06-11 09:16:36 -07:00
Tiger Oakes
d11f6f2e9f [components] Add sameOriginAs Uri helper 2020-06-11 09:16:32 -07:00
Arturo Mejia
083c4dce15 [components] Closes https://github.com/mozilla-mobile/android-components/issues/7308: Update the store queuedDownloads when mutate
the download state.
2020-06-09 15:09:42 -04:00
Tiger Oakes
52b165e7c6 [components] Add getNormalOrPrivateTabs function 2020-06-01 16:04:52 -07:00
Christian Sadilek
ebcab79763 [components] Closes https://github.com/mozilla-mobile/android-components/issues/7103 https://github.com/mozilla-mobile/android-components/issues/5217: Move queued download state to browser store 2020-05-28 12:09:02 -04:00
Tiger Oakes
ecbbc64d60 [components] Closes https://github.com/mozilla-mobile/android-components/issues/7023 - Add HistoryState to content state 2020-05-22 09:56:22 -07:00
Tiger Oakes
796b6fec6a [components] Use helper to change state of tab in BrowserStore 2020-05-19 09:26:55 -07:00
ekager
efaa39ca49 [components] Adds MediaFullscreenOrientationFeature 2020-05-19 16:13:48 +02:00
ekager
13a8e25103 [components] For https://github.com/mozilla-mobile/android-components/issues/6757 - Adds firstContentfulPaint callback and var to session 2020-05-13 20:44:34 -07:00
Tiger Oakes
d44f30c932 [components] For https://github.com/mozilla-mobile/android-components/issues/5028 - Add webAppManifest to ContentState 2020-05-13 15:03:27 -07:00
Christian Sadilek
387b26e835 [components] Closes https://github.com/mozilla-mobile/android-components/issues/2985: Launch reader view in extension page 2020-05-05 13:15:51 -04:00
MozLando
74d2b171f3 [components] Merge https://github.com/mozilla-mobile/android-components/pull/6769
6769: Closes https://github.com/mozilla-mobile/android-components/issues/6538: Add navigation state to browser state r=pocmo a=csadilek

Need this for my reader mode refactor :). 

Co-authored-by: Christian Sadilek <christian.sadilek@gmail.com>
2020-04-28 13:13:57 +00:00
Jonathan Almeida
b86fa6dfb5 [components] Close https://github.com/mozilla-mobile/android-components/issues/6601: Update targetSdkVersion to 29 2020-04-28 03:16:54 -04:00
Christian Sadilek
3df4ba49df [components] Closes https://github.com/mozilla-mobile/android-components/issues/6538: Add navigation state to browser state 2020-04-27 18:58:27 -04:00
Simon Chae
b28f7f286e [components] Closes https://github.com/mozilla-mobile/android-components/issues/6228: Expose allowedInPrivateBrowsing control 2020-04-20 15:55:40 -04:00
Roger Yang
4d09fc463c [components] Close https://github.com/mozilla-mobile/android-components/issues/5795: Support viewport-fit descriptor via onMetaViewportFitChange 2020-04-08 18:19:11 -04:00
Sebastian Kaspari
9312a769b8 [components] Issue https://github.com/mozilla-mobile/android-components/issues/6580: Do not launch media service for muted media.
Co-authored-by: Caleb Everett <everett.caleb@gmail.com>
2020-04-08 16:28:35 +02:00
MozLando
4f475847a3 [components] Merge https://github.com/mozilla-mobile/android-components/pull/6547
6547: Closes https://github.com/mozilla-mobile/android-components/issues/4397: Migrate feature-readerview to browser-state r=pocmo a=csadilek

@pocmo Super happy with how the middleware worked out. It basically maps state to other (action/state), as relevant to reader view e.g. the url has changed -> a new reader check is required.

The other cases handled by the middleware are:
- User opens a tab via the context menu (may or may not switch to it directly)
- A new tab is selected
- A tab is removed (see comment in middleware)

All other functionality remains the same. Diff is big mostly because of test refactorings :)

I found another way that allows us to remove all reader state from the session right away! I am storing the state in the snapshot directly (same as `engineState`) and let the `SessionManager` deal with adding/deleting it based on the state in the store. This way we don't need to pass the store along to the serializer / session storage.

Co-authored-by: Christian Sadilek <christian.sadilek@gmail.com>
2020-04-07 14:46:08 +00:00
Christian Sadilek
69624c4f41 [components] Closes https://github.com/mozilla-mobile/android-components/issues/4397: Migrate feature-readerview to browser-state 2020-04-06 14:51:20 -04:00
MozLando
1dd8d3ad1b [components] Merge https://github.com/mozilla-mobile/android-components/pull/6401
6401: For https://github.com/mozilla-mobile/android-components/issues/6399: Add method to find session by url r=pocmo a=mcarare



Co-authored-by: mcarare <mihai.carare.dev@gmail.com>
2020-04-02 11:56:08 +00:00
Gabriel Luong
2498983b5d [components] Closes https://github.com/mozilla-mobile/android-components/issues/6352: Add contextId to BrowserState 2020-03-28 00:09:42 -04:00
mcarare
5a9e816809 [components] For https://github.com/mozilla-mobile/android-components/issues/6399: Add unit test to findTabByUrl 2020-03-27 13:38:57 +02:00
mcarare
d9b7accb95 [components] For https://github.com/mozilla-mobile/android-components/issues/6399: Add BrowserState extension function to find tab by url 2020-03-26 19:05:47 +02:00
Sebastian Kaspari
c6e53e9674 [components] Issue https://github.com/mozilla-mobile/android-components/issues/4287: Use immutable data types in MediaReducer. 2020-03-26 15:06:38 +01:00
Sebastian Kaspari
9494a60934 [components] Issue https://github.com/mozilla-mobile/android-components/issues/4287: Add unit tests for MediaAction. 2020-03-26 15:06:38 +01:00
Sebastian Kaspari
212ce4a1cc [components] Issue https://github.com/mozilla-mobile/android-components/issues/4287: Refactor feature-media to use browser-state instead of browser-session. 2020-03-26 15:06:35 +01:00
Sebastian
20a9a3bf3f [components] Issue https://github.com/mozilla-mobile/android-components/issues/6235: lib-state/browser-state: Add support for middleware. 2020-03-13 18:17:20 +01:00
Sebastian Kaspari
386640d8c7 [components] Issue https://github.com/mozilla-mobile/android-components/issues/5933: On memory pressure close engine sessions and keep state for restoring later.
Unfortunately the implementation for this needs to live in SessionManager as long as it keeps
references to EngineSession instances and thumbnails. Therefore we determine what to trim in
SessionManager and notify BrowserStore to perform the same changes.

Hopefully in a not to distant future we can move that to BrowserStore.
2020-03-05 12:38:59 +01:00
MozLando
8e1f42e65c [components] Merge https://github.com/mozilla-mobile/android-components/pull/6034
6034: Closes https://github.com/mozilla-mobile/android-components/issues/6011: Integrate DebuggerDelegate to support temporary extensions r=Amejia481 a=csadilek

GeckoView calls us back now when a debug / temporary extension was installed so we can refresh the list of installed extensions to make sure action handlers are hooked up. 

We're gonna have to uninstall all extensions and call `listInstalledExtensions` again to re-install everything that is there now incl. the new temporary extension. This is fine as it's for debugging purposes only.

Co-authored-by: Christian Sadilek <christian.sadilek@gmail.com>
2020-02-24 18:44:10 +00:00
Christian Sadilek
318d58e5bd [components] Closes https://github.com/mozilla-mobile/android-components/issues/6011: Integrate DebuggerDelegate to support temporary extensions 2020-02-24 13:25:45 -05:00
Sebastian Kaspari
4dc2b68f89 [components] Closes https://github.com/mozilla-mobile/android-components/issues/5965: Migrate concept-tabstray, browser-tabstray and feature-tabs to use browser-state. 2020-02-24 09:52:41 +01:00
MozLando
d0659e1907 [components] Merge https://github.com/mozilla-mobile/android-components/pull/5864 https://github.com/mozilla-mobile/android-components/pull/5997 https://github.com/mozilla-mobile/android-components/pull/6008 (part 1)
5864: Fixed `ContextMenuFeature` and `DownloadsFeature` not working for non-selected normal tab r=pocmo a=JasonHK

- Added `BrowserState.findTabOrCustomTabOrSelectedTab` extension method.
- Fixed `ContextMenuFeature` not working for non-selected normal tab.
- Fixed `DownloadsFeature` not working for non-selected normal tab



5997: Closes https://github.com/mozilla-mobile/android-components/issues/5792: Potential deadlock between unsubscribe and dispatch r=pocmo a=csadilek

As with our previous deadlock fix, we do **not** want to change the lock on the `Subscription`, as it guarantees we never dispatch to paused or stopped observers. However, the inner lock on `subscriptions` is only there for visibility purposes. We can achieve the same, namely making sure retrievals reflect the results of the most recently completed update, by using a concurrent HashSet: A set projection of https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/ConcurrentHashMap.html

This removes the potential of a deadlock and I don't see any change in semantics: The `removeSubscription` case is guarded by the `Subscription` lock and can't overlap with dispatching to the same subscription. The `addSubscription` case is guarded by the lock on the `Store` which is also required for `dipsatching`, so add and dispatch can't overlap either.

@pocmo wdyt?

6008: Bug 1615248 - add missing nightly entry in .cron.yml r=pocmo a=MihaiTabara

Follow-up from https://github.com/mozilla-mobile/android-components/pull/5967, I forgot to add its `cron.yml` corresponding entry for nightly releases.

Co-authored-by: Jason Kwok <JasonHK@users.noreply.github.com>
Co-authored-by: Christian Sadilek <christian.sadilek@gmail.com>
Co-authored-by: Mihai Tabara <mtabara@mozilla.com>
2020-02-20 19:52:44 +00:00
Sebastian Kaspari
821b87e3ce [components] Closes https://github.com/mozilla-mobile/android-components/issues/5966: Migrate browser-icons to use browser-state. 2020-02-19 09:48:42 +01:00
Severin Rudie
5b868c9ca0 [components] For https://github.com/mozilla-mobile/fenix/issues/5695: adds '{app} Search' to text selection context menu 2020-02-14 08:40:46 -08:00
Jason Kwok
e47487dee0 [components] Added BrowserState.findCustomTabOrSelectedTab extension method 2020-02-09 22:49:06 +08:00
Christian Sadilek
83bb0be49c [components] Closes https://github.com/mozilla-mobile/android-components/issues/5805: Addon name missing after uninstall / reinstall 2020-02-04 12:38:53 -05:00
Simon Chae
d4d7831a78 [components] For https://github.com/mozilla-mobile/android-components/issues/5572: Refactor web extension popup initialization 2020-01-23 19:36:58 -05:00
Simon Chae
be37eb80ce [components] Closes https://github.com/mozilla-mobile/android-components/issues/5572: Update BrowserAction to allow opening a popup 2020-01-22 14:16:35 -05:00
Christian Sadilek
70570d5ac2 [components] Issue https://github.com/mozilla-mobile/android-components/issues/4470: Wire up API for page action support
- This is basically just a copy of our browser action API, with some
refactoring to make some types and methods generic
2020-01-20 17:41:21 -05:00
Tiger Oakes
00ae4eaf07 [components] Closes https://github.com/mozilla-mobile/android-components/issues/3963 - Use stable AndroidX Browser lib 2019-12-18 20:55:03 -08:00
Arturo Mejia
d62d205d48 [components] For issue https://github.com/mozilla-mobile/android-components/issues/5143 Initial support for triggering Addon updates. 2019-12-13 10:53:08 -05:00
Christian Sadilek
12d68f202e [components] Issue https://github.com/mozilla-mobile/android-components/issues/4500: Add API for installing/uninstalling third-party extensions 2019-12-11 16:57:12 -05:00
Sawyer Blatz
da864f4056 [components] Fixes https://github.com/mozilla-mobile/android-components/issues/5264: Passes DownloadState to FetchDownloadManager when completed 2019-12-09 10:31:59 -08:00
Christian Sadilek
9d0f21d694 [components] Issue https://github.com/mozilla-mobile/android-components/issues/4500: Add action / state to enable and disable extension 2019-12-05 17:29:36 -05:00
Christian Sadilek
15c3b5aa99 [components] Closes https://github.com/mozilla-mobile/android-components/issues/4774: Link addons to their installed extensions 2019-12-05 13:40:38 -05:00
Christian Sadilek
805815825b [components] Closes https://github.com/mozilla-mobile/android-components/issues/4791: Support opening default action popup, +sample 2019-11-29 15:09:07 -05:00