LaurentC. Опубликовано 15 сентября, 2016 Поделиться Опубликовано 15 сентября, 2016 Hello, First of all congrats for this excellent component! There is a little bug which occurs when creating TfgProgressDialog/TfgActivityDialog after using a MessageDlg, the progress dialog / activity dialog appears for a second then disappears. here a sample of code: if not m_obtMgr.IsBLEEnabled then begin DoShowMessage(siLang1.GetText('RS_OperationAborted') + #13 + siLang1.GetText('RS_BluetoothDisabled')); Exit; end; gDialogStatus := -1; MessageDlg(siLang1.GetText('RS_FMWakeUpAllConfirm'), TMsgDlgType.mtConfirmation, [TMsgDlgBtn.mbYes, TMsgDlgBtn.mbNo], 0, procedure (const AResult: TModalResult) begin case AResult of mrYes : gDialogStatus := 0; else gDialogStatus := 1; end; end); while (gDialogStatus < 0) do StartYield; if gDialogStatus = 0 then begin gProgressDialog := TfgProgressDialog.Create(self); gProgressDialog.Title := siLang1.GetText('RS_dialogWakeUpInProgress'); gProgressDialog.Message := siLang1.GetText('RS_DialogPleaseWait'); gProgressDialog.Theme := TfgDialogTheme.Dark; gProgressDialog.Cancellable := True; gProgressDialog.OnCancel := AdvCancelButtonClick; gProgressDialog.Kind := TfgProgressDialogKind.Determinated; gProgressDialog.ResetProgress; gProgressDialog.Max := round(Duration/1000); gProgressDialog.show; WkUpTimer.OnTimer := OnWkUpTimer; WkUpTimer.Interval := 1000; WkUpTimer.Enabled := true; while (gProgressDialog.Progress < gProgressDialog.Max) do startYield; WkUpTimer.Enabled := false; gProgressDialog.Hide; ResetScan; etc.... Цитата Ссылка на комментарий
Рекомендуемые сообщения
Присоединяйтесь к обсуждению
Вы можете написать сейчас и зарегистрироваться позже. Если у вас есть аккаунт, авторизуйтесь, чтобы опубликовать от имени своего аккаунта.