|
@@ -124,6 +124,7 @@ import com.vpn.fastestvpnservice.viewmodels.HomeViewModel
|
|
|
import com.vpn.fastestvpnservice.viewmodels.ServerListViewModel
|
|
|
import com.wireguard.android.backend.GoBackend
|
|
|
import de.blinkt.openvpn.core.App
|
|
|
+import kotlinx.coroutines.delay
|
|
|
import java.util.Locale
|
|
|
|
|
|
lateinit var vpnConnectionsUtil: VPNConnectionsUtil
|
|
@@ -880,7 +881,7 @@ fun HomeTV(
|
|
|
modifier = Modifier
|
|
|
.fillMaxWidth(fraction = 0.4f)
|
|
|
.padding(horizontal = 0.dp, vertical = 2.dp)
|
|
|
- .padding(top = 0.dp)
|
|
|
+ .padding(top = 10.dp)
|
|
|
.height(50.dp)
|
|
|
.onKeyEvent {
|
|
|
if (it.type == KeyEventType.KeyDown && it.key == Key.DirectionDown) {
|
|
@@ -1066,6 +1067,13 @@ fun HomeTV(
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ LaunchedEffect(key1 = isFeedbackClicked) {
|
|
|
+ if (isFeedbackClicked) {
|
|
|
+ delay(150)
|
|
|
+ isDelayedFeedbackClicked = true
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
val backgroundColor by animateColorAsState(
|
|
|
targetValue = if (isDelayedFeedbackClicked) colorResource(id = R.color.yellow_feedback)
|
|
|
else MaterialTheme.colorScheme.outlineVariant, label = "Color"
|
|
@@ -1073,7 +1081,7 @@ fun HomeTV(
|
|
|
|
|
|
Box(
|
|
|
modifier = Modifier
|
|
|
- .padding(horizontal = 0.dp)
|
|
|
+ .padding(top = 10.dp)
|
|
|
.padding(vertical = 5.dp)
|
|
|
.fillMaxWidth(fraction = 0.4f)
|
|
|
.height(55.dp)
|
|
@@ -1160,8 +1168,8 @@ fun HomeTV(
|
|
|
}
|
|
|
,
|
|
|
colorFilter = ColorFilter.tint(
|
|
|
- if (isFeedbackClicked && isThumbUpClicked) colorResource(id = R.color.switch_green)
|
|
|
- else if (isThumbUpFocused) colorResource(id = R.color.dark_blue_gray_text)
|
|
|
+ if (isThumbUpFocused) colorResource(id = R.color.dark_blue_gray_text)
|
|
|
+ else if (isFeedbackClicked && isThumbUpClicked) colorResource(id = R.color.switch_green)
|
|
|
else colorResource(id = R.color.white)
|
|
|
)
|
|
|
)
|
|
@@ -1214,8 +1222,8 @@ fun HomeTV(
|
|
|
}
|
|
|
},
|
|
|
colorFilter = ColorFilter.tint(
|
|
|
- if (isFeedbackClicked && isThumbDownClicked) colorResource(id = R.color.Red)
|
|
|
- else if (isThumbDownFocused) colorResource(id = R.color.dark_blue_gray_text)
|
|
|
+ if (isThumbDownFocused) colorResource(id = R.color.dark_blue_gray_text)
|
|
|
+ else if (isFeedbackClicked && isThumbDownClicked) colorResource(id = R.color.Red)
|
|
|
else colorResource(id = R.color.white)
|
|
|
)
|
|
|
)
|