public ImageButton(SCALE scale, String text)
 {
     this.Scale = scale;
     this.BackColor = Color.Transparent;
     this.text = text;
     this.Paint += onPaintWhite;
     this.MouseDown += onClick;
     this.MouseUp += onRelase;
 }
Example #2
0
 public ImageButton(SCALE scale, String text)
 {
     this.Scale      = scale;
     this.BackColor  = Color.Transparent;
     this.text       = text;
     this.Paint     += onPaintWhite;
     this.MouseDown += onClick;
     this.MouseUp   += onRelase;
 }
Example #3
0
        // private Patient patient;



        public Temperature(double temperature, SCALE scale, RECOREDTYPE recordedFrom, RECORDEDDURING partOfDay,
                           DateTime timeStamp)
        {
            this.temperature  = temperature;
            this.scale        = scale;
            this.recordedFrom = recordedFrom;
            this.partOfDay    = partOfDay;
            this.timeStamp    = timeStamp;
            // this.patient = patient;
        }
Example #4
0
 // Below method is used to convert patient temperature to celcius
 private double convertedTemperature(double temp, SCALE scale)
 {
     if (scale.Equals(SCALE.FARHENHEAT))
     {
         return((temp - 32) * (5 / 9));
     }
     else
     {
         return(temp - 273.15);
     }
 }
 private IEnumerator MoveNextDoor(GameObject pair, SCALE scale)
 {
     yield return new WaitForFixedUpdate ();
     print ((int)scale);
     this.transform.localScale += new Vector3 (0.01f * (int)scale, 0.01f * (int)scale, 0.01f * (int)scale);
     if (this.transform.localScale.x < 0.5f && scale == SCALE.DECREASE)
     {
         this.transform.position = pair.transform.position;
         this.StartCoroutine(MoveNextDoor(pair,SCALE.GROWUP));
     }
     else if(scale == SCALE.GROWUP && this.transform.localScale.x >= 1)
     {
         //bher
     }
     else
     {
         StartCoroutine(MoveNextDoor(pair, scale));
     }
 }
Example #6
0
    private IEnumerator MoveNextDoor(GameObject pair, SCALE scale)
    {
        yield return(new WaitForFixedUpdate());

        print((int)scale);
        this.transform.localScale += new Vector3(0.01f * (int)scale, 0.01f * (int)scale, 0.01f * (int)scale);
        if (this.transform.localScale.x < 0.5f && scale == SCALE.DECREASE)
        {
            this.transform.position = pair.transform.position;
            this.StartCoroutine(MoveNextDoor(pair, SCALE.GROWUP));
        }
        else if (scale == SCALE.GROWUP && this.transform.localScale.x >= 1)
        {
            //bher
        }
        else
        {
            StartCoroutine(MoveNextDoor(pair, scale));
        }
    }
Example #7
0
            public string getName(string value)
            {
                bool negative = false;

                if (value.StartsWith("-"))
                {
                    negative = true;
                    value    = value.Substring(1);
                }

                int    decimals     = value.IndexOf(".");
                string decimalValue = null;

                if (0 <= decimals)
                {
                    decimalValue = value.Substring(decimals + 1);
                    value        = value.Substring(0, decimals);
                }

                string name = processor.getName(value);

                string[] separatorarray = { SEPARATOR };
                string[] namearray      = { name };

                if (String.IsNullOrEmpty(name))
                {
                    name = ZERO_TOKEN;
                }
                else if (negative)
                {
                    name = MINUS + SEPARATOR + name;
                }

                if (!(null == decimalValue || String.IsNullOrEmpty(decimalValue)))
                {
                    name = name + SEPARATOR + UNION_AND + SEPARATOR + processor.getName(decimalValue) +
                           SEPARATOR + SCALE.getName(-decimalValue.Length);
                }

                return(name);
            }
Example #8
0
            public string getName(string value)
            {
                StringBuilder buffer = new StringBuilder();

                int number;

                if (String.IsNullOrEmpty(value))
                {
                    number = 0;
                }
                else if (value.Length > 4)
                {
                    number = Convert.ToInt32(value.Substring(value.Length - 4), 10);
                }
                else
                {
                    number = Convert.ToInt32(value, 10);
                }
                number %= 1000;  // keep at least three digits

                if (number >= 100)
                {
                    buffer.Append(unitProcessor.getName(number / 100));
                    buffer.Append(SEPARATOR);
                    buffer.Append(SCALE.getName(EXPONENT));
                }

                string tensName = tensProcessor.getName(number % 100);

                if (!String.IsNullOrEmpty(tensName) && (number >= 100))
                {
                    buffer.Append(SEPARATOR);
                }
                buffer.Append(tensName);

                return(buffer.ToString());
            }
Example #9
0
 public string getToken()
 {
     return(SCALE.getName(getPartDivider()));
 }
Example #10
0
 protected void SecondaryScale()
 {
     mode = SCALE.SECONDARY;
 }
Example #11
0
 protected void PrimaryScale()
 {
     mode = SCALE.PRIMARY;
 }
Example #12
0
 public void setScale(SCALE scale)
 {
     this.scale = scale;
 }