|
Jitsi: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
net.java.sip.communicator.util.swing.SIPCommFrame
net.java.sip.communicator.impl.gui.main.MainFrame
public class MainFrame
The main application window. This class is the core of this UI implementation. It stores all available protocol providers and their operation sets, as well as all registered accounts, the MetaContactListService and all sent messages that aren't delivered yet.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class net.java.sip.communicator.util.swing.SIPCommFrame |
|---|
SIPCommFrame.MainContentPane |
| Nested classes/interfaces inherited from class javax.swing.JFrame |
|---|
JFrame.AccessibleJFrame |
| Nested classes/interfaces inherited from class java.awt.Frame |
|---|
Frame.AccessibleAWTFrame |
| Nested classes/interfaces inherited from class java.awt.Window |
|---|
Window.AccessibleAWTWindow |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary |
|---|
| Fields inherited from class javax.swing.JFrame |
|---|
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled |
| Fields inherited from class java.awt.Frame |
|---|
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR |
| Fields inherited from class java.awt.Component |
|---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface net.java.sip.communicator.service.gui.ExportedWindow |
|---|
ABOUT_WINDOW, ADD_CONTACT_WINDOW, CHAT_WINDOW, MAIN_WINDOW |
| Fields inherited from interface javax.swing.WindowConstants |
|---|
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
|---|---|
MainFrame()
Creates an instance of MainFrame. |
|
| Method Summary | |
|---|---|
void |
addAccount(ProtocolProviderService protocolProvider)
Adds an account to the application. |
void |
addNativePlugins()
Adds all native plugins to this container. |
void |
addProtocolProvider(ProtocolProviderService protocolProvider)
Adds a protocol provider. |
void |
addProtocolSupportedOperationSets(ProtocolProviderService protocolProvider)
Adds all protocol supported operation sets. |
void |
addProviderContactHandler(ProtocolProviderService protocolProvider,
ContactEventHandler contactHandler)
Adds the given contactHandler to handle contact events for the given protocolProvider. |
void |
addSearchFieldListener(TextFieldChangeListener l)
Adds the given TextFieldChangeListener to listen for any changes that occur in the search field. |
void |
bringToFront()
Brings this window to front. |
void |
clearCurrentSearchText()
Clears the current text in the search field. |
protected void |
close(boolean isEscaped)
Overwrites the SIPCommFrame close method. |
void |
ctrlEnterKeyTyped()
Called when the CTRL-ENTER or CMD-ENTER keys were typed when this window was the focused window. |
void |
enableUnknownContactView(boolean isEnabled)
Enters or exits the "unknown contact" view. |
String |
getAccountAddress(ProtocolProviderService protocolProvider)
Returns the account user id for the given protocol provider. |
String |
getAccountDisplayName(ProtocolProviderService protocolProvider)
Returns the account user display name for the given protocol provider. |
AccountStatusPanel |
getAccountStatusPanel()
Returns the account status panel. |
OperationSetAdHocMultiUserChat |
getAdHocMultiUserChatOpSet(ProtocolProviderService protocolProvider)
Returns the multi user chat operation set for the given protocol provider. |
ContactEventHandler |
getContactHandler(ProtocolProviderService protocolProvider)
Returns the ContactEventHandler registered for this protocol provider. |
ContactListPane |
getContactListPanel()
Returns the panel containing the ContactList. |
String |
getCurrentSearchText()
Returns the text currently shown in the search field. |
WindowID |
getIdentifier()
Returns the identifier of this window. |
MainMenu |
getMainMenu()
Returns the main menu in the application window. |
OperationSetMultiUserChat |
getMultiUserChatOpSet(ProtocolProviderService protocolProvider)
Returns the multi user chat operation set for the given protocol provider. |
static OperationSetPresence |
getProtocolPresenceOpSet(ProtocolProviderService protocolProvider)
Returns the presence operation set for the given protocol provider. |
ProtocolProviderService |
getProtocolProviderForAccount(String accountName)
Returns the protocol provider associated to the account given by the account user identifier. |
Object |
getProtocolProviderLastStatus(ProtocolProviderService protocolProvider)
If the protocol provider supports presence operation set searches the last status which was selected, otherwise returns null. |
Iterator<ProtocolProviderService> |
getProtocolProviders()
Returns a set of all protocol providers. |
int |
getProviderIndex(ProtocolProviderService protocolProvider)
Returns the index of the given protocol provider. |
Object |
getSource()
Returns this window. |
OperationSetBasicTelephony<?> |
getTelephonyOpSet(ProtocolProviderService protocolProvider)
Returns the telephony operation set for the given protocol provider. |
OperationSetWebContactInfo |
getWebContactInfoOpSet(ProtocolProviderService protocolProvider)
Returns the Web Contact Info operation set for the given protocol provider. |
boolean |
hasProtocolProvider(ProtocolProviderService protocolProvider)
Checks whether we have already loaded the protocol provider. |
void |
initBounds()
Sets frame size and position. |
boolean |
isFrameVisible()
Implements isVisible in the UIService interface. |
void |
loadSkin()
Reloads skin information |
void |
maximize()
Maximizes this window. |
void |
minimize()
Minimizes this window. |
void |
pluginComponentAdded(PluginComponentEvent event)
Adds the associated with this PluginComponentEvent component to the appropriate container. |
void |
pluginComponentRemoved(PluginComponentEvent event)
Removes the associated with this PluginComponentEvent component from this container. |
void |
removeProtocolProvider(ProtocolProviderService protocolProvider)
Adds an account to the application. |
void |
removeProtocolSupportedOperationSets(ProtocolProviderService protocolProvider)
Removes all protocol supported operation sets. |
void |
removeProviderContactHandler(ProtocolProviderService protocolProvider)
Removes the ContactEventHandler corresponding to the given protocolProvider. |
void |
removeSearchFieldListener(TextFieldChangeListener l)
Removes the given TextFieldChangeListener that listens for any changes that occur in the search field. |
void |
requestFocusInCenterPanel()
Requests the focus in the center panel, which contains either the contact list or the unknown contact panel. |
void |
setContactList(MetaContactListService contactList)
Initializes the contact list panel. |
void |
setFrameVisible(boolean isVisible)
Implements setVisible in the UIService interface. |
void |
setParams(Object[] windowParams)
Implementation of ExportedWindow.setParams(Object[]). |
protected void |
windowClosed(WindowEvent event)
|
protected void |
windowClosing(WindowEvent event)
Overrides SIPCommFrame#windowClosing(WindowEvent). |
| Methods inherited from class net.java.sip.communicator.util.swing.SIPCommFrame |
|---|
addKeybindingAction, dispose, setKeybindingInput, setSizeAndLocation, setVisible, setVisible, update, validate |
| Methods inherited from class java.awt.Frame |
|---|
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface net.java.sip.communicator.service.gui.ExportedWindow |
|---|
isFocused, isVisible, setLocation, setSize, setVisible |
| Methods inherited from interface java.awt.MenuContainer |
|---|
getFont, postEvent |
| Constructor Detail |
|---|
public MainFrame()
| Method Detail |
|---|
public void requestFocusInCenterPanel()
public void initBounds()
public void enableUnknownContactView(boolean isEnabled)
isEnabled - true to enable the "unknown contact" view,
false - otherwise.public void setContactList(MetaContactListService contactList)
contactList - The MetaContactListService containing
the contact list data.public void addProtocolSupportedOperationSets(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider.public void removeProtocolSupportedOperationSets(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider.public Iterator<ProtocolProviderService> getProtocolProviders()
public ProtocolProviderService getProtocolProviderForAccount(String accountName)
accountName - The account user identifier.
public void addProtocolProvider(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider to add.public boolean hasProtocolProvider(ProtocolProviderService protocolProvider)
protocolProvider - the provider to check.
public void removeProtocolProvider(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider of the account.public int getProviderIndex(ProtocolProviderService protocolProvider)
protocolProvider - the protocol provider to search for
public void addAccount(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider of the account.public String getAccountAddress(ProtocolProviderService protocolProvider)
protocolProvider - the protocol provider corresponding to the
account to add
public String getAccountDisplayName(ProtocolProviderService protocolProvider)
protocolProvider - the protocol provider corresponding to the
account to add
public static OperationSetPresence getProtocolPresenceOpSet(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider for which the
presence operation set is searched.
public OperationSetWebContactInfo getWebContactInfoOpSet(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider for which the TN
is searched.
public OperationSetBasicTelephony<?> getTelephonyOpSet(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider for which the telephony
operation set is about.
public OperationSetAdHocMultiUserChat getAdHocMultiUserChatOpSet(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider for which the multi user
chat operation set is about.
public OperationSetMultiUserChat getMultiUserChatOpSet(ProtocolProviderService protocolProvider)
protocolProvider - The protocol provider for which the multi user
chat operation set is about.
public ContactListPane getContactListPanel()
public String getCurrentSearchText()
public void clearCurrentSearchText()
public void addSearchFieldListener(TextFieldChangeListener l)
l - the TextFieldChangeListener to addpublic void removeSearchFieldListener(TextFieldChangeListener l)
l - the TextFieldChangeListener to removepublic Object getProtocolProviderLastStatus(ProtocolProviderService protocolProvider)
protocolProvider - the protocol provider we're interested in.
protected void close(boolean isEscaped)
close in class SIPCommFrameisEscaped - indicates if this window has been closed by pressing
the escape keypublic MainMenu getMainMenu()
public void addProviderContactHandler(ProtocolProviderService protocolProvider,
ContactEventHandler contactHandler)
protocolProvider - the ProtocolProviderService, which
contacts should be handled by the given contactHandlercontactHandler - the ContactEventHandler that would handle
events coming from the UI for any contacts belonging to the given
providerpublic void removeProviderContactHandler(ProtocolProviderService protocolProvider)
protocolProvider - the protocol provider, which contact handler
we would like to removepublic ContactEventHandler getContactHandler(ProtocolProviderService protocolProvider)
protocolProvider - the ProtocolProviderService for which
we are searching a ContactEventHandler.
public void pluginComponentAdded(PluginComponentEvent event)
pluginComponentAdded in interface PluginComponentListenerevent - the PluginComponentEvent that has notified us of
the add of a plugin componentpublic void pluginComponentRemoved(PluginComponentEvent event)
pluginComponentRemoved in interface PluginComponentListenerevent - the PluginComponentEvent that notified us of the
remove of a plugin componentpublic void addNativePlugins()
public void bringToFront()
bringToFront in interface ExportedWindowpublic WindowID getIdentifier()
getIdentifier in interface ExportedWindowpublic Object getSource()
getSource in interface ExportedWindowpublic void maximize()
maximize in interface ExportedWindowpublic void minimize()
minimize in interface ExportedWindowpublic boolean isFrameVisible()
isVisible in the UIService interface. Checks if
the main application window is visible.
true if main application window is visible,
false otherwiseUIService.isVisible()public void setFrameVisible(boolean isVisible)
setVisible in the UIService interface. Shows or
hides the main application window depending on the parameter
visible.
isVisible - true if we are to show the main application frame and
false otherwise.UIService.setVisible(boolean)public AccountStatusPanel getAccountStatusPanel()
public void setParams(Object[] windowParams)
ExportedWindow.setParams(Object[]).
setParams in interface ExportedWindowwindowParams - the parameters to pass.protected void windowClosed(WindowEvent event)
event - Currently not usedprotected void windowClosing(WindowEvent event)
windowClosing in class SIPCommFrameevent - the WindowEvent that notified uspublic void ctrlEnterKeyTyped()
public void loadSkin()
loadSkin in interface Skinnable
|
Jitsi: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||