当我尝试在屏幕底部的EditText中写入内容时,软键盘会隐藏EditText.我该如何解决这个问题?下面是我的xml代码.我在片段中使用它.
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content" >
<LinearLayout
android:id="@+id/linearLayoutTopDetails"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/linearLayoutTop"
android:layout_marginLeft="6dp"
android:layout_marginRight="6dp"
android:layout_marginTop="6dp"
android:orientation="vertical" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@drawable/list_design1"
android:orientation="vertical" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="80dp"
android:layout_weight="100"
android:orientation="horizontal" >
<ImageView
android:id="@+id/ImageViewProfImagePostDetail"
android:layout_width="0dp"
android:layout_height="fill_parent"
android:layout_marginTop="2dp"
android:layout_weight="24.84"
android:paddingLeft="5dp"
android:paddingRight="5dp"
android:paddingTop="5dp" />
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="60"
android:orientation="vertical" >
<TextView
android:id="@+id/textViewNamePostDetail"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Robin"
android:textSize="17sp" />
<TextView
android:id="@+id/textViewLocationPostDetail"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="1dp"
android:drawableLeft="@drawable/location"
android:text="beijing, China" />
<TextView
android:id="@+id/textViewTimeAgoPostDetail"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=" 18min ago" />
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="fill_parent"
android:layout_weight="15"
android:orientation="horizontal" > …Run Code Online (Sandbox Code Playgroud) android android-keypad android-layout android-edittext android-scrollview
我开发了两种不同传感器的应用程序.它们分别正常工作,但是当我尝试使用它们来创建两个不同的总线时,Alljoyn给出了这个例外.
org.alljoyn.services.common.BusAlreadyExistException:先前已使用BusAttachment设置了该对象.
下面是我的连接源代码.谁能告诉我为什么我遇到这个问题.
private void connect()
{ org.alljoyn.bus.alljoyn.DaemonInit.PrepareDaemon(getApplicationContext());
bus = new BusAttachment("ControlPanelBrowser", BusAttachment.RemoteMessage.Receive);
bus.registerBusListener(new BusListener());
Status status = bus.registerBusObject(mControlPanelSignalInterface, Constants.SERVICE_PATH);
if (status != Status.OK) {
Log.d(TAG, "Problem while registering bus object");
}
SharedPreferences settings = getSharedPreferences(PREFS_NAME, 0);
srpPassword = settings.getString(PREFS_PASSWORD, DEFAULT_SECURED_SRP_PASSWORD);
SrpAnonymousKeyListener authListener = new SrpAnonymousKeyListener(this, logger, AUTH_MECHANISMS);
Status authStatus = bus.registerAuthListener(authListener.getAuthMechanismsAsString(),
authListener, getKeyStoreFileName());
if ( authStatus != Status.OK ) {
Log.e(TAG, "Failed to register AuthListener");
}
status = bus.connect();
if (Status.OK == status){
String daemonName = Constants.DAEMON_NAME_PREFIX + ".ControlPanelBrowser.G" …Run Code Online (Sandbox Code Playgroud) 伙计我必须在谷歌地图上用缩放显示标记.当用户放大或缩小标记时,可以看到屏幕上的地图区域.如何使用Android谷歌地图?
android google-maps-markers android-maps android-mapview android-maps-v2