01: /*
02: * Copyright Javelin Software, All rights reserved.
03: */
04:
05: package com.javelin.swinglets.plaf.wml;
06:
07: import java.awt.*;
08: import java.util.*;
09: import java.io.*;
10:
11: import javax.swing.*;
12:
13: import com.javelin.swinglets.*;
14: import com.javelin.swinglets.plaf.*;
15:
16: /**
17: * WMLHiddenUI defines a look and feel for default WML.
18: *
19: * @author Robin Sharp
20: */
21:
22: public class WMLHiddenUI extends WMLComponentUI {
23: /**
24: * Render the UI on the PrintWriter
25: */
26: public void update(PrintWriter out, SComponent c) {
27:
28: if (!c.isVisible())
29: return;
30:
31: SHidden hidden = (SHidden) c;
32:
33: out.print("<postfield name=\"");
34: out.print(hidden.getName());
35: out.print("\"");
36:
37: if (hidden.getValue() != null) {
38: out.print(" value=\"");
39: out.print(hidden.getValue());
40: out.print("\"");
41: }
42:
43: updateEvent(out, c);
44:
45: out.println(" />");
46:
47: }
48:
49: }
|