Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

TreeView's mapping of node to Widget fixed #27

Open
wants to merge 1 commit into from

2 participants

@drjayvee

The mapping API changed in YUI 3.6.1, see 8cedb47
TreeView has to wait for Nodes to be instantiated before calling
Widget._mapInstance, since the Node's yuid is used for mapping,
not the DOM's id

Jeroen Versteeg TreeView's mapping of node to Widget fixed
The mapping API changed in YUI 3.6.1, see 8cedb47
TreeView has to wait for Nodes to be instantiated before calling
`Widget._mapInstance`, since the Node's yuid is used for mapping,
not the DOM's id
19187d0
@juandopazo

Hi! This repository is only for tracking the content of the gallery. You need to open issues and send pull requests to the author's repository. In this case it's https://github.com/allenrabinovich/yui3-gallery.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jun 19, 2013
  1. TreeView's mapping of node to Widget fixed

    Jeroen Versteeg authored
    The mapping API changed in YUI 3.6.1, see 8cedb47
    TreeView has to wait for Nodes to be instantiated before calling
    `Widget._mapInstance`, since the Node's yuid is used for mapping,
    not the DOM's id
This page is out of date. Refresh to see the latest.
View
3  src/gallery-yui-treeview/js/TreeView.js
@@ -266,6 +266,9 @@ Example usage:
treeNode.append(childrenHTML);
treeWidget.set("populated", true);
+ treeWidget.each(function (child) {
+ child._mapInstance(Y.stamp(child.get('boundingBox')));
+ }, this);
},
/**
View
3  src/gallery-yui-treeview/js/TreeViewHTMLRenderer.js
@@ -192,8 +192,6 @@ Y.WidgetHTMLRenderer.prototype = {
}
buffer.push(Handlebars.render(this.BOUNDING_TEMPLATE, context));
-
- this._mapInstance(context.id);
},
/**
@@ -272,6 +270,7 @@ Y.WidgetHTMLRenderer.prototype = {
// We need to setup bb/cb references, before bind/sync for backwards compat
this.syncRenderedBoxes();
+ this._mapInstance(Y.stamp(this.get('boundingBox')));
this._bindUI();
this.bindUI();
Something went wrong with that request. Please try again.