Skip to content

Commit

Permalink
unbind off the right method per event name tristen.
Browse files Browse the repository at this point in the history
  • Loading branch information
tristen committed Apr 9, 2013
1 parent e8045df commit f229464
Show file tree
Hide file tree
Showing 5 changed files with 1,633 additions and 1,626 deletions.
27 changes: 14 additions & 13 deletions app.css
Original file line number Diff line number Diff line change
Expand Up @@ -664,25 +664,26 @@ em { font-style:italic; }
/* ------------------------------------------
Page Components
---------------------------------------------*/
.content-search {
.topbar {
border-bottom:1px solid #C3CCD0;
margin-bottom:-1px;
position:relative;
z-index:10;
height:60px;
}
.content-search input {
border:none;
margin-top:5px;
padding:15px;
font-size:18px;
line-height:26px;
width:90%;
height:50px;
}
.content-search .icon {
top:10px;
}

.content-search input {
border:none;
margin-top:5px;
padding:15px;
font-size:18px;
line-height:26px;
width:90%;
height:50px;
}
.content-search .icon {
top:10px;
}

.menu li {
float:left;
Expand Down
6 changes: 3 additions & 3 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ <h2><a class='repo' href='#<%= titleUrl %>'><%= title %></a></h2>

<script data-template='post' type='text/html'>
<% if (markdown) { %>
<div class='toolbar'>
<div class='topbar toolbar'>
<div class='inner'>
<div class='dropdown-menu fr'>
<a href='#' class='round dropdown-hover'>Markdown</a>
Expand Down Expand Up @@ -138,7 +138,7 @@ <h2><a class='repo' href='#<%= titleUrl %>'><%= title %></a></h2>
</script>

<script data-template='posts' type='text/html'>
<div class='content-search'>
<div class='topbar content-search'>
<span class='icon search inline fr'></span>
<input type='text' id='filter' placeholder='Filter Files' />
</div>
Expand All @@ -158,7 +158,7 @@ <h2><a class='repo' href='#<%= titleUrl %>'><%= title %></a></h2>
</script>

<script data-template='profile' type='text/html'>
<div class='content-search'>
<div class='topbar content-search'>
<span class='icon search inline fr'></span>
<input type='text' id='filter' placeholder='Filter projects' />
</div>
Expand Down
13 changes: 8 additions & 5 deletions js/prose/views/post.js
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,10 @@
} else {
hash.splice(-2, 2, href, hash[hash.length - 1]);
}

console.log(_(hash).compact().join('/'));
router.navigate(_(hash).compact().join('/'), true);

return false;
},

Expand Down Expand Up @@ -563,13 +566,13 @@
remove: function () {
// Unbind pagehide event handler when View is removed
this.options.eventRegister.unbind('edit', this.postViews);
this.options.eventRegister.unbind('preview', this.postViews);
this.options.eventRegister.unbind('settings', this.postViews);
this.options.eventRegister.unbind('preview', this.preview);
this.options.eventRegister.unbind('settings', this.settings);
this.options.eventRegister.unbind('deleteFile', this.deleteFile);
this.options.eventRegister.unbind('updateMetaData', this.updateMetaData);
this.options.eventRegister.unbind('save', this.updateMetaData);
this.options.eventRegister.unbind('translate', this.updateMetaData);
this.options.eventRegister.unbind('updateFile', this.updateMetaData);
this.options.eventRegister.unbind('save', this.save);
this.options.eventRegister.unbind('translate', this.translate);
this.options.eventRegister.unbind('updateFile', this.updateFile);

$(window).unbind('pagehide');
Backbone.View.prototype.remove.call(this);
Expand Down
Loading

0 comments on commit f229464

Please sign in to comment.