equal
deleted
inserted
replaced
37 import java.lang.reflect.InvocationTargetException; |
37 import java.lang.reflect.InvocationTargetException; |
38 |
38 |
39 /** |
39 /** |
40 * An utility window class. This is a base class for Tooltip and Balloon. |
40 * An utility window class. This is a base class for Tooltip and Balloon. |
41 */ |
41 */ |
|
42 @SuppressWarnings("serial") // JDK-implementation class |
42 public abstract class InfoWindow extends Window { |
43 public abstract class InfoWindow extends Window { |
43 private Container container; |
44 private Container container; |
44 private Closer closer; |
45 private Closer closer; |
45 |
46 |
46 protected InfoWindow(Frame parent, Color borderColor) { |
47 protected InfoWindow(Frame parent, Color borderColor) { |
144 |
145 |
145 /** The bounds of the target of the InfoWindow. */ |
146 /** The bounds of the target of the InfoWindow. */ |
146 Rectangle getBounds(); |
147 Rectangle getBounds(); |
147 } |
148 } |
148 |
149 |
|
150 @SuppressWarnings("serial") // JDK-implementation class |
149 public static class Tooltip extends InfoWindow { |
151 public static class Tooltip extends InfoWindow { |
150 |
152 |
151 public interface LiveArguments extends InfoWindow.LiveArguments { |
153 public interface LiveArguments extends InfoWindow.LiveArguments { |
152 /** The tooltip to be displayed. */ |
154 /** The tooltip to be displayed. */ |
153 String getTooltipString(); |
155 String getTooltipString(); |
237 return !(p.x < trayRect.x || p.x > (trayRect.x + trayRect.width) || |
239 return !(p.x < trayRect.x || p.x > (trayRect.x + trayRect.width) || |
238 p.y < trayRect.y || p.y > (trayRect.y + trayRect.height)); |
240 p.y < trayRect.y || p.y > (trayRect.y + trayRect.height)); |
239 } |
241 } |
240 } |
242 } |
241 |
243 |
|
244 @SuppressWarnings("serial") // JDK-implementation class |
242 public static class Balloon extends InfoWindow { |
245 public static class Balloon extends InfoWindow { |
243 |
246 |
244 public interface LiveArguments extends InfoWindow.LiveArguments { |
247 public interface LiveArguments extends InfoWindow.LiveArguments { |
245 /** The action to be performed upon clicking the baloon. */ |
248 /** The action to be performed upon clicking the baloon. */ |
246 String getActionCommand(); |
249 String getActionCommand(); |