1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.krad.uif.widget;
17
18 import org.apache.commons.lang.StringUtils;
19 import org.kuali.rice.krad.datadictionary.parse.BeanTag;
20 import org.kuali.rice.krad.datadictionary.parse.BeanTagAttribute;
21
22 import java.util.HashMap;
23 import java.util.Map;
24
25
26
27
28
29
30
31
32
33
34
35 @BeanTag(name = "blockUI-bean", parent = "Uif-BlockUI")
36 public class BlockUI extends WidgetBase {
37
38 private String blockingImageSource;
39
40 public BlockUI() {
41 super();
42 }
43
44
45
46
47
48
49 @Override
50 public Map<String, String> getTemplateOptions() {
51 Map<String, String> templateOptions = super.getTemplateOptions();
52
53 if (templateOptions == null) {
54 super.setTemplateOptions(templateOptions = new HashMap<String, String>());
55 }
56
57 if (StringUtils.isNotBlank(blockingImageSource) && !templateOptions.containsKey("blockingImage")) {
58 templateOptions.put("blockingImage", blockingImageSource);
59 }
60
61 return templateOptions;
62 }
63
64
65
66
67
68
69
70
71
72
73
74 @BeanTagAttribute(name="blockingImageSource")
75 public String getBlockingImageSource() {
76 return blockingImageSource;
77 }
78
79
80
81
82
83
84 public void setBlockingImageSource(String blockingImageSource) {
85 this.blockingImageSource = blockingImageSource;
86 }
87
88
89
90
91 @Override
92 protected <T> void copyProperties(T component) {
93 super.copyProperties(component);
94 BlockUI blockUICopy = (BlockUI) component;
95 blockUICopy.setBlockingImageSource(this.blockingImageSource);
96 }
97 }