Android - Remove Place Autocomplete Search Bar from Action Bar -


i using placeautocompletefragment in application. working fine, problem doesn't want have place autocomplete search in action bar. insted want use edittext below action bar.

i want use full screen mode, want remove search places action bar.

this full activity.xml code:

    <relativelayout xmlns:android="http://schemas.android.com/apk/res/android"     xmlns:app="http://schemas.android.com/apk/res-auto"     xmlns:tools="http://schemas.android.com/tools"     android:layout_width="match_parent"     android:layout_height="match_parent"     tools:context="example.fragmentsample.mainactivity">      <button         android:id="@+id/btncurrentlocation"         android:layout_width="match_parent"         android:onclick="fncgetcurrentlocation"         android:background="@drawable/btn_current_location"         android:text="detect location"         android:backgroundtint="#ff0000"         android:gravity="left|center_vertical"         android:paddingleft="10dp"         android:layout_height="50dp" />      <fragment         android:id="@+id/place_autocomplete_fragment"         android:layout_below="@+id/btncurrentlocation"         android:layout_width="match_parent"         android:layout_height="wrap_content"         android:name="com.google.android.gms.location.places.ui.placeautocompletefragment"         />       <textview         android:id="@+id/lblcurrentlocation"         android:layout_width="wrap_content"         android:textsize="30dp"         android:layout_height="wrap_content"         android:layout_centerinparent="true"/>    </relativelayout> 

below code that, using google place autocomplete full screen mode:

try {             intent intent = new placeautocomplete.intentbuilder(placeautocomplete.mode_fullscreen).build(this);             startactivityforresult(intent, place_autocomplete_request_code);         } catch (googleplayservicesrepairableexception e) {             // todo: handle error.         } catch (googleplayservicesnotavailableexception e) {             // todo: handle error.         } 

help appreciated.

thanks in advance!


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

.htaccess - ERR_TOO_MANY_REDIRECTS htaccess -