Ejemplo n.º 1
0
        private void DebugMc(MemoryCard memory)
        {
            // ─ │┌ ┐└ ┘├ ┤┬ ┴ ┼
            log.Debug("┌─────────────────────┐");
            log.Debug("│     MEMORY CARD     │");
            log.Debug("└─────────────────────┘\n");

            log.Debug(String.Format("Memory card Path: {0}", memory.GetPath()));
            log.Debug(String.Format("Memory card Free space: {0}", memory.GetFreeSpace()));
            log.Debug(String.Format("Memory card save count: {0}\n", memory.LoadSaves().Count - 2));

            log.Debug("Memory card Save List:\n");

            List <SaveFile> saveList = memory.LoadSaves();

            for (int i = 2; i < saveList.Count; i++)
            {
                log.Debug("┌─────────────────────────────────────────────────────────────────────────────┐");
                log.Debug(String.Format("│  FILE Nº {0,-67}│", String.Format("{0:D3}", i - 1)));
                log.Debug("├─────────────────────────────────────────────────────────────────────────────┤");
                log.Debug(String.Format("│ Save Name: {0,-65}|", saveList[i].FileName));
                log.Debug(String.Format("│ Save Size: {0,-65}|", saveList[i].FileSize));
                log.Debug(String.Format("│ Save Date: {0,-65}|", saveList[i].FileDate));
                log.Debug(String.Format("│ Save Description: {0,-58}|", saveList[i].FileDescription));
                log.Debug("└─────────────────────────────────────────────────────────────────────────────┘\n");
                //Console.WriteLine();
            }
        }
Ejemplo n.º 2
0
        private void ShowMcContent(MemoryCard card, DataGridView mcView)
        {
            mcView.Rows.Clear();

            List <SaveFile> listFiles = card.LoadSaves();

            for (int i = 2; i <= listFiles.Count - 1; i++)
            {
                SaveFile save = listFiles[i];
                mcView.Rows.Add(save.FileName, save.FileSize, save.FileDate, save.FileDescription);
            }

            toolStripStatusLabel1.Text = card.GetPath();
            toolStripStatusLabel2.Text = card.GetFreeSpace();
        }