Exemplo n.º 1
0
        private void BtnJoin_Click(object sender, EventArgs e)
        {
            ResetVars();

            if (!JCore.CheckJoiner(this))
            {
                return;
            }

            if (!JCore.LoadParts(this))
            {
                return;
            }

            if (JnChkCrc.Checked && JnChkCrc.Enabled && !crcCheckStatus)
            {
                CheckSfvCrc();
                crcCheckStatus = true;
                return;
            }

            if (crcCheckStatus)
            {
                crcCheckStatus = false;
            }

            long pSize = 0;

            currentProc = 1;

            ProgBar.Value        = 0;
            fJoin.OutputFileName = JCore.OutFileName;
            fJoin.OutputFolder   = JnTxtFolder.Text;
            fJoin.Priority       = GetPriority();
            if (OpCmbBuffer.SelectedIndex == 0)
            {
                pSize = JCore.GetPartSize();
                if (pSize > 0)
                {
                    fJoin.BufferSize = GetBestBuffer(pSize);
                }
            }
            else
            {
                fJoin.BufferSize = GetSelectedBuffer();
            }

            ShowRunPanel();
            //Calc time
            StartTime();

            fJoin.Join();
            Tmr.Enabled = true;
        }
Exemplo n.º 2
0
 private void JnTxtFile_TextChanged(object sender, EventArgs e)
 {
     JCore.CheckMainFile();
     if (!JCore.InvalidFile)
     {
         string path = Directory.GetParent(JnTxtFile.Text).FullName;
         if (!JnTxtFolder.Items.Contains(path))
         {
             JnTxtFolder.Items.Add(path);
         }
     }
 }