|
From: <du...@us...> - 2007-04-07 09:44:23
|
Revision: 294
http://mp-plugins.svn.sourceforge.net/mp-plugins/?rev=294&view=rev
Author: dukus
Date: 2007-04-07 02:44:22 -0700 (Sat, 07 Apr 2007)
Log Message:
-----------
Modified Paths:
--------------
trunk/plugins/mpinstaler/MPInstaler/MPInstaler.csproj
trunk/plugins/mpinstaler/MPInstaler/MPinstalerStruct.cs
trunk/plugins/mpinstaler/MPInstaler/wizard/wizard_1.cs
Added Paths:
-----------
trunk/plugins/mpinstaler/MPInstaler/MPIutils.cs
Modified: trunk/plugins/mpinstaler/MPInstaler/MPInstaler.csproj
===================================================================
--- trunk/plugins/mpinstaler/MPInstaler/MPInstaler.csproj 2007-04-07 08:26:43 UTC (rev 293)
+++ trunk/plugins/mpinstaler/MPInstaler/MPInstaler.csproj 2007-04-07 09:44:22 UTC (rev 294)
@@ -189,6 +189,7 @@
<Compile Include="wizard\controlp.Designer.cs">
<DependentUpon>controlp.cs</DependentUpon>
</Compile>
+ <Compile Include="MPIutils.cs" />
<Compile Include="wizard\wizard_1.cs">
<SubType>Form</SubType>
</Compile>
Added: trunk/plugins/mpinstaler/MPInstaler/MPIutils.cs
===================================================================
--- trunk/plugins/mpinstaler/MPInstaler/MPIutils.cs (rev 0)
+++ trunk/plugins/mpinstaler/MPInstaler/MPIutils.cs 2007-04-07 09:44:22 UTC (rev 294)
@@ -0,0 +1,22 @@
+using System;
+using System.Diagnostics;
+using System.Collections.Generic;
+using System.Text;
+
+namespace MPInstaler
+{
+ public class MPIutils
+ {
+ public MPIutils()
+ {
+ }
+
+ static public void StartApp(string file)
+ {
+ Process app = new Process();
+ app.StartInfo.FileName = file;
+ app.StartInfo.Arguments = "";
+ app.Start();
+ }
+ }
+}
Modified: trunk/plugins/mpinstaler/MPInstaler/MPinstalerStruct.cs
===================================================================
--- trunk/plugins/mpinstaler/MPInstaler/MPinstalerStruct.cs 2007-04-07 08:26:43 UTC (rev 293)
+++ trunk/plugins/mpinstaler/MPInstaler/MPinstalerStruct.cs 2007-04-07 09:44:22 UTC (rev 294)
@@ -707,6 +707,23 @@
else return false;
}
+ public void ExecuteAction()
+ {
+ switch (Place)
+ {
+ case "POSTSETUP":
+ switch (Id)
+ {
+ case 0:
+ MPIutils.StartApp(Config.GetFile(Config.Dir.Base,Command));
+ break;
+ case 1:
+ break;
+ }
+ break;
+ }
+ }
+
override public string ToString()
{
string x_ret = string.Empty;
Modified: trunk/plugins/mpinstaler/MPInstaler/wizard/wizard_1.cs
===================================================================
--- trunk/plugins/mpinstaler/MPInstaler/wizard/wizard_1.cs 2007-04-07 08:26:43 UTC (rev 293)
+++ trunk/plugins/mpinstaler/MPInstaler/wizard/wizard_1.cs 2007-04-07 09:44:22 UTC (rev 294)
@@ -14,6 +14,7 @@
public int step = 0;
public MPpackageStruct package;
MPInstallHelper inst = new MPInstallHelper();
+ List<ActionInfo> actions = new List<ActionInfo>();
public wizard_1()
{
package = new MPpackageStruct();
@@ -188,6 +189,7 @@
ActionInfo ac = package._intalerStruct.FindAction("POSTSETUP");
if (ac != null)
{
+ actions.Add(ac);
listBox1.Visible = false;
skinlister.Items.Clear();
skinlister.Visible = true;
@@ -244,7 +246,19 @@
private void button_cancel_Click(object sender, EventArgs e)
{
- this.Close();
+ if (step == 7)
+ {
+ foreach (ActionInfo ac in actions)
+ {
+ int i=skinlister.Items.IndexOf(ac.ToString());
+ if (skinlister.GetSelected(i))
+ ac.ExecuteAction();
+ }
+ }
+ else
+ {
+ this.Close();
+ }
}
private void button_back_Click(object sender, EventArgs e)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|