Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
04/23/10 07:38:24 (15 years ago)
Author:
gkronber
Message:

Reintegrated plugin administration controls. #989

Location:
trunk/sources/HeuristicLab.PluginInfrastructure/Advanced
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.PluginInfrastructure/Advanced/InstallationManagerForm.Designer.cs

    r3508 r3509  
    5353      this.localPluginsTabPage = new System.Windows.Forms.TabPage();
    5454      this.updateButton = new System.Windows.Forms.Button();
    55       this.localPluginManagerView = new HeuristicLab.PluginInfrastructure.Advanced.LocalPluginManagerView();
    5655      this.availablePluginsTabPage = new System.Windows.Forms.TabPage();
    57       this.remotePluginInstaller = new HeuristicLab.PluginInfrastructure.Advanced.RemotePluginInstallerView();
    5856      this.refreshButton = new System.Windows.Forms.Button();
     57      this.uploadPluginsTabPage = new System.Windows.Forms.TabPage();
     58      this.manageProductsTabPage = new System.Windows.Forms.TabPage();
    5959      this.logTabPage = new System.Windows.Forms.TabPage();
    6060      this.logTextBox = new System.Windows.Forms.TextBox();
     
    6565      this.optionsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
    6666      this.connectionSettingsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
    67       this.uploadPluginsTabPage = new System.Windows.Forms.TabPage();
    68       this.manageProductsTabPage = new System.Windows.Forms.TabPage();
     67      this.localPluginManagerView = new HeuristicLab.PluginInfrastructure.Advanced.LocalPluginManagerView();
     68      this.remotePluginInstaller = new HeuristicLab.PluginInfrastructure.Advanced.RemotePluginInstallerView();
     69      this.pluginEditor = new HeuristicLab.PluginInfrastructure.Advanced.PluginEditor();
     70      this.productEditor = new HeuristicLab.PluginInfrastructure.Advanced.ProductEditor();
    6971      this.statusStrip.SuspendLayout();
    7072      this.tabControl.SuspendLayout();
    7173      this.localPluginsTabPage.SuspendLayout();
    7274      this.availablePluginsTabPage.SuspendLayout();
     75      this.uploadPluginsTabPage.SuspendLayout();
     76      this.manageProductsTabPage.SuspendLayout();
    7377      this.logTabPage.SuspendLayout();
    7478      this.menuStrip.SuspendLayout();
     
    170174      this.updateButton.Click += new System.EventHandler(this.updateAllButton_Click);
    171175      //
    172       // localPluginManagerView
    173       //
    174       this.localPluginManagerView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    175                   | System.Windows.Forms.AnchorStyles.Left)
    176                   | System.Windows.Forms.AnchorStyles.Right)));
    177       this.localPluginManagerView.Location = new System.Drawing.Point(6, 6);
    178       this.localPluginManagerView.Name = "localPluginManagerView";
    179       this.localPluginManagerView.Plugins = null;
    180       this.localPluginManagerView.Size = new System.Drawing.Size(569, 293);
    181       this.localPluginManagerView.TabIndex = 0;
    182       this.localPluginManagerView.ItemChecked += new System.Windows.Forms.ItemCheckedEventHandler(this.localPluginManager_ItemChecked);
    183       //
    184176      // availablePluginsTabPage
    185177      //
     
    195187      this.availablePluginsTabPage.UseVisualStyleBackColor = true;
    196188      //
    197       // remotePluginInstaller
    198       //
    199       this.remotePluginInstaller.AllPlugins = new HeuristicLab.PluginInfrastructure.IPluginDescription[0];
    200       this.remotePluginInstaller.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    201                   | System.Windows.Forms.AnchorStyles.Left)
    202                   | System.Windows.Forms.AnchorStyles.Right)));
    203       this.remotePluginInstaller.Location = new System.Drawing.Point(6, 6);
    204       this.remotePluginInstaller.Name = "remotePluginInstaller";
    205       this.remotePluginInstaller.NewPlugins = new HeuristicLab.PluginInfrastructure.IPluginDescription[0];
    206       this.remotePluginInstaller.Products = new HeuristicLab.PluginInfrastructure.Advanced.DeploymentService.ProductDescription[0];
    207       this.remotePluginInstaller.ShowAllPlugins = false;
    208       this.remotePluginInstaller.Size = new System.Drawing.Size(571, 293);
    209       this.remotePluginInstaller.TabIndex = 14;
    210       this.remotePluginInstaller.ItemChecked += new System.Windows.Forms.ItemCheckedEventHandler(this.remotePluginInstaller_ItemChecked);
    211       //
    212189      // refreshButton
    213190      //
     
    223200      this.refreshButton.Click += new System.EventHandler(this.refreshRemoteButton_Click);
    224201      //
     202      // uploadPluginsTabPage
     203      //
     204      this.uploadPluginsTabPage.Controls.Add(this.pluginEditor);
     205      this.uploadPluginsTabPage.Location = new System.Drawing.Point(4, 22);
     206      this.uploadPluginsTabPage.Name = "uploadPluginsTabPage";
     207      this.uploadPluginsTabPage.Padding = new System.Windows.Forms.Padding(3);
     208      this.uploadPluginsTabPage.Size = new System.Drawing.Size(583, 342);
     209      this.uploadPluginsTabPage.TabIndex = 3;
     210      this.uploadPluginsTabPage.Text = "Upload Plugins";
     211      this.uploadPluginsTabPage.UseVisualStyleBackColor = true;
     212      //
     213      // manageProductsTabPage
     214      //
     215      this.manageProductsTabPage.Controls.Add(this.productEditor);
     216      this.manageProductsTabPage.Location = new System.Drawing.Point(4, 22);
     217      this.manageProductsTabPage.Name = "manageProductsTabPage";
     218      this.manageProductsTabPage.Padding = new System.Windows.Forms.Padding(3);
     219      this.manageProductsTabPage.Size = new System.Drawing.Size(583, 342);
     220      this.manageProductsTabPage.TabIndex = 4;
     221      this.manageProductsTabPage.Text = "Manage Products";
     222      this.manageProductsTabPage.UseVisualStyleBackColor = true;
     223      //
    225224      // logTabPage
    226225      //
     
    301300      this.connectionSettingsToolStripMenuItem.Click += new System.EventHandler(this.connectionSettingsToolStripMenuItem_Click);
    302301      //
    303       // uploadPluginsTabPage
    304       //
    305       this.uploadPluginsTabPage.Location = new System.Drawing.Point(4, 22);
    306       this.uploadPluginsTabPage.Name = "uploadPluginsTabPage";
    307       this.uploadPluginsTabPage.Padding = new System.Windows.Forms.Padding(3);
    308       this.uploadPluginsTabPage.Size = new System.Drawing.Size(583, 342);
    309       this.uploadPluginsTabPage.TabIndex = 3;
    310       this.uploadPluginsTabPage.Text = "Upload Plugins";
    311       this.uploadPluginsTabPage.UseVisualStyleBackColor = true;
    312       //
    313       // manageProductsTabPage
    314       //
    315       this.manageProductsTabPage.Location = new System.Drawing.Point(4, 22);
    316       this.manageProductsTabPage.Name = "manageProductsTabPage";
    317       this.manageProductsTabPage.Padding = new System.Windows.Forms.Padding(3);
    318       this.manageProductsTabPage.Size = new System.Drawing.Size(583, 342);
    319       this.manageProductsTabPage.TabIndex = 4;
    320       this.manageProductsTabPage.Text = "Manage Products";
    321       this.manageProductsTabPage.UseVisualStyleBackColor = true;
     302      // localPluginManagerView
     303      //
     304      this.localPluginManagerView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
     305                  | System.Windows.Forms.AnchorStyles.Left)
     306                  | System.Windows.Forms.AnchorStyles.Right)));
     307      this.localPluginManagerView.Location = new System.Drawing.Point(6, 6);
     308      this.localPluginManagerView.Name = "localPluginManagerView";
     309      this.localPluginManagerView.Plugins = null;
     310      this.localPluginManagerView.Size = new System.Drawing.Size(569, 293);
     311      this.localPluginManagerView.TabIndex = 0;
     312      this.localPluginManagerView.ItemChecked += new System.Windows.Forms.ItemCheckedEventHandler(this.localPluginManager_ItemChecked);
     313      //
     314      // remotePluginInstaller
     315      //
     316      this.remotePluginInstaller.AllPlugins = new HeuristicLab.PluginInfrastructure.IPluginDescription[0];
     317      this.remotePluginInstaller.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
     318                  | System.Windows.Forms.AnchorStyles.Left)
     319                  | System.Windows.Forms.AnchorStyles.Right)));
     320      this.remotePluginInstaller.Location = new System.Drawing.Point(6, 6);
     321      this.remotePluginInstaller.Name = "remotePluginInstaller";
     322      this.remotePluginInstaller.NewPlugins = new HeuristicLab.PluginInfrastructure.IPluginDescription[0];
     323      this.remotePluginInstaller.Products = new HeuristicLab.PluginInfrastructure.Advanced.DeploymentService.ProductDescription[0];
     324      this.remotePluginInstaller.ShowAllPlugins = false;
     325      this.remotePluginInstaller.Size = new System.Drawing.Size(571, 293);
     326      this.remotePluginInstaller.TabIndex = 14;
     327      this.remotePluginInstaller.ItemChecked += new System.Windows.Forms.ItemCheckedEventHandler(this.remotePluginInstaller_ItemChecked);
     328      //
     329      // pluginEditor
     330      //
     331      this.pluginEditor.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
     332                  | System.Windows.Forms.AnchorStyles.Left)
     333                  | System.Windows.Forms.AnchorStyles.Right)));
     334      this.pluginEditor.Location = new System.Drawing.Point(6, 6);
     335      this.pluginEditor.Name = "pluginEditor";
     336      this.pluginEditor.Size = new System.Drawing.Size(571, 330);
     337      this.pluginEditor.TabIndex = 0;
     338      //
     339      // productEditor
     340      //
     341      this.productEditor.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
     342                  | System.Windows.Forms.AnchorStyles.Left)
     343                  | System.Windows.Forms.AnchorStyles.Right)));
     344      this.productEditor.Location = new System.Drawing.Point(6, 6);
     345      this.productEditor.Name = "productEditor";
     346      this.productEditor.Size = new System.Drawing.Size(571, 330);
     347      this.productEditor.TabIndex = 0;
    322348      //
    323349      // InstallationManagerForm
     
    338364      this.localPluginsTabPage.ResumeLayout(false);
    339365      this.availablePluginsTabPage.ResumeLayout(false);
     366      this.uploadPluginsTabPage.ResumeLayout(false);
     367      this.manageProductsTabPage.ResumeLayout(false);
    340368      this.logTabPage.ResumeLayout(false);
    341369      this.logTabPage.PerformLayout();
     
    371399    private System.Windows.Forms.TabPage uploadPluginsTabPage;
    372400    private System.Windows.Forms.TabPage manageProductsTabPage;
     401    private PluginEditor pluginEditor;
     402    private ProductEditor productEditor;
    373403  }
    374404}
  • trunk/sources/HeuristicLab.PluginInfrastructure/Advanced/PluginComparisonView.cs

    r3474 r3509  
    3636  internal partial class PluginComparisonView : Form {
    3737
    38     public PluginComparisonView(PluginDescription localPlugin, PluginDescription serverPlugin) {
     38    public PluginComparisonView(IPluginDescription localPlugin, IPluginDescription serverPlugin) {
    3939      InitializeComponent();
    4040      //Caption = "Compare plugins";
  • trunk/sources/HeuristicLab.PluginInfrastructure/Advanced/PluginEditor.cs

    r3474 r3509  
    3131using ICSharpCode.SharpZipLib.Zip;
    3232using System.IO;
     33using HeuristicLab.PluginInfrastructure.Manager;
    3334
    3435namespace HeuristicLab.PluginInfrastructure.Advanced {
    35   internal partial class PluginEditor : InstallationManagerControl {
    36     private Dictionary<IPluginDescription, DeploymentService.PluginDescription> localAndServerPlugins;
     36  internal partial class PluginEditor : UserControl {
     37    private Dictionary<IPluginDescription, IPluginDescription> localAndServerPlugins;
    3738    private BackgroundWorker pluginUploadWorker;
    3839    private BackgroundWorker updateServerPluginsWorker;
     
    4243      // Caption = "Upload Plugins";
    4344
    44       localAndServerPlugins = new Dictionary<IPluginDescription, DeploymentService.PluginDescription>();
     45      localAndServerPlugins = new Dictionary<IPluginDescription, IPluginDescription>();
    4546
    4647      #region initialize backgroundworkers
     
    6465        }
    6566        // refresh server plugins (find matching local plugins)
    66         var plugins = (DeploymentService.PluginDescription[])e.Result;
     67        var plugins = (IPluginDescription[])e.Result;
    6768        foreach (var plugin in plugins) {
    6869          var matchingLocalPlugin = (from localPlugin in localAndServerPlugins.Keys
     
    168169    private void listView_ItemActivate(object sender, EventArgs e) {
    169170      foreach (var item in listView.SelectedItems) {
    170         var plugin = (IPluginDescription)((ListViewItem)item).Tag;
     171        var plugin = (PluginDescription)((ListViewItem)item).Tag;
    171172        var compView = new PluginComparisonView(plugin, localAndServerPlugins[plugin]);
    172173        compView.Show();
  • trunk/sources/HeuristicLab.PluginInfrastructure/Advanced/PluginView.cs

    r3474 r3509  
    3737    private const string IMAGE_KEY_DOCUMENT = "Document";
    3838
    39     private PluginDescription plugin;
     39    private IPluginDescription plugin;
    4040
    4141    public PluginView() {
     
    4444    }
    4545
    46     public PluginView(PluginDescription plugin) {
     46    public PluginView(IPluginDescription plugin) {
    4747      InitializeComponent();
    4848      PopulateImageList();
     
    6565      contactTextBox.Text = CombineStrings(plugin.ContactName, plugin.ContactEmail);
    6666      descriptionTextBox.Text = plugin.Description;
    67       stateTextBox.Text = plugin.PluginState.ToString();
    68       errorTextBox.Text = plugin.LoadingErrorInformation;
     67      var localPlugin = plugin as PluginDescription;
     68      if (localPlugin != null) {
     69        stateTextBox.Text = localPlugin.PluginState.ToString();
     70        errorTextBox.Text = localPlugin.LoadingErrorInformation;
     71      }
    6972      foreach (PluginDescription dependency in plugin.Dependencies) {
    7073        var depItem = new ListViewItem(new string[] { dependency.Name, dependency.Version.ToString() });
Note: See TracChangeset for help on using the changeset viewer.