Skip to content

Commit

Permalink
Change heading order
Browse files Browse the repository at this point in the history
  • Loading branch information
arturadib committed Jun 7, 2011
1 parent dd8ce1f commit 9272a2e
Show file tree
Hide file tree
Showing 10 changed files with 24 additions and 24 deletions.
4 changes: 2 additions & 2 deletions 1.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// **This example illustrates the declaration and instantiation of a View.**
//
// _Working example: [1.html](../1.html)._
// _[Go to Example 2](2.html)_
//
// **This example illustrates the declaration and instantiation of a View.**

// jQuery's document-ready function
$(function(){
Expand Down
4 changes: 2 additions & 2 deletions 2.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// **This example illustrates the binding of DOM events to View methods.**
//
// _Working example: [2.html](../2.html)._
// _[Go to Example 3](3.html)_
//
// **This example illustrates the binding of DOM events to View methods.**

//
$(function(){
Expand Down
4 changes: 2 additions & 2 deletions 3.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// **This example illustrates how to use a Collection of Models to store data, and how to tie changes in those to a View.**
//
// _Working example: [3.html](../3.html)._
// _[Go to Example 4](4.html)_
//
// **This example illustrates how to use a Collection of Models to store data, and how to tie changes in those to a View.**

//
$(function(){
Expand Down
4 changes: 2 additions & 2 deletions 4.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// **This example illustrates how to break down a View of Collections and Models into one View per Model.**
//
// _Working example: [4.html](../4.html)._
// _[Go to Example 5](5.html)_
//
// **This example illustrates how to break down a View of Collections and Models into one View per Model.**

//
$(function(){
Expand Down
4 changes: 2 additions & 2 deletions 5.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// _Working example: [5.html](../5.html)._
//
// **This example introduces two new Model actions (swap and delete), illustrating how such actions can be handled within a Model's View.**
//
// _Working example: [5.html](../5.html)._

//
$(function(){
Expand Down
6 changes: 3 additions & 3 deletions docs/1.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html> <html> <head> <title>1.js</title> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <link rel="stylesheet" media="all" href="docco.css" /> </head> <body> <div id="container"> <div id="background"></div> <div id="jump_to"> Jump To &hellip; <div id="jump_wrapper"> <div id="jump_page"> <a class="source" href="1.html"> 1.js </a> <a class="source" href="2.html"> 2.js </a> <a class="source" href="3.html"> 3.js </a> <a class="source" href="4.html"> 4.js </a> <a class="source" href="5.html"> 5.js </a> </div> </div> </div> <table cellpadding="0" cellspacing="0"> <thead> <tr> <th class="docs"> <h1> 1.js </h1> </th> <th class="code"> </th> </tr> </thead> <tbody> <tr id="section-1"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-1">&#182;</a> </div> <p><em>Working example: <a href="../1.html">1.html</a>.</em> <br />
<em><a href="2.html">Go to Example 2</a></em></p>
<!DOCTYPE html> <html> <head> <title>1.js</title> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <link rel="stylesheet" media="all" href="docco.css" /> </head> <body> <div id="container"> <div id="background"></div> <div id="jump_to"> Jump To &hellip; <div id="jump_wrapper"> <div id="jump_page"> <a class="source" href="1.html"> 1.js </a> <a class="source" href="2.html"> 2.js </a> <a class="source" href="3.html"> 3.js </a> <a class="source" href="4.html"> 4.js </a> <a class="source" href="5.html"> 5.js </a> </div> </div> </div> <table cellpadding="0" cellspacing="0"> <thead> <tr> <th class="docs"> <h1> 1.js </h1> </th> <th class="code"> </th> </tr> </thead> <tbody> <tr id="section-1"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-1">&#182;</a> </div> <p><strong>This example illustrates the declaration and instantiation of a View.</strong></p>

<p><strong>This example illustrates the declaration and instantiation of a View.</strong></p> </td> <td class="code"> <div class="highlight"><pre></pre></div> </td> </tr> <tr id="section-2"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-2">&#182;</a> </div> <p>jQuery's document-ready function</p> </td> <td class="code"> <div class="highlight"><pre><span class="nx">$</span><span class="p">(</span><span class="kd">function</span><span class="p">(){</span></pre></div> </td> </tr> <tr id="section-3"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-3">&#182;</a> </div> <p><strong>ListView class</strong>: This is the main view for our program.</p> </td> <td class="code"> <div class="highlight"><pre> <span class="kd">var</span> <span class="nx">ListView</span> <span class="o">=</span> <span class="nx">Backbone</span><span class="p">.</span><span class="nx">View</span><span class="p">.</span><span class="nx">extend</span><span class="p">({</span>
<p><em>Working example: <a href="../1.html">1.html</a>.</em> <br />
<em><a href="2.html">Go to Example 2</a></em></p> </td> <td class="code"> <div class="highlight"><pre></pre></div> </td> </tr> <tr id="section-2"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-2">&#182;</a> </div> <p>jQuery's document-ready function</p> </td> <td class="code"> <div class="highlight"><pre><span class="nx">$</span><span class="p">(</span><span class="kd">function</span><span class="p">(){</span></pre></div> </td> </tr> <tr id="section-3"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-3">&#182;</a> </div> <p><strong>ListView class</strong>: This is the main view for our program.</p> </td> <td class="code"> <div class="highlight"><pre> <span class="kd">var</span> <span class="nx">ListView</span> <span class="o">=</span> <span class="nx">Backbone</span><span class="p">.</span><span class="nx">View</span><span class="p">.</span><span class="nx">extend</span><span class="p">({</span>
<span class="nx">el</span><span class="o">:</span> <span class="nx">$</span><span class="p">(</span><span class="s1">&#39;body&#39;</span><span class="p">),</span> <span class="c1">// attaches `this.el` to an existing element.</span></pre></div> </td> </tr> <tr id="section-4"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-4">&#182;</a> </div> <p><code>initialize()</code>: Automatically called upon instantiation. Where you make all types of bindings, <em>excluding</em> UI events, such as clicks, etc.</p> </td> <td class="code"> <div class="highlight"><pre> <span class="nx">initialize</span><span class="o">:</span> <span class="kd">function</span><span class="p">(){</span>
<span class="nx">_</span><span class="p">.</span><span class="nx">bindAll</span><span class="p">(</span><span class="k">this</span><span class="p">,</span> <span class="s1">&#39;render&#39;</span><span class="p">);</span> <span class="c1">// fixes loss of context for &#39;this&#39; within methods</span>

Expand Down
6 changes: 3 additions & 3 deletions docs/2.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html> <html> <head> <title>2.js</title> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <link rel="stylesheet" media="all" href="docco.css" /> </head> <body> <div id="container"> <div id="background"></div> <div id="jump_to"> Jump To &hellip; <div id="jump_wrapper"> <div id="jump_page"> <a class="source" href="1.html"> 1.js </a> <a class="source" href="2.html"> 2.js </a> <a class="source" href="3.html"> 3.js </a> <a class="source" href="4.html"> 4.js </a> <a class="source" href="5.html"> 5.js </a> </div> </div> </div> <table cellpadding="0" cellspacing="0"> <thead> <tr> <th class="docs"> <h1> 2.js </h1> </th> <th class="code"> </th> </tr> </thead> <tbody> <tr id="section-1"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-1">&#182;</a> </div> <p><em>Working example: <a href="../2.html">2.html</a>.</em> <br />
<em><a href="3.html">Go to Example 3</a></em></p>
<!DOCTYPE html> <html> <head> <title>2.js</title> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <link rel="stylesheet" media="all" href="docco.css" /> </head> <body> <div id="container"> <div id="background"></div> <div id="jump_to"> Jump To &hellip; <div id="jump_wrapper"> <div id="jump_page"> <a class="source" href="1.html"> 1.js </a> <a class="source" href="2.html"> 2.js </a> <a class="source" href="3.html"> 3.js </a> <a class="source" href="4.html"> 4.js </a> <a class="source" href="5.html"> 5.js </a> </div> </div> </div> <table cellpadding="0" cellspacing="0"> <thead> <tr> <th class="docs"> <h1> 2.js </h1> </th> <th class="code"> </th> </tr> </thead> <tbody> <tr id="section-1"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-1">&#182;</a> </div> <p><strong>This example illustrates the binding of DOM events to View methods.</strong></p>

<p><strong>This example illustrates the binding of DOM events to View methods.</strong></p> </td> <td class="code"> <div class="highlight"><pre></pre></div> </td> </tr> <tr id="section-2"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-2">&#182;</a> </div> </td> <td class="code"> <div class="highlight"><pre><span class="nx">$</span><span class="p">(</span><span class="kd">function</span><span class="p">(){</span>
<p><em>Working example: <a href="../2.html">2.html</a>.</em> <br />
<em><a href="3.html">Go to Example 3</a></em></p> </td> <td class="code"> <div class="highlight"><pre></pre></div> </td> </tr> <tr id="section-2"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-2">&#182;</a> </div> </td> <td class="code"> <div class="highlight"><pre><span class="nx">$</span><span class="p">(</span><span class="kd">function</span><span class="p">(){</span>
<span class="kd">var</span> <span class="nx">ListView</span> <span class="o">=</span> <span class="nx">Backbone</span><span class="p">.</span><span class="nx">View</span><span class="p">.</span><span class="nx">extend</span><span class="p">({</span>
<span class="nx">el</span><span class="o">:</span> <span class="nx">$</span><span class="p">(</span><span class="s1">&#39;body&#39;</span><span class="p">),</span> <span class="c1">// el attaches to existing element</span></pre></div> </td> </tr> <tr id="section-3"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-3">&#182;</a> </div> <p><code>events</code>: Where DOM events are bound to View methods. Backbone doesn't have a separate controller to handle such bindings; it all happens in a View.</p> </td> <td class="code"> <div class="highlight"><pre> <span class="nx">events</span><span class="o">:</span> <span class="p">{</span>
<span class="s1">&#39;click button#add&#39;</span><span class="o">:</span> <span class="s1">&#39;addItem&#39;</span>
Expand Down
Loading

0 comments on commit 9272a2e

Please sign in to comment.