1 26 27 package org.objectweb.openccm.packaging.widgets; 28 29 36 public class PropertiesSimpleType 37 extends org.objectweb.apollon.gui.bricks.AbstractBrick 38 { 39 45 46 private javax.swing.JComboBox scrolling_list; 47 48 54 57 public 58 PropertiesSimpleType () 59 { 60 this("type"); 61 } 62 63 public 64 PropertiesSimpleType (String label) 65 { 66 super(label); 67 68 String [] values 70 = { 71 "boolean" 72 ,"char" 73 ,"double" 74 ,"float" 75 ,"short" 76 ,"long" 77 ,"objref" 78 ,"octet" 79 ,"string" 80 ,"ulong" 81 ,"ushort" 82 ,"longlong" 83 ,"ulonglong" 84 ,"longdouble" 85 ,"wchar" 86 ,"wstring" 87 ,"fixed" 88 }; 89 90 scrolling_list = new javax.swing.JComboBox (values); 92 93 set("string"); 95 scrolling_list.validate(); 96 97 this.add(this.scrolling_list); 98 } 99 100 106 109 public String 110 get() 111 { 112 return (String )this.scrolling_list.getSelectedItem(); 113 } 114 115 118 public void 119 set (String line_text) 120 { 121 this.scrolling_list.setSelectedItem(line_text); 122 } 123 124 } 125 | Popular Tags |