mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-19 23:07:33 +09:00
Enhance PDF handling by introducing DISPOSITION_FORCE_INLINE and updating content disposition logic
This commit is contained in:
parent
9a60e2c532
commit
257ddfa48d
6 changed files with 63 additions and 7 deletions
|
|
@ -293,10 +293,14 @@ interface nsIChannel : nsIRequest
|
|||
* if available and if applicable. This allows determining inline versus
|
||||
* attachment.
|
||||
*
|
||||
* Setting contentDisposition provides a hint to the channel about the
|
||||
* disposition. If a normal Content-Disposition header is present its
|
||||
* value will always be used. If it is missing the hinted value will
|
||||
* be used if set.
|
||||
* Setting contentDisposition provides a hint to the channel about the
|
||||
* disposition. If the hint is DISPOSITION_ATTACHMENT and a normal
|
||||
* Content-Disposition header is present, the hinted value will always be
|
||||
* used. If the hint is DISPOSITION_FORCE_INLINE then the disposition is
|
||||
* inline and the header is not used. The value from Content-Disposition
|
||||
* header is only used when the hinted value is not DISPOSITION_INLINE or
|
||||
* DISPOSITION_FORCE_INLINE.
|
||||
* If the header is missing the hinted value will be used if set.
|
||||
*
|
||||
* Implementations should throw NS_ERROR_NOT_AVAILABLE if the header either
|
||||
* doesn't exist for this type of channel or is empty, and return
|
||||
|
|
@ -305,6 +309,7 @@ interface nsIChannel : nsIRequest
|
|||
attribute unsigned long contentDisposition;
|
||||
const unsigned long DISPOSITION_INLINE = 0;
|
||||
const unsigned long DISPOSITION_ATTACHMENT = 1;
|
||||
const unsigned long DISPOSITION_FORCE_INLINE = 2;
|
||||
|
||||
/**
|
||||
* Access to the filename portion of the Content-Disposition header if
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue