зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1501665 Part 1: Add a webidl property to Document to track if it's in an RDM pane. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D19235 --HG-- extra : source : be1026de486b096cee639ca584b1e8108c4b73cb
This commit is contained in:
Родитель
b7de66af4f
Коммит
642e907b47
|
@ -1340,7 +1340,8 @@ Document::Document(const char* aContentType)
|
|||
mSavedResolution(1.0f),
|
||||
mPendingInitialTranslation(false),
|
||||
mGeneration(0),
|
||||
mCachedTabSizeGeneration(0) {
|
||||
mCachedTabSizeGeneration(0),
|
||||
mInRDMPane(false) {
|
||||
MOZ_LOG(gDocumentLeakPRLog, LogLevel::Debug, ("DOCUMENT %p created", this));
|
||||
|
||||
SetIsInDocument();
|
||||
|
|
|
@ -3715,6 +3715,9 @@ class Document : public nsINode,
|
|||
|
||||
void SetPrototypeDocument(nsXULPrototypeDocument* aPrototype);
|
||||
|
||||
bool InRDMPane() const { return mInRDMPane; }
|
||||
void SetInRDMPane(bool aInRDMPane) { mInRDMPane = aInRDMPane; }
|
||||
|
||||
protected:
|
||||
void DoUpdateSVGUseElementShadowTrees();
|
||||
|
||||
|
@ -4678,6 +4681,8 @@ class Document : public nsINode,
|
|||
int32_t mCachedTabSizeGeneration;
|
||||
nsTabSizes mCachedTabSizes;
|
||||
|
||||
bool mInRDMPane;
|
||||
|
||||
public:
|
||||
// Needs to be public because the bindings code pokes at it.
|
||||
js::ExpandoAndGeneration mExpandoAndGeneration;
|
||||
|
|
|
@ -567,3 +567,13 @@ partial interface Document {
|
|||
[SameObject, Pref="dom.security.featurePolicy.webidl.enabled"]
|
||||
readonly attribute Policy policy;
|
||||
};
|
||||
|
||||
/**
|
||||
* Document extensions to support devtools.
|
||||
*/
|
||||
partial interface Document {
|
||||
// Is the Document embedded in a Responsive Design Mode pane. This property
|
||||
// is not propegated to descendant Documents upon settting.
|
||||
[ChromeOnly]
|
||||
attribute boolean inRDMPane;
|
||||
};
|
||||
|
|
Загрузка…
Ссылка в новой задаче