public DownloadForm(IOciResources ociResources, string namespaceName, string bucketName, string targetName, string regionName) { InitializeComponent(); OciResources = ociResources; NamespaceName = namespaceName; BucketName = bucketName; TargetName = targetName; RegionName = regionName; this.PathLab.Text = bucketName + "://" + targetName + "(" + regionName + ")"; IsBucket = string.IsNullOrEmpty(TargetName); if (!IsBucket) { IsFile = !TargetName.EndsWith("/") && !string.IsNullOrEmpty(TargetName); if (IsFile) { OptionFilenameSetButton.Checked = true; OptionSaveCheckBox.Enabled = false; } else { OptionRadioButtonA.Checked = true; OptionFilenameSetButton.Enabled = false; } } else { OptionRadioButtonA.Checked = true; OptionFilenameSetButton.Enabled = false; } }
public MainForm() { DoubleBuffered = true; InitializeComponent(); OciResources = new OciResources(); ObjectList.ContextMenuStrip = NormalMenuStrip; }
public UploadForm(IOciResources ociResources, string namespaceName, string bucketName, string targetPath, string regionName) { InitializeComponent(); OciResources = ociResources; NamespaceName = namespaceName; BucketName = bucketName; TargetPath = targetPath; RegionName = regionName; PathLab.Text = bucketName + "://" + targetPath + "(" + regionName + ")"; FileListView.ContextMenuStrip = MenuStrip; }
public NewAddForm(IOciResources ociResources, string namespaceName, string bucketName, string directoryName, string regionName, string compartmentId = "") { InitializeComponent(); OciResources = ociResources; NamespaceName = namespaceName; BucketName = bucketName; DirectoryName = directoryName; RegionName = regionName; CompartmentId = compartmentId; string compartmentName = ""; if (!string.IsNullOrEmpty(compartmentId)) { compartmentName = OciResources.GetCompartmentName(compartmentId); } IsBucket = string.IsNullOrEmpty(bucketName); if (IsBucket) { this.PathLab.Text = compartmentName + "/"; var regions = ociResources.GetRegions(); foreach (var region in regions) { RegionsBox.Items.Add(region.RegionName); } } else { this.PathLab.Text = compartmentName + "/" + bucketName + "://" + directoryName; RegionsBox.Items.Add(regionName); RegionsBox.Enabled = false; } }