Skip to content

Commit

Permalink
Keep owner marked while navigating f/b information.
Browse files Browse the repository at this point in the history
  • Loading branch information
yunosh committed Mar 4, 2016
1 parent 44c5512 commit 572b788
Showing 1 changed file with 24 additions and 8 deletions.
32 changes: 24 additions & 8 deletions kronolith/js/kronolith.js
Original file line number Diff line number Diff line change
Expand Up @@ -6368,10 +6368,7 @@ KronolithCore = {
case 3: response = 'Declined'; break;
case 4: response = 'Tentative'; break;
}
tr.insert(new Element('td')
.writeAttribute('title', attendee.l + (attendee.o ? ' (' + Kronolith.text.organizer + ') ' : ''))
.addClassName('kronolithAttendee' + (attendee.o ? 'Organizer' : response))
.insert(attendee.e ? attendee.e.escapeHTML() : attendee.l.escapeHTML()));
tr.insert(this.getAttendeeCell(attendee, response));
for (i = 0; i < 24; i++) {
tr.insert(new Element('td', { className: 'kronolithFBUnknown' }));
}
Expand All @@ -6391,10 +6388,7 @@ KronolithCore = {
case 3: response = 'Declined'; break;
case 4: response = 'Tentative'; break;
}
row.insert(new Element('td')
.writeAttribute('title', attendee.l)
.addClassName('kronolithAttendee' + response)
.insert(attendee.e ? attendee.e.escapeHTML() : attendee.l.escapeHTML()));
row.insert(this.getAttendeeCell(attendee, response));
for (i = 0; i < 24; i++) {
row.insert(new Element('td', { className: 'kronolithFBUnknown' }));
}
Expand All @@ -6410,6 +6404,28 @@ KronolithCore = {
}.bind(this));
},

getAttendeeCell: function(attendee, response)
{
var className, label, title;

className = 'kronolithAttendee';
title = attendee.l;
if (attendee.o) {
className += 'Organizer';
title += ' (' + Kronolith.text.organizer + ') ';
} else {
className += response;
}
label = attendee.e
? attendee.e.escapeHTML()
: attendee.l.escapeHTML();

return new Element('td')
.writeAttribute('title', title)
.addClassName(className)
.insert(label);
},

addResourceTabLink: function()
{
var l = new Element('li').insert(
Expand Down

0 comments on commit 572b788

Please sign in to comment.