/*
* Upload Panel
*/
this.fileTextField = new XBayaTextField();
XBayaLabel fileLabel = new XBayaLabel("Upload File Path", this.fileTextField);
this.uploadBucketTextField = new XBayaTextField();
XBayaLabel uploadBucketLabel = new XBayaLabel("Bucket Name", this.uploadBucketTextField);
GridPanel uploadPanel = new GridPanel();
uploadPanel.getSwingComponent().setBorder(BorderFactory.createTitledBorder("Upload"));
uploadPanel.add(fileLabel);
uploadPanel.add(this.fileTextField);
uploadPanel.add(uploadBucketLabel);
uploadPanel.add(this.uploadBucketTextField);
uploadPanel.layout(2, 2, GridPanel.WEIGHT_NONE, 1);
/*
* Download Panel
*/if (AmazonCredential.getInstance().getAwsAccessKeyId().equals("AKIAI3GNMQVYA5LSQNEQ")) { // Avoid to use
// default Aws
// Access Key
JOptionPane.showMessageDialog(AmazonS3UtilsWindow.this.dialog.getDialog(), "Aws Access Key not set!",
"Error", JOptionPane.ERROR_MESSAGE);
return;
}
this.downloadBucketTextField = new XBayaTextField();
XBayaLabel downloadBucketLabel = new XBayaLabel("Bucket Name", this.downloadBucketTextField);
this.keyTextField = new XBayaTextField();
XBayaLabel keyLabel = new XBayaLabel("Key Name", this.keyTextField);
this.folderTextField = new XBayaTextField();
XBayaLabel folderLabel = new XBayaLabel("Download Location", this.folderTextField);
GridPanel downloadPanel = new GridPanel();
downloadPanel.getSwingComponent().setBorder(BorderFactory.createTitledBorder("Download"));
downloadPanel.add(downloadBucketLabel);
downloadPanel.add(this.downloadBucketTextField);