CERCA
PER MODELLO
FullScreen Chatbox! :)

Utente del giorno: carotix con ben 2 Thanks ricevuti nelle ultime 24 ore
Utente della settimana: bluemask con ben 8 Thanks ricevuti negli ultimi sette giorni
Utente del mese: megthebest con ben 27 Thanks ricevuti nell'ultimo mese

Visualizzazione dei risultati da 1 a 1 su 1
Discussione:

PROBLEMA google maps su interfaccia

Se questa discussione ti è stata utile, ti preghiamo di lasciare un messaggio di feedback in modo che possa essere preziosa in futuro anche per altri utenti come te!
  1. #1
    Androidiano


    Registrato dal
    Jul 2014
    Messaggi
    59

    Ringraziamenti
    0
    Ringraziato 0 volte in 0 Posts
    Predefinito

    PROBLEMA google maps su interfaccia

    Ciao ragazzi,
    nella mia applicazione ho un problema, in particolare per quanto riguarda la mappa nel file XML che descrive l'interfaccia.
    In pratica se l'interfaccia è composta solamente dalla mappa, funziona correttamente, apre la mappa su tutto lo schermo:
    Questo l'xml;

     
    1
    <?xml version="1.0" encoding="utf-8"?>
    2
    <fragment xmlns:android="http://schemas.android.com/apk/res/android"
    3
             android:id="@+id/map"
    4
             android:layout_width="match_parent"
    5
             android:layout_height="match_parent"
    6
             android:name="com.google.android.gms.maps.MapFragm  ent"/>


    se invece disegno l'interfaccia inserendo vari layout ecc e metto la mappa all'interno di un layout, l'applicazione si arresta...
    Ecco l'xml:
    x
     
    1
    <LinearLayout
    2
           xmlns:android="http://schemas.android.com/apk/res/android"
    3
           xmlns:tools="http://schemas.android.com/tools"
    4
           android:layout_width="match_parent"
    5
           android:layout_height="match_parent"
    6
           android:layout_alignParentLeft="true"
    7
           android:layout_alignParentTop="true"
    8
           android:background="#000000"
    9
           android:orientation="vertical" >
    10
            <LinearLayout
    11
               android:layout_width="match_parent"
    12
               android:layout_height="300px"
    13
               android:layout_weight="0.50"
    14
               android:background="#000000" >
    15
                <LinearLayout
    16
                   android:layout_width="250px"
    17
                   android:layout_height="match_parent"
    18
                   android:orientation="vertical" >
    19
                    <ScrollView
    20
                       android:id="@+id/scrollView1"
    21
                       android:layout_width="match_parent"
    22
                       android:layout_height="match_parent">"
    23
                        <LinearLayout
    24
                           android:layout_width="match_parent"
    25
                           android:layout_height="match_parent"
    26
                           android:orientation="vertical" 
    27
                           android:background="#ffffff"
    28
                           >
    29
                            <Button
    30
                               android:id="@+id/discoveryTotaleButton"
    31
                               android:layout_width="wrap_content"
    32
                               android:layout_height="wrap_content"
    33
                               android:text="DISCOVERY TOTALE" />
    34
                            <Button
    35
                       android:id="@+id/button2"
    36
                       android:layout_width="wrap_content"
    37
                       android:layout_height="wrap_content"
    38
                       android:text="Button" />
    39
    40
                    <Button
    41
                       android:id="@+id/button3"
    42
                       android:layout_width="wrap_content"
    43
                       android:layout_height="wrap_content"
    44
                       android:text="Button" />
    45
    46
                    <Button
    47
                       android:id="@+id/button4"
    48
                       android:layout_width="wrap_content"
    49
                       android:layout_height="wrap_content"
    50
                       android:text="Button" />
    51
    52
                    <Button
    53
                       android:id="@+id/button5"
    54
                       android:layout_width="wrap_content"
    55
                       android:layout_height="wrap_content"
    56
                       android:text="Button" />
    57
                    
    58
                    <Button
    59
                       android:id="@+id/button6"
    60
                       android:layout_width="wrap_content"
    61
                       android:layout_height="wrap_content"
    62
                       android:text="Button" />
    63
                    
    64
                    <Button
    65
                       android:id="@+id/button7"
    66
                       android:layout_width="wrap_content"
    67
                       android:layout_height="wrap_content"
    68
                       android:text="Button" />
    69
    70
                            <Button
    71
                               android:id="@+id/button8"
    72
                               android:layout_width="wrap_content"
    73
                               android:layout_height="wrap_content"
    74
                               android:text="Button" />
    75
                            
    76
                            
    77
                            
    78
    79
                            
    80
    81
                            
    82
                            
    83
                        </LinearLayout>
    84
                    </ScrollView>
    85
    86
                    
    87
    88
                </LinearLayout>
    89
                
    90
                <LinearLayout
    91
               android:layout_width="match_parent"
    92
               android:layout_height="match_parent"
    93
                >
    94
                
    95
                <fragment 
    96
             android:id="@+id/map"
    97
             android:layout_width="match_parent"
    98
             android:layout_height="match_parent"
    99
             />
    100
                
    101
                </LinearLayout>
    102
            </LinearLayout>
    103
            <LinearLayout
    104
               android:layout_width="fill_parent"
    105
               android:layout_height="wrap_content"
    106
               android:layout_alignParentLeft="true"
    107
               android:layout_alignParentTop="true"
    108
               android:layout_weight="74.41"
    109
               android:background="#345678"
    110
               android:orientation="vertical" >
    111
                <TextView
    112
                   android:id="@+id/textView2"
    113
                   android:layout_width="wrap_content"
    114
                   android:layout_height="wrap_content"
    115
                   android:text="Posizione per le info da stampare" />
    116
    117
            </LinearLayout>
    118
        </LinearLayout>


    Sapete il motivo?

  2.  

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire risposte
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Torna su
Privacy Policy