action.dateSelected(new DateExt(getDate()));
}
}
private AnimatedPanelWithText getTodayPanel() {
final AnimatedPanelWithText panel = new AnimatedPanelWithText();
panel.setInternalText("Today");
panel.setBackground(CalendarSettings.BACKGROUNDCOLOR);
panel.setMinimumSize(new Dimension(180, 20));
panel.setPreferredSize(new Dimension(180, 20));
panel.addMouseListener(new MouseAdapter() {
@Override
public void mouseEntered(MouseEvent e) {
panel.setForeground(Color.BLUE);
String text=dateToString(new Date(), includeTime);
panel.setText(text);
}
@Override
public void mouseExited(MouseEvent e) {
panel.setForeground(Color.BLACK);
panel.setText("Today");
}
@Override
public void mousePressed(MouseEvent e) {
today();