Topic de maitrekaras :

Relation Filles/Gars. Célibat X couple.

Tu crois que je sais pas ? :rire:
Je copie ce qui est donné sur internet :(
Ouais mais faut adapter si tu vois que les tuto font de la merde. Envoie ton projet ou le tuto que tu suis pour que je jette un coup d'oeil.
Je rafistole plusieurs tuto + j'ai reperé l'erreur, je corrigerais demain la j'ai la flemme :hap:
Rofl. D'accord, tant mieux.
Bonne nuit Dany.
D'ici ce soir j'ai un code operationnel :hap:
Hier je prenais en main la tech, et j'ai plus ou moins tout compris :hap:
Je te fais confiance ! J'exige un rapport détaillé toutes les trois heures pour juger ton avancée.
Fuck you :hap:
Je me fais des journées de fdp en ce moment, en attaquant avec de la muscu à 8h eu mat :rire:
J'ai modifié mon code pour avoir un layout principal avec le logo et un bouton qui renvoie sur un 2eme layout, et j'ai un layout useless impossible à acceder, bah mon application se lance pas et reste sur un fond blanc, tu veux bien y jeter un oeuil ? je suis en train d'upload sur dropbox le dossier :hap:

Trop long DB, on a le layout map, qui n'est pas censé etre accessible, ça c'est le code java de ce layout

package paris.arya.moanaguinet.arya;

import android.content.Context;
import android.content.pm.PackageManager;
import android.location.LocationManager;
import android.support.design.widget.FloatingActionButton;
import android.support.v4.app.ActivityCompat;
import android.support.v4.app.FragmentActivity;
import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.View;
import android.widget.Button;

import com.google.android.gms.maps.CameraUpdateFactory;
import com.google.android.gms.maps.GoogleMap;
import com.google.android.gms.maps.OnMapReadyCallback;
import com.google.android.gms.maps.SupportMapFragment;
import com.google.android.gms.maps.model.LatLng;
import com.google.android.gms.maps.model.MarkerOptions;

import static android.support.design.widget.FloatingActionButton.*;




public class MapsActivity extends FragmentActivity implements OnMapReadyCallback {

    private GoogleMap mMap;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_maps);
        // Obtain the SupportMapFragment and get notified when the map is ready to be used.
        SupportMapFragment mapFragment = (SupportMapFragment) getSupportFragmentManager()
                .findFragmentById(R.id.map);
        mapFragment.getMapAsync(this);
    }


    /**
     * Manipulates the map once available.
     * This callback is triggered when the map is ready to be used.
     * This is where we can add markers or lines, add listeners or move the camera. In this case,
     * we just add a marker near Sydney, Australia.
     * If Google Play services is not installed on the device, the user will be prompted to install
     * it inside the SupportMapFragment. This method will only be triggered once the user has
     * installed Google Play services and returned to the app.
     */
    @Override
    public void onMapReady(GoogleMap googleMap) {
        mMap = googleMap;
        if (ActivityCompat.checkSelfPermission(this, android.Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, android.Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {
            // TODO: Consider calling
            //    ActivityCompat#requestPermissions
            // here to request the missing permissions, and then overriding
            //   public void onRequestPermissionsResult(int requestCode, String[] permissions,
            //                                          int[] grantResults)
            // to handle the case where the user grants the permission. See the documentation
            // for ActivityCompat#requestPermissions for more details.
            return;
        }

        mMap.setMyLocationEnabled(true);
    }



}

le .XML

 <fragment xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:id="@+id/map"
    android:name="com.google.android.gms.maps.SupportMapFragment"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context="paris.arya.moanaguinet.arya.MapsActivity">




</fragment>


le java principal

package paris.arya.moanaguinet.arya;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;

/**
 * Created by moanaguinet on 31/01/2017.
 */

public class menuPrincipal extends Activity {

    class principal extends Activity {


        @Override
        public void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.activity_maps);  //Définition de la vue principale
            Button ButtonConnexion = (Button) findViewById(R.id.button);   //Appel du "button"
            ButtonConnexion.setOnClickListener(new View.OnClickListener() {
                @Override
                public void onClick(View view) {
                    Intent intent = new Intent(principal.this, Commander.class);  //Lancer commander
                    startActivity(intent);    //Afficher la vue
                }
            });

        }
    }
}

le .xml du layout principal

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:orientation="vertical" android:layout_width="match_parent"
    android:layout_height="match_parent">

    <Button
        android:id="@+id/button"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_gravity="bottom|center"
        android:text="Commander ici"
        android:padding="10dp"
        android:layout_marginBottom="20dp"
        android:paddingRight="10dp"/>

    <ImageView
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:srcCompat="@drawable/arya"
        android:id="@+id/imageView" />
</LinearLayout>

le java du layout ou il faut aller avec le bouton

package paris.arya.moanaguinet.arya;
import android.app.Activity;
import android.os.Bundle;
/**
 * Created by moanaguinet on 30/01/2017.
 */


public class Commander extends Activity
    {
        public void onCreate(Bundle savedInstanceState) //A la   creation de la vue
        {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.position); //Afficher la vue portant le nom "position"
        }
    }


et le .xml

 <?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical" android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@drawable/arya">


    <TextView
        android:text="Hello World!"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:id="@+id/textView" />
</LinearLayout>

et le manifest

 <?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="paris.arya.moanaguinet.arya">

    <!--
         The ACCESS_COARSE/FINE_LOCATION permissions are not required to use
         Google Maps Android API v2, but you must specify either coarse or fine
         location permissions for the 'MyLocation' functionality. 
    -->
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

    <application
        android:allowBackup="true"
        android:icon="@drawable/arya"
        android:label="@string/app_name"
        android:supportsRtl="true"
        android:theme="@style/AppTheme">

        <!--
             The API key for Google Maps-based APIs is defined as a string resource.
             (See the file "res/values/google_maps_api.xml").
             Note that the API key is linked to the encryption key used to sign the APK.
             You need a different API key for each encryption key, including the release key that is used to
             sign the APK for publishing.
             You can define the keys for the debug and release targets in src/debug/ and src/release/. 
        -->
        <meta-data
            android:name="com.google.android.geo.API_KEY"
            android:value="@string/google_maps_key" />

        <activity
            android:name=".menuPrincipal"
            android:label="Arya">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
        <activity
            android:name=".Commander"
            android:label="Cut" >
    </activity>


        <activity android:name=".MapsActivity"
            android:label="maps" >

        </activity>
    </application>

</manifest> 
et ça fait bugguer à mort mon téléphone https://image.noelshack.com/fichiers/2016/36/1473263957-risitas33.png
Non mais upload ton projet en .zip pour que je puisse l'importer, je vais pas checker comme ça.
Mais je suis sûr que t'y es presque tkt.
J'ai un pote dev qui est chaud pour mon projet, il va faire l'appli :hap:
T'abandonnes trop vite wesh.
Clairement :hap:
Mais j'ai pas envie de me prendre la tete :hap:
Puis il est chaud depuis le debut et ok pour nous faire l'appli, donc bon :hap:
Et tu comptes le payer ?
Lui filer des parts de la société :oui:

Le 31 janvier 2017 à 16:14:21 Wolstraat a écrit :
Lui filer des parts de la société :oui:

Je veux bien t'aider pour des parts :noel:

Données du topic

Auteur
maitrekaras
Date de création
5 juin 2014 à 22:00:11
Nb. messages archivés
27958
Nb. messages JVC
27958
Voir le topic sur JVC

Afficher uniquement les messages de l'auteur du topic

En ligne sur JvArchive

JvArchive compagnon

Découvrez JvArchive compagnon , l'userscript combattant la censure abusive sur le 18-25 !