Beispiel #1
0
 public static rMindColors Current()
 {
     lock (sync)
     {
         if (instance == null)
         {
             instance = new rMindColors();
         }
         return(instance);
     }
 }
Beispiel #2
0
        public static Color ColorRandom(byte min, byte max)
        {
            var colors = new rMindColors();
            var rand   = colors.m_random;

            var R = (byte)rand.Next(min, max);
            var G = (byte)rand.Next(min, max);
            var B = (byte)rand.Next(min, max);

            return(ColorHelper.FromArgb(255, R, G, B));
        }
Beispiel #3
0
        public static rMindColors GetInstance()
        {
            if (m_instance == null)
            {
                lock (sync)
                {
                    if (m_instance == null)
                    {
                        m_instance = new rMindColors();
                    }
                }
            }

            return(m_instance);
        }