minor fix

This commit is contained in:
androiddevkkotlin 2020-11-06 10:16:03 +02:00
parent 26ce1f9d7b
commit 47e8aa403b
3 changed files with 90 additions and 91 deletions

View file

@ -1,49 +1,49 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:osmand="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minHeight="@dimen/bottom_sheet_selected_item_title_height"
android:paddingLeft="@dimen/content_padding"
android:paddingRight="@dimen/content_padding"
android:paddingTop="@dimen/measurement_tool_menu_title_padding_top"
android:orientation="vertical"
android:paddingEnd="@dimen/content_padding"
android:paddingStart="@dimen/content_padding">
xmlns:osmand="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minHeight="@dimen/bottom_sheet_selected_item_title_height"
android:paddingLeft="@dimen/content_padding"
android:paddingRight="@dimen/content_padding"
android:paddingTop="@dimen/measurement_tool_menu_title_padding_top"
android:orientation="vertical"
android:paddingEnd="@dimen/content_padding"
android:paddingStart="@dimen/content_padding">
<ImageView
android:id="@+id/header"
osmand:srcCompat="@drawable/ic_action_openstreetmap_logo_colored"
android:gravity="center"
android:layout_width="@dimen/bottom_sheet_list_item_height"
android:layout_height="@dimen/bottom_sheet_list_item_height"
android:layout_gravity="center"/>
<ImageView
android:id="@+id/header"
osmand:srcCompat="@drawable/ic_action_openstreetmap_logo_colored"
android:gravity="center"
android:layout_width="@dimen/bottom_sheet_list_item_height"
android:layout_height="@dimen/bottom_sheet_list_item_height"
android:layout_gravity="center"/>
<net.osmand.plus.widgets.TextViewEx
android:id="@+id/title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:drawablePadding="@dimen/content_padding_small"
android:ellipsize="end"
android:gravity="center"
android:maxLines="1"
android:layout_marginTop="@dimen/content_padding_small"
android:paddingBottom="@dimen/content_padding_small"
android:textColor="?android:textColorPrimary"
android:textSize="@dimen/default_list_text_size"
osmand:typeface="@string/font_roboto_medium"
tools:text="Some title" />
<net.osmand.plus.widgets.TextViewEx
android:id="@+id/title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:drawablePadding="@dimen/content_padding_small"
android:ellipsize="end"
android:gravity="center"
android:maxLines="1"
android:layout_marginTop="@dimen/content_padding_small"
android:paddingBottom="@dimen/content_padding_small"
android:textColor="?android:textColorPrimary"
android:textSize="@dimen/default_list_text_size"
osmand:typeface="@string/font_roboto_medium"
android:text="@string/login_open_street_map_org" />
<net.osmand.plus.widgets.TextViewEx
android:id="@+id/description"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:lineSpacingMultiplier="@dimen/bottom_sheet_text_spacing_multiplier"
android:textColor="?android:textColorPrimary"
android:paddingTop="@dimen/content_padding_small"
android:textSize="@dimen/default_list_text_size"
osmand:typeface="@string/font_roboto_regular"
tools:text="Some description" />
<net.osmand.plus.widgets.TextViewEx
android:id="@+id/description"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:lineSpacingMultiplier="@dimen/bottom_sheet_text_spacing_multiplier"
android:textColor="?android:textColorPrimary"
android:paddingTop="@dimen/content_padding_small"
android:textSize="@dimen/default_list_text_size"
osmand:typeface="@string/font_roboto_regular"
android:text="@string/open_street_map_login_mode" />
</LinearLayout>

View file

@ -1,58 +1,58 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:osmand="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingStart="@dimen/content_padding"
android:paddingLeft="@dimen/content_padding"
android:paddingTop="@dimen/bottom_sheet_content_margin"
android:paddingEnd="@dimen/content_padding"
android:paddingRight="@dimen/content_padding"
android:paddingBottom="@dimen/bottom_sheet_content_margin">
xmlns:osmand="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingStart="@dimen/content_padding"
android:paddingLeft="@dimen/content_padding"
android:paddingTop="@dimen/bottom_sheet_content_margin"
android:paddingEnd="@dimen/content_padding"
android:paddingRight="@dimen/content_padding"
android:paddingBottom="@dimen/bottom_sheet_content_margin">
<net.osmand.plus.widgets.TextViewEx
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/bottom_sheet_content_margin"
android:ellipsize="end"
android:gravity="center_vertical"
android:letterSpacing="@dimen/text_button_letter_spacing"
android:maxLines="1"
android:minHeight="@dimen/bottom_sheet_icon_margin"
android:text="@string/login_open_street_map"
android:textSize="@dimen/default_list_text_size"
osmand:typeface="@string/font_roboto_medium" />
<net.osmand.plus.widgets.TextViewEx
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/bottom_sheet_content_margin"
android:ellipsize="end"
android:gravity="center_vertical"
android:letterSpacing="@dimen/text_button_letter_spacing"
android:maxLines="1"
android:minHeight="@dimen/bottom_sheet_icon_margin"
android:text="@string/login_open_street_map"
android:textSize="@dimen/default_list_text_size"
osmand:typeface="@string/font_roboto_medium" />
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/name_text_box"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/bottom_sheet_content_margin"
android:hint="@string/user_login">
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/name_text_box"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/bottom_sheet_content_margin"
android:hint="@string/user_login">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/name_edit_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:imeOptions="actionDone" />
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/name_edit_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:imeOptions="actionDone" />
</com.google.android.material.textfield.TextInputLayout>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/password_text_box"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/user_password">
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/password_text_box"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/user_password">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/password_edit_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:imeOptions="actionDone"
android:inputType="textPassword" />
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/password_edit_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:imeOptions="actionDone"
android:inputType="textPassword" />
</com.google.android.material.textfield.TextInputLayout>
</com.google.android.material.textfield.TextInputLayout>
</LinearLayout>

View file

@ -17,6 +17,7 @@ import net.osmand.AndroidUtils;
import net.osmand.plus.R;
import net.osmand.plus.UiUtilities.DialogButtonType;
import net.osmand.plus.base.MenuBottomSheetDialogFragment;
import net.osmand.plus.base.bottomsheetmenu.SimpleBottomSheetItem;
import net.osmand.plus.base.bottomsheetmenu.simpleitems.DividerSpaceItem;
import net.osmand.plus.base.bottomsheetmenu.simpleitems.ShortDescriptionItem;
import net.osmand.plus.osmedit.oauth.OsmOAuthAuthorizationAdapter;
@ -33,9 +34,7 @@ public class LoginBottomSheetFragment extends MenuBottomSheetDialogFragment {
@Override
public void createMenuItems(Bundle savedInstanceState) {
items.add(new ShortDescriptionItem.Builder()
.setDescription(getString(R.string.open_street_map_login_mode))
.setTitle(getString(R.string.login_open_street_map_org))
items.add(new SimpleBottomSheetItem.Builder()
.setLayoutId(R.layout.bottom_sheet_login)
.create());