Skip to content

Commit

Permalink
Mensaje para descargas completadas
Browse files Browse the repository at this point in the history
  • Loading branch information
forestrf committed Aug 24, 2014
1 parent 5068b85 commit 52bc99e
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
9 changes: 5 additions & 4 deletions Project files/F4M-Downloader/Descargador.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public class Descargador
public string horaRestanteString = "";

Boolean cancelado = false;
public String fallado = "";
public String estado = "";

ProcessStartInfo procesoAdobeHDS;
Process exeProcessProcesoAdobeHDS;
Expand Down Expand Up @@ -105,19 +105,20 @@ public bool download ()
Console.WriteLine ("AdobeHDS ha fallado.");
Debug.WriteLine(Utilidades.WL("AdobeHDS ha fallado"));
Debug.WriteLine(Utilidades.WL(e.ToString()));
fallado = "AdobeHDS ha fallado";
estado = "AdobeHDS ha fallado";
return false;
}

if (porcentajeInt == 0)
fallado = "Fallo";
estado = "Fallo";
else {
porcentaje = 100;
porcentajeInt = 100;
estado = "Terminado";
}


return !cancelado;
return !cancelado && estado == "Terminado";
}

public void p_ErrorDataReceived(object sender, DataReceivedEventArgs e)
Expand Down
4 changes: 2 additions & 2 deletions Project files/F4M-Downloader/HTML.cs
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,11 @@ public static class HTML
"<div class=\"q\">Quitar</div>" +
"</div>";
for (int i=0; i<MainClass.descargasEnProceso.Count; i++) {
if (MainClass.descargasEnProceso [i].fallado != "") {
if (MainClass.descargasEnProceso [i].estado != "") {
resp += "<div class=\"elemento\">" +
"<div class=\"n\">" + MainClass.descargasEnProceso [i].nombre + "</div>" +
"<div class=\"u\">" + MainClass.descargasEnProceso [i].url + "</div>" +
"<div class=\"p\">"+MainClass.descargasEnProceso [i].fallado+"</div>" +
"<div class=\"p\">"+MainClass.descargasEnProceso [i].estado+"</div>" +
"<div class=\"t\"></div>" +
"<div class=\"q\"><a href=\"/?accion=cancelarDescarga&elem=" + i + "\">Quitar</a></div>" +
"</div>";
Expand Down
2 changes: 1 addition & 1 deletion Project files/F4M-Downloader/MainClass.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public static class MainClass
public static string adobeHDSFile = "";
public static string relativePath = "";

public static string version = "0.0.3";
public static string version = "0.0.4";

public static int puerto = 25435;

Expand Down

0 comments on commit 52bc99e

Please sign in to comment.