aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohannes Dahlström <johannes.dahlstrom@vaadin.com>2012-02-02 15:51:49 +0000
committerJohannes Dahlström <johannes.dahlstrom@vaadin.com>2012-02-02 15:51:49 +0000
commit823372bb76040aa7a830c075b4bd49d850f0c83a (patch)
treef73d088bfd807cda2fcb84028d6427668a8a4f38
parent2b7c87b8b3e681a7fd56b32c4884559afde158fa (diff)
downloadvaadin-framework-823372bb76040aa7a830c075b4bd49d850f0c83a.tar.gz
vaadin-framework-823372bb76040aa7a830c075b4bd49d850f0c83a.zip
[merge from 6.7] Fixed #8315 - take leap years into account in focusNext/PreviousYear
svn changeset:22864/svn branch:6.8
-rw-r--r--src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java b/src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java
index 96ca818bb4..513c94ef98 100644
--- a/src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java
+++ b/src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java
@@ -628,6 +628,7 @@ public class VCalendarPanel extends FocusableFlexTable implements
private void focusPreviousYear(int years) {
int currentMonth = focusedDate.getMonth();
focusedDate.setYear(focusedDate.getYear() - years);
+ displayedMonth.setYear(displayedMonth.getYear() - years);
/*
* If the focused date was a leap day (Feb 29), the new date becomes Mar
* 1 if the new year is not also a leap year. Set it to Feb 28 instead.