diff options
author | Artur Signell <artur.signell@itmill.com> | 2010-08-24 11:26:19 +0000 |
---|---|---|
committer | Artur Signell <artur.signell@itmill.com> | 2010-08-24 11:26:19 +0000 |
commit | 7fc521683ac1b6bbd5828072d3d818fdfc30fd4f (patch) | |
tree | 39a75fbd2f388e742cdac80af1550960524a49bc /src/com | |
parent | 57e6f82715368f57e7a6dc8f1415c01198f4bf45 (diff) | |
download | vaadin-framework-7fc521683ac1b6bbd5828072d3d818fdfc30fd4f.tar.gz vaadin-framework-7fc521683ac1b6bbd5828072d3d818fdfc30fd4f.zip |
Code cleanup
svn changeset:14574/svn branch:6.4
Diffstat (limited to 'src/com')
-rw-r--r-- | src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java b/src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java index 500a6ea869..f71d98b4c8 100644 --- a/src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java +++ b/src/com/vaadin/terminal/gwt/client/ui/VCalendarPanel.java @@ -202,8 +202,9 @@ public class VCalendarPanel extends FocusableFlexTable implements private void focusDay(int day) {
// Only used when calender body is present
if (resolution > VDateField.RESOLUTION_MONTH) {
- if (focusedDay != null)
+ if (focusedDay != null) {
focusedDay.removeStyleDependentName(CN_FOCUSED);
+ }
if (day > 0 && focusedDate != null) {
focusedDate.setDate(day);
@@ -237,8 +238,9 @@ public class VCalendarPanel extends FocusableFlexTable implements value.setDate(day);
- if (selectedDay != null)
+ if (selectedDay != null) {
selectedDay.removeStyleDependentName(CN_SELECTED);
+ }
int rowCount = days.getRowCount();
for (int i = 0; i < rowCount; i++) {
@@ -293,7 +295,7 @@ public class VCalendarPanel extends FocusableFlexTable implements public void setResolution(int resolution) {
if (resolution != this.resolution) {
- this.oldResolution = this.resolution;
+ oldResolution = this.resolution;
this.resolution = resolution;
}
}
@@ -595,13 +597,13 @@ public class VCalendarPanel extends FocusableFlexTable implements }
if (isTimeSelectorNeeded()
- && (time == null || this.resolution != this.oldResolution)) {
+ && (time == null || resolution != oldResolution)) {
time = new VTime();
setWidget(2, 0, time);
getFlexCellFormatter().setColSpan(2, 0, 5);
getFlexCellFormatter().setStyleName(2, 0,
VDateField.CLASSNAME + "-calendarpanel-time");
- this.oldResolution = this.resolution;
+ oldResolution = resolution;
} else if (isTimeSelectorNeeded()) {
time.updateTimes();
} else if (time != null) {
@@ -1245,8 +1247,9 @@ public class VCalendarPanel extends FocusableFlexTable implements selectFocused();
}
- if (!hasFocus)
+ if (!hasFocus) {
focusDay(-1);
+ }
}
/**
@@ -1627,7 +1630,7 @@ public class VCalendarPanel extends FocusableFlexTable implements * The listener to trigger
*/
public void setValueChangeListener(ValueChangeListener listener) {
- this.valueChangeListener = listener;
+ valueChangeListener = listener;
}
/**
@@ -1636,7 +1639,7 @@ public class VCalendarPanel extends FocusableFlexTable implements * @param listener
*/
public void setTimeChangeListener(TimeChangeListener listener) {
- this.timeChangeListener = listener;
+ timeChangeListener = listener;
}
/**
|