mirror of
https://github.com/igniterealtime/Spark.git
synced 2025-12-01 12:27:58 +00:00
Updating for 2.5.0 release.
git-svn-id: http://svn.igniterealtime.org/svn/repos/spark/trunk@7845 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
@ -24,6 +24,17 @@ import org.jivesoftware.spark.ui.PresenceListener;
|
||||
import org.jivesoftware.spark.ui.status.StatusBar;
|
||||
import org.jivesoftware.spark.ui.status.StatusItem;
|
||||
|
||||
import javax.swing.AbstractAction;
|
||||
import javax.swing.Action;
|
||||
import javax.swing.BorderFactory;
|
||||
import javax.swing.ImageIcon;
|
||||
import javax.swing.JFrame;
|
||||
import javax.swing.JMenu;
|
||||
import javax.swing.JMenuItem;
|
||||
import javax.swing.JPanel;
|
||||
import javax.swing.JPopupMenu;
|
||||
import javax.swing.JScrollPane;
|
||||
|
||||
import java.awt.BorderLayout;
|
||||
import java.awt.Color;
|
||||
import java.awt.Dimension;
|
||||
@ -40,17 +51,6 @@ import java.awt.event.MouseAdapter;
|
||||
import java.awt.event.MouseEvent;
|
||||
import java.util.Iterator;
|
||||
|
||||
import javax.swing.AbstractAction;
|
||||
import javax.swing.Action;
|
||||
import javax.swing.BorderFactory;
|
||||
import javax.swing.ImageIcon;
|
||||
import javax.swing.JFrame;
|
||||
import javax.swing.JMenu;
|
||||
import javax.swing.JMenuItem;
|
||||
import javax.swing.JPanel;
|
||||
import javax.swing.JPopupMenu;
|
||||
import javax.swing.JScrollPane;
|
||||
|
||||
/**
|
||||
* Handles tray icon operations inside of Spark. Use to display incoming chat requests, incoming messages
|
||||
* and general notifications.
|
||||
@ -201,6 +201,7 @@ public final class Notifications implements ActionListener, MainWindowListener {
|
||||
Object o = e.getSource();
|
||||
if (!(o instanceof JMenuItem)) {
|
||||
MainWindow window = SparkManager.getMainWindow();
|
||||
/*
|
||||
if (window.isVisible() && window.getState() == Frame.NORMAL) {
|
||||
long now = System.currentTimeMillis();
|
||||
if (now - madeVisibleTime > 1000) {
|
||||
@ -210,6 +211,7 @@ public final class Notifications implements ActionListener, MainWindowListener {
|
||||
}
|
||||
|
||||
madeVisibleTime = System.currentTimeMillis();
|
||||
*/
|
||||
showMainWindow();
|
||||
return;
|
||||
}
|
||||
@ -349,7 +351,7 @@ public final class Notifications implements ActionListener, MainWindowListener {
|
||||
return;
|
||||
}
|
||||
|
||||
// trayIcon.displayMessage(title, body, TrayIcon.INFO_MESSAGE_TYPE);
|
||||
// trayIcon.displayMessage(title, body, TrayIcon.INFO_MESSAGE_TYPE);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -333,7 +333,7 @@ public class TranscriptWindow extends ChatArea {
|
||||
final SimpleDateFormat formatter = new SimpleDateFormat("h:mm a");
|
||||
final String date = formatter.format(insertDate);
|
||||
|
||||
return "[" + date + "] ";
|
||||
return "(" + date + ") ";
|
||||
}
|
||||
lastUpdated = insertDate;
|
||||
return "";
|
||||
@ -366,7 +366,7 @@ public class TranscriptWindow extends ChatArea {
|
||||
insertCustomText(notificationDateFormatter.format(date), true, true, Color.GRAY);
|
||||
}
|
||||
|
||||
value = "[" + messageDateFormatter.format(date) + "] ";
|
||||
value = "(" + messageDateFormatter.format(date) + ") ";
|
||||
value = value + userid + ": ";
|
||||
|
||||
|
||||
@ -457,7 +457,7 @@ public class TranscriptWindow extends ChatArea {
|
||||
|
||||
String value = "";
|
||||
if (insertionDate != null) {
|
||||
value = "[" + formatter.format(insertionDate) + "] ";
|
||||
value = "(" + formatter.format(insertionDate) + ") ";
|
||||
}
|
||||
buf.append("<tr><td nowrap><font size=2>").append(value).append("<strong>").append(from).append(":</strong> ").append(body).append("</font></td></tr>");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user