Add support for overriding UbuntuWebView ui toolkit components by embedders

Bug #1679599 reported by Santosh
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Oxide
New
Undecided
Unassigned

Bug Description

Currently UbuntuWebView have internal implementation of ui components(js dialog, filepicker, context menu).
We also need to support the overriding of these components by embedders since legacy webview already had the API to do that.

Revision history for this message
Olivier Tilloy (osomon) wrote :

I'm not sure we really want to allow overriding all those components (IIUC they are not overridable by design).

I can see a clear use case for the filepicker component though, where apps want to provide a custom content picker.

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

I don't think this is desired. UbuntuWebView deprecates the legacy API points for providing UI components and making them unavailable in the new webview is deliberate.

The context menu is already customizable via an API that allows the application to add / remove actions. The internal context menu implementation depends on functionality that we're probably never going to expose in a public API (specifying the referrer URL in page loads), so it's not actually possible right now to provide a fully featured context menu by replacing the UI component wholesale anyway (and that's going to be even more true when features like spell check get added).

There's a separate bug already for allowing applications to handle JS dialogs (bug 1637197), but that's not going to use the legacy API. It will be a new API using a signal, which is a lot more flexible and will allow the application to do things like implement its own queuing mechanism.

I'm not sure what to do about the content picker issue yet.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.