From 74d6ee79778ebf0875921ed6442fef8f519bf343 Mon Sep 17 00:00:00 2001 From: Equip de Desenvolupadors de PBE Date: Tue, 4 Dec 2012 12:36:40 +0000 Subject: [PATCH] --- src/com/upc/pbe/upcnews/Directoris.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/com/upc/pbe/upcnews/Directoris.java b/src/com/upc/pbe/upcnews/Directoris.java index eb96265..f17c3b3 100644 --- a/src/com/upc/pbe/upcnews/Directoris.java +++ b/src/com/upc/pbe/upcnews/Directoris.java @@ -34,6 +34,7 @@ public class Directoris extends Activity implements OnClickListener { this.crearButtons(); + //Descarrega del HTML de l'index, busqueda de directoris i creacio dels botons s = ((UpcApp) getApplication()).getDesc(); HTMLParser pars = new HTMLParser(); @@ -103,22 +104,21 @@ public class Directoris extends Activity implements OnClickListener { } public void buttonClicked(Button b) { + + //Descarrega de la pàgina HTML del directori i busqueda d'un .m3u8 en ella Log.d(TAG, "Click on " + b.getText()); d = new Descarrega(url + "/" + b.getText() + "/", file, folder); String str = d.doInBackground(); - HTMLParser pars = new HTMLParser(); String urlvideo = pars.findvideo(str, url + "/" + b.getText() + "/"); - Log.d(TAG, urlvideo); - + + //Descarrega de l'arxiu .m3u8 (si existeix) i parseig if (urlvideo.equalsIgnoreCase("No s'ha trobat")) { Toast.makeText(this, "The directory " + b.getText() + " does not contain any '.m3u8' file", Toast.LENGTH_LONG).show(); } else { d = new Descarrega(urlvideo, file, folder); String m3u8 = d.doInBackground(); - - // m3u8 --> PARSE! Parser p = new Parser(); try { ArrayList m3u8parsed = p.parseFile(m3u8); -- libgit2 0.22.2