Fixes
This commit is contained in:
@@ -24,10 +24,7 @@ class ServiceNotification(private val service: Service) {
|
||||
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.TIRAMISU) {
|
||||
return true
|
||||
}
|
||||
if (Application.notification.areNotificationsEnabled()) {
|
||||
return true
|
||||
}
|
||||
return false
|
||||
return Application.notification.areNotificationsEnabled()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -36,7 +33,7 @@ class ServiceNotification(private val service: Service) {
|
||||
NotificationCompat.Builder(service, notificationChannel).setWhen(0)
|
||||
.setContentTitle("sing-box")
|
||||
.setContentText("service started").setOnlyAlertOnce(true)
|
||||
.setSmallIcon(R.drawable.ic_launcher_foreground)
|
||||
.setSmallIcon(R.drawable.ic_menu)
|
||||
.setCategory(NotificationCompat.CATEGORY_SERVICE)
|
||||
.setContentIntent(
|
||||
PendingIntent.getActivity(
|
||||
|
||||
@@ -274,6 +274,7 @@ class GroupsFragment : Fragment(), CommandClientHandler {
|
||||
RecyclerView.ViewHolder(binding.root) {
|
||||
|
||||
fun bind(groupView: GroupView, group: OutboundGroup, item: OutboundGroupItem) {
|
||||
if (group.selectable) {
|
||||
binding.itemCard.setOnClickListener {
|
||||
binding.selectedView.isVisible = true
|
||||
groupView.updateSelected(group, item)
|
||||
@@ -287,6 +288,7 @@ class GroupsFragment : Fragment(), CommandClientHandler {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
binding.selectedView.isInvisible = group.selected != item.tag
|
||||
binding.itemName.text = item.tag
|
||||
binding.itemType.text = Libbox.proxyDisplayType(item.type)
|
||||
|
||||
@@ -169,9 +169,6 @@ class ConfigurationFragment : Fragment() {
|
||||
val popup = PopupMenu(button.context, button)
|
||||
popup.setForceShowIcon(true)
|
||||
popup.menuInflater.inflate(R.menu.profile_menu, popup.menu)
|
||||
if (profile.typed.type != TypedProfile.Type.Remote) {
|
||||
popup.menu.removeItem(R.id.action_share)
|
||||
}
|
||||
popup.setOnMenuItemClickListener {
|
||||
when (it.itemId) {
|
||||
R.id.action_share -> {
|
||||
|
||||
BIN
app/src/main/res/drawable/ic_menu.png
Normal file
BIN
app/src/main/res/drawable/ic_menu.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.1 KiB |
Reference in New Issue
Block a user