mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-22 06:02:11 +02:00
Bug 549013 - Eclipse menu won't display on Ubuntu 16.04 LTS when SSH/Serial command shells are opened
Buglink: https://bugs.eclipse.org/bugs/show_bug.cgi?id=549013 Signed-off-by: Julien Dehaudt <julien.dehaudt@st.com>
This commit is contained in:
parent
009ec61cff
commit
19351cbc2b
1 changed files with 14 additions and 11 deletions
|
@ -74,13 +74,12 @@ import org.eclipse.swt.dnd.Clipboard;
|
|||
import org.eclipse.swt.dnd.DND;
|
||||
import org.eclipse.swt.dnd.TextTransfer;
|
||||
import org.eclipse.swt.dnd.Transfer;
|
||||
import org.eclipse.swt.events.FocusEvent;
|
||||
import org.eclipse.swt.events.FocusListener;
|
||||
import org.eclipse.swt.events.KeyAdapter;
|
||||
import org.eclipse.swt.events.KeyEvent;
|
||||
import org.eclipse.swt.events.KeyListener;
|
||||
import org.eclipse.swt.events.MouseAdapter;
|
||||
import org.eclipse.swt.events.MouseEvent;
|
||||
import org.eclipse.swt.events.MouseTrackListener;
|
||||
import org.eclipse.swt.graphics.Font;
|
||||
import org.eclipse.swt.layout.GridData;
|
||||
import org.eclipse.swt.layout.GridLayout;
|
||||
|
@ -143,7 +142,7 @@ public class VT100TerminalControl implements ITerminalControlForText, ITerminalC
|
|||
private KeyListener fKeyHandler;
|
||||
private final ITerminalListener fTerminalListener;
|
||||
private String fMsg = ""; //$NON-NLS-1$
|
||||
private TerminalFocusListener fFocusListener;
|
||||
private TerminalMouseTrackListener fFocusListener;
|
||||
private ITerminalConnector fConnector;
|
||||
private final ITerminalConnector[] fConnectors;
|
||||
private final boolean fUseCommonPrefs;
|
||||
|
@ -793,10 +792,10 @@ public class VT100TerminalControl implements ITerminalControlForText, ITerminalC
|
|||
|
||||
protected void setupListeners() {
|
||||
fKeyHandler = new TerminalKeyHandler();
|
||||
fFocusListener = new TerminalFocusListener();
|
||||
fFocusListener = new TerminalMouseTrackListener();
|
||||
|
||||
getCtlText().addKeyListener(fKeyHandler);
|
||||
getCtlText().addFocusListener(fFocusListener);
|
||||
getCtlText().addMouseTrackListener(fFocusListener);
|
||||
|
||||
}
|
||||
|
||||
|
@ -878,17 +877,21 @@ public class VT100TerminalControl implements ITerminalControlForText, ITerminalC
|
|||
public VT100Emulator getTerminalText() {
|
||||
return fTerminalText;
|
||||
}
|
||||
protected class TerminalFocusListener implements FocusListener {
|
||||
protected class TerminalMouseTrackListener implements MouseTrackListener {
|
||||
private IContextActivation terminalContextActivation = null;
|
||||
private IContextActivation editContextActivation = null;
|
||||
|
||||
protected TerminalFocusListener() {
|
||||
protected TerminalMouseTrackListener() {
|
||||
super();
|
||||
}
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("cast")
|
||||
public void focusGained(FocusEvent event) {
|
||||
public void mouseHover(MouseEvent e) {
|
||||
}
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("cast")
|
||||
public void mouseEnter(MouseEvent e) {
|
||||
// Disable all keyboard accelerators (e.g., Control-B) so the Terminal view
|
||||
// can see every keystroke. Without this, Emacs, vi, and Bash are unusable
|
||||
// in the Terminal view.
|
||||
|
@ -900,8 +903,8 @@ public class VT100TerminalControl implements ITerminalControlForText, ITerminalC
|
|||
}
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("cast")
|
||||
public void focusLost(FocusEvent event) {
|
||||
@SuppressWarnings("cast")
|
||||
public void mouseExit(MouseEvent e) {
|
||||
// Enable all keybindings.
|
||||
captureKeyEvents(false);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue