mirror of
https://codeberg.org/gitnex/GitNex.git
synced 2023-12-13 20:50:18 +01:00
Use FAB button for team repos and members
This commit is contained in:
parent
e2be2ec018
commit
3c96a042ae
|
@ -6,6 +6,7 @@ import org.mian.gitnex.R;
|
|||
import org.mian.gitnex.activities.AddNewTeamMemberActivity;
|
||||
import org.mian.gitnex.activities.AddNewTeamRepoActivity;
|
||||
import org.mian.gitnex.clients.RetrofitClient;
|
||||
import org.mian.gitnex.fragments.OrganizationTeamInfoMembersFragment;
|
||||
import org.mian.gitnex.fragments.OrganizationTeamInfoReposFragment;
|
||||
import org.mian.gitnex.helpers.AlertDialogs;
|
||||
import org.mian.gitnex.helpers.Toasty;
|
||||
|
@ -34,6 +35,7 @@ public class TeamActions {
|
|||
|
||||
if (response.code() == 204) {
|
||||
|
||||
OrganizationTeamInfoMembersFragment.refreshMembers = true;
|
||||
Toasty.success(
|
||||
context, context.getString(R.string.memberRemovedMessage));
|
||||
((AddNewTeamMemberActivity) context).finish();
|
||||
|
@ -81,6 +83,7 @@ public class TeamActions {
|
|||
|
||||
if (response.code() == 204) {
|
||||
|
||||
OrganizationTeamInfoMembersFragment.refreshMembers = true;
|
||||
Toasty.success(
|
||||
context, context.getString(R.string.memberAddedMessage));
|
||||
((AddNewTeamMemberActivity) context).finish();
|
||||
|
|
|
@ -1,31 +1,24 @@
|
|||
package org.mian.gitnex.activities;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.Menu;
|
||||
import android.view.MenuInflater;
|
||||
import android.view.MenuItem;
|
||||
import android.widget.TextView;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.viewpager2.adapter.FragmentStateAdapter;
|
||||
import com.google.android.material.tabs.TabLayoutMediator;
|
||||
import org.gitnex.tea4j.v2.models.OrganizationPermissions;
|
||||
import org.gitnex.tea4j.v2.models.Team;
|
||||
import org.mian.gitnex.R;
|
||||
import org.mian.gitnex.databinding.ActivityOrgTeamInfoBinding;
|
||||
import org.mian.gitnex.fragments.BottomSheetOrganizationTeamsFragment;
|
||||
import org.mian.gitnex.fragments.OrganizationTeamInfoMembersFragment;
|
||||
import org.mian.gitnex.fragments.OrganizationTeamInfoPermissionsFragment;
|
||||
import org.mian.gitnex.fragments.OrganizationTeamInfoReposFragment;
|
||||
import org.mian.gitnex.structs.BottomSheetListener;
|
||||
|
||||
/**
|
||||
* @author M M Arif
|
||||
*/
|
||||
public class OrganizationTeamInfoActivity extends BaseActivity implements BottomSheetListener {
|
||||
public class OrganizationTeamInfoActivity extends BaseActivity {
|
||||
|
||||
private Team team;
|
||||
|
||||
|
@ -101,52 +94,4 @@ public class OrganizationTeamInfoActivity extends BaseActivity implements Bottom
|
|||
})
|
||||
.attach();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onCreateOptionsMenu(Menu menu) {
|
||||
OrganizationPermissions permissions =
|
||||
(OrganizationPermissions) getIntent().getSerializableExtra("permissions");
|
||||
if (permissions == null || permissions.isIsOwner()) {
|
||||
MenuInflater inflater = getMenuInflater();
|
||||
inflater.inflate(R.menu.generic_nav_dotted_menu, menu);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onOptionsItemSelected(MenuItem item) {
|
||||
int id = item.getItemId();
|
||||
|
||||
if (id == android.R.id.home) {
|
||||
finish();
|
||||
return true;
|
||||
} else if (id == R.id.genericMenu) {
|
||||
BottomSheetOrganizationTeamsFragment bottomSheet =
|
||||
new BottomSheetOrganizationTeamsFragment();
|
||||
Bundle args = new Bundle();
|
||||
args.putBoolean("showRepo", !team.isIncludesAllRepositories());
|
||||
bottomSheet.setArguments(args);
|
||||
bottomSheet.show(getSupportFragmentManager(), "orgTeamsBottomSheet");
|
||||
return true;
|
||||
} else {
|
||||
return super.onOptionsItemSelected(item);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onButtonClicked(String text) {
|
||||
if ("newMember".equals(text)) {
|
||||
Intent intent =
|
||||
new Intent(OrganizationTeamInfoActivity.this, AddNewTeamMemberActivity.class);
|
||||
intent.putExtra("teamId", team.getId());
|
||||
startActivity(intent);
|
||||
} else if ("newRepo".equals(text)) {
|
||||
Intent intent =
|
||||
new Intent(OrganizationTeamInfoActivity.this, AddNewTeamRepoActivity.class);
|
||||
intent.putExtra("teamId", team.getId());
|
||||
intent.putExtra("teamName", team.getName());
|
||||
intent.putExtra("orgName", getIntent().getStringExtra("orgName"));
|
||||
startActivity(intent);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,59 +0,0 @@
|
|||
package org.mian.gitnex.fragments;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.google.android.material.bottomsheet.BottomSheetDialogFragment;
|
||||
import org.mian.gitnex.databinding.BottomSheetOrganizationTeamsBinding;
|
||||
import org.mian.gitnex.structs.BottomSheetListener;
|
||||
|
||||
/**
|
||||
* @author M M Arif
|
||||
*/
|
||||
public class BottomSheetOrganizationTeamsFragment extends BottomSheetDialogFragment {
|
||||
|
||||
private BottomSheetListener bmListener;
|
||||
|
||||
@Nullable @Override
|
||||
public View onCreateView(
|
||||
@NonNull LayoutInflater inflater,
|
||||
@Nullable ViewGroup container,
|
||||
@Nullable Bundle savedInstanceState) {
|
||||
|
||||
BottomSheetOrganizationTeamsBinding bottomSheetOrganizationTeamsBinding =
|
||||
BottomSheetOrganizationTeamsBinding.inflate(inflater, container, false);
|
||||
|
||||
bottomSheetOrganizationTeamsBinding.addNewMember.setOnClickListener(
|
||||
v1 -> {
|
||||
bmListener.onButtonClicked("newMember");
|
||||
dismiss();
|
||||
});
|
||||
|
||||
if (!requireArguments().getBoolean("showRepo")) {
|
||||
bottomSheetOrganizationTeamsBinding.addRepo.setVisibility(View.GONE);
|
||||
}
|
||||
bottomSheetOrganizationTeamsBinding.addRepo.setOnClickListener(
|
||||
v1 -> {
|
||||
bmListener.onButtonClicked("newRepo");
|
||||
dismiss();
|
||||
});
|
||||
|
||||
return bottomSheetOrganizationTeamsBinding.getRoot();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onAttach(@NonNull Context context) {
|
||||
super.onAttach(context);
|
||||
|
||||
try {
|
||||
bmListener = (BottomSheetListener) context;
|
||||
} catch (ClassCastException e) {
|
||||
Log.e("BsOrganizationTeams", e.toString());
|
||||
}
|
||||
}
|
||||
}
|
|
@ -26,7 +26,7 @@ import org.mian.gitnex.viewmodels.OrganizationLabelsViewModel;
|
|||
*/
|
||||
public class OrganizationLabelsFragment extends Fragment {
|
||||
|
||||
private final OrganizationPermissions permissions;
|
||||
private OrganizationPermissions permissions;
|
||||
private OrganizationLabelsViewModel organizationLabelsViewModel;
|
||||
private ProgressBar mProgressBar;
|
||||
private RecyclerView mRecyclerView;
|
||||
|
@ -36,16 +36,16 @@ public class OrganizationLabelsFragment extends Fragment {
|
|||
private String repoOwner;
|
||||
private final String type = "org";
|
||||
|
||||
public OrganizationLabelsFragment(OrganizationPermissions permissions) {
|
||||
this.permissions = permissions;
|
||||
public OrganizationLabelsFragment() {
|
||||
}
|
||||
|
||||
public static OrganizationLabelsFragment newInstance(
|
||||
String repoOwner, OrganizationPermissions permissions) {
|
||||
|
||||
OrganizationLabelsFragment fragment = new OrganizationLabelsFragment(permissions);
|
||||
OrganizationLabelsFragment fragment = new OrganizationLabelsFragment();
|
||||
Bundle args = new Bundle();
|
||||
args.putString(getOrgName, repoOwner);
|
||||
args.putSerializable("permissions", permissions);
|
||||
fragment.setArguments(args);
|
||||
return fragment;
|
||||
}
|
||||
|
@ -58,6 +58,7 @@ public class OrganizationLabelsFragment extends Fragment {
|
|||
if (getArguments() != null) {
|
||||
|
||||
repoOwner = getArguments().getString(getOrgName);
|
||||
permissions = (OrganizationPermissions) getArguments().getSerializable("permissions");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ import org.mian.gitnex.viewmodels.RepositoriesViewModel;
|
|||
*/
|
||||
public class OrganizationRepositoriesFragment extends Fragment {
|
||||
|
||||
private final OrganizationPermissions permissions;
|
||||
private OrganizationPermissions permissions;
|
||||
private RepositoriesViewModel repositoriesViewModel;
|
||||
private FragmentRepositoriesBinding fragmentRepositoriesBinding;
|
||||
private ReposListAdapter adapter;
|
||||
|
@ -38,16 +38,15 @@ public class OrganizationRepositoriesFragment extends Fragment {
|
|||
private static final String getOrgName = null;
|
||||
private String orgName;
|
||||
|
||||
public OrganizationRepositoriesFragment(OrganizationPermissions permissions) {
|
||||
this.permissions = permissions;
|
||||
}
|
||||
public OrganizationRepositoriesFragment() {}
|
||||
|
||||
public static OrganizationRepositoriesFragment newInstance(
|
||||
String orgName, OrganizationPermissions permissions) {
|
||||
OrganizationRepositoriesFragment fragment =
|
||||
new OrganizationRepositoriesFragment(permissions);
|
||||
new OrganizationRepositoriesFragment();
|
||||
Bundle args = new Bundle();
|
||||
args.putString(getOrgName, orgName);
|
||||
args.putSerializable("permissions", permissions);
|
||||
fragment.setArguments(args);
|
||||
return fragment;
|
||||
}
|
||||
|
@ -57,6 +56,7 @@ public class OrganizationRepositoriesFragment extends Fragment {
|
|||
super.onCreate(savedInstanceState);
|
||||
if (getArguments() != null) {
|
||||
orgName = getArguments().getString(getOrgName);
|
||||
permissions = (OrganizationPermissions) getArguments().getSerializable("permissions");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package org.mian.gitnex.fragments;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
|
@ -12,10 +13,14 @@ import java.util.List;
|
|||
import org.gitnex.tea4j.v2.models.Team;
|
||||
import org.gitnex.tea4j.v2.models.User;
|
||||
import org.mian.gitnex.R;
|
||||
import org.mian.gitnex.activities.AddNewTeamMemberActivity;
|
||||
import org.mian.gitnex.activities.CreateLabelActivity;
|
||||
import org.mian.gitnex.activities.OrganizationTeamInfoActivity;
|
||||
import org.mian.gitnex.adapters.UserGridAdapter;
|
||||
import org.mian.gitnex.clients.RetrofitClient;
|
||||
import org.mian.gitnex.databinding.FragmentOrganizationTeamInfoMembersBinding;
|
||||
import org.mian.gitnex.helpers.Toasty;
|
||||
import org.mian.gitnex.viewmodels.OrganizationLabelsViewModel;
|
||||
import retrofit2.Call;
|
||||
import retrofit2.Callback;
|
||||
import retrofit2.Response;
|
||||
|
@ -30,6 +35,7 @@ public class OrganizationTeamInfoMembersFragment extends Fragment {
|
|||
private FragmentOrganizationTeamInfoMembersBinding binding;
|
||||
private Team team;
|
||||
private UserGridAdapter adapter;
|
||||
public static boolean refreshMembers = false;
|
||||
|
||||
public OrganizationTeamInfoMembersFragment() {}
|
||||
|
||||
|
@ -55,9 +61,27 @@ public class OrganizationTeamInfoMembersFragment extends Fragment {
|
|||
binding.members.setAdapter(adapter);
|
||||
fetchMembersAsync();
|
||||
|
||||
binding.addNewMember.setOnClickListener(
|
||||
v1 -> {
|
||||
Intent intent =
|
||||
new Intent(getContext(), AddNewTeamMemberActivity.class);
|
||||
intent.putExtra("teamId", team.getId());
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
return binding.getRoot();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onResume() {
|
||||
super.onResume();
|
||||
|
||||
if (refreshMembers) {
|
||||
fetchMembersAsync();
|
||||
refreshMembers = false;
|
||||
}
|
||||
}
|
||||
|
||||
private void fetchMembersAsync() {
|
||||
|
||||
Call<List<User>> call =
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package org.mian.gitnex.fragments;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.Looper;
|
||||
|
@ -16,7 +17,9 @@ import androidx.lifecycle.ViewModelProvider;
|
|||
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
import org.gitnex.tea4j.v2.models.Team;
|
||||
import org.mian.gitnex.R;
|
||||
import org.mian.gitnex.activities.AddNewTeamRepoActivity;
|
||||
import org.mian.gitnex.activities.MainActivity;
|
||||
import org.mian.gitnex.activities.OrganizationTeamInfoActivity;
|
||||
import org.mian.gitnex.adapters.ReposListAdapter;
|
||||
import org.mian.gitnex.databinding.FragmentRepositoriesBinding;
|
||||
import org.mian.gitnex.helpers.Constants;
|
||||
|
@ -41,6 +44,7 @@ public class OrganizationTeamInfoReposFragment extends Fragment {
|
|||
|
||||
Bundle bundle = new Bundle();
|
||||
bundle.putSerializable("team", team);
|
||||
bundle.putBoolean("showRepo", !team.isIncludesAllRepositories());
|
||||
fragment.setArguments(bundle);
|
||||
|
||||
return fragment;
|
||||
|
@ -59,7 +63,7 @@ public class OrganizationTeamInfoReposFragment extends Fragment {
|
|||
|
||||
repositoriesViewModel = new ViewModelProvider(this).get(RepositoriesViewModel.class);
|
||||
|
||||
fragmentRepositoriesBinding.addNewRepo.setVisibility(View.GONE);
|
||||
fragmentRepositoriesBinding.addNewRepo.setText(R.string.pageTitleAddRepository);
|
||||
|
||||
fragmentRepositoriesBinding.recyclerView.setHasFixedSize(true);
|
||||
fragmentRepositoriesBinding.recyclerView.setLayoutManager(
|
||||
|
@ -81,6 +85,19 @@ public class OrganizationTeamInfoReposFragment extends Fragment {
|
|||
|
||||
fetchDataAsync();
|
||||
|
||||
if (!requireArguments().getBoolean("showRepo")) {
|
||||
fragmentRepositoriesBinding.addNewRepo.setVisibility(View.GONE);
|
||||
}
|
||||
fragmentRepositoriesBinding.addNewRepo.setOnClickListener(
|
||||
v1 -> {
|
||||
Intent intent =
|
||||
new Intent(getContext(), AddNewTeamRepoActivity.class);
|
||||
intent.putExtra("teamId", team.getId());
|
||||
intent.putExtra("teamName", team.getName());
|
||||
intent.putExtra("orgName", requireActivity().getIntent().getStringExtra("orgName"));
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
return fragmentRepositoriesBinding.getRoot();
|
||||
}
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@
|
|||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:text="@string/addButton"
|
||||
android:text="@string/pageTitleAddRepository"
|
||||
android:textColor="?attr/primaryTextColor"
|
||||
android:maxLines="1"
|
||||
android:textSize="@dimen/dimen20sp"/>
|
||||
|
|
|
@ -34,6 +34,23 @@
|
|||
android:textColor="?attr/primaryTextColor"
|
||||
android:textSize="@dimen/dimen18sp" />
|
||||
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
style="?attr/materialCardViewFilledStyle"
|
||||
android:layout_width="@dimen/dimen48dp"
|
||||
android:layout_height="@dimen/dimen4dp"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginTop="@dimen/dimen8dp"
|
||||
android:layout_marginBottom="@dimen/dimen16dp"
|
||||
app:cardCornerRadius="@dimen/dimen24dp"
|
||||
app:cardElevation="@dimen/dimen0dp">
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="?attr/dividerColor" />
|
||||
|
||||
</com.google.android.material.card.MaterialCardView>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<com.google.android.flexbox.FlexboxLayout
|
||||
|
|
|
@ -1,81 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?attr/primaryBackgroundColor"
|
||||
android:orientation="vertical"
|
||||
android:paddingTop="6dp"
|
||||
android:paddingBottom="12dp">
|
||||
|
||||
<androidx.core.widget.NestedScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/orgTeamHeadFrame"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="8dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/bottomSheetHeader"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="@string/team"
|
||||
android:textColor="?attr/primaryTextColor"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<com.google.android.flexbox.FlexboxLayout
|
||||
android:id="@+id/orgTeamSection"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="4dp"
|
||||
app:alignContent="center"
|
||||
app:alignItems="flex_start"
|
||||
app:flexWrap="wrap"
|
||||
app:justifyContent="center">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/addRepo"
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:gravity="center"
|
||||
android:padding="4dp"
|
||||
android:text="@string/addButton"
|
||||
android:textColor="?attr/primaryTextColor"
|
||||
android:textSize="16sp"
|
||||
app:drawableTopCompat="@drawable/ic_repo"
|
||||
app:layout_alignSelf="flex_start"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/addNewMember"
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:gravity="center"
|
||||
android:padding="4dp"
|
||||
android:text="@string/addRemove"
|
||||
android:textColor="?attr/primaryTextColor"
|
||||
android:textSize="16sp"
|
||||
app:drawableTopCompat="@drawable/ic_person_add"
|
||||
app:layout_alignSelf="flex_start"/>
|
||||
|
||||
</com.google.android.flexbox.FlexboxLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
|
||||
</LinearLayout>
|
|
@ -175,6 +175,23 @@
|
|||
android:textColor="?attr/primaryTextColor"
|
||||
android:textSize="@dimen/dimen18sp" />
|
||||
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
style="?attr/materialCardViewFilledStyle"
|
||||
android:layout_width="@dimen/dimen48dp"
|
||||
android:layout_height="@dimen/dimen4dp"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginTop="@dimen/dimen8dp"
|
||||
android:layout_marginBottom="@dimen/dimen16dp"
|
||||
app:cardCornerRadius="@dimen/dimen24dp"
|
||||
app:cardElevation="@dimen/dimen0dp">
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="?attr/dividerColor" />
|
||||
|
||||
</com.google.android.material.card.MaterialCardView>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<com.google.android.flexbox.FlexboxLayout
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<androidx.coordinatorlayout.widget.CoordinatorLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
|
@ -12,40 +13,48 @@
|
|||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:indeterminate="true"
|
||||
app:indicatorColor="?attr/progressIndicatorColor"/>
|
||||
app:indicatorColor="?attr/progressIndicatorColor" />
|
||||
|
||||
<LinearLayout
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
android:background="?attr/primaryBackgroundColor"
|
||||
android:padding="@dimen/dimen4dp">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="?attr/primaryBackgroundColor"
|
||||
android:padding="@dimen/dimen4dp">
|
||||
|
||||
<GridView
|
||||
android:id="@+id/members"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:scrollbars="none"
|
||||
android:numColumns="2"
|
||||
android:gravity="center"/>
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/noDataMembers"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_margin="15dp"
|
||||
<GridView
|
||||
android:id="@+id/members"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:scrollbars="none"
|
||||
android:numColumns="2"
|
||||
android:gravity="center"
|
||||
android:text="@string/noDataFound"
|
||||
android:textColor="?attr/primaryTextColor"
|
||||
android:textSize="18sp"
|
||||
android:visibility="gone"/>
|
||||
android:clipToPadding="false"
|
||||
android:paddingBottom="@dimen/dimen72dp" />
|
||||
|
||||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
|
||||
</LinearLayout>
|
||||
<TextView
|
||||
android:id="@+id/noDataMembers"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_margin="@dimen/dimen16dp"
|
||||
android:gravity="center"
|
||||
android:text="@string/noDataFound"
|
||||
android:textColor="?attr/primaryTextColor"
|
||||
android:textSize="@dimen/dimen18sp"
|
||||
android:visibility="gone" />
|
||||
|
||||
<com.google.android.material.floatingactionbutton.ExtendedFloatingActionButton
|
||||
android:id="@+id/addNewMember"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="end|bottom"
|
||||
android:layout_margin="@dimen/dimen16dp"
|
||||
android:text="@string/addRemoveMember"
|
||||
android:contentDescription="@string/addRemoveMember"
|
||||
android:textColor="?attr/primaryBackgroundColor"
|
||||
android:backgroundTint="?attr/fabColor"
|
||||
app:iconTint="?attr/primaryBackgroundColor"
|
||||
app:icon="@drawable/ic_add" />
|
||||
|
||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
||||
|
|
|
@ -53,6 +53,7 @@
|
|||
<string name="pageTitleAdministration">Administration</string>
|
||||
<string name="pageTitleNewPullRequest">New Pull Request</string>
|
||||
<string name="pageTitleUsers">Users</string>
|
||||
<string name="pageTitleAddRepository">Add Repository</string>
|
||||
<!-- page titles -->
|
||||
|
||||
<string name="repoName">Demo repo</string>
|
||||
|
@ -293,6 +294,7 @@
|
|||
<string name="repoRemovedMessage">Repository removed from the team successfully</string>
|
||||
<string name="repoAddToTeamMessage">Add repository %1$s to organization %2$s team %3$s</string>
|
||||
<string name="repoRemoveTeamMessage">Remove repository %1$s from team %2$s</string>
|
||||
<string name="addRemoveMember">Add / Remove Member</string>
|
||||
<!-- org tabbed layout str -->
|
||||
|
||||
<!-- create team -->
|
||||
|
|
Loading…
Reference in a new issue