Exemple #1
0
        public ScreenBase defineScreen()
        {
            ScreenBase result = new ColorfulScreen();

            Console.WriteLine("Choose screen type index:");
            Console.WriteLine($"0 - {nameof(MonochromeScreen)}");
            Console.WriteLine($"1 - {nameof(ColorfulScreen)}");
            int screenType = Convert.ToInt32(Console.ReadLine());

            if (screenType == 0)
            {
                result = new MonochromeScreen();
            }
            if (screenType == 1)
            {
                Console.WriteLine("Choose ColorfulScreen type index:");
                Console.WriteLine($"0 - {nameof(OLEDScreen)}");
                Console.WriteLine($"1 - {nameof(RetinaScreen)}");
                int colorfulScreenType = Convert.ToInt32(Console.ReadLine());
                if (colorfulScreenType == 0)
                {
                    result = new OLEDScreen();
                }
                else if (colorfulScreenType == 1)
                {
                    result = new RetinaScreen();
                }
            }
            return(result);
        }
Exemple #2
0
        static void Main(string[] args)
        {
            ScreenBase   retina  = new RetinaScreen();
            IScreenImage image   = new DefaultImage("a shiny unicorn!", QualityRates.High);
            Screen       screen  = new MultiTouchScreen(100, 10, 999999, "1024x720", retina, 5);
            Battery      battery = new Battery(BatteryTypes.NickelCadmium, 4100, true);
            Microphone   mic     = new Microphone();

            Mobile mob = new Mobile(screen, battery, mic);

            Console.WriteLine(mob.MobScreen);
            mob.MobScreen.Dysplay.Show(image);
            mob.MobScreen.Touch();

            Console.WriteLine(mob.MobBattery);

            mob.MobMicro.IsMuted     = true;
            mob.MobMicro.Sensetivity = 8;
            mob.MobMicro.Sensetivity = 200;
            mob.MobMicro.Sensetivity = 0;

            Console.ReadLine();
        }
Exemple #3
0
 public SimCorpMobile(Battery battery, Simcard simcard, IOutput output) : base(battery, simcard, output)
 {
     vRetinaScreen        = new RetinaScreen(1.2, 2.5, 300, 30000, output);
     vIlluminatedKeyboard = new IlluminatedKeyboard(102, new CultureInfo("ua-UA", false));
 }
Exemple #4
0
 public ModernMobile(IOutput output) : base(output)
 {
     Screen = new RetinaScreen(output, new CoordsFlat(1080, 1920), new SizeFlat(50f, 100f));
 }
Exemple #5
0
 public ModernMobile(IOutput output, BackgroundWorkerFactoryMethod backgroundWorkerFactory = null) : base(output, backgroundWorkerFactory)
 {
     Screen = new RetinaScreen(output, new CoordsFlat(1080, 1920), new SizeFlat(50f, 100f));
 }