feat: MDC (and update generated localizations and project file)

This commit is contained in:
naturecodevoid
2023-06-01 07:38:26 -07:00
parent 40c6d60138
commit 465c87d442
23 changed files with 1746 additions and 31 deletions

View File

@@ -205,6 +205,17 @@ struct DevModeMenu: View {
} footer: {
Text(L10n.DevModeView.Signing.footer)
}
#if MDC
Section {
SwiftUI.Button(action: {
UserDefaults.shared.lastInstalldPatchBootTime = nil
UIApplication.alert(title: L10n.Action.success)
}, label: { Text(L10n.DevModeView.Mdc.fakeUndo3AppLimitPatch) }).foregroundColor(.red)
} header: {
Text(L10n.DevModeView.Mdc.header)
}
#endif
}
.navigationTitle(L10n.DevModeView.title)
.enableInjection()

View File

@@ -36,6 +36,7 @@ struct SettingsView: View {
@State var isShowingDevModePrompt = false
@State var isShowingDevModeMenu = false
@State var isShowingResetAdiPbConfirmation = false
@State var isShowingMDCPopup = false
@State var externalURLToShow: URL?
@State var quickLookURL: URL?
@@ -99,6 +100,21 @@ struct SettingsView: View {
NavigationLink(L10n.AppIconsView.title) {
AppIconsView()
}
#if MDC
NavigationLink(L10n.Remove3AppLimitView.title) {
Remove3AppLimitView()
}
#else
if CowExploits.isSupported {
NavigationLink(L10n.Remove3AppLimitView.title) {}
.disabled(true)
.alert(isPresented: self.$isShowingMDCPopup) {
Alert(title: Text(L10n.Remove3AppLimitView.title), message: Text(L10n.SettingsView.mdcPopup))
}
.onTapGesture { self.isShowingMDCPopup = true }
}
#endif
}
Section {