diff options
| author | Misko Hevery | 2011-02-07 13:28:42 -0800 |
|---|---|---|
| committer | Misko Hevery | 2011-02-16 00:48:22 -0500 |
| commit | 0a5c00abf8664fdbdc5d16b13adb1989b4531cdf (patch) | |
| tree | 42d9426de8aa7917ba2dc127ee35dbc5890d7877 /src/Angular.js | |
| parent | a004d487c4bb48b2bec19b60bc5ddc5244029be5 (diff) | |
| download | angular.js-0a5c00abf8664fdbdc5d16b13adb1989b4531cdf.tar.bz2 | |
Add public API to retrieve scope from element.
Diffstat (limited to 'src/Angular.js')
| -rw-r--r-- | src/Angular.js | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/Angular.js b/src/Angular.js index b856aa24..9a1ab4a2 100644 --- a/src/Angular.js +++ b/src/Angular.js @@ -1032,5 +1032,12 @@ function angularJsConfig(document, config) { function bindJQuery(){ // bind to jQuery if present; jQuery = window.jQuery; - angular.element = jqLite = jQuery || jqLiteWrap; + // reset to jQuery or default to us. + if (window.jQuery) { + jqLite = window.jQuery; + jqLite.fn.scope = JQLite.prototype.scope; + } else { + jqLite = jqLiteWrap; + } + angular.element = jqLite; } |
