rappid/rAppid.js — pull request #47 by it-ony (2013-06-24 23:03:39+00:00)
Title: fixed binding initialization.

@krebbl I fixed the initialization of Bindings. In the constructor all attributes are parsed for being a Binding. If the attribute is a binding the value is set to null and the binding definition is stored in the $bindingsAttributes object.

Within the `_initializeBindings` method the before parsed bindings are now evaluated and stored on the $. For TextElement I implemented the same logic.

All tests are green, but there is at least on error with bindings for attributes with the same name. An example is
```

```

within an ItemsView. The root of the problem is that we're store the bound value under the $

```
attr[this._getItemKey()] = item;
attr[this._getIndexKey()] = index;
```

and so the it fails to find the right scope because this hack. We need a solution for this and then it can be merged.

```
if (pathElement.type != Binding.TYPE_FNC && attrKey == pathElement.name) {
searchScope = searchScope.$parentScope;
}
```