Skip to content
Permalink
Browse files

Added settings panel.

  • Loading branch information...
IAmCoder committed Jan 6, 2015
1 parent bb0f3df commit 8291c951614ec6d4b404c8bd4689fc3a99745fc2
@@ -106,25 +106,25 @@
"Entry"
{
"MsmKey" = "8:_UNDEFINED"
"OwnerKey" = "8:_373BD2069568CF6F3E23F327BDE1FCAC"
"OwnerKey" = "8:_A9A3AC4C8A7C44DBAB98F307C7C1F646"
"MsmSig" = "8:_UNDEFINED"
}
"Entry"
{
"MsmKey" = "8:_UNDEFINED"
"OwnerKey" = "8:_369B740A8EA1EDCAA237C4DEAD53DB36"
"OwnerKey" = "8:_7F551CABE8A04FE5A84124E2575ECD7D"
"MsmSig" = "8:_UNDEFINED"
}
"Entry"
{
"MsmKey" = "8:_UNDEFINED"
"OwnerKey" = "8:_7F551CABE8A04FE5A84124E2575ECD7D"
"OwnerKey" = "8:_369B740A8EA1EDCAA237C4DEAD53DB36"
"MsmSig" = "8:_UNDEFINED"
}
"Entry"
{
"MsmKey" = "8:_UNDEFINED"
"OwnerKey" = "8:_A9A3AC4C8A7C44DBAB98F307C7C1F646"
"OwnerKey" = "8:_373BD2069568CF6F3E23F327BDE1FCAC"
"MsmSig" = "8:_UNDEFINED"
}
}
@@ -224,7 +224,7 @@
{
"Name" = "8:.NET Framework"
"Message" = "8:[VSDNETMSG]"
"FrameworkVersion" = "8:3.5.30729"
"FrameworkVersion" = "8:3.5.30729 "
"AllowLaterVersions" = "11:FALSE"
"InstallUrl" = "8:http://go.microsoft.com/fwlink/?LinkId=76617"
}
@@ -328,7 +328,7 @@
{
"AssemblyRegister" = "3:1"
"AssemblyIsInGAC" = "11:FALSE"
"AssemblyAsmDisplayName" = "8:lucidcode.LucidScribe.Interface, Version=1.0.2.0, Culture=neutral, processorArchitecture=MSIL"
"AssemblyAsmDisplayName" = "8:lucidcode.LucidScribe.Interface, Version=1.0.3.0, Culture=neutral, processorArchitecture=MSIL"
"ScatterAssemblies"
{
"_7F551CABE8A04FE5A84124E2575ECD7D"
@@ -399,7 +399,7 @@
{
"AssemblyRegister" = "3:1"
"AssemblyIsInGAC" = "11:FALSE"
"AssemblyAsmDisplayName" = "8:lucidcode.LucidScribe.Interface, Version=1.0.2.0, Culture=neutral, processorArchitecture=MSIL"
"AssemblyAsmDisplayName" = "8:lucidcode.LucidScribe.Interface, Version=1.0.3.0, Culture=neutral, processorArchitecture=MSIL"
"ScatterAssemblies"
{
"_A9A3AC4C8A7C44DBAB98F307C7C1F646"
@@ -648,15 +648,15 @@
{
"Name" = "8:Microsoft Visual Studio"
"ProductName" = "8:Lucid Scribe Pranayama"
"ProductCode" = "8:{9F91BCD2-A631-4594-97D5-9946ED52BE55}"
"PackageCode" = "8:{B38A6B7A-9D3F-4AC3-80CD-0B5F64B15D01}"
"ProductCode" = "8:{4EABC8CF-5D3E-4581-B4DB-556DDA35024A}"
"PackageCode" = "8:{598228B8-E199-4172-93F6-03DF3162227A}"
"UpgradeCode" = "8:{C0218038-C124-43B2-835C-ABB9CC8A9FB8}"
"AspNetVersion" = "8:4.0.30319.0"
"RestartWWWService" = "11:FALSE"
"RemovePreviousVersions" = "11:TRUE"
"DetectNewerInstalledVersion" = "11:TRUE"
"InstallAllUsers" = "11:TRUE"
"ProductVersion" = "8:1.0.5"
"ProductVersion" = "8:1.0.6"
"Manufacturer" = "8:lucidcode"
"ARPHELPTELEPHONE" = "8:"
"ARPHELPLINK" = "8:http://www.lucid-code.com/Support"
BIN +4 KB (120%) Lucid Scribe - Pranayama.suo
Binary file not shown.
Binary file not shown.
@@ -13,33 +13,23 @@ namespace lucidcode.LucidScribe.Plugin.Pranayama
{
public partial class ExerciseForm : Form
{
public String SelectedExercise = "";

public event ExerciseChangedEventHandler ExerciseChanged;
public delegate void ExerciseChangedEventHandler(string Exercise);

public ExerciseForm()
{
InitializeComponent();
}

private void lstPlaylists_MouseMove(object sender, MouseEventArgs e)
{
if (lstExercises.GetItemAt(e.X, e.Y) != null)
{
lstExercises.Cursor = Cursors.Hand;
}
else
{
lstExercises.Cursor = Cursors.Default;
}
}

private void lstPlaylists_SelectedIndexChanged(object sender, EventArgs e)
private void settingsControl_ExerciseChanged(string Exercise)
{
if (lstExercises.SelectedItems.Count > 0)
if (ExerciseChanged != null)
{
SelectedExercise = lstExercises.SelectedItems[0].Text;
DialogResult = DialogResult.OK;
Close();
ExerciseChanged(Exercise);
}
DialogResult = DialogResult.OK;
Close();
}
}
}

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
@@ -125,7 +125,7 @@
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0yLjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAACW
DQAAAk1TRnQBSQFMAwEBAAGYAQABmAEAAR8BAAEcAQAE/wEZAQAI/wFCAU0BNgcAATYDAAEoAwABfAMA
DQAAAk1TRnQBSQFMAwEBAAHIAQAByAEAAR8BAAEcAQAE/wEZAQAI/wFCAU0BNgcAATYDAAEoAwABfAMA
ARwDAAEBAQABGAUAAbABKBIAXf//ABgABv8B6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHW
AccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHW
AccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6QHWAccB6AHX
@@ -187,15 +187,6 @@
</value>
</data>
<assembly alias="System.Drawing" name="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="Label5.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAJcEhZcwAADrwAAA68AZW8ckkAAACXSURBVDhPnZDBDcAgCEU9uFF3YqfePHQc745j860kiGBr
X0JMLP9JCStKKTWlq+LsV3sgDI6D/gnwMsK/JwDbr2PsVfU2HzRZ5JzbOUn0pj1BjHGoFgYcwL+iPIFk
EOhNs4CIzAKDQCMFkkBnC4JpAoSsCQCCXKaAA3oHnwWrHciwK9CwAE1W8bfePsOCFa8C+aJXT3cIN4jJ
kEFaMsuqAAAAAElFTkSuQmCC
</value>
</data>
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAABAAUAEBAQAAAABAAoAQAAVgAAACAgAAAAABgAqAwAAH4BAAAQEAAAAAAYAGgDAAAmDgAAQEAAAAAA
@@ -8,6 +8,7 @@ namespace lucidcode.LucidScribe.Plugin.Pranayama
public class PluginHandler : lucidcode.LucidScribe.Interface.LucidPluginBase
{

ExerciseForm exerciseForm = new ExerciseForm();
private double m_intInhale = 8;
private double m_intHoldIn = 32;
private double m_intHoldOut = 0;
@@ -42,41 +43,9 @@ public override bool Initialize()
{
try
{
ExerciseForm formExercise = new ExerciseForm();
formExercise = new ExerciseForm();
formExercise.ShowDialog();

SelectedExercise = formExercise.SelectedExercise;

if (SelectedExercise == "8:32:16")
{
m_intInhale = 8;
m_intHoldIn = 32;
m_intHoldOut = 0;
m_intExhale = 16;
m_intRepeat = -1;
m_intCapacity = 900;
}
else if (SelectedExercise == "Kapalbhati")
{
// Warm up first
m_intInhale = 7;
m_intHoldIn = 0;
m_intHoldOut = 0;
m_intExhale = 7;
m_intRepeat = 4;
m_intCapacity = 900;
}
else if (SelectedExercise == "Heart Breath")
{
m_intInhale = 7;
m_intHoldIn = 0;
m_intHoldOut = 0;
m_intExhale = 7;
m_intRepeat = -1;
m_intCapacity = 900;
}

exerciseForm.ExerciseChanged += exerciseForm_ExerciseChanged;
exerciseForm.ShowDialog();

return true;
}
catch (Exception ex)
@@ -85,6 +54,57 @@ public override bool Initialize()
}
}

void exerciseForm_ExerciseChanged(string Exercise)
{
if (SelectedExercise == Exercise)
{
return;
}

SelectedExercise = Exercise;

if (SelectedExercise == "8:32:16")
{
m_intInhale = 8;
m_intHoldIn = 32;
m_intHoldOut = 0;
m_intExhale = 16;
m_intRepeat = -1;
m_intCapacity = 900;
}
else if (SelectedExercise == "Kapalbhati")
{
// Warm up first
m_intInhale = 7;
m_intHoldIn = 0;
m_intHoldOut = 0;
m_intExhale = 7;
m_intRepeat = 4;
m_intCapacity = 900;
}
else if (SelectedExercise == "Heart Breath")
{
m_intInhale = 7;
m_intHoldIn = 0;
m_intHoldOut = 0;
m_intExhale = 7;
m_intRepeat = -1;
m_intCapacity = 900;
}

m_Stage = Stage.Inhaling;
m_dtTime = DateTime.Now;
m_dblValue = 0;
}

public override System.Windows.Forms.Control SettingsPanel
{
get
{
return exerciseForm.settingsControl;
}
}

public override double Value
{
get
Oops, something went wrong.

0 comments on commit 8291c95

Please sign in to comment.
You can’t perform that action at this time.