|
using System;
using System.Collections;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Windows.Forms;
namespace SteganoDemo
{
/// <summary>
/// Zusammendfassende Beschreibung f�r CountOfUnitsDisplayControl.
/// </summary>
public class CountOfUnitsDisplayControl : System.Windows.Forms.UserControl
{
private System.Windows.Forms.Label lblCountAvailableCarrierUnits;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label lblCountRequiredCarrierUnits;
private System.ComponentModel.Container components = null;
private bool countRequiredVisible = true;
public bool CountRequiredVisible{
get{ return countRequiredVisible; }
set{
countRequiredVisible
= lblCountRequiredCarrierUnits.Visible
= lblRequiredCarrierUnits.Visible = value;
}
}
private long countAvailableCarrierUnits;
private System.Windows.Forms.Label lblRequiredCarrierUnits;
public long CountAvailableCarrierUnits{
get{ return countAvailableCarrierUnits; }
set{
countAvailableCarrierUnits = value;
lblCountAvailableCarrierUnits.Text = (value > 0)
? value.ToString()
: "unknown";
}
}
private long countRequiredCarrierUnits;
public long CountRequiredCarrierUnits{
get{ return countRequiredCarrierUnits; }
set{
countRequiredCarrierUnits = value;
lblCountRequiredCarrierUnits.Text = (value > 0)
? value.ToString()
: "unknown";
}
}
public event EventHandler ValueChanged;
public CountOfUnitsDisplayControl()
{
// Dieser Aufruf ist f�r den Windows Form-Designer erforderlich.
InitializeComponent();
// TODO: Initialisierungen nach dem Aufruf von InitForm hinzuf�gen
}
/// <summary>
/// Die verwendeten Ressourcen bereinigen.
/// </summary>
protected override void Dispose( bool disposing )
{
if( disposing )
{
if(components != null)
{
components.Dispose();
}
}
base.Dispose( disposing );
}
#region Component Designer generated code
/// <summary>
/// Erforderliche Methode f�r die Designerunterst�tzung.
/// Der Inhalt der Methode darf nicht mit dem Code-Editor ge�ndert werden.
/// </summary>
private void InitializeComponent()
{
this.lblCountAvailableCarrierUnits = new System.Windows.Forms.Label();
this.label6 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.lblRequiredCarrierUnits = new System.Windows.Forms.Label();
this.lblCountRequiredCarrierUnits = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// lblCountAvailableCarrierUnits
//
this.lblCountAvailableCarrierUnits.Anchor = (System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right);
this.lblCountAvailableCarrierUnits.Location = new System.Drawing.Point(696, 0);
this.lblCountAvailableCarrierUnits.Name = "lblCountAvailableCarrierUnits";
this.lblCountAvailableCarrierUnits.Size = new System.Drawing.Size(80, 32);
this.lblCountAvailableCarrierUnits.TabIndex = 18;
this.lblCountAvailableCarrierUnits.Text = "0";
this.lblCountAvailableCarrierUnits.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lblCountAvailableCarrierUnits.TextChanged += new System.EventHandler(this.numberbox_TextChanged);
//
// label6
//
this.label6.Anchor = (System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right);
this.label6.Location = new System.Drawing.Point(544, 0);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(144, 32);
this.label6.TabIndex = 16;
this.label6.Text = "Available Carrier Units:";
this.label6.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// label2
//
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(120, 28);
this.label2.TabIndex = 14;
this.label2.Text = "Carrier Files";
this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
//
// lblRequiredCarrierUnits
//
this.lblRequiredCarrierUnits.Anchor = (System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right);
this.lblRequiredCarrierUnits.Location = new System.Drawing.Point(312, 0);
this.lblRequiredCarrierUnits.Name = "lblRequiredCarrierUnits";
this.lblRequiredCarrierUnits.Size = new System.Drawing.Size(144, 32);
this.lblRequiredCarrierUnits.TabIndex = 15;
this.lblRequiredCarrierUnits.Text = "Required Carrier Units:";
this.lblRequiredCarrierUnits.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// lblCountRequiredCarrierUnits
//
this.lblCountRequiredCarrierUnits.Anchor = (System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right);
this.lblCountRequiredCarrierUnits.Location = new System.Drawing.Point(456, 0);
this.lblCountRequiredCarrierUnits.Name = "lblCountRequiredCarrierUnits";
this.lblCountRequiredCarrierUnits.Size = new System.Drawing.Size(72, 32);
this.lblCountRequiredCarrierUnits.TabIndex = 17;
this.lblCountRequiredCarrierUnits.Text = "0";
this.lblCountRequiredCarrierUnits.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lblCountRequiredCarrierUnits.TextChanged += new System.EventHandler(this.numberbox_TextChanged);
//
// CountOfUnitsDisplayControl
//
this.Controls.AddRange(new System.Windows.Forms.Control[] {
this.lblCountAvailableCarrierUnits,
this.label6,
this.label2,
this.lblRequiredCarrierUnits,
this.lblCountRequiredCarrierUnits});
this.Name = "CountOfUnitsDisplayControl";
this.Size = new System.Drawing.Size(776, 32);
this.ResumeLayout(false);
}
#endregion
private void numberbox_TextChanged(object sender, System.EventArgs e) {
if(ValueChanged != null){
ValueChanged(this, new EventArgs());
}
}
}
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.