mirror of
https://github.com/nextcloud/talk-android
synced 2025-07-29 15:45:12 +01:00
Fix a few bugs
Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
parent
e35cfe90e7
commit
0430796c21
@ -110,11 +110,9 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
||||
public static final String TAG = "ContactsController";
|
||||
|
||||
private static final String KEY_SEARCH_QUERY = "ContactsController.searchQuery";
|
||||
@BindView(R.id.call_header_layout)
|
||||
public RelativeLayout callHeaderLayout;
|
||||
@BindView(R.id.initial_relative_layout)
|
||||
@Nullable @BindView(R.id.call_header_layout)
|
||||
public RelativeLayout initialRelativeLayout;
|
||||
@BindView(R.id.secondary_relative_layout)
|
||||
@Nullable @BindView(R.id.secondary_relative_layout)
|
||||
public RelativeLayout secondaryRelativeLayout;
|
||||
@Inject
|
||||
UserUtils userUtils;
|
||||
@ -172,7 +170,11 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
||||
|
||||
@Override
|
||||
protected View inflateView(@NonNull LayoutInflater inflater, @NonNull ViewGroup container) {
|
||||
return inflater.inflate(R.layout.controller_contacts_rv, container, false);
|
||||
if (isNewConversationView) {
|
||||
return inflater.inflate(R.layout.controller_contacts_rv, container, false);
|
||||
} else {
|
||||
return inflater.inflate(R.layout.controller_generic_rv, container, false);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -467,12 +469,6 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
||||
return firstName.compareToIgnoreCase(secondName);
|
||||
});
|
||||
|
||||
if (isNewConversationView) {
|
||||
callHeaderLayout.setVisibility(View.VISIBLE);
|
||||
} else {
|
||||
callHeaderLayout.setVisibility(View.GONE);
|
||||
}
|
||||
|
||||
adapter.updateDataSet(contactItems, true);
|
||||
searchItem.setVisible(contactItems.size() > 0);
|
||||
swipeRefreshLayout.setRefreshing(false);
|
||||
@ -751,7 +747,7 @@ public class ContactsController extends BaseController implements SearchView.OnQ
|
||||
return true;
|
||||
}
|
||||
|
||||
@OnClick(R.id.call_header_layout)
|
||||
@Optional @OnClick(R.id.call_header_layout)
|
||||
void toggleCallHeader() {
|
||||
adapter.toggleSelection(0);
|
||||
isPublicCall = adapter.isSelected(0);
|
||||
|
@ -45,6 +45,7 @@ import autodagger.AutoInjector;
|
||||
import io.reactivex.CompletableObserver;
|
||||
import io.reactivex.Observer;
|
||||
import io.reactivex.disposables.Disposable;
|
||||
import io.reactivex.schedulers.Schedulers;
|
||||
import okhttp3.JavaNetCookieJar;
|
||||
import okhttp3.OkHttpClient;
|
||||
import retrofit2.Retrofit;
|
||||
@ -83,6 +84,7 @@ public class AccountRemovalJob extends Job {
|
||||
|
||||
ncApi.unregisterDeviceForNotificationsWithNextcloud(ApiUtils.getCredentials(userEntity.getUsername(),
|
||||
userEntity.getToken()), ApiUtils.getUrlNextcloudPush(userEntity.getBaseUrl()))
|
||||
.subscribeOn(Schedulers.newThread())
|
||||
.subscribe(new Observer<GenericOverall>() {
|
||||
@Override
|
||||
public void onSubscribe(Disposable d) {
|
||||
@ -102,6 +104,7 @@ public class AccountRemovalJob extends Job {
|
||||
ncApi.unregisterDeviceForNotificationsWithProxy
|
||||
(ApiUtils.getCredentials(userEntity.getUsername(),
|
||||
userEntity.getToken()), ApiUtils.getUrlPushProxy(), queryMap)
|
||||
.subscribeOn(Schedulers.newThread())
|
||||
.subscribe(new Observer<Void>() {
|
||||
@Override
|
||||
public void onSubscribe(Disposable d) {
|
||||
@ -154,7 +157,9 @@ public class AccountRemovalJob extends Job {
|
||||
});
|
||||
} else {
|
||||
userUtils.deleteUser(userEntity.getUsername(),
|
||||
userEntity.getBaseUrl()).subscribe(new CompletableObserver() {
|
||||
userEntity.getBaseUrl())
|
||||
.subscribeOn(Schedulers.newThread())
|
||||
.subscribe(new CompletableObserver() {
|
||||
@Override
|
||||
public void onSubscribe(Disposable d) {
|
||||
|
||||
@ -174,7 +179,9 @@ public class AccountRemovalJob extends Job {
|
||||
} catch (IOException e) {
|
||||
Log.d(TAG, "Something went wrong while removing job at parsing PushConfigurationState");
|
||||
userUtils.deleteUser(userEntity.getUsername(),
|
||||
userEntity.getBaseUrl()).subscribe(new CompletableObserver() {
|
||||
userEntity.getBaseUrl())
|
||||
.subscribeOn(Schedulers.newThread())
|
||||
.subscribe(new CompletableObserver() {
|
||||
@Override
|
||||
public void onSubscribe(Disposable d) {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user