diff options
author | Damian Minkov <damencho@jitsi.org> | 2014-06-06 16:11:07 +0300 |
---|---|---|
committer | Damian Minkov <damencho@jitsi.org> | 2014-06-06 16:11:07 +0300 |
commit | 6bb76649e890519f1b3eeab7da63ebe36e3d6a7f (patch) | |
tree | 619490eada119f50526c6bba8867a07b7d3c2d27 /src | |
parent | 29c0cf0340d6335fc48b45808bb87dde33b344a8 (diff) | |
download | jitsi-6bb76649e890519f1b3eeab7da63ebe36e3d6a7f.zip jitsi-6bb76649e890519f1b3eeab7da63ebe36e3d6a7f.tar.gz jitsi-6bb76649e890519f1b3eeab7da63ebe36e3d6a7f.tar.bz2 |
Fixes copy text from chat conversation history and once again the losing focus of chat write area.
Diffstat (limited to 'src')
-rw-r--r-- | src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java | 30 | ||||
-rw-r--r-- | src/net/java/sip/communicator/impl/gui/main/chat/ChatWindow.java | 3 |
2 files changed, 2 insertions, 31 deletions
diff --git a/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java b/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java index bf325c6..a4f50c5 100644 --- a/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java +++ b/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java @@ -64,7 +64,6 @@ public class ChatPanel ChatRoomLocalUserRoleListener, ChatRoomMemberPropertyChangeListener, FileTransferStatusListener, - KeyEventDispatcher, Skinnable { /** @@ -229,9 +228,6 @@ public class ChatPanel } this.addComponentListener(new TabSelectionComponentListener()); - - KeyboardFocusManager.getCurrentKeyboardFocusManager() - .addKeyEventDispatcher(this); } /** @@ -449,9 +445,6 @@ public class ChatPanel */ public void dispose() { - KeyboardFocusManager.getCurrentKeyboardFocusManager() - .removeKeyEventDispatcher(this); - writeMessagePanel.dispose(); chatSession.dispose(); conversationPanel.dispose(); @@ -3122,27 +3115,4 @@ public class ChatPanel chatConferencesDialog.setCreatePanelEnabled(!available); chatConferencesDialog.setEndConferenceButtonEnabled(available); } - - /** - * Dispatches key events and process those that were generated when - * conversationPanel ChatTextPane is focused and they were targeting the - * write message panel. - * @param e the <tt>KeyEvent</tt> to dispatch. - * @return <tt>true</tt> if the KeyboardFocusManager should take no - * further action with regard to the KeyEvent; <tt>false</tt> - * otherwise. - */ - public boolean dispatchKeyEvent(KeyEvent e) - { - if(e.getSource() != conversationPanel.getChatTextPane() - || writeMessagePanel.getEditorPane().isFocusOwner()) - return false; - - writeMessagePanel.getEditorPane().requestFocusInWindow(); - - KeyboardFocusManager.getCurrentKeyboardFocusManager() - .redispatchEvent(writeMessagePanel.getEditorPane(), e); - - return true; - } } diff --git a/src/net/java/sip/communicator/impl/gui/main/chat/ChatWindow.java b/src/net/java/sip/communicator/impl/gui/main/chat/ChatWindow.java index f2e1725..ac0fea7 100644 --- a/src/net/java/sip/communicator/impl/gui/main/chat/ChatWindow.java +++ b/src/net/java/sip/communicator/impl/gui/main/chat/ChatWindow.java @@ -1288,7 +1288,8 @@ public class ChatWindow // Don't re-dispatch any events if the menu is active. Fixes the // navigation in the menu. - if (menuBar.isSelected()) + if (menuBar.getSelectedMenu() != null + && menuBar.getSelectedMenu().isPopupMenuVisible()) { return false; } |