From d74c9b1ff2fd333c7a518cf679b576ab7d49ad2d Mon Sep 17 00:00:00 2001 From: Jan Schneider Date: Mon, 15 Mar 2010 19:09:22 +0100 Subject: [PATCH] Fix a few search-related bugs. --- kronolith/js/kronolith.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/kronolith/js/kronolith.js b/kronolith/js/kronolith.js index 51e228627..b7dd6f6db 100644 --- a/kronolith/js/kronolith.js +++ b/kronolith/js/kronolith.js @@ -290,7 +290,8 @@ KronolithCore = { date = this.date; } - if (this.view == loc && date.getYear() == this.date.getYear() && + if (this.view != 'agenda' && + this.view == loc && date.getYear() == this.date.getYear() && ((loc == 'year') || (loc == 'month' && date.getMonth() == this.date.getMonth()) || (loc == 'week' && date.getRealWeek() == this.date.getRealWeek()) || @@ -354,7 +355,7 @@ KronolithCore = { case 'search': var cals = [], term = locParts[0], query = Object.toJSON({ title: term }); - this.closeView(); + this.closeView('agenda'); this.updateView(null, 'search', term); $H(Kronolith.conf.calendars).each(function(type) { $H(type.value).each(function(calendar) { @@ -592,8 +593,7 @@ KronolithCore = { $('kronolithAgendaDate') .update(this.setTitle(Kronolith.text.agenda + ' ' + dates[0].toString('d') + ' - ' + dates[1].toString('d'))); } else { - $('kronolithViewAgenda') - .down('caption span') + $('kronolithAgendaDate') .update(this.setTitle(Kronolith.text.searching.interpolate({ term: data }))); } @@ -3367,6 +3367,7 @@ console.log(x); case 'kronolithSearchButton': this.go('search:' + $F('kronolithSearchTerm')) + e.stop(); break; case 'kronolithNotifications': -- 2.11.0