Beispiel #1
0
        public Download(string urlPageVideo, DownloadManagerM manager)
        {
            if(urlPageVideo != null)
                if (!urlPageVideo.StartsWith("http://"))
                {
                    if (!urlPageVideo.StartsWith("https://"))
                        urlPageVideo = "http://" + urlPageVideo;
                    else
                    {
                        //Remove the s from https
                        urlPageVideo.Remove(4, 1);
                    }
                }

            this.urlPageVideo = urlPageVideo;
            this.manager = manager;

            fileType = "";
            segments = null;
            p_videoInfo = null;
            fichierLocal = null;
            p_isPaused = false;
            isCanceled = false;
            downloadStarted = false;
            //downloadStartTime = DateTime.Now;
            nombreSegmentsActifs = 0;
            speedTimer = new Stopwatch();
            totalDownloadTime = new Stopwatch();
        }
Beispiel #2
0
        public YoutubeDownload(DownloadManagerM downloadManagerM, string clipboardContent)
            : base(null, downloadManagerM)
        {
            // TODO: Complete member initialization

            this.clipboardContent = clipboardContent;
        }
Beispiel #3
0
        public Segment(long taille, long debut, Download downloader, DownloadManagerM manager)
        {
            this.size = taille;
            this.startIndex = debut;
            this.content = null;
            this.download = downloader;
            this.manager = manager;
            offset = 0;
            nbreRestart = 0;

            this.threadLock = new object();
        }
        public ClipboardMonitor(DownloadManagerM manager)
        {
            InitializeComponent();

            m_downloadManager = manager;
            Width = 0;
            Height = 0;
            WindowStyle = WindowStyle.None;
            ShowInTaskbar = false;
            ShowActivated = false;
            this.Visibility = System.Windows.Visibility.Hidden;
            timeWatch = new Stopwatch();
            timeWatch.Start();
        }
Beispiel #5
0
        public DownloadInfo(String urlVideoFile, String videoTitre, long videoTaille, String filePath, String extension, DownloadManagerMV managerMV, DownloadManagerM managerM, Download download, int videoIndex = -1)
        {
            this.p_downloadManagerMV = managerMV;
            this.p_downloadManagerM = managerM;
            this.p_titre = videoTitre;
            this.p_taille = videoTaille;
            this.urlVideoFile = urlVideoFile;
            this.p_saveFilePath = filePath;
            this.p_fileExtension = extension;
            this.download = download;
            this.fileExistsAlready = false;
            this.videoIndex = videoIndex;

            SetFileName();
            CheckIndexation();

            p_downloaded = 0;
            p_lastTime = DateTime.Now;
            downloadedLast = 0;
            p_speed = 0;
        }
Beispiel #6
0
 public JustinTVDownload(string urlPageVideo, DownloadManagerM manager)
     : base(urlPageVideo, manager)
 {
     nombreTimeout = 0;
 }
 internal void Start()
 {
     this.managerM = new DownloadManagerM(this);
     this.managerM.mainWindowPtr = new OldWindow(new WindowInteropHelper(App.Current.MainWindow).Handle);
 }
Beispiel #8
0
 public YoutubeDownload(string urlPageVideo, DownloadManagerM manager)
     : base(urlPageVideo, manager)
 {
     nombreTimeout = 0;
 }
 public GiantBombDownload(string urlPageVideo, DownloadManagerM manager)
     : base(urlPageVideo, manager)
 {
     nombreTimeout = 0;
 }
 public GametrailersDownload(string urlPageVideo, DownloadManagerM manager)
     : base(urlPageVideo, manager)
 {
     nombreTimeout = 0;
 }
 public DailyMotionDownload(string urlPageVideo, DownloadManagerM manager)
     : base(urlPageVideo, manager)
 {
     nombreTimeout = 0;
 }