Aller au contenu
View in the app

A better way to browse. Learn more.

Forum de Frandroid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Image Map comment en HTML

Featured Replies

Posté(e)

Bonjour tout le monde,

Je souhaiterais faire le même genre de truc que les images maps en html, c'est à dire afficher une image et ensuite que l'utilisateur puisse cliquer sur certaine partie de l'image.

J'ai retourné toute la doc, je n'ai rien trouvé...

Merci de m'avoir lu !

Modifié par Rox

Posté(e)
  • Auteur

Bon, j'ai pas trouvé pour les imagemap, mais j'ai contourné le problème.

J'ai fait un tableview avec l'image en background, et chaque cellule est clickable.

voili voilu, si ça peux servir à quelqu'un :)


<?xml version="1.0" encoding="utf-8"?>
<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/tblJobs"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@drawable/muscleselect"
android:shrinkColumns="*">
<TableRow
	android:layout_width="fill_parent"
	android:layout_height="wrap_content"
	>
	<View android:id="@+id/z1"
		android:layout_width="160dp"
		android:layout_height="140dp"
		android:onClick="popMe"/>
	<View android:id="@+id/z2"
		android:layout_width="317dp"
		android:layout_height="140dp"
           android:onClick="popMe/>
</TableRow>
</TableLayout>

et dans le java


package org.me.testapp;

import android.app.Activity;
import android.widget.Toast;
import android.os.Bundle;
import android.view.View ; 

public class testApp extends Activity {


@Override
public void onCreate(Bundle icicle) {
	super.onCreate(icicle);
	setContentView(R.layout.tabletest);
}

	public void popMe (View view) {

	Toast toast = Toast.makeText(this.getApplicationContext(), "ID : "+view.getId(), Toast.LENGTH_LONG);
	toast.show();

}
}

Archivé

Ce sujet est désormais archivé et ne peut plus recevoir de nouvelles réponses.

Account

Navigation

Rechercher

Rechercher

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.