MCPcopy Index your code
hub / github.com/benfry/processing4 / buildLayout

Method buildLayout

app/src/processing/app/contrib/StatusPanel.java:86–194  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

84
85
86 protected void buildLayout() {
87 iconLabel = new JLabel();
88 iconLabel.setHorizontalAlignment(SwingConstants.CENTER);
89
90 label = new JTextPane();
91 label.setEditable(false);
92 label.setOpaque(false);
93 label.setContentType("text/html");
94 label.addHyperlinkListener(e -> {
95 if (e.getEventType() == HyperlinkEvent.EventType.ACTIVATED) {
96 if (e.getURL() != null) {
97 Platform.openURL(e.getURL().toString());
98 }
99 }
100 });
101 //installButton = Toolkit.createIconButton("Install", installIcon);
102 installButton = new JButton("Install");
103 //installButton.setDisabledIcon(installIcon);
104// installButton.setFont(buttonFont);
105 installButton.setHorizontalAlignment(SwingConstants.LEFT);
106 installButton.addActionListener(e -> {
107 installButton.setEnabled(false);
108 StatusDetail currentDetail =
109 contributionTab.listPanel.getSelectedDetail();
110 currentDetail.installContrib(contributionTab.listPanel);
111 applyDetail(currentDetail);
112 });
113
114 buildProgressBar();
115
116 updateLabel = new JLabel(" ");
117// updateLabel.setFont(buttonFont);
118 updateLabel.setHorizontalAlignment(SwingConstants.CENTER);
119
120 //updateButton = Toolkit.createIconButton("Update", updateIcon);
121 updateButton = new JButton("Update");
122// updateButton.setFont(buttonFont);
123 updateButton.setHorizontalAlignment(SwingConstants.LEFT);
124 updateButton.addActionListener(e -> {
125 updateButton.setEnabled(false);
126 StatusDetail currentDetail =
127 contributionTab.listPanel.getSelectedDetail();
128 currentDetail.updateContrib(contributionTab.listPanel);
129 applyDetail(currentDetail);
130 });
131
132 //removeButton = Toolkit.createIconButton("Remove", removeIcon);
133 removeButton = new JButton("Remove");
134// removeButton.setFont(buttonFont);
135 removeButton.setHorizontalAlignment(SwingConstants.LEFT);
136 removeButton.addActionListener(e -> {
137 removeButton.setEnabled(false);
138 StatusDetail currentPanel =
139 contributionTab.listPanel.getSelectedDetail();
140 currentPanel.removeContrib();
141 applyDetail(currentPanel);
142 });
143

Callers 1

StatusPanelMethod · 0.95

Calls 11

openURLMethod · 0.95
installContribMethod · 0.95
applyDetailMethod · 0.95
buildProgressBarMethod · 0.95
updateContribMethod · 0.95
removeContribMethod · 0.95
setEditableMethod · 0.80
getSelectedDetailMethod · 0.80
addGapMethod · 0.80
setVisibleMethod · 0.65
toStringMethod · 0.45

Tested by

no test coverage detected