Open Bug 1539363 Opened 7 years ago Updated 7 months ago

View Source API

Categories

(GeckoView :: General, enhancement, P3)

All
Android
enhancement

Tracking

(Not tracked)

People

(Reporter: JanH, Unassigned)

Details

As a fallback you can simply prepend view-source: to the URL, but doing it properly means going through ViewSourceUtils, which means a GeckoView API is needed?

I wonder what the best way to implement that API would be? It can't be a simple viewSource() method on the Session, because that causes complications when wanting to view the source in a new Session. In that case you'd either have to first load the page normally in a new session before being able to call viewSource(), which is stupid, or if you simply intercept onLoadRequest() and then load the URI manually in a new Session that means that ViewSourceUtils and whatever additional work that is doing would be bypassed same as if you just tried directly loading "view-source:" + original URL.

So to me that would seem to indicate that perhaps it should be a load flag instead?

Yup, load flag seems reasonable to me.

Priority: -- → P3
Severity: normal → S3

Tasks and enhancements should have severity N/A.

Severity: S3 → N/A
You need to log in before you can comment on or make changes to this bug.