Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/365.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java EditText未按预期工作。也许是筑巢的问题?_Java_Android_Android Layout_Android Edittext - Fatal编程技术网

Java EditText未按预期工作。也许是筑巢的问题?

Java EditText未按预期工作。也许是筑巢的问题?,java,android,android-layout,android-edittext,Java,Android,Android Layout,Android Edittext,所以,我有这个活动: <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical

所以,我有这个活动:

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


    <ListView
        android:id="@android:id/setting_list"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@android:color/white"
        android:layout_weight="1"
        />

    <!-- fragment container -->
    <ScrollView
        android:id="@+id/scrollfragment"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_weight="1">

        <FrameLayout
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:id="@+id/fragment_container"
            />

    </ScrollView>
</LinearLayout>

在fragment_容器框架布局中,我的应用程序将有一些设置。 我有编辑昵称和编辑密码片段,每个片段都有编辑文本。 问题是,当我试图在这些编辑文本中键入任何内容(电子邮件、旧密码、新密码、确认密码)时,我并没有得到任何反馈。没有什么。就好像我在点击一个文本视图或任何你无法与之交互的东西。这显然不是我想要的,因为我需要能够更改这些设置

我真的不知道该怎么做,部分原因是我尝试谷歌搜索的每一件事都导致了一些关于如何停用我的编辑文本的指南,这与我必须做的恰恰相反。是的,我试着做那些指南建议的相反的事情。 没用

有人能帮我吗?我可以给你看你需要的每一行代码

编辑: 我的更改密码片段:

<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    tools:context=".FragmentCambioPassword">


    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@color/window_background"
        android:gravity="center"
        android:orientation="vertical"
        android:padding="@dimen/activity_horizontal_margin"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintTop_toTopOf="parent"
        tools:layout_editor_absoluteX="0dp"
        tools:layout_editor_absoluteY="0dp"
        tools:ignore="MissingConstraints">

        <ProgressBar
            android:id="@+id/progressBar"
            android:layout_width="30dp"
            android:layout_height="30dp"
            android:layout_gravity="center"
            android:layout_marginBottom="20dp"
            android:visibility="gone"
            tools:ignore="MissingConstraints" />

        <android.support.design.widget.TextInputLayout
            android:id="@+id/textInputLayoutOldPassword"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="8dp"
            android:layout_marginBottom="8dp"
            app:layout_constraintBottom_toBottomOf="parent"
            app:layout_constraintVertical_bias="0.100000024">

            <EditText
                android:id="@+id/oldPassword"
                android:layout_width="match_parent"
                android:layout_height="56dp"
                android:focusableInTouchMode="true"
                android:hint="@string/old_password"
                android:imeOptions="actionUnspecified"
                android:inputType="textPassword"
                android:maxLines="1"
                android:singleLine="true"
                android:clickable="true"
                android:textColor="@android:color/black" />
        </android.support.design.widget.TextInputLayout>

        <android.support.design.widget.TextInputLayout
            android:id="@+id/textInputLayoutPassword"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="8dp"
            android:layout_marginBottom="8dp"
            app:layout_constraintBottom_toBottomOf="parent"
            app:layout_constraintVertical_bias="0.100000024">

            <EditText
                android:id="@+id/newPassword"
                android:layout_width="match_parent"
                android:layout_height="56dp"
                android:focusableInTouchMode="true"
                android:hint="@string/new_password"
                android:imeOptions="actionUnspecified"
                android:inputType="textPassword"
                android:maxLines="1"
                android:singleLine="true"
                android:textColor="@android:color/black" />
        </android.support.design.widget.TextInputLayout>

        <android.support.design.widget.TextInputLayout
            android:id="@+id/textInputLayoutConfPassword"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="8dp"
            android:layout_marginBottom="8dp"
            app:layout_constraintBottom_toBottomOf="parent"
            app:layout_constraintVertical_bias="0.100000024">

            <EditText
                android:id="@+id/confPassword"
                android:layout_width="match_parent"
                android:layout_height="56dp"
                android:focusableInTouchMode="true"
                android:hint="@string/confirm_password"
                android:imeOptions="actionUnspecified"
                android:inputType="textPassword"
                android:maxLines="1"
                android:singleLine="true"
                android:textColor="@android:color/black" />
        </android.support.design.widget.TextInputLayout>

        <Button
            android:id="@+id/changePsw"
            style="?android:textAppearanceSmall"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="16dp"
            android:background="@color/colorPrimary"
            android:text="@string/cambia"
            android:textColor="@android:color/white"
            android:textStyle="bold" />

    </LinearLayout>

</ScrollView>```

all other fragments are done in a similar fashion. Please ask if you need more.

```
所有其他片段都以类似的方式完成。如果您需要更多,请询问。

给我们看一些代码,这样我们就可以了解问题出在哪里。我编辑了消息。我希望这足够了。我不认为你需要在滚动视图中添加片段。