Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed mismatch between code in the getting_started repo and the guide…

…s page. These changes were pushed a month ago, but were missed because the push was to an already merged branch.
  • Loading branch information...
commit 20332db8366b00b901377be7312d9985f28b5026 1 parent 797802e
@geojeff geojeff authored
Showing with 5 additions and 7 deletions.
  1. +5 −7 source/getting_started_3.textile
View
12 source/getting_started_3.textile
@@ -203,7 +203,7 @@ to have time to operate as it would in a normal web app situation.
h5. main.js (app root directory)
<javascript filename="apps/todos_three/main.js">
-TodosThree.main = function main() {
+TodosThree.main = function () {
TodosThree.statechart.initStatechart();
};
@@ -402,14 +402,12 @@ h5. SHOWING_DESTROY_CONFIRMATION State
TodosThree.SHOWING_DESTROY_CONFIRMATION = SC.State.design({
_panel: null,
- todosBinding: 'TodosThree.completedTodosController.content',
-
enterState: function() {
- var todos = this.get('todos');
var displayDescription = "Are you sure that you wish to clear the following tasks?<br /><br />";
+ var completedTodos = TodosThree.completedTodosController;
displayDescription += "<ul>";
- displayDescription += todos.map(function(t) { return "<li>%@</li>".fmt(t.get('title')) }).join('\n');
+ displayDescription += completedTodos.map(function(t) { return "<li>%@</li>".fmt(t.get('title')); }).join('\n');
displayDescription += "</ul>";
this._panel = SC.AlertPane.warn({
@@ -421,8 +419,8 @@ TodosThree.SHOWING_DESTROY_CONFIRMATION = SC.State.design({
displayDescription: displayDescription,
buttons: [
- { title: 'Clear', action: 'confirm', default: NO },
- { title: 'Cancel', action: 'cancel', default: YES }
+ { title: 'Clear', action: 'confirm' },
+ { title: 'Cancel', action: 'cancel' }
]
});
},
Please sign in to comment.
Something went wrong with that request. Please try again.