aboutsummaryrefslogtreecommitdiff
path: root/files/ja/web/api/progressevent
diff options
context:
space:
mode:
authorPeter Bengtsson <mail@peterbe.com>2020-12-08 14:40:17 -0500
committerPeter Bengtsson <mail@peterbe.com>2020-12-08 14:40:17 -0500
commit33058f2b292b3a581333bdfb21b8f671898c5060 (patch)
tree51c3e392513ec574331b2d3f85c394445ea803c6 /files/ja/web/api/progressevent
parent8b66d724f7caf0157093fb09cfec8fbd0c6ad50a (diff)
downloadtranslated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.gz
translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.bz2
translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.zip
initial commit
Diffstat (limited to 'files/ja/web/api/progressevent')
-rw-r--r--files/ja/web/api/progressevent/index.html161
1 files changed, 161 insertions, 0 deletions
diff --git a/files/ja/web/api/progressevent/index.html b/files/ja/web/api/progressevent/index.html
new file mode 100644
index 0000000000..c481c0d782
--- /dev/null
+++ b/files/ja/web/api/progressevent/index.html
@@ -0,0 +1,161 @@
+---
+title: ProgressEvent
+slug: Web/API/ProgressEvent
+translation_of: Web/API/ProgressEvent
+---
+<p>{{APIRef("DOM Events")}}</p>
+
+<p>The <strong><code>ProgressEvent</code></strong> インターフェースは (<code>XMLHttpRequest</code>、または {{HTMLElement("img")}}, {{HTMLElement("audio")}}, {{HTMLElement("video")}}, {{HTMLElement("style")}} ,{{HTMLElement("link")}}のような基本的なリソースのロードなどの)のようなHTTPリクエストイベントの基本的なプロセスの進捗の進み具合を表示します。</p>
+
+<h2 id="コンストラクタ">コンストラクタ</h2>
+
+<dl>
+ <dt>{{domxref("ProgressEvent.ProgressEvent", "ProgressEvent()")}}</dt>
+ <dd>Creates a <code>ProgressEvent</code> event with the given parameters.</dd>
+</dl>
+
+<h2 id="Properties">Properties</h2>
+
+<p><em>Also inherits properties from its parent {{domxref("Event")}}</em>.</p>
+
+<dl>
+ <dt>{{domxref("ProgressEvent.lengthComputable")}} {{readonlyInline}}</dt>
+ <dd>Is a {{domxref("Boolean")}} flag indicating if the total work to be done, and the amount of work already done, by the underlying process is calculable. In other words, it tells if the progress is measurable or not.</dd>
+ <dt>{{domxref("ProgressEvent.loaded")}} {{readonlyInline}}</dt>
+ <dd>Is an <code>unsigned long long</code> representing the amount of work already performed by the underlying process. The ratio of work done can be calculated with the property and <code>ProgressEvent.total</code>. When downloading a resource using HTTP, this only represent the part of the content itself, not headers and other overhead.</dd>
+ <dt>{{domxref("ProgressEvent.total")}} {{readonlyInline}}</dt>
+ <dd>Is an <code>unsigned long long</code> representing the total amount of work that the underlying process is in the progress of performing. When downloading a resource using HTTP, this only represent the content itself, not headers and other overhead.</dd>
+</dl>
+
+<h2 id="メソッド">メソッド</h2>
+
+<dl>
+</dl>
+
+<p><em>Also inherits methods <em>from its parent {{domxref("Event")}}.</em></em></p>
+
+<dl>
+ <dt>{{domxref("ProgressEvent.initProgressEvent()")}} {{deprecated_inline}}{{non-Standard_inline}}</dt>
+ <dd>Initializes a <code>ProgressEvent</code> created using the deprecated {{domxref("Document.createEvent()", "Document.createEvent(\"ProgressEvent\")")}} method.</dd>
+</dl>
+
+<h2 id="例">例</h2>
+
+<p>The following example adds a <code>ProgressEvent</code> to a new {{domxref("XMLHTTPRequest")}} and uses it to display the status of the request.</p>
+
+<pre class="brush: js"> var progressBar = document.getElementById("p"),
+ client = new XMLHttpRequest()
+ client.open("GET", "magical-unicorns")
+ client.onprogress = function(pe) {
+ if(pe.lengthComputable) {
+ progressBar.max = pe.total
+ progressBar.value = pe.loaded
+ }
+ }
+ client.onloadend = function(pe) {
+ progressBar.value = pe.loaded
+ }
+ client.send()</pre>
+
+<h2 id="仕様書">仕様書</h2>
+
+<table class="standard-table">
+ <tbody>
+ <tr>
+ <th scope="col">Specification</th>
+ <th scope="col">Status</th>
+ <th scope="col">Comment</th>
+ </tr>
+ <tr>
+ <td>{{SpecName('Progress Events', '#interface-progressevent', 'ProgressEvent')}}</td>
+ <td>{{Spec2('Progress Events')}}</td>
+ <td>Initial definition.</td>
+ </tr>
+ </tbody>
+</table>
+
+<h2 id="ブラウザ互換性">ブラウザ互換性</h2>
+
+<p>{{CompatibilityTable}}</p>
+
+<div id="compat-desktop">
+<table class="compat-table">
+ <tbody>
+ <tr>
+ <th>Feature</th>
+ <th>Chrome</th>
+ <th>Firefox (Gecko)</th>
+ <th>Internet Explorer</th>
+ <th>Opera</th>
+ <th>Safari</th>
+ </tr>
+ <tr>
+ <td>Basic support</td>
+ <td>1.0</td>
+ <td>{{CompatGeckoDesktop("1.9.1")}}</td>
+ <td>10.0</td>
+ <td>{{CompatVersionUnknown}}</td>
+ <td>{{CompatVersionUnknown}}</td>
+ </tr>
+ <tr>
+ <td><code>initProgressEvent()</code> {{non-standard_inline}}{{deprecated_inline}}</td>
+ <td>{{CompatNo}}<sup>[1]</sup></td>
+ <td>{{CompatNo}}<sup>[2]</sup></td>
+ <td>10.0</td>
+ <td>{{CompatNo}}<sup>[4]</sup></td>
+ <td>{{CompatNo}}<sup>[3]</sup></td>
+ </tr>
+ </tbody>
+</table>
+</div>
+
+<div id="compat-mobile">
+<table class="compat-table">
+ <tbody>
+ <tr>
+ <th>Feature</th>
+ <th>Android</th>
+ <th>Android Webview</th>
+ <th>Firefox Mobile (Gecko)</th>
+ <th>IE Mobile</th>
+ <th>Opera Mobile</th>
+ <th>Safari Mobile</th>
+ <th>Chrome for Android</th>
+ </tr>
+ <tr>
+ <td>Basic support</td>
+ <td>{{CompatVersionUnknown}}</td>
+ <td>{{CompatVersionUnknown}}</td>
+ <td>{{CompatGeckoMobile("1.9.1")}}</td>
+ <td>10.0</td>
+ <td>{{CompatVersionUnknown}}</td>
+ <td>{{CompatVersionUnknown}}</td>
+ <td>{{CompatVersionUnknown}}</td>
+ </tr>
+ <tr>
+ <td><code>initProgressEvent()</code> {{non-standard_inline}}{{deprecated_inline}}</td>
+ <td>{{CompatNo}}<sup>[3]</sup></td>
+ <td>{{CompatNo}}</td>
+ <td>{{CompatNo}}<sup>[2]</sup></td>
+ <td>10.0</td>
+ <td>{{CompatNo}}<sup>[4]</sup></td>
+ <td>{{CompatNo}}<sup>[3]</sup></td>
+ <td>{{CompatNo}}</td>
+ </tr>
+ </tbody>
+</table>
+</div>
+
+<p>[1] This feature was implemented in Chrome 1.0, but removed in Chrome 17.0.</p>
+
+<p>[2] This feature was implemented in Gecko 1.9.1 {{geckoRelease("1.9.1")}}, but removed in Gecko 22 {{geckoRelease("22")}}.</p>
+
+<p>[3] This feature was removed at some point.</p>
+
+<p>[4] This feature was removed in Opera 15.0.</p>
+
+<h2 id="See_also">See also</h2>
+
+<ul>
+ <li>The {{domxref("Event")}} base interface.</li>
+</ul>