TV-Browser 3.3.3 API

tvbrowser.ui.tray
Class Java6Tray

java.lang.Object
  extended by tvbrowser.ui.tray.Java6Tray

public class Java6Tray
extends java.lang.Object

Tray for TV-Browser on systems with Java 6 and tray support.

Author:
René Mach

Method Summary
 void addLeftClickAction(java.awt.event.ActionListener listener)
          Add a Left-Click-Action
 void addLeftDoubleClickAction(java.awt.event.ActionListener listener)
          Add a Left-DoubleClick-Action
 void addRightClickAction(java.awt.event.ActionListener listener)
          Add a Right-Click-Action
static Java6Tray create()
          Creates the Java 6 tray.
 java.awt.Dimension getTrayIconSize()
          Gets the useable size for tray icon.
 boolean init(javax.swing.JFrame parent, java.lang.String tooltip)
          Init the System-Tray
 void setTrayPopUp(javax.swing.JPopupMenu trayMenu)
          Add Popup to Tray-Icon
 void setVisible(boolean b)
          Set the visibility of the TrayIcon
 boolean showBalloonTip(java.lang.String caption, java.lang.String message, java.awt.TrayIcon.MessageType messageType)
          Shows a balloon tip on the TV-Browser tray icon.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

create

public static Java6Tray create()
Creates the Java 6 tray.

Returns:
The Java 6 tray instance.

addLeftClickAction

public void addLeftClickAction(java.awt.event.ActionListener listener)
Add a Left-Click-Action

Parameters:
listener - Action that is triggered on left click

addLeftDoubleClickAction

public void addLeftDoubleClickAction(java.awt.event.ActionListener listener)
Add a Left-DoubleClick-Action

Parameters:
listener - Action that is triggered on left doubleclick

addRightClickAction

public void addRightClickAction(java.awt.event.ActionListener listener)
Add a Right-Click-Action

Parameters:
listener - Action that is triggered on right click

init

public boolean init(javax.swing.JFrame parent,
                    java.lang.String tooltip)
Init the System-Tray

Parameters:
parent - Parent-Frame
tooltip - Tooltip
Returns:
true, if successfull

setTrayPopUp

public void setTrayPopUp(javax.swing.JPopupMenu trayMenu)
Add Popup to Tray-Icon

Parameters:
trayMenu - Popup

setVisible

public void setVisible(boolean b)
Set the visibility of the TrayIcon

Parameters:
b - Visibility

getTrayIconSize

public java.awt.Dimension getTrayIconSize()
Gets the useable size for tray icon.

Returns:
The useable size for tray icon.

showBalloonTip

public boolean showBalloonTip(java.lang.String caption,
                              java.lang.String message,
                              java.awt.TrayIcon.MessageType messageType)
Shows a balloon tip on the TV-Browser tray icon.

Parameters:
caption - The caption of the displayed message.
message - The message to display in the balloon tip.
messageType - The type of the displayed balllon tip.
Returns:
If the balloon tip could be shown.

TV-Browser 3.3.3 API

TV-Browser 3.3.3, Copyright (C) 2004-2008 TV-Browser Team (dev@tvbrowser.org)