hide the cursor
This commit is contained in:
parent
92f1a7282a
commit
28989f2511
|
@ -3,6 +3,7 @@ package de.ctdo.crashtest.gui;
|
||||||
import javax.swing.*;
|
import javax.swing.*;
|
||||||
import java.awt.*;
|
import java.awt.*;
|
||||||
import java.awt.event.*;
|
import java.awt.event.*;
|
||||||
|
import java.awt.image.BufferedImage;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
@ -20,6 +21,11 @@ public class MainGui extends JFrame implements IGuiControl {
|
||||||
setExtendedState(Frame.MAXIMIZED_BOTH);
|
setExtendedState(Frame.MAXIMIZED_BOTH);
|
||||||
setUndecorated(true);
|
setUndecorated(true);
|
||||||
|
|
||||||
|
setCursor(getToolkit().createCustomCursor( new BufferedImage(3, 3, BufferedImage.TYPE_INT_ARGB),
|
||||||
|
new Point(0, 0), "null"));
|
||||||
|
textWall.setCursor(getToolkit().createCustomCursor( new BufferedImage(3, 3, BufferedImage.TYPE_INT_ARGB),
|
||||||
|
new Point(0, 0), "null"));
|
||||||
|
|
||||||
addKeyListener(new KeyAdapter() {
|
addKeyListener(new KeyAdapter() {
|
||||||
@Override
|
@Override
|
||||||
public void keyTyped(KeyEvent e) {
|
public void keyTyped(KeyEvent e) {
|
||||||
|
@ -34,7 +40,7 @@ public class MainGui extends JFrame implements IGuiControl {
|
||||||
addWindowListener(new WindowAdapter() {
|
addWindowListener(new WindowAdapter() {
|
||||||
@Override
|
@Override
|
||||||
public void windowClosing(WindowEvent e) {
|
public void windowClosing(WindowEvent e) {
|
||||||
for(GuiEventListener listener: listenerList) {
|
for (GuiEventListener listener : listenerList) {
|
||||||
listener.windowClosing();
|
listener.windowClosing();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -118,7 +124,8 @@ public class MainGui extends JFrame implements IGuiControl {
|
||||||
final Runnable runnable = new Runnable() {
|
final Runnable runnable = new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
extraField.setText(text + " ");
|
String txt = text.substring(0, Math.min(text.length(), 8));
|
||||||
|
extraField.setText(txt + " ");
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue