1:
8:
9: package ;
10: import ;
11:
12:
22: public class WindowAttributes
23: {
24:
25: public final static long MASK_BUTTON_PRESS = 1L<< 2,
26: MASK_BUTTON_RELEASE = 1L<< 3,
27: MASK_EXPOSURE = 1L<<15,
28: MASK_STRUCTURE_NOTIFY = 1L<<17;
29:
30: public WindowAttributes()
31: {
32: init(null);
33: }
34:
35: public WindowAttributes(Window from)
36: {
37: initFromWindow(from);
38: }
39:
40: private native void initFromWindow(Window from);
41: private native void init(WindowAttributes copyFrom);
42: protected native void finalize();
43:
44: public Object clone()
45: {
46: try
47: {
48: WindowAttributes attributes = (WindowAttributes) super.clone();
49:
50: attributes.in = null;
51: attributes.out = null;
52:
53:
54:
55: attributes.init(this);
56: return attributes;
57: }
58: catch (CloneNotSupportedException ex)
59: {
60:
61: throw new InternalError ();
62: }
63: }
64:
65: public native void setBackground(long pixel);
66: public native void setBackground(Pixmap pixmap);
67: public native void setEventMask(long eventMask);
68:
69: public void setVisual(Visual visual)
70: {
71: this.visual = visual;
72: }
73:
74:
80: public native Visual getVisual();
81:
82: Display display;
83:
84:
88: RawData in = null;
89:
90:
94: RawData out = null;
95:
96: long mask;
97:
98:
99: Visual visual = null;
100:
101: public native void apply(Window window);
102:
103: final RawData getXSetWindowAttributesStructure()
104: {
105: if (out == null)
106: initOut();
107: return out;
108: }
109:
110: void initOut()
111: {
112: throw new UnsupportedOperationException("not implemented yet");
113: }
114: }