Example #1
0
        public override void AwakeFromNib()
        {
            base.AwakeFromNib();

            //set window background color
            this.Window.BackgroundColor = NSColor.FromSrgb(1, 1, (float)1, (float)1);
            ConnectPopupButton.AddItem("New Server");
            ConnectPopupButton.AddItems(VMCAAppEnvironment.Instance.LocalData.GetServerArray());
        }
Example #2
0
        public override void AwakeFromNib()
        {
            base.AwakeFromNib();

            //set window background color
            this.Window.BackgroundColor = NSColor.FromSrgb(1, 1, (float)1, (float)1);
            ConnectPopupButton.AddItem("New Server");
            var tokens  = SnapInContext.Instance.AuthTokenManager.GetAllAuthTokens();
            var servers = tokens.Where(x => x.ServerDto != null).OrderByDescending(x => x.ServerDto.UpdatedOn).Select(x => x.ServerDto.ServerName).Take(3).ToArray();

            ConnectPopupButton.AddItems(servers);
        }