mirror of
https://github.com/nextcloud/notes-android.git
synced 2024-11-23 13:26:15 +03:00
Remove custom alert styling
This commit is contained in:
parent
b751dfe310
commit
f485ebcbd1
5 changed files with 8 additions and 17 deletions
|
@ -57,7 +57,7 @@ public class AccountChooserDialogFragment extends AppCompatDialogFragment implem
|
|||
RecyclerView.Adapter adapter = new AccountChooserAdapter(accountsList, this, getActivity());
|
||||
accountRecyclerView.setAdapter(adapter);
|
||||
|
||||
return new AlertDialog.Builder(getActivity(), R.style.ncAlertDialog)
|
||||
return new AlertDialog.Builder(getActivity())
|
||||
.setView(view)
|
||||
.setTitle(R.string.simple_move)
|
||||
.setNegativeButton(android.R.string.cancel, null)
|
||||
|
|
|
@ -137,7 +137,7 @@ public class CategoryDialogFragment extends AppCompatDialogFragment {
|
|||
}
|
||||
});
|
||||
|
||||
return new AlertDialog.Builder(getActivity(), R.style.ncAlertDialog)
|
||||
return new AlertDialog.Builder(getActivity())
|
||||
.setTitle(R.string.change_category_title)
|
||||
.setView(dialogView)
|
||||
.setCancelable(true)
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package it.niedermann.owncloud.notes.persistence;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.BroadcastReceiver;
|
||||
import android.content.ClipData;
|
||||
import android.content.ClipboardManager;
|
||||
|
@ -17,6 +16,7 @@ import android.view.View;
|
|||
import android.widget.Toast;
|
||||
|
||||
import androidx.appcompat.app.AlertDialog;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
import com.google.android.material.snackbar.Snackbar;
|
||||
import com.nextcloud.android.sso.exceptions.NextcloudApiNotRespondingException;
|
||||
|
@ -427,11 +427,11 @@ public class NoteServerSyncHelper {
|
|||
Log.e(TAG, e.getMessage(), e);
|
||||
}
|
||||
String statusMessage = context.getApplicationContext().getString(R.string.error_sync, context.getApplicationContext().getString(status.str));
|
||||
if (context instanceof ViewProvider && context instanceof Activity) {
|
||||
if (context instanceof ViewProvider && context instanceof AppCompatActivity) {
|
||||
Snackbar.make(((ViewProvider) context).getView(), statusMessage, Snackbar.LENGTH_LONG)
|
||||
.setAction(R.string.simple_more, v -> {
|
||||
String debugInfos = ExceptionUtil.getDebugInfos((Activity) context, exceptions);
|
||||
new AlertDialog.Builder(context, R.style.ncAlertDialog)
|
||||
String debugInfos = ExceptionUtil.getDebugInfos((AppCompatActivity) context, exceptions);
|
||||
new AlertDialog.Builder(context)
|
||||
.setTitle(statusMessage)
|
||||
.setMessage(debugInfos)
|
||||
.setPositiveButton(android.R.string.copy, (a, b) -> {
|
||||
|
|
|
@ -19,11 +19,11 @@
|
|||
|
||||
<color name="icon_color_default">#757575</color>
|
||||
|
||||
<color name="widget_background">#DFFFFFFF</color>
|
||||
<color name="widget_background">#dfffffff</color>
|
||||
<color name="widget_fg_default">#000000</color>
|
||||
<color name="widget_fg_contrast">#ffffff</color>
|
||||
|
||||
<color name="category_background">#FFF</color>
|
||||
<color name="category_background">#ffffff</color>
|
||||
<color name="category_border">@color/primary</color>
|
||||
|
||||
<!-- Dark Theme -->
|
||||
|
|
|
@ -8,20 +8,11 @@
|
|||
<item name="windowActionModeOverlay">true</item>
|
||||
</style>
|
||||
|
||||
<style name="ncAlertDialog" parent="@style/Theme.AppCompat.DayNight.Dialog.Alert">
|
||||
<item name="colorAccent">@color/primary</item>
|
||||
<item name="colorPrimary">@color/primary</item>
|
||||
<item name="colorPrimaryDark">@color/primary</item>
|
||||
<item name="android:windowBackground">@color/bg_normal</item>
|
||||
</style>
|
||||
|
||||
<style name="fab">
|
||||
<item name="android:layout_margin">16dp</item>
|
||||
<item name="android:layout_width">wrap_content</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:layout_gravity">end|bottom</item>
|
||||
<item name="android:layout_alignParentBottom">true</item>
|
||||
<item name="android:layout_alignParentRight">true</item>
|
||||
</style>
|
||||
|
||||
<style name="SplashTheme" parent="AppTheme">
|
||||
|
|
Loading…
Reference in a new issue