mirror of
https://github.com/nextcloud/talk-android.git
synced 2024-11-29 18:08:58 +03:00
remove unused method parameters
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
This commit is contained in:
parent
5ad6da86f1
commit
0fe562d415
2 changed files with 17 additions and 17 deletions
|
@ -71,6 +71,7 @@ import com.nextcloud.talk.utils.preferences.AppPreferences;
|
|||
import org.greenrobot.eventbus.EventBus;
|
||||
import org.greenrobot.eventbus.Subscribe;
|
||||
import org.greenrobot.eventbus.ThreadMode;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.parceler.Parcels;
|
||||
|
||||
import java.io.IOException;
|
||||
|
@ -255,7 +256,7 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
|||
adapter = new FlexibleAdapter<>(contactItems, getActivity(), false);
|
||||
|
||||
if (currentUser != null) {
|
||||
fetchData(true);
|
||||
fetchData();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -459,7 +460,7 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
|||
}
|
||||
}
|
||||
|
||||
private void fetchData(boolean startFromScratch) {
|
||||
private void fetchData() {
|
||||
dispose(null);
|
||||
|
||||
alreadyFetching = true;
|
||||
|
@ -506,12 +507,12 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
|||
.retry(3)
|
||||
.subscribe(new Observer<ResponseBody>() {
|
||||
@Override
|
||||
public void onSubscribe(Disposable d) {
|
||||
public void onSubscribe(@NotNull Disposable d) {
|
||||
contactsQueryDisposable = d;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onNext(ResponseBody responseBody) {
|
||||
public void onNext(@NotNull ResponseBody responseBody) {
|
||||
if (responseBody != null) {
|
||||
Participant participant;
|
||||
|
||||
|
@ -636,7 +637,8 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
|||
}
|
||||
|
||||
if (o1 instanceof ContactItem && o2 instanceof ContactItem) {
|
||||
if ("groups".equals(((ContactItem) o1).getModel().getSource()) && "groups".equals(((ContactItem) o2).getModel().getSource())) {
|
||||
if ("groups".equals(((ContactItem) o1).getModel().getSource()) &&
|
||||
"groups".equals(((ContactItem) o2).getModel().getSource())) {
|
||||
return firstName.compareToIgnoreCase(secondName);
|
||||
} else if ("groups".equals(((ContactItem) o1).getModel().getSource())) {
|
||||
return -1;
|
||||
|
@ -661,7 +663,7 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
|||
}
|
||||
|
||||
@Override
|
||||
public void onError(Throwable e) {
|
||||
public void onError(@NotNull Throwable e) {
|
||||
if (swipeRefreshLayout != null) {
|
||||
swipeRefreshLayout.setRefreshing(false);
|
||||
}
|
||||
|
@ -679,7 +681,6 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
|||
disengageProgressBar();
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
private void prepareViews() {
|
||||
|
@ -688,7 +689,7 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
|||
recyclerView.setHasFixedSize(true);
|
||||
recyclerView.setAdapter(adapter);
|
||||
|
||||
swipeRefreshLayout.setOnRefreshListener(() -> fetchData(true));
|
||||
swipeRefreshLayout.setOnRefreshListener(this::fetchData);
|
||||
swipeRefreshLayout.setColorSchemeResources(R.color.colorPrimary);
|
||||
swipeRefreshLayout.setProgressBackgroundColorSchemeResource(R.color.refresh_spinner_background);
|
||||
|
||||
|
@ -759,7 +760,7 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
|||
public boolean onQueryTextChange(String newText) {
|
||||
if (!newText.equals("") && adapter.hasNewFilter(newText)) {
|
||||
adapter.setFilter(newText);
|
||||
fetchData(true);
|
||||
fetchData();
|
||||
} else if (newText.equals("")) {
|
||||
adapter.setFilter("");
|
||||
adapter.updateDataSet(contactItems);
|
||||
|
|
|
@ -374,7 +374,7 @@ public class OperationsMenuController extends BaseController {
|
|||
@io.reactivex.annotations.NonNull RoomOverall roomOverall
|
||||
) {
|
||||
conversation = roomOverall.getOcs().getData();
|
||||
initiateConversation(false);
|
||||
initiateConversation();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -388,7 +388,7 @@ public class OperationsMenuController extends BaseController {
|
|||
}
|
||||
});
|
||||
} else {
|
||||
initiateConversation(false);
|
||||
initiateConversation();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -594,7 +594,6 @@ public class OperationsMenuController extends BaseController {
|
|||
}
|
||||
|
||||
private void inviteUsersToAConversation() {
|
||||
RetrofitBucket retrofitBucket;
|
||||
final ArrayList<String> localInvitedUsers = invitedUsers;
|
||||
final ArrayList<String> localInvitedGroups = invitedGroups;
|
||||
if (localInvitedGroups.size() > 0) {
|
||||
|
@ -608,7 +607,7 @@ public class OperationsMenuController extends BaseController {
|
|||
addGroupsToConversation(localInvitedUsers, localInvitedGroups, apiVersion);
|
||||
addUsersToConversation(localInvitedUsers, localInvitedGroups, apiVersion);
|
||||
} else {
|
||||
initiateConversation(true);
|
||||
initiateConversation();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -653,7 +652,7 @@ public class OperationsMenuController extends BaseController {
|
|||
}
|
||||
|
||||
if (localInvitedGroups.size() == 0 && localInvitedUsers.size() == 0) {
|
||||
initiateConversation(true);
|
||||
initiateConversation();
|
||||
}
|
||||
dispose();
|
||||
}
|
||||
|
@ -707,7 +706,7 @@ public class OperationsMenuController extends BaseController {
|
|||
}
|
||||
|
||||
if (localInvitedGroups.size() == 0 && localInvitedUsers.size() == 0) {
|
||||
initiateConversation(true);
|
||||
initiateConversation();
|
||||
}
|
||||
dispose();
|
||||
}
|
||||
|
@ -717,7 +716,7 @@ public class OperationsMenuController extends BaseController {
|
|||
}
|
||||
}
|
||||
|
||||
private void initiateConversation(boolean dismissView) {
|
||||
private void initiateConversation() {
|
||||
eventBus.post(new ConversationsListFetchDataEvent());
|
||||
|
||||
Bundle bundle = new Bundle();
|
||||
|
@ -787,7 +786,7 @@ public class OperationsMenuController extends BaseController {
|
|||
showResultImage(true, false);
|
||||
} else {
|
||||
conversation = roomOverall.getOcs().getData();
|
||||
initiateConversation(true);
|
||||
initiateConversation();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue