(function(scope) {

scope.WebkitShadowDOM = {
  ShadowRoot: function(inElement) {
    var root = inElement.webkitCreateShadowRoot();
    // TODO(sjmiles): .shadow, .host, .olderSubtree are supposed to be native,
    // at least for public ShadowDOMs
    root.olderSubtree = inElement.shadow;
    inElement.shadow = root;
    root.host = inElement;
    // TODO(sjmiles): enabled by default so that @host polyfills will
    // work under composition. Can remove when @host is implemented
    // natively.
    root.applyAuthorStyles = true;
    return root;
  },
  distribute: function() {},
  localQuery: function(inElement, inSlctr) {
    return inElement.querySelector(inSlctr);
  },
  localQueryAll: function(inElement, inSlctr) {
    return inElement.querySelectorAll(inSlctr);
  },
  deref: function(inNode) {
    return inNode;
  },
  localNodes: function(inNode) {
    return inNode.childNodes;
  },
  localParent: function(inNode) {
    return inNode.parentNode;
  },
  forEach: Array.prototype.forEach.call.bind(Array.prototype.forEach)
};

})(window.__exported_components_polyfill_scope__);

@@ -341,16 +341,315 @@
 lement;%0A
+    // Set up gesture events on shadow%0A    if (window.PointerGestures) %7B%0A      PointerGestures.register(root);%0A      // Set up pointerevents on shadow%0A      if (window.PointerEventsPolyfill) %7B%0A        PointerEventsPolyfill.setTouchAction(root, inElement.getAttribute('touch-action'));%0A      %7D%0A    %7D%0A
     // T

Enable pointer events and gestures for native ShadowDOM