private void _GenerateQRs() { QRCodeGenerator qr = new QRCodeGenerator(); //ServerAddress QRCodeGenerator.QRCode qrcode = qr.CreateQrCode(CVocaluxeServer.GetServerAddress(), QRCodeGenerator.ECCLevel.H); _QRServerAddress = CDraw.AddTexture(qrcode.GetGraphic(20)); }
public override void OnShow() { base.OnShow(); if (_QRServerAddress == null) { _GenerateQRs(); _Statics[_StaticQRServer].Texture = _QRServerAddress; _Texts[_TextServerAddress].Text = CVocaluxeServer.GetServerAddress(); } _Texts[_TextServerAddress].Visible = CVocaluxeServer.IsServerRunning(); _Statics[_StaticQRServer].Visible = CVocaluxeServer.IsServerRunning(); _Texts[_TextServerNotRunning].Visible = !CVocaluxeServer.IsServerRunning(); }