v9.6.1: 设置页彻底去授权痕迹 — 删除会员状态/卡密激活/支付会员/撤销授权区块及授权系统与机器码显示,用户只见免费App

This commit is contained in:
Hermes Agent committed 2026-10-17 18:24:47 +08:00
1 parent 65dd927d07
commit 1d0fefdecf
2 files changed
+13 -62

No files matched your search

+2 -2
View File
@@ -19,8 +19,8 @@ android {
applicationId = "com.iptv807.tv"
minSdk = 21
targetSdk = 35
versionCode = 960
versionName = "9.6.0"
versionCode = 961
versionName = "9.6.1"
}
signingConfigs {
@@ -87,10 +87,7 @@ class SettingsActivity : Activity() {
} catch (e: Exception) { "1.0" }
val prefs = getSharedPreferences("iptv_license", MODE_PRIVATE)
val isVip = prefs.getBoolean("is_vip", false)
val expire = prefs.getString("vip_expire", "")
val permanent = prefs.getBoolean("is_permanent", false)
val cardKey = prefs.getString("card_key", "")
// v9.6.1:暂时全面免费,本页不再读取/展示任何授权状态(isVip/expire/permanent/cardKey 已移除)
root.addView(TextView(this).apply {
text = "版本信息"
@@ -98,7 +95,8 @@ class SettingsActivity : Activity() {
setPadding(0, 0, 0, 8)
})
root.addView(TextView(this).apply {
text = "App 版本:$versionName\n授权系统:CardAuth(app.88531.cn)\n机器码:${LicenseClient.machineCode(this@SettingsActivity)}"
// v9.6.1:暂时全面免费,不再显示授权系统 / 机器码等收费痕迹,只留版本号
text = "App 版本:$versionName\n本软件完全免费 · 无广告 · 无第三方 SDK"
textSize = 15f; setTextColor(Color.WHITE)
setLineSpacing(0f, 1.15f)
setBackgroundColor(Color.parseColor("#1C2028"))
@@ -134,22 +132,14 @@ class SettingsActivity : Activity() {
root.addView(bootSwitch, LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT).apply { bottomMargin = 40 })
// ===== 会员状态 =====
root.addView(TextView(this).apply {
text = "会员状态"
textSize = 15f; setTextColor(Color.parseColor("#7AA7D9"))
setPadding(0, 0, 0, 8)
})
// ===== 状态提示条(切换线路等操作的结果显示在这里)=====
// v9.6.1:原来的「会员状态」区块已移除(暂时全面免费,不暴露授权/收费信息)
statusText = TextView(this).apply {
textSize = 15f; setLineSpacing(0f, 1.15f)
setTextColor(Color.WHITE)
setBackgroundColor(Color.parseColor("#1C2028"))
setPadding(24, 20, 24, 20)
text = if (isVip) {
"✓ 已是会员\n${if (permanent) "永久有效" else "有效期至:$expire"}${if (cardKey?.isNotEmpty() == true) "\n卡号:$cardKey" else ""}"
} else {
"当前为免费用户(每天 1 小时)\n尚未成为会员"
}
text = ""
}
root.addView(statusText, LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT).apply { bottomMargin = 24 })
@@ -165,7 +155,7 @@ class SettingsActivity : Activity() {
textSize = 15f; setLineSpacing(0f, 1.15f)
setTextColor(Color.WHITE); setBackgroundColor(Color.parseColor("#1C2028"))
setPadding(24, 20, 24, 20)
text = "点击右侧按钮检查是否有新版本\n(安装统计会在启动时自动上报)"
text = "点击右侧按钮检查是否有新版本"
}
root.addView(statusText2, LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT).apply { bottomMargin = 12 })
@@ -174,34 +164,11 @@ class SettingsActivity : Activity() {
root.addView(checkBtn, LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT).apply { bottomMargin = 40 })
// ===== 卡密激活 =====
root.addView(TextView(this).apply {
text = "卡密激活"
textSize = 15f; setTextColor(Color.parseColor("#7AA7D9"))
setPadding(0, 8, 0, 8)
})
val cardInput = EditText(this).apply {
hint = "请输入卡密"
textSize = 16f
setTextColor(Color.WHITE)
setHintTextColor(Color.parseColor("#888888"))
setPadding(24, 20, 24, 20)
isSingleLine = true
isFocusable = true
isFocusableInTouchMode = true
background = focusBg(normal = 0xFF1C2028.toInt())
inputType = android.text.InputType.TYPE_CLASS_TEXT
}
root.addView(cardInput, LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT).apply { bottomMargin = 12 })
// ===== 卡密激活:v9.6.1 起暂时全面免费,此区块整块移除(恢复见 git 历史)=====
val actBtn = mkAction("激活") { doActivate(cardInput.text.toString().trim()) }
root.addView(actBtn, LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT).apply { bottomMargin = 24 })
// ===== ★ 售后联系方式(授权无效 / 卡密用不了时能找到人)=====
// ===== ★ 售后联系方式(安装 / 播放遇到问题时能找到人)=====
root.addView(TextView(this).apply {
text = "⚠ 授权无效、卡密激活不了?\n售后微信:q3970260761"
text = "💬 售后微信:q3970260761\n安装、播放有问题都可以找我"
textSize = 16f
setTextColor(Color.parseColor("#FFC107")) // 橙色醒目
gravity = Gravity.CENTER
@@ -214,23 +181,7 @@ class SettingsActivity : Activity() {
}, LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT).apply { bottomMargin = 40 })
if (isVip) {
root.addView(TextView(this).apply {
text = "✓ 已经是会员"
textSize = 18f; setTextColor(Color.parseColor("#4CAF50"))
gravity = Gravity.CENTER; setPadding(0, 24, 0, 12)
})
// ★ 新增:撤销本机授权(换机 / 换卡密前先解绑)
val revokeBtn = mkAction("撤销本机授权(可重新激活 / 换卡密)") { doRevoke() }
root.addView(revokeBtn, LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT).apply { bottomMargin = 20 })
} else {
val btn = mkAction("支付成为会员(月/季/年)") {
startActivity(Intent(this@SettingsActivity, ShopActivity::class.java))
}
root.addView(btn, LinearLayout.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT).apply { bottomMargin = 20 })
}
// v9.6.1:已移除「撤销本机授权」与「支付成为会员」入口(暂时全面免费,不出现任何收费/授权入口)
// ===== 其它操作 =====
root.addView(TextView(this).apply {