Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tie BarProp object lifetime to the Window object #4430

Merged
merged 2 commits into from
Mar 14, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 16 additions & 26 deletions source
Original file line number Diff line number Diff line change
Expand Up @@ -78443,8 +78443,7 @@ interface <dfn data-export="" data-dfn-type="interface">Window</dfn> : <span>Eve
[Replaceable] readonly attribute <span>BarProp</span> <span data-x="dom-window-personalbar">personalbar</span>;
[Replaceable] readonly attribute <span>BarProp</span> <span data-x="dom-window-scrollbars">scrollbars</span>;
[Replaceable] readonly attribute <span>BarProp</span> <span data-x="dom-window-statusbar">statusbar</span>;
[Replaceable] readonly attribute <span>BarProp</span> <span data-x="dom-window-toolbar">toolbar</span>;<!--
[Replaceable] readonly attribute <span>BarProp</span> <span data-x="dom-window-directories">directories</span>; // legacy (Gecko-only) -->
[Replaceable] readonly attribute <span>BarProp</span> <span data-x="dom-window-toolbar">toolbar</span>;
attribute DOMString <span data-x="dom-window-status">status</span>;
void <span data-x="dom-window-close">close</span>();
readonly attribute boolean <span data-x="dom-window-closed">closed</span>;
Expand Down Expand Up @@ -79203,7 +79202,6 @@ interface <dfn>BarProp</dfn> {
};</code></pre>

<dl class="domintro">

<dt><var>window</var> . <code subdfn data-x="dom-window-locationbar">locationbar</code> . <code subdfn data-x="dom-BarProp-visible">visible</code></dt>
<dd>
<p>Returns true if the location bar is visible; otherwise, returns false.</p>
Expand All @@ -79215,7 +79213,6 @@ interface <dfn>BarProp</dfn> {
</dd>

<dt><var>window</var> . <code subdfn data-x="dom-window-personalbar">personalbar</code> . <code data-x="dom-BarProp-visible">visible</code></dt>
<!--<dt><var>window</var> . <code subdfn data-x="dom-window-directories">directories</code> . <code data-x="dom-BarProp-visible">visible</code></dt>-->
<dd>
<p>Returns true if the personal bar is visible; otherwise, returns false.</p>
</dd>
Expand All @@ -79234,45 +79231,45 @@ interface <dfn>BarProp</dfn> {
<dd>
<p>Returns true if the toolbar is visible; otherwise, returns false.</p>
</dd>

</dl>

<div w-nodev>

<p>The <dfn data-x="dom-BarProp-visible">visible</dfn> attribute, on getting, must return either
true or a value determined by the user agent to most accurately represent the visibility state of
the user interface element that the object represents, as described below.</p>
<p>The <dfn data-x="dom-BarProp-visible">visible</dfn> attribute's getter must run these
steps:</p>

<p>The following <code>BarProp</code> objects exist for each <code>Document</code> object in a
<span>browsing context</span>. Some of the user interface elements represented by these objects
might have no equivalent in some user agents; for those user agents, except when otherwise
specified, the object must act as if it was present and visible (i.e. its <code
data-x="dom-BarProp-visible">visible</code> attribute must return true).</p>
<ol>
<li><p>If this <code>BarProp</code> object's <span>relevant global object</span>'s <span
data-x="window bc">browsing context</span> is null, then return false.</p></li>

<dl>
<li><p>If the user agent does not have a user interface element that the object represents, as
described below, then return true.</p></li>

<dt><dfn>The location bar <code>BarProp</code> object</dfn></dt>
<li><p>Return true or a value determined by the user agent to most accurately represent the
visibility state of the user interface element that the object represents, as described
below.</p></li>
</ol>

<p>The following <code>BarProp</code> objects must exist for each <code>Window</code> object:</p>

<dl>
<dt><dfn>The location bar <code>BarProp</code> object</dfn></dt>
<dd>Represents the user interface element that contains a control that displays the
<span>URL</span> of the <span>active document</span>, or some similar interface concept.</dd>

<dt><dfn>The menu bar <code>BarProp</code> object</dfn></dt>

<dd>Represents the user interface element that contains a list of commands in menu form, or some
similar interface concept.</dd>

<dt><dfn>The personal bar <code>BarProp</code> object</dfn></dt>

<dd>Represents the user interface element that contains links to the user's favorite pages, or
some similar interface concept.</dd>

<dt><dfn>The scrollbar <code>BarProp</code> object</dfn></dt>

<dd>Represents the user interface element that contains a scrolling mechanism, or some similar
interface concept.</dd>

<dt><dfn>The status bar <code>BarProp</code> object</dfn></dt>

<dd>Represents a user interface element found immediately below or after the document, as
appropriate for the user's media, which typically provides information about ongoing network
activity or information about elements that the user's pointing device is current indicating. If
Expand All @@ -79281,14 +79278,12 @@ interface <dfn>BarProp</dfn> {
data-x="dom-BarProp-visible">visible</code> attribute may return false).</dd>

<dt><dfn>The toolbar <code>BarProp</code> object</dfn></dt>

<dd>Represents the user interface element found immediately above or before the document, as
appropriate for the user's media, which typically provides <span>session history</span> traversal
controls (back and forward buttons, reload buttons, etc). If the user agent has no such user
interface element, then the object may act as if the corresponding user interface element was
absent (i.e. its <code data-x="dom-BarProp-visible">visible</code> attribute may return
false).</dd>

</dl>

<p>The <dfn><code data-x="dom-window-locationbar">locationbar</code></dfn> attribute must return
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While here maybe add 's getter

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I intentionally didn't because I assume #4431 will touch these.

Expand All @@ -79309,11 +79304,6 @@ interface <dfn>BarProp</dfn> {
<p>The <dfn><code data-x="dom-window-toolbar">toolbar</code></dfn> attribute must return <span>the
toolbar <code>BarProp</code> object</span>.</p>

<!--
<p>For legacy reasons, the <dfn><code data-x="dom-window-directories">directories</code></dfn>
attribute must also return <span>the personal bar <code>BarProp</code> object</span>.</p>
-->

<hr>

<p>For historical reasons, the <dfn><code data-x="dom-window-status">status</code></dfn> attribute
Expand Down