use of com.jsql.view.swing.action.ActionCheckIP in project jsql-injection by ron190.
the class PanelPreferences method initializePanelProxy.
private void initializePanelProxy() {
panelProxy.setLayout(new BoxLayout(panelProxy, BoxLayout.Y_AXIS));
panelProxy.setBorder(this.panelBorder);
final var buttonCheckIp = new JButton("Check your IP");
buttonCheckIp.addActionListener(new ActionCheckIP());
buttonCheckIp.setToolTipText("<html><b>Verify what public IP address is used by jSQL</b><br>" + "Usually it's your own public IP if you don't use a proxy. If you use a proxy<br>" + "like TOR then your public IP is hidden and another one is used instead.</html>");
buttonCheckIp.setContentAreaFilled(true);
buttonCheckIp.setBorder(UiUtil.BORDER_ROUND_BLU);
var flatButtonMouseAdapter = new FlatButtonMouseAdapter(buttonCheckIp);
flatButtonMouseAdapter.setContentVisible(true);
buttonCheckIp.addMouseListener(flatButtonMouseAdapter);
var labelProxy = new JLabel("<html><b>Proxy</b> / Settings for tools like Burp and Tor</html>");
panelProxy.removeAll();
panelProxy.add(labelProxy, BorderLayout.NORTH);
panelProxy.add(this.panelProxyPreferences);
var panelCheckIp = new JPanel(new FlowLayout(FlowLayout.LEADING, 0, 0));
panelCheckIp.setBorder(BorderFactory.createEmptyBorder(15, 0, 0, 0));
panelCheckIp.add(buttonCheckIp);
panelCheckIp.add(Box.createGlue());
panelProxy.add(panelCheckIp);
labelProxy.setAlignmentX(Component.LEFT_ALIGNMENT);
this.panelProxyPreferences.setAlignmentX(Component.LEFT_ALIGNMENT);
panelCheckIp.setAlignmentX(Component.LEFT_ALIGNMENT);
}
Aggregations