Proyectos de Subversion Android Microlearning - Nuevo Interface

Rev

Rev 53 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 53 Rev 54
Línea 179... Línea 179...
179
 
179
 
180
        if(!notificacionList.get(position).get("url").isEmpty())
180
        if(!notificacionList.get(position).get("url").isEmpty())
181
        {
181
        {
182
            Log.e("Tiene url", "vamos alla");
182
            Log.e("Tiene url", "vamos alla");
-
 
183
            Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse(notificacionList.get(position).get("url")));
183
            Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse(notificacionList.get(position).get("url")));
184
            try{
-
 
185
                startActivity(browserIntent);
-
 
186
            }catch (Exception e)
-
 
187
            {
-
 
188
                Toast.makeText(getContext(), "Necesitas un navegador para ver esta web", Toast.LENGTH_SHORT).show();
184
            startActivity(browserIntent);
189
            }
185
        }
190
        }
186
        else
191
        else
187
        {
192
        {
188
            Log.e("No hay url", "no hago nada");
193
            Log.e("No hay url", "no hago nada");