public void StatusBar_setTranslucent()
        {
            var waitHandle = new AutoResetEvent(false);
            var statusBar  = new MockStatusBar(waitHandle);
            var module     = CreateStatusBarModule(statusBar);

            module.setTranslucent(false);
            waitHandle.WaitOne();

            Assert.AreEqual(statusBar.BackgroundOpacity, 1.0);

            module.setTranslucent(true);
            waitHandle.WaitOne();

            Assert.AreEqual(statusBar.BackgroundOpacity, 0.5);
        }
        public void StatusBar_setHidden()
        {
            var waitHandle = new AutoResetEvent(false);
            var statusBar  = new MockStatusBar(waitHandle);
            var module     = CreateStatusBarModule(statusBar);

            module.setHidden(true);
            waitHandle.WaitOne();

            Assert.AreEqual(statusBar.Hidden, true);

            module.setHidden(false);
            waitHandle.WaitOne();

            Assert.AreEqual(statusBar.Hidden, false);
        }
        public void StatusBar_setTranslucent()
        {
            var waitHandle = new AutoResetEvent(false);
            var statusBar = new MockStatusBar(waitHandle);
            var module = CreateStatusBarModule(statusBar);

            module.setTranslucent(false);
            waitHandle.WaitOne();

            Assert.AreEqual(statusBar.BackgroundOpacity, 1.0);

            module.setTranslucent(true);
            waitHandle.WaitOne();

            Assert.AreEqual(statusBar.BackgroundOpacity, 0.5);
        }
        public void StatusBar_setHidden()
        {
            var waitHandle = new AutoResetEvent(false);
            var statusBar = new MockStatusBar(waitHandle);
            var module = CreateStatusBarModule(statusBar);

            module.setHidden(true);
            waitHandle.WaitOne();

            Assert.AreEqual(statusBar.Hidden, true);

            module.setHidden(false);
            waitHandle.WaitOne();

            Assert.AreEqual(statusBar.Hidden, false);
        }
        public void StatusBar_setColor()
        {
            var waitHandle = new AutoResetEvent(false);
            var statusBar = new MockStatusBar(waitHandle);
            var module = CreateStatusBarModule(statusBar);

            var color = 0xabcdefed;
            module.setColor(color);

            waitHandle.WaitOne();

            var b = (byte)color;
            color >>= 8;
            var g = (byte)color;
            color >>= 8;
            var r = (byte)color;

            Assert.AreEqual(r, statusBar.BackgroundColor.Value.R);
            Assert.AreEqual(g, statusBar.BackgroundColor.Value.G);
            Assert.AreEqual(b, statusBar.BackgroundColor.Value.B);
        }
        public void StatusBar_setColor()
        {
            var waitHandle = new AutoResetEvent(false);
            var statusBar  = new MockStatusBar(waitHandle);
            var module     = CreateStatusBarModule(statusBar);

            var color = 0xabcdefed;

            module.setColor(color);

            waitHandle.WaitOne();

            var b = (byte)color;

            color >>= 8;
            var g = (byte)color;

            color >>= 8;
            var r = (byte)color;

            Assert.AreEqual(r, statusBar.BackgroundColor.Value.R);
            Assert.AreEqual(g, statusBar.BackgroundColor.Value.G);
            Assert.AreEqual(b, statusBar.BackgroundColor.Value.B);
        }