mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-27 21:03:54 +01:00
Code cleanup
This commit is contained in:
parent
c326cce576
commit
dff9ded51f
9 changed files with 43 additions and 197 deletions
|
|
@ -32,7 +32,7 @@ import fr.free.nrw.commons.auth.AuthenticatedActivity;
|
|||
import fr.free.nrw.commons.auth.SessionManager;
|
||||
import fr.free.nrw.commons.location.LocationServiceManager;
|
||||
import fr.free.nrw.commons.nearby.NearbyNotificationCardView;
|
||||
import fr.free.nrw.commons.nearby.NearbyTestLayersFragment;
|
||||
import fr.free.nrw.commons.nearby.mvp.fragments.NearbyParentFragment;
|
||||
import fr.free.nrw.commons.notification.Notification;
|
||||
import fr.free.nrw.commons.notification.NotificationActivity;
|
||||
import fr.free.nrw.commons.notification.NotificationController;
|
||||
|
|
@ -185,7 +185,7 @@ public class MainActivity extends AuthenticatedActivity implements FragmentManag
|
|||
isContributionsFragmentVisible = false;
|
||||
updateMenuItem();
|
||||
// Do all permission and GPS related tasks on tab selected, not on create
|
||||
((NearbyTestLayersFragment)contributionsActivityPagerAdapter.getItem(1)).nearbyParentFragmentPresenter.onTabSelected();
|
||||
((NearbyParentFragment)contributionsActivityPagerAdapter.getItem(1)).nearbyParentFragmentPresenter.onTabSelected();
|
||||
break;
|
||||
default:
|
||||
tabLayout.getTabAt(CONTRIBUTIONS_TAB_POSITION).select();
|
||||
|
|
@ -266,7 +266,7 @@ public class MainActivity extends AuthenticatedActivity implements FragmentManag
|
|||
}
|
||||
} else if (getSupportFragmentManager().findFragmentByTag(nearbyFragmentTag) != null && !isContributionsFragmentVisible) {
|
||||
// Means that nearby fragment is visible (not contributions fragment)
|
||||
NearbyTestLayersFragment nearbyFragment = (NearbyTestLayersFragment) contributionsActivityPagerAdapter.getItem(1);
|
||||
NearbyParentFragment nearbyFragment = (NearbyParentFragment) contributionsActivityPagerAdapter.getItem(1);
|
||||
nearbyFragment.nearbyParentFragmentPresenter.backButtonClicked();
|
||||
} else {
|
||||
super.onBackPressed();
|
||||
|
|
@ -343,7 +343,7 @@ public class MainActivity extends AuthenticatedActivity implements FragmentManag
|
|||
return true;
|
||||
case R.id.list_sheet:
|
||||
if (contributionsActivityPagerAdapter.getItem(1) != null) {
|
||||
((NearbyTestLayersFragment)contributionsActivityPagerAdapter.getItem(1)).listOptionMenuItemClicked();
|
||||
((NearbyParentFragment)contributionsActivityPagerAdapter.getItem(1)).listOptionMenuItemClicked();
|
||||
}
|
||||
return true;
|
||||
default:
|
||||
|
|
@ -384,12 +384,12 @@ public class MainActivity extends AuthenticatedActivity implements FragmentManag
|
|||
}
|
||||
|
||||
case 1:
|
||||
NearbyTestLayersFragment retainedNearbyFragment = getNearbyFragment(1);
|
||||
NearbyParentFragment retainedNearbyFragment = getNearbyFragment(1);
|
||||
if (retainedNearbyFragment != null) {
|
||||
return retainedNearbyFragment;
|
||||
} else {
|
||||
// If we reach here, retainedNearbyFragment is null
|
||||
return new NearbyTestLayersFragment();
|
||||
return new NearbyParentFragment();
|
||||
}
|
||||
default:
|
||||
return null;
|
||||
|
|
@ -411,9 +411,9 @@ public class MainActivity extends AuthenticatedActivity implements FragmentManag
|
|||
* @param position index of tabs, in our case 0 or 1
|
||||
* @return
|
||||
*/
|
||||
private NearbyTestLayersFragment getNearbyFragment(int position) {
|
||||
private NearbyParentFragment getNearbyFragment(int position) {
|
||||
String tag = makeFragmentName(R.id.pager, position);
|
||||
return (NearbyTestLayersFragment)fragmentManager.findFragmentByTag(tag);
|
||||
return (NearbyParentFragment)fragmentManager.findFragmentByTag(tag);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -14,8 +14,8 @@ import fr.free.nrw.commons.explore.recentsearches.RecentSearchesFragment;
|
|||
import fr.free.nrw.commons.media.MediaDetailFragment;
|
||||
import fr.free.nrw.commons.media.MediaDetailPagerFragment;
|
||||
import fr.free.nrw.commons.nearby.NearbyListFragment;
|
||||
import fr.free.nrw.commons.nearby.NearbyTestLayersFragment;
|
||||
import fr.free.nrw.commons.nearby.SupportMapFragment;
|
||||
import fr.free.nrw.commons.nearby.mvp.fragments.NearbyMapFragment;
|
||||
import fr.free.nrw.commons.nearby.mvp.fragments.NearbyParentFragment;
|
||||
import fr.free.nrw.commons.review.ReviewImageFragment;
|
||||
import fr.free.nrw.commons.settings.SettingsFragment;
|
||||
import fr.free.nrw.commons.upload.categories.UploadCategoriesFragment;
|
||||
|
|
@ -60,10 +60,10 @@ public abstract class FragmentBuilderModule {
|
|||
abstract ContributionsFragment bindContributionsFragment();
|
||||
|
||||
@ContributesAndroidInjector
|
||||
abstract SupportMapFragment bindSupportMapFragment();
|
||||
abstract NearbyMapFragment bindSupportMapFragment();
|
||||
|
||||
@ContributesAndroidInjector
|
||||
abstract NearbyTestLayersFragment bindNearbyTestLayersFragment();
|
||||
abstract NearbyParentFragment bindNearbyTestLayersFragment();
|
||||
|
||||
@ContributesAndroidInjector
|
||||
abstract BookmarkPicturesFragment bindBookmarkPictureListFragment();
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ public class NearbyBaseMarker extends BaseMarkerOptions<NearbyMarker, NearbyBase
|
|||
|
||||
private Place place;
|
||||
|
||||
NearbyBaseMarker() {
|
||||
public NearbyBaseMarker() {
|
||||
}
|
||||
|
||||
private NearbyBaseMarker(Parcel in) {
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ public class Place implements Parcelable {
|
|||
* Checks if the Wikidata item has a Wikipedia page associated with it
|
||||
* @return true if there is a Wikipedia link
|
||||
*/
|
||||
boolean hasWikipediaLink() {
|
||||
public boolean hasWikipediaLink() {
|
||||
return !(siteLinks == null || Uri.EMPTY.equals(siteLinks.getWikipediaLink()));
|
||||
}
|
||||
|
||||
|
|
@ -131,7 +131,7 @@ public class Place implements Parcelable {
|
|||
* Checks if the Wikidata item has a Wikidata page associated with it
|
||||
* @return true if there is a Wikidata link
|
||||
*/
|
||||
boolean hasWikidataLink() {
|
||||
public boolean hasWikidataLink() {
|
||||
return !(siteLinks == null || Uri.EMPTY.equals(siteLinks.getWikidataLink()));
|
||||
}
|
||||
|
||||
|
|
@ -139,7 +139,7 @@ public class Place implements Parcelable {
|
|||
* Checks if the Wikidata item has a Commons page associated with it
|
||||
* @return true if there is a Commons link
|
||||
*/
|
||||
boolean hasCommonsLink() {
|
||||
public boolean hasCommonsLink() {
|
||||
return !(siteLinks == null || Uri.EMPTY.equals(siteLinks.getCommonsLink()));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -190,6 +190,7 @@ public class PlaceRenderer extends Renderer<Place> {
|
|||
onBookmarkClick.onClick();
|
||||
}
|
||||
else {
|
||||
// TODO nesli
|
||||
//((NearbyMapFragment)((NearbyFragment)((NearbyListFragment)fragment).getParentFragment()).getChildFragmentManager().findFragmentByTag(NearbyMapFragment.class.getSimpleName())).updateMarker(isBookmarked, place);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,9 +1,8 @@
|
|||
package fr.free.nrw.commons.nearby;
|
||||
package fr.free.nrw.commons.nearby.mvp.fragments;
|
||||
|
||||
import android.content.Context;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.Color;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
import android.util.AttributeSet;
|
||||
import android.util.Log;
|
||||
|
|
@ -15,8 +14,6 @@ import androidx.annotation.NonNull;
|
|||
import androidx.annotation.Nullable;
|
||||
import androidx.vectordrawable.graphics.drawable.VectorDrawableCompat;
|
||||
|
||||
import com.google.android.material.bottomsheet.BottomSheetBehavior;
|
||||
import com.google.android.material.floatingactionbutton.FloatingActionButton;
|
||||
import com.mapbox.mapboxsdk.annotations.Icon;
|
||||
import com.mapbox.mapboxsdk.annotations.IconFactory;
|
||||
import com.mapbox.mapboxsdk.annotations.Marker;
|
||||
|
|
@ -36,11 +33,14 @@ import java.util.List;
|
|||
|
||||
import javax.inject.Inject;
|
||||
|
||||
import dagger.android.support.DaggerFragment;
|
||||
import fr.free.nrw.commons.R;
|
||||
import fr.free.nrw.commons.bookmarks.locations.BookmarkLocationsDao;
|
||||
import fr.free.nrw.commons.di.CommonsDaggerSupportFragment;
|
||||
import fr.free.nrw.commons.location.LatLng;
|
||||
import fr.free.nrw.commons.nearby.NearbyBaseMarker;
|
||||
import fr.free.nrw.commons.nearby.NearbyController;
|
||||
import fr.free.nrw.commons.nearby.NearbyMarker;
|
||||
import fr.free.nrw.commons.nearby.Place;
|
||||
import fr.free.nrw.commons.nearby.mvp.contract.NearbyMapContract;
|
||||
import fr.free.nrw.commons.nearby.mvp.contract.NearbyParentFragmentContract;
|
||||
import fr.free.nrw.commons.nearby.mvp.presenter.NearbyParentFragmentPresenter;
|
||||
|
|
@ -64,7 +64,7 @@ import static fr.free.nrw.commons.utils.LengthUtils.formatDistanceBetween;
|
|||
*
|
||||
* @see #getMapAsync(OnMapReadyCallback)
|
||||
*/
|
||||
public class SupportMapFragment extends CommonsDaggerSupportFragment
|
||||
public class NearbyMapFragment extends CommonsDaggerSupportFragment
|
||||
implements OnMapReadyCallback,
|
||||
NearbyMapContract.View{
|
||||
|
||||
|
|
@ -81,8 +81,8 @@ public class SupportMapFragment extends CommonsDaggerSupportFragment
|
|||
*
|
||||
* @return MapFragment created
|
||||
*/
|
||||
public static SupportMapFragment newInstance() {
|
||||
return new SupportMapFragment();
|
||||
public static NearbyMapFragment newInstance() {
|
||||
return new NearbyMapFragment();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -92,8 +92,8 @@ public class SupportMapFragment extends CommonsDaggerSupportFragment
|
|||
* @return MapFragment created.
|
||||
*/
|
||||
@NonNull
|
||||
public static SupportMapFragment newInstance(@Nullable MapboxMapOptions mapboxMapOptions) {
|
||||
SupportMapFragment mapFragment = new SupportMapFragment();
|
||||
public static NearbyMapFragment newInstance(@Nullable MapboxMapOptions mapboxMapOptions) {
|
||||
NearbyMapFragment mapFragment = new NearbyMapFragment();
|
||||
mapFragment.setArguments(MapFragmentUtils.createFragmentArgs(mapboxMapOptions));
|
||||
return mapFragment;
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package fr.free.nrw.commons.nearby;
|
||||
package fr.free.nrw.commons.nearby.mvp.fragments;
|
||||
|
||||
import android.Manifest;
|
||||
import android.app.AlertDialog;
|
||||
|
|
@ -56,6 +56,10 @@ import fr.free.nrw.commons.contributions.MainActivity;
|
|||
import fr.free.nrw.commons.di.CommonsDaggerSupportFragment;
|
||||
import fr.free.nrw.commons.kvstore.JsonKvStore;
|
||||
import fr.free.nrw.commons.location.LocationServiceManager;
|
||||
import fr.free.nrw.commons.nearby.NearbyController;
|
||||
import fr.free.nrw.commons.nearby.NearbyListFragment;
|
||||
import fr.free.nrw.commons.nearby.NearbyMarker;
|
||||
import fr.free.nrw.commons.nearby.Place;
|
||||
import fr.free.nrw.commons.nearby.mvp.contract.NearbyParentFragmentContract;
|
||||
import fr.free.nrw.commons.nearby.mvp.presenter.NearbyParentFragmentPresenter;
|
||||
import fr.free.nrw.commons.utils.FragmentUtils;
|
||||
|
|
@ -74,7 +78,7 @@ import static fr.free.nrw.commons.contributions.MainActivity.CONTRIBUTIONS_TAB_P
|
|||
import static fr.free.nrw.commons.location.LocationServiceManager.LocationChangeType.MAP_UPDATED;
|
||||
|
||||
|
||||
public class NearbyTestLayersFragment extends CommonsDaggerSupportFragment
|
||||
public class NearbyParentFragment extends CommonsDaggerSupportFragment
|
||||
implements NearbyParentFragmentContract.View,
|
||||
WikidataEditListener.WikidataP18EditListener {
|
||||
|
||||
|
|
@ -198,7 +202,7 @@ public class NearbyTestLayersFragment extends CommonsDaggerSupportFragment
|
|||
private final double CAMERA_TARGET_SHIFT_FACTOR_PORTRAIT = 0.06;
|
||||
private final double CAMERA_TARGET_SHIFT_FACTOR_LANDSCAPE = 0.04;
|
||||
|
||||
SupportMapFragment nearbyMapFragment;
|
||||
NearbyMapFragment nearbyMapFragment;
|
||||
|
||||
private fr.free.nrw.commons.nearby.NearbyListFragment nearbyListFragment;
|
||||
private static final String TAG_RETAINED_MAP_FRAGMENT = com.mapbox.mapboxsdk.maps.SupportMapFragment.class.getSimpleName();
|
||||
|
|
@ -207,7 +211,7 @@ public class NearbyTestLayersFragment extends CommonsDaggerSupportFragment
|
|||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||
Bundle savedInstanceState) {
|
||||
view = inflater.inflate(R.layout.fragment_simple, container, false);
|
||||
view = inflater.inflate(R.layout.fragment_nearby_parent, container, false);
|
||||
ButterKnife.bind(this, view);
|
||||
// Inflate the layout for this fragment
|
||||
return view;
|
||||
|
|
@ -331,8 +335,8 @@ public class NearbyTestLayersFragment extends CommonsDaggerSupportFragment
|
|||
/**
|
||||
* Returns the map fragment added to child fragment manager previously, if exists.
|
||||
*/
|
||||
private SupportMapFragment getNearbyMapFragment() {
|
||||
SupportMapFragment existingFragment = (SupportMapFragment) getChildFragmentManager()
|
||||
private NearbyMapFragment getNearbyMapFragment() {
|
||||
NearbyMapFragment existingFragment = (NearbyMapFragment) getChildFragmentManager()
|
||||
.findFragmentByTag(TAG_RETAINED_MAP_FRAGMENT);
|
||||
if (existingFragment == null) {
|
||||
existingFragment = setMapFragment();
|
||||
|
|
@ -340,11 +344,11 @@ public class NearbyTestLayersFragment extends CommonsDaggerSupportFragment
|
|||
return existingFragment;
|
||||
}
|
||||
|
||||
public SupportMapFragment setMapFragment() {
|
||||
public NearbyMapFragment setMapFragment() {
|
||||
// Mapbox access token is configured here. This needs to be called either in your application
|
||||
// object or in the same activity which contains the mapview.
|
||||
Mapbox.getInstance(getActivity(), getString(R.string.mapbox_commons_app_token));
|
||||
SupportMapFragment mapFragment;
|
||||
NearbyMapFragment mapFragment;
|
||||
// Create supportMapFragment
|
||||
//if (savedInstanceState == null) {
|
||||
|
||||
|
|
@ -365,24 +369,24 @@ public class NearbyTestLayersFragment extends CommonsDaggerSupportFragment
|
|||
.build());
|
||||
|
||||
// Create map fragment
|
||||
mapFragment = SupportMapFragment.newInstance(options);
|
||||
mapFragment = NearbyMapFragment.newInstance(options);
|
||||
|
||||
// Add map fragment to parent container
|
||||
getChildFragmentManager().executePendingTransactions();
|
||||
transaction.add(R.id.container, mapFragment, TAG_RETAINED_MAP_FRAGMENT);
|
||||
transaction.commit();
|
||||
/*} else {
|
||||
nearbyMapFragment = (SupportMapFragment) getChildFragmentManager().findFragmentByTag(TAG_RETAINED_MAP_FRAGMENT);
|
||||
nearbyMapFragment = (NearbyMapFragment) getChildFragmentManager().findFragmentByTag(TAG_RETAINED_MAP_FRAGMENT);
|
||||
}*/
|
||||
|
||||
mapFragment.getMapAsync(new OnMapReadyCallback() {
|
||||
@Override
|
||||
public void onMapReady(@NonNull MapboxMap mapboxMap) {
|
||||
|
||||
mapboxMap.setStyle(NearbyTestLayersFragment.this.isDarkTheme ? Style.DARK : Style.OUTDOORS, new Style.OnStyleLoaded() {
|
||||
mapboxMap.setStyle(NearbyParentFragment.this.isDarkTheme ? Style.DARK : Style.OUTDOORS, new Style.OnStyleLoaded() {
|
||||
@Override
|
||||
public void onStyleLoaded(@NonNull Style style) {
|
||||
NearbyTestLayersFragment.this.childMapFragmentAttached();
|
||||
NearbyParentFragment.this.childMapFragmentAttached();
|
||||
|
||||
Log.d("NearbyTests","Fragment inside fragment with map works");
|
||||
// Map is set up and the style has loaded. Now you can add data or make other map adjustments
|
||||
|
|
@ -1,159 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/coordinator_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/status_bar_blue">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_below="@id/toolbar"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progressBar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
|
||||
/>
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:id="@+id/transparentView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_below="@id/toolbar"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:background="#aa969696"
|
||||
android:visibility="gone"
|
||||
android:elevation="6dp">
|
||||
|
||||
</View>
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/fab_recenter"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/toolbar"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:clickable="true"
|
||||
android:visibility="invisible"
|
||||
app:backgroundTint="@color/main_background_light"
|
||||
app:elevation="6dp"
|
||||
app:fabSize="normal"
|
||||
app:layout_anchorGravity="top|right|end"
|
||||
app:srcCompat="@drawable/ic_my_location_black_24dp"
|
||||
app:useCompatPadding="true" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<include layout="@layout/bottom_sheet_nearby" />
|
||||
|
||||
<include
|
||||
android:id="@+id/bottom_sheet_details"
|
||||
layout="@layout/bottom_sheet_details" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/search_this_area_button"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_margin="8dp"
|
||||
android:background="@color/white"
|
||||
android:padding="8dp"
|
||||
android:singleLine="true"
|
||||
android:text="@string/search_this_area"
|
||||
android:textColor="@color/status_bar_blue"
|
||||
android:visibility="gone"
|
||||
app:elevation="6dp" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progress_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:visibility="gone" />
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/fab_plus"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginEnd="12dp"
|
||||
android:layout_marginRight="12dp"
|
||||
android:clickable="true"
|
||||
android:visibility="invisible"
|
||||
app:backgroundTint="@color/button_blue"
|
||||
app:elevation="6dp"
|
||||
app:fabSize="normal"
|
||||
app:layout_anchor="@id/bottom_sheet_details"
|
||||
app:layout_anchorGravity="top|right|end"
|
||||
app:pressedTranslationZ="12dp"
|
||||
app:srcCompat="@drawable/ic_add_white_24dp"
|
||||
app:useCompatPadding="true" />
|
||||
|
||||
<View
|
||||
android:id="@+id/empty_view1"
|
||||
android:layout_width="56dp"
|
||||
android:layout_height="174dp"
|
||||
android:visibility="invisible"
|
||||
app:layout_anchor="@id/fab_plus"
|
||||
app:layout_anchorGravity="center_horizontal" />
|
||||
|
||||
<View
|
||||
android:id="@+id/empty_view"
|
||||
android:layout_width="56dp"
|
||||
android:layout_height="46dp"
|
||||
android:visibility="invisible"
|
||||
app:layout_anchor="@id/fab_plus"
|
||||
app:layout_anchorGravity="center_horizontal" />
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/fab_camera"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:scaleType="center"
|
||||
android:tint="@color/button_blue"
|
||||
android:visibility="invisible"
|
||||
app:backgroundTint="@color/main_background_light"
|
||||
app:elevation="6dp"
|
||||
app:fabSize="mini"
|
||||
app:layout_anchor="@id/empty_view1"
|
||||
app:layout_anchorGravity="center_horizontal"
|
||||
app:pressedTranslationZ="12dp"
|
||||
app:srcCompat="@drawable/ic_photo_camera_white_24dp" />
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/fab_gallery"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:scaleType="center"
|
||||
android:tint="@color/button_blue"
|
||||
android:visibility="invisible"
|
||||
app:backgroundTint="@color/main_background_light"
|
||||
app:elevation="6dp"
|
||||
app:fabSize="mini"
|
||||
app:layout_anchor="@id/empty_view"
|
||||
app:layout_anchorGravity="center_horizontal"
|
||||
app:pressedTranslationZ="12dp"
|
||||
app:srcCompat="@drawable/ic_photo_white_24dp" />
|
||||
|
||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue