fedilab-Android-App/app/src/main/res/layout/popup_poll.xml

104 lines
3.8 KiB
XML

<?xml version="1.0" encoding="utf-8"?><!--
Copyright 2019 Thomas Schneider
This file is a part of Fedilab
This program is free software; you can redistribute it and/or modify it under the terms of the
GNU General Public License as published by the Free Software Foundation; either version 3 of the
License, or (at your option) any later version.
Fedilab is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
Public License for more details.
You should have received a copy of the GNU General Public License along with Fedilab; if not,
see <http://www.gnu.org/licenses>.
-->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:paddingLeft="20dp"
android:paddingRight="20dp">
<ScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content">
<LinearLayout
android:id="@+id/poll_items_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<EditText
android:id="@+id/choice_1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:hint="@string/poll_choice_1"
android:inputType="text"
android:singleLine="true" />
<EditText
android:id="@+id/choice_2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:hint="@string/poll_choice_2"
android:inputType="text"
android:singleLine="true" />
</LinearLayout>
</ScrollView>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageButton
android:id="@+id/add_poll_item"
android:layout_width="28dp"
android:layout_height="28dp"
android:layout_gravity="center"
android:layout_marginEnd="5dp"
android:layout_marginRight="5dp"
android:adjustViewBounds="true"
android:background="@color/transparent"
android:contentDescription="@string/add_poll_item"
android:scaleType="centerCrop"
android:src="@drawable/ic_add" />
<ImageButton
android:id="@+id/remove_poll_item"
android:layout_width="28dp"
android:layout_height="28dp"
android:layout_gravity="center"
android:layout_marginEnd="5dp"
android:layout_marginRight="5dp"
android:adjustViewBounds="true"
android:background="@color/transparent"
android:contentDescription="@string/remove_poll_item"
android:scaleType="centerCrop"
android:src="@drawable/ic_remove_white" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<Spinner
android:id="@+id/poll_choice"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="3" />
<Spinner
android:id="@+id/poll_duration"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="2" />
</LinearLayout>
</LinearLayout>