Merge pull request #3 from SemvdH/develop

Develop
This commit is contained in:
SemvdH
2021-01-07 11:21:59 +01:00
committed by GitHub
2 changed files with 12 additions and 0 deletions

View File

@@ -4,6 +4,7 @@ import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Button;
import androidx.fragment.app.DialogFragment;
@@ -15,6 +16,8 @@ public class HelpPopup extends DialogFragment {
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
View rootView = inflater.inflate(R.layout.help_popup, container, false);
getDialog().setTitle("Simple Dialog");
Button okButton = rootView.findViewById(R.id.help_ok_button);
okButton.setOnClickListener(v -> dismiss());
return rootView;
}
}

View File

@@ -44,6 +44,15 @@
</ScrollView>
<Button
android:id="@+id/help_ok_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
android:text="ok"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@+id/helpPopTitle" />