private void OnProgress(_DBG.SRecordFile.Block block, int offset, bool fLast) { int percent = (int)(offset * 100 / block.data.Length); if ((percent % 10) == 0 && m_lastPercent != percent) { m_lastPercent = percent; m_form.DumpToOutput(string.Format("Percent Complete {0}%", percent)); } }
void OnProgress(_DBG.SRecordFile.Block bl, int offset, bool fLast) { if (fLast) { Console.Write("\n"); } else { Console.Write("Block: 0x{0:X8} - {1:d6} bytes {2}% \r", bl.address, bl.data.Length, offset * 100 / bl.data.Length); } }
void Callback_Progress(_DBG.SRecordFile.Block bl, int offset, bool fLast) { foreach (ListViewItem item in this.listViewFiles.CheckedItems) { if (item.Tag == bl && fLast == false) { item.Selected = true; } else { item.Selected = false; } } progressBar1.Value = fLast ? 0 : Math.Min((int)(offset * 100 / bl.data.Length), 100); }
void OnProgress(_DBG.SRecordFile.Block bl, int offset, bool fLast) { GenericCallback(m_callback_Progress, bl, offset, fLast); }