Skip to content

Commit

Permalink
8274396: Suppress more warnings on non-serializable non-transient ins…
Browse files Browse the repository at this point in the history
…tance fields in client libs

Reviewed-by: bpb, naoto, serb, iris
  • Loading branch information
jddarcy committed Sep 28, 2021
1 parent e49e5b5 commit d8a278f
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,7 @@ public void removePropertyChangeListener(PropertyChangeListener l) {
}

private Font font;
@SuppressWarnings("serial") // Type of field is not Serializable
private Toolkit toolkit;
private String sampleText = "Abcde...";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,12 @@
// This class is final due to the 6607310 fix. Refer to the CR for details.
public final class CompositionArea extends JPanel implements InputMethodListener {

@SuppressWarnings("serial") // Type of field is not Serializable
private CompositionAreaHandler handler;

@SuppressWarnings("serial") // Type of field is not Serializable
private TextLayout composedTextLayout;
@SuppressWarnings("serial") // Type of field is not Serializable
private TextHitInfo caret = null;
private JFrame compositionWindow;
private static final int TEXT_ORIGIN_X = 5;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ public class InputMethodJFrame
extends JFrame
implements InputMethodWindow {

@SuppressWarnings("serial") // Type of field is not Serializable
InputContext inputContext = null;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ public class SimpleInputMethodWindow
extends Frame
implements InputMethodWindow {

@SuppressWarnings("serial") // Type of field is not Serializable
InputContext inputContext = null;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ public class PrinterJobWrapper implements PrintRequestAttribute {
@Serial
private static final long serialVersionUID = -8792124426995707237L;

@SuppressWarnings("serial") // Type of field is not Serializable
private PrinterJob job;

public PrinterJobWrapper(PrinterJob job) {
Expand Down

0 comments on commit d8a278f

Please sign in to comment.