001
014
015 package com.liferay.taglib.ui;
016
017 import com.liferay.portal.kernel.util.StringPool;
018 import com.liferay.portal.kernel.util.Validator;
019 import com.liferay.taglib.util.IncludeTag;
020
021 import javax.servlet.http.HttpServletRequest;
022
023
026 public class FlashTag extends IncludeTag {
027
028 public void setAlign(String align) {
029 if (Validator.isNotNull(align)) {
030 _align = align;
031 }
032 }
033
034 public void setAllowFullScreen(String allowFullScreen) {
035 if (Validator.isNotNull(allowFullScreen)) {
036 _allowFullScreen = allowFullScreen;
037 }
038 }
039
040 public void setAllowScriptAccess(String allowScriptAccess) {
041 if (Validator.isNotNull(allowScriptAccess)) {
042 _allowScriptAccess = allowScriptAccess;
043 }
044 }
045
046 public void setBase(String base) {
047 if (Validator.isNotNull(base)) {
048 _base = base;
049 }
050 }
051
052 public void setBgcolor(String bgcolor) {
053 if (Validator.isNotNull(bgcolor)) {
054 _bgcolor = bgcolor;
055 }
056 }
057
058 public void setDevicefont(String devicefont) {
059 if (Validator.isNotNull(devicefont)) {
060 _devicefont = devicefont;
061 }
062 }
063
064 public void setFlashvars(String flashvars) {
065 if (Validator.isNotNull(flashvars)) {
066 _flashvars = flashvars;
067 }
068 }
069
070 public void setHeight(String height) {
071 if (Validator.isNotNull(height)) {
072 _height = height;
073 }
074 }
075
076 public void setId(String id) {
077 if (Validator.isNotNull(id)) {
078 _id = id;
079 }
080 }
081
082 public void setLoop(String loop) {
083 if (Validator.isNotNull(loop)) {
084 _loop = loop;
085 }
086 }
087
088 public void setMenu(String menu) {
089 if (Validator.isNotNull(menu)) {
090 _menu = menu;
091 }
092 }
093
094 public void setMovie(String movie) {
095 _movie = movie;
096 }
097
098 public void setPlay(String play) {
099 if (Validator.isNotNull(play)) {
100 _play = play;
101 }
102 }
103
104 public void setQuality(String quality) {
105 if (Validator.isNotNull(quality)) {
106 _quality = quality;
107 }
108 }
109
110 public void setSalign(String salign) {
111 if (Validator.isNotNull(salign)) {
112 _salign = salign;
113 }
114 }
115
116 public void setScale(String scale) {
117 if (Validator.isNotNull(scale)) {
118 _scale = scale;
119 }
120 }
121
122 public void setSwliveconnect(String swliveconnect) {
123 if (Validator.isNotNull(swliveconnect)) {
124 _swliveconnect = swliveconnect;
125 }
126 }
127
128 public void setVersion(String version) {
129 if (Validator.isNotNull(version)) {
130 _version = version;
131 }
132 }
133
134 public void setWidth(String width) {
135 if (Validator.isNotNull(width)) {
136 _width = width;
137 }
138 }
139
140 public void setWmode(String wmode) {
141 if (Validator.isNotNull(wmode)) {
142 _wmode = wmode;
143 }
144 }
145
146 @Override
147 protected void cleanUp() {
148 _align = "left";
149 _allowFullScreen = Boolean.FALSE.toString();
150 _allowScriptAccess = "sameDomain";
151 _base = StringPool.PERIOD;
152 _bgcolor = "#FFFFFF";
153 _devicefont = Boolean.TRUE.toString();
154 _flashvars = StringPool.BLANK;
155 _height = "500";
156 _id = StringPool.BLANK;
157 _loop = Boolean.TRUE.toString();
158 _menu = Boolean.FALSE.toString();
159 _movie = StringPool.BLANK;
160 _play = Boolean.FALSE.toString();
161 _quality = "best";
162 _salign = StringPool.BLANK;
163 _scale = "showall";
164 _swliveconnect = Boolean.FALSE.toString();
165 _version = "7";
166 _width = "100%";
167 _wmode = "opaque";
168 }
169
170 @Override
171 protected String getPage() {
172 return _PAGE;
173 }
174
175 @Override
176 protected void setAttributes(HttpServletRequest request) {
177 request.setAttribute("liferay-ui:flash:align", _align);
178 request.setAttribute(
179 "liferay-ui:flash:allowFullScreen", _allowFullScreen);
180 request.setAttribute(
181 "liferay-ui:flash:allowScriptAccess", _allowScriptAccess);
182 request.setAttribute("liferay-ui:flash:base", _base);
183 request.setAttribute("liferay-ui:flash:bgcolor", _bgcolor);
184 request.setAttribute("liferay-ui:flash:devicefont", _devicefont);
185 request.setAttribute("liferay-ui:flash:flashvars", _flashvars);
186 request.setAttribute("liferay-ui:flash:height", _height);
187 request.setAttribute("liferay-ui:flash:id", _id);
188 request.setAttribute("liferay-ui:flash:loop", _loop);
189 request.setAttribute("liferay-ui:flash:menu", _menu);
190 request.setAttribute("liferay-ui:flash:movie", _movie);
191 request.setAttribute("liferay-ui:flash:play", _play);
192 request.setAttribute("liferay-ui:flash:quality", _quality);
193 request.setAttribute("liferay-ui:flash:salign", _salign);
194 request.setAttribute("liferay-ui:flash:scale", _scale);
195 request.setAttribute("liferay-ui:flash:swliveconnect", _swliveconnect);
196 request.setAttribute("liferay-ui:flash:version", _version);
197 request.setAttribute("liferay-ui:flash:width", _width);
198 request.setAttribute("liferay-ui:flash:wmode", _wmode);
199 }
200
201 private static final String _PAGE = "/html/taglib/ui/flash/page.jsp";
202
203 private String _align = "left";
204 private String _allowFullScreen = Boolean.FALSE.toString();
205 private String _allowScriptAccess = "sameDomain";
206 private String _base = StringPool.PERIOD;
207 private String _bgcolor = "#FFFFFF";
208 private String _devicefont = Boolean.TRUE.toString();
209 private String _flashvars = StringPool.BLANK;
210 private String _height = "500";
211 private String _id = StringPool.BLANK;
212 private String _loop = Boolean.TRUE.toString();
213 private String _menu = Boolean.FALSE.toString();
214 private String _movie = StringPool.BLANK;
215 private String _play = Boolean.FALSE.toString();
216 private String _quality = "best";
217 private String _salign = StringPool.BLANK;
218 private String _scale = "showall";
219 private String _swliveconnect = Boolean.FALSE.toString();
220 private String _version = "7";
221 private String _width = "100%";
222 private String _wmode = "opaque";
223
224 }