< prev index next >
src/java.desktop/unix/classes/sun/awt/X11/XFileDialogPeer.java
Print this page
@@ -133,10 +133,11 @@
XFileDialogPeer(FileDialog target) {
super((Dialog)target);
this.target = target;
}
+ @SuppressWarnings("deprecation")
private void init(FileDialog target) {
fileDialog = target; //new Dialog(target, target.getTitle(), false);
this.title = target.getTitle();
this.mode = target.getMode();
this.target = target;
@@ -412,10 +413,11 @@
}
/**
* handle the cancel event
*/
+ @SuppressWarnings("deprecation")
void handleCancel() {
KeyboardFocusManager.getCurrentKeyboardFocusManager()
.removeKeyEventDispatcher(this);
setSelectionField(null);
@@ -433,19 +435,21 @@
}
/**
* handle the quit event
*/
+ @SuppressWarnings("deprecation")
void handleQuitButton() {
dir = null;
file = null;
target.hide();
}
/**
* set the entry of the new dir with f
*/
+ @SuppressWarnings("deprecation")
void setFilterEntry(String d, String f) {
File fe = new File(d);
if (fe.isDirectory() && fe.canRead()) {
// Fixed 6260659: File Name set programmatically in FileDialog is overridden during navigation, XToolkit
@@ -636,10 +640,11 @@
handleQuitButton();
}
}
}
+ @SuppressWarnings("deprecation")
public boolean dispatchKeyEvent(KeyEvent keyEvent) {
int id = keyEvent.getID();
int keyCode = keyEvent.getKeyCode();
if (id == KeyEvent.KEY_PRESSED && keyCode == KeyEvent.VK_ESCAPE) {
@@ -772,10 +777,11 @@
}
super.dispose();
}
// 03/02/2005 b5097243 Pressing 'ESC' on a file dlg does not dispose the dlg on Xtoolkit
+ @SuppressWarnings("deprecation")
public void setVisible(boolean b){
if (fileDialog == null) {
init(target);
}
@@ -850,10 +856,11 @@
class Separator extends Canvas {
public final static int HORIZONTAL = 0;
public final static int VERTICAL = 1;
int orientation;
+ @SuppressWarnings("deprecation")
public Separator(int length, int thickness, int orient) {
super();
orientation = orient;
if (orient == HORIZONTAL) {
resize(length, thickness);
@@ -861,10 +868,11 @@
// VERTICAL
resize(thickness, length);
}
}
+ @SuppressWarnings("deprecation")
public void paint(Graphics g) {
int x1, y1, x2, y2;
Rectangle bbox = bounds();
Color c = getBackground();
Color brighter = c.brighter();
< prev index next >