Casey Foster
34ce37137e
Fix #1791 reorder constructor so attributes is defined for parse
2012-11-01 17:02:37 -07:00
Brad Dunbar
ef8e10fafb
Further simplify Router#_bindRoutes.
2012-10-24 17:59:40 -04:00
Casey Foster
dbad306684
Match save to new set signature
2012-10-23 07:44:17 -07:00
Casey Foster
f73de64c33
Refactor set to avoid unnecessary arguments object creation
2012-10-22 20:22:58 -07:00
Genadi Samokovarov
85a1e3ea5c
Use _.pick to simplify View#_configure
2012-10-22 12:51:43 +03:00
Genadi Samokovarov
4e0627cbbc
Update outdated comments
2012-10-22 01:37:49 +03:00
Casey Foster
dd592ad806
Be sure to return the value of beforeSend
2012-10-19 13:42:15 -07:00
Jeremy Ashkenas
203e9b9e2d
Merge pull request #1757 from braddunbar/beforesend
...
Preserve user provided beforeSend.
2012-10-19 13:28:27 -07:00
Brad Dunbar
1d909d4fe0
Fix #1756 - preserve user provided beforeSend.
2012-10-19 16:08:40 -04:00
Michał Łowicki
817f8728a2
Call 'beforeSend' function set with $.ajaxSetup when Backbone.emulateHTTP is set to true.
...
Previously if we set:
Backbone.emulateHTTP = true;
and 'beforeSend' on $.ajax via:
$.ajaxSetup({
beforeSend: function (xhr) {
xhr.setRequestHeader('X-CSRFToken', $.cookie('csrftoken'));
}
});
Then 'beforeSend' won't be called on xhr requests.
2012-10-19 20:57:02 +02:00
Brad Dunbar
3685f7649f
Fix #1751 - root is exports, not global.
2012-10-19 10:45:52 -04:00
Brad Dunbar
db26c74d1a
Merge pull request #1746 from michalkot/master.
...
Allow empty routes.
2012-10-17 07:53:15 -04:00
michalkot
d73b6d7da9
allow empty routes
2012-10-17 10:37:36 +01:00
Brad Dunbar
8638bfef0a
Add extend to Backbone.History.
2012-10-16 08:11:33 -04:00
Jeremy Ashkenas
9df2b8d33c
Merge pull request #1736 from wookiehangover/issue1735
...
fix for #1735 - consistently use attrs in Model constructor
2012-10-15 11:27:05 -07:00
Brad Dunbar
9b0e85213b
Minor optimization to Router#_bindRoutes.
2012-10-15 10:00:37 -04:00
Sam Breed
b41d5628c7
fix for #1735 - consistently use attrs in Model constructor
2012-10-14 11:51:30 -06:00
Radoslav Stankov
4a20d66f66
Check if model/collection support .off when disposing of the view
2012-10-05 22:04:12 +03:00
Jeremy Ashkenas
f0586cfa5f
period in comment
2012-10-03 15:18:46 -04:00
Jeremy Ashkenas
bdefd3cce1
Merge branch 'change-bug' of https://github.com/tgriesser/backbone
2012-10-03 15:11:01 -04:00
Ian Storm Taylor
3169cfe6ed
swapped optional route syntax to parentheses, and adding docs
2012-10-02 19:10:59 -07:00
Ian Storm Taylor
ac8a807f49
added optional groups to route syntax, with tests
2012-10-02 19:10:59 -07:00
Brad Dunbar
3f530c2ab5
Fix #1695 - Ignore location.search during pushState transition.
2012-10-02 06:36:23 -04:00
Jeremy Ashkenas
84039f3924
Merge pull request #1693 from braddunbar/el-function
...
Allow view.el to be provided as a function.
2012-10-01 20:18:57 -07:00
Jeremy Ashkenas
06c764c5e8
merge conflict resolved
2012-10-01 17:06:27 -04:00
Jeremy Ashkenas
804bb551cb
Merge branch 'master' of github.com:documentcloud/backbone
2012-10-01 16:21:11 -04:00
Jeremy Ashkenas
2eabf0450c
fixing unescaped regex
2012-10-01 16:20:58 -04:00
Brad Dunbar
e2d5483616
Allow view.el to be provided as a function.
2012-10-01 15:39:02 -04:00
Tim Griesser
2e4f48e450
whitespace cleanup after rebase
2012-10-01 15:22:20 -04:00
Tim Griesser
71b6404d73
refactor change/set, fixing #1478 and #1664
2012-10-01 15:16:55 -04:00
Brad Dunbar
2b646c6bff
Fix #1684 - Correct regression in refactoring extend.
2012-10-01 13:16:47 -04:00
Sam Breed
b347f9f8d4
consistently handle undefined being passed to the model constr ( #1545 )
2012-10-01 10:06:00 -06:00
Jeremy Ashkenas
57e1e7d083
Merge pull request #1612 from joshvermaire/chain_navigation
...
allow for chaining of router navigation
2012-09-28 12:15:04 -07:00
Jeremy Ashkenas
9ba384627c
Merge pull request #1667 from braddunbar/add
...
Fix #1604 - Refactor add, remove index option.
2012-09-26 11:53:45 -07:00
Brad Dunbar
a45ab0095f
Remove dead code.
...
Since the root will always contain a leading slash and
the fragment will never contain a leading slash, the
fragment will never start with the root.
2012-09-24 14:37:18 -04:00
Brad Dunbar
142d2ac832
Fix #1604 - Refactor add, remove index option.
...
* Avoid temporary constructs by splicing duplicates during traversal.
* Remove `index` option.
* Avoid creating empty options.
2012-09-22 08:59:37 -04:00
Brad Dunbar
a424341355
Fix #1653 - Ensure that History can be used outside of the browser.
...
* Dispense with options argument.
* Use `window` to retrieve location/history by default.
* Don't throw outside of the browser, allowing location and
history to be replaced appropriately.
2012-09-17 14:38:48 -04:00
Jeremy Ashkenas
161c3a21d7
Merge pull request #1656 from braddunbar/sortby-groupby
...
Fix #1655 - sortBy & groupBy use attributes.
2012-09-17 08:35:18 -07:00
Brad Dunbar
c344201f6e
Fix #1655 - sortBy & groupBy use attributes.
2012-09-17 11:31:46 -04:00
Jeremy Ashkenas
ff0ddbcee2
Merge pull request #1650 from braddunbar/#
...
Fix #1649 - Set location.hash with a leading #.
2012-09-17 08:26:34 -07:00
Jeremy Ashkenas
8ea7d9a01d
Merge pull request #1644 from braddunbar/default-options
...
Refactor reset/sort.
2012-09-14 10:49:57 -07:00
Brad Dunbar
07b6760a87
Style - Split long line into two.
2012-09-14 11:02:30 -04:00
Brad Dunbar
7c993bd3fd
Fix #1649 - Set location.hash with a leading #.
2012-09-14 10:56:50 -04:00
Brad Dunbar
85fca58bb9
Refactor reset/sort.
...
* Avoid creating unnecessary objects/arrays.
* Add test for sort-style comparator context.
2012-09-14 08:13:33 -04:00
Brad Dunbar
36a733a8bc
Tweak string comparator implementation.
2012-09-14 08:05:41 -04:00
Brad Dunbar
8fdcaf207a
Merge pull request #1587 from krawaller/master.
...
Conflicts:
test/collection.js
2012-09-14 07:19:57 -04:00
KungD
8f29954011
removed prefix logic
2012-09-14 07:22:22 +02:00
KungD
4707b02056
removed automatic sorting in anticipation of sort option to .set
2012-09-12 18:27:10 +02:00
KungD
342a525e12
automatic resort when sorting attribute changes
2012-09-12 06:43:55 +02:00
KungD
43491f6f28
minor performance refactor
2012-09-12 06:09:48 +02:00