Bug 702770 - Expose GfxInfo properties in about:support. r=jrmuizel
authorMatt Woodrow <mwoodrow@mozilla.com>
Fri, 18 Nov 2011 17:00:37 +1300
changeset 80412 c625d6aedcc29a2254a49a1f6ec5d83cbda19569
parent 80411 36b377464b44dce09299a5c896a2a6f892066113
child 80413 fce30603aea9b6618e333f8e28760318414b4a87
push id3443
push usermwoodrow@mozilla.com
push dateFri, 18 Nov 2011 04:01:12 +0000
treeherdermozilla-inbound@4af4c72eafa7 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjrmuizel
bugs702770
milestone11.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 702770 - Expose GfxInfo properties in about:support. r=jrmuizel
toolkit/content/aboutSupport.js
toolkit/content/aboutSupport.xhtml
--- a/toolkit/content/aboutSupport.js
+++ b/toolkit/content/aboutSupport.js
@@ -175,16 +175,24 @@ function populateGraphicsSection() {
   {
     if(value) {
       table.push(createParentElement("tr", [
         createHeader(bundle.GetStringFromName(name)),
         createElement("td", value),
       ]));
     }
   }
+  
+  function pushLiteralInfoRow(table, name, value)
+  {
+    table.push(createParentElement("tr", [
+      createHeader(name),
+      createElement("td", value),
+    ]));
+  }
 
   function errorMessageForFeature(feature) {
     var errorMessage;
     var status;
     try {
       status = gfxInfo.getFeatureStatus(feature);
     } catch(e) {}
     switch (status) {
@@ -303,26 +311,37 @@ function populateGraphicsSection() {
         gfxInfo.getFeatureStatus(gfxInfo.FEATURE_WEBGL_OPENGL) == gfxInfo.FEATURE_NO_INFO)
       webglfeature = gfxInfo.FEATURE_WEBGL_OPENGL;
 #else
     var webglfeature = gfxInfo.FEATURE_WEBGL_OPENGL;
 #endif
     pushFeatureInfoRow(trGraphics, "webglRenderer", webglfeature, webglenabled, webglrenderer);
 
     appendChildren(graphics_tbody, trGraphics);
+    
+    // display registered graphics properties
+    let graphics_info_properties = document.getElementById("graphics-info-properties");
+    var info = gfxInfo.getInfo();
+    let trGraphicsProperties = [];
+    for (var property in info) {
+      pushLiteralInfoRow(trGraphicsProperties, property, info[property]);
+    }
+    appendChildren(graphics_info_properties, trGraphicsProperties);
    
     // display any failures that have occurred
     let graphics_failures_tbody = document.getElementById("graphics-failures-tbody");
     let trGraphicsFailures = gfxInfo.getFailures().map(function (value)
         createParentElement("tr", [
             createElement("td", value)
         ])
     );
     appendChildren(graphics_failures_tbody, trGraphicsFailures);
 
+
+
   } // end if (gfxInfo)
 
   let windows = Services.ww.getWindowEnumerator();
   let acceleratedWindows = 0;
   let totalWindows = 0;
   let mgrType;
   while (windows.hasMoreElements()) {
     totalWindows++;
--- a/toolkit/content/aboutSupport.xhtml
+++ b/toolkit/content/aboutSupport.xhtml
@@ -221,16 +221,21 @@
       </h2>
 
       <table>
         <tbody id="graphics-tbody">
         </tbody>
       </table>
 
       <table>
+        <tbody id="graphics-info-properties">
+        </tbody>
+      </table>
+
+      <table>
         <tbody id="graphics-failures-tbody">
         </tbody>
       </table>
 
     </div>
 
   </body>