[android] Renamed all_pass to bookmarks_all everywhere

This commit is contained in:
Александр Зацепин 2019-11-26 17:11:18 +03:00 committed by Arsentiy Milchakov
parent 2f720e3498
commit ea12fd7097
8 changed files with 15 additions and 15 deletions

View file

@ -4,7 +4,7 @@
<data>
<variable
name="page"
type="com.mapswithme.maps.purchase.AllPassSubscriptionPage" />
type="com.mapswithme.maps.purchase.BookmarksAllSubscriptionPage" />
</data>
<RelativeLayout
xmlns:tools="http://schemas.android.com/tools"

View file

@ -91,7 +91,7 @@
android:layout_marginEnd="@dimen/margin_base_plus"
app:buttonBackground="@drawable/button_accent"
app:buttonTextColor="@color/white_primary"
app:saleBackground="@drawable/all_pass_sale_bg"
app:saleBackground="@drawable/bookmarks_all_sale_bg"
app:saleTextColor="@color/tips_and_triks_primary_text_night"
app:progressColor="@color/white_primary"
app:showSale="true" />

View file

@ -43,7 +43,7 @@ public class BookmarksAllSubscriptionFragment extends AbstractBookmarkSubscripti
View onSubscriptionCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container,
@Nullable Bundle savedInstanceState)
{
View root = inflater.inflate(R.layout.pager_fragment_all_pass_subscription, container,
View root = inflater.inflate(R.layout.pager_fragment_bookmarks_all_subscription, container,
false);
setTopStatusBarOffset(root);
@ -92,8 +92,8 @@ public class BookmarksAllSubscriptionFragment extends AbstractBookmarkSubscripti
{
return new DotPager.Builder(requireContext(), viewPager, adapter)
.setIndicatorContainer(indicatorContainer)
.setActiveDotDrawable(R.drawable.all_pass_marker_active)
.setInactiveDotDrawable(R.drawable.all_pass_marker_inactive)
.setActiveDotDrawable(R.drawable.bookmarks_all_marker_active)
.setInactiveDotDrawable(R.drawable.bookmarks_all_marker_inactive)
.build();
}
@ -122,7 +122,7 @@ public class BookmarksAllSubscriptionFragment extends AbstractBookmarkSubscripti
@Override
public Fragment getItem(int i)
{
return AllPassSubscriptionFragment.newInstance(i);
return BookmarksAllSubscriptionPageFragment.newInstance(i);
}
@Override

View file

@ -3,7 +3,7 @@ package com.mapswithme.maps.purchase;
import androidx.annotation.StringRes;
import com.mapswithme.maps.R;
public enum AllPassSubscriptionPage
public enum BookmarksAllSubscriptionPage
{
FIRST(R.string.all_pass_subscription_message_title,
R.string.all_pass_subscription_message_subtitle),
@ -17,7 +17,7 @@ public enum AllPassSubscriptionPage
@StringRes
private final int mDescriptionId;
AllPassSubscriptionPage(@StringRes int titleId, @StringRes int descriptionId)
BookmarksAllSubscriptionPage(@StringRes int titleId, @StringRes int descriptionId)
{
mTitleId = titleId;
mDescriptionId = descriptionId;

View file

@ -10,11 +10,11 @@ import androidx.annotation.Nullable;
import androidx.databinding.DataBindingUtil;
import androidx.fragment.app.Fragment;
import com.mapswithme.maps.R;
import com.mapswithme.maps.databinding.FragmentAllPassSubscriptionBinding;
import com.mapswithme.maps.databinding.FragmentBookmarksAllSubscriptionBinding;
import java.util.Objects;
public class AllPassSubscriptionFragment extends Fragment
public class BookmarksAllSubscriptionPageFragment extends Fragment
{
private static final String BUNDLE_INDEX = "index";
@ -24,23 +24,23 @@ public class AllPassSubscriptionFragment extends Fragment
@Nullable Bundle savedInstanceState)
{
int index = Objects.requireNonNull(getArguments()).getInt(BUNDLE_INDEX);
AllPassSubscriptionPage page = AllPassSubscriptionPage.values()[index];
FragmentAllPassSubscriptionBinding binding = makeBinding(inflater, container);
BookmarksAllSubscriptionPage page = BookmarksAllSubscriptionPage.values()[index];
FragmentBookmarksAllSubscriptionBinding binding = makeBinding(inflater, container);
binding.setPage(page);
return binding.getRoot();
}
@NonNull
private static FragmentAllPassSubscriptionBinding makeBinding(@NonNull LayoutInflater inflater,
private static FragmentBookmarksAllSubscriptionBinding makeBinding(@NonNull LayoutInflater inflater,
@Nullable ViewGroup container)
{
return DataBindingUtil.inflate(inflater, R.layout.fragment_all_pass_subscription, container, false);
return DataBindingUtil.inflate(inflater, R.layout.fragment_bookmarks_all_subscription, container, false);
}
@NonNull
static Fragment newInstance(int index)
{
AllPassSubscriptionFragment fragment = new AllPassSubscriptionFragment();
BookmarksAllSubscriptionPageFragment fragment = new BookmarksAllSubscriptionPageFragment();
Bundle args = new Bundle();
args.putInt(BUNDLE_INDEX, index);
fragment.setArguments(args);