dom/apps/tests/test_widget_browser.html
author Kan-Ru Chen (陳侃如) <kanru@kanru.info>
Wed, 12 Nov 2014 14:20:19 +0800
changeset 215295 920775ddfb85bebc35d2b65f60ad41069516dd0c
parent 215294 dom/apps/tests/test_widget.html@a3604ab2b3cae0cb23291de4ed2e2e6876283b66
permissions -rw-r--r--
Bug 1044736 - Part 6. Widget should only require embed-widgets permission. r=fabrice As discussed on dev-webapi[1] the app that wants to use widgets only need the "embed-widgets" permission to use <iframe mozbrowser mozwidget> If the app also wants to implement a browser, it could request the "browser" separately. A <iframe mozbrowser mozwidget> will have restricted mozbrowser API defined on the prototype if the embedder has the "brower" permission; they will always throw when used. [1]: https://groups.google.com/d/msg/mozilla.dev.webapi/uQweGWtVKRA/Bj1jZq3LN-0J

<!DOCTYPE HTML>
<html>
<head>
  <meta charset="utf-8">
  <title>Test for DataStore - basic operation on a readonly db</title>
  <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
  <script type="application/javascript" src="file_test_widget.js"></script>
  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
</head>
<body>
<div id="container"></div>
  <script type="application/javascript;version=1.7">
  SimpleTest.waitForExplicitFinish();
  gHasBrowserPermission = true;
  runTest();
  </script>
</body>
</html>