Implemented timeline selection.

* Added personal VIM ide extension.
* Implemented timeline selection (resolves D0007)
* Slightly restyled the new timeline button and timeline list menu.
This commit is contained in:
Jonathan Bernard
2011-06-10 11:49:45 -05:00
parent b5eadd6fc4
commit 99d04935cb
21 changed files with 389 additions and 20 deletions

View File

@ -362,7 +362,7 @@ $(document).ready(function(){
initialize: function(options) {
_.bindAll(this, 'render', 'renderOne', 'editId',
'editDesc', 'updateOnEnter');
'editDesc', 'updateOnEnter', 'close');
if (options.initialTimelineId == undefined) {
throw "Can not create a TimelineListView without an initial timeline."
@ -466,7 +466,8 @@ $(document).ready(function(){
initialize: function() {
_.bindAll(this, 'initializeViews', 'loadInitialData');
_.bindAll(this, 'initializeViews', 'loadInitialData',
'selectTimeline');
appThis = this;
@ -541,6 +542,25 @@ $(document).ready(function(){
async: false}).responseText);
return data;
},
selectTimeline: function(e) {
if (e) {
// get the timeline model
var tl = this.timelines.collection.get(e.srcElement.text);
// set the on the timeline view
this.timelines.view.selected = tl;
// set the timeline on the EntryList
this.entries.collection.timeline = tl;
// refresh TimelineListView
this.timelines.view.render();
// refresh EntryList records
this.entries.collection.fetch()
}
}
});