public MyGuiScreenSimpleProgress(MyTextsWrapperEnum caption, StringBuilder text) : base(new Vector2(0.5f, 0.5f), MyGuiConstants.SCREEN_BACKGROUND_COLOR, new Vector2(0.4f, 0.4f)) { m_text = text; m_closeOnEsc = false; m_isTopMostScreen = true; AddCaption(caption, new Vector2(0f, 0.021f)); m_progressWheel = new MyGuiControlRotatingWheel(this, Vector2.Zero, MyGuiConstants.DEFAULT_CONTROL_FOREGROUND_COLOR.ToVector4(), 0.5f, MyGuiDrawAlignEnum.HORISONTAL_CENTER_AND_VERTICAL_CENTER, MyGuiManager.GetLoadingTexture()); Controls.Add(m_progressWheel); m_progressText = new MyGuiControlLabel(this, new Vector2(0f, 0.12f), null, m_text, MyGuiConstants.LABEL_TEXT_COLOR, MyGuiConstants.LABEL_TEXT_SCALE, MyGuiDrawAlignEnum.HORISONTAL_CENTER_AND_VERTICAL_CENTER); Controls.Add(m_progressText); }
private void StartTransfering() { m_isTransferingInProgress = true; m_okButton.Enabled = false; m_okButton.Visible = false; //m_cancelButton.Enabled = false; //m_cancelButton.Visible = false; m_timeFromStartTransfering = 0; m_transferingProgress = new MyGuiControlRotatingWheel(this, new Vector2(0f, 0f), MyGuiConstants.DEFAULT_CONTROL_FOREGROUND_COLOR.ToVector4(), 0.5f, MyGuiDrawAlignEnum.HORISONTAL_CENTER_AND_VERTICAL_CENTER, MyGuiManager.GetLoadingTexture()); OnEnterCallback -= OnOkClickDelegate; DrawMouseCursor = false; m_transferingProgressCue = MyAudio.AddCue2D(MySoundCuesEnum.HudInventoryTransfer); }