Posts

Sort by:
Post not yet marked as solved
0 Replies
4 Views
When the content exceeds 40 lines of text, crazy behaviour starts to happen. The content jumps up and down while typing. Is there any other way to implement simple editor that can handle around 200 lines without this crazy behaviour?
Posted
by
Post not yet marked as solved
0 Replies
8 Views
In App Store Connect, is an organization's Legal Entity name separate from the App Store display name? My organization currently has the same name for both App Store display name and Legal Entity name. It contains an apostrophe, which is desired on the App Store for brand consistency. However, an apostrophe is no longer permitted in the Legal Entity name (it was entered in before that restriction came into effect). If I remove the apostrophe from the Legal Entity name to satisfy compliance warnings, will that update the App Store display name as well? I ask here because I'm supposing that if I remove the apostrophe and it does update the display name, the input validation won't let me enter it back. Any help would be appreciated - thanks!
Post not yet marked as solved
0 Replies
9 Views
I have a container view implementation that reads preference values from child views: public struct Reader<Content>: View where Content: View { public var content: () -> Content public init(@ViewBuilder content: @escaping () -> Content) { self.content = content } public var body: some View { content() .onPreferenceChange(NumericPreferenceKey.self) { value in // ... } } } This works fine until the content passed in to the container view is a Group. At that point the onPreferenceChanged modifier is applied to every child of the group, which leads to bugs in my situation. One thing I can do is simply put the content in a VStack: public var body: some View { VStack(content: content) .onPreferenceChange(NumericPreferenceKey.self) { value in // ... } } And that works fine to "Ungroup" before applying the onPreferenceChanged modifier. However, is this best practice? Is there a better way to apply a modifier to content as a whole instead of to each member of a potential group? Is it concerning that I might have an extra VStack in the view hierarchy with this fix?
Posted
by
Post not yet marked as solved
0 Replies
10 Views
I'm running into this error, when the underlying SwiftData object changes (gets an object added to it): *" A NavigationLink is presenting a value of type “Project” but there is no matching navigationDestination declaration visible from the location of the link. The link cannot be activated. Note: Links search for destinations in any surrounding NavigationStack, then within the same column of a NavigationSplitView. "* For instance, when I first fire up the simulator, clicking on any existing project correctly takes me to its details page. However, as soon as I add a new project or delete a project, none of the navigation links work any more. If I reload the simulator, they all work again! Makes me suspect it's an error with not recomputing the links when the underlying data change, but I can't figure out what I need to change, as everything looks correct. Any help would be appreciated! ContentView: struct ContentView: View { @Environment(\.modelContext) var modelContext @Query(sort: \Project.endDate) var projects: [Project] var body: some View { NavigationStack { Group { if projects.isEmpty { ContentUnavailableView("Enter your first project.", systemImage: "clipboard") } else { List { ForEach(projects, id: \.id) { project in NavigationLink(value: project) { HStack { DaysTile( days: project.numWorkDaysNowUntilEnd, description: "Work Days Remaining" ) .padding(.trailing, 5) VStack(alignment: .leading) { Text(project.name) .font(.title) Text("Start: \(project.startDate.formatted(date: .abbreviated, time: .omitted))") .foregroundStyle(.secondary) Text("End: \(project.endDate.formatted(date: .abbreviated, time: .omitted))") .foregroundStyle(.secondary) } } } } .onDelete(perform: deleteProjects) } .navigationDestination(for: Project.self) { project in ProjectDetailView(project: project) } } } .navigationTitle("Project Tracker") .toolbar { NavigationLink { AddProjectView() } label: { Label("Add New Project", systemImage: "plus") } } } } func deleteProjects(at offsets: IndexSet) { for offset in offsets { let project = projects[offset] modelContext.delete(project) } } } #Preview { ContentView() .modelContainer(for: Project.self, inMemory: true) }
Posted
by
Post not yet marked as solved
0 Replies
7 Views
I can't find a way to download a USDZ at runtime and load it into a Reality View with Reality kit. As an example, imagine downloading one of the 3D models from this Apple Developer page: https://developer.apple.com/augmented-reality/quick-look/ I think the process should be: Download the file from the web and store in temporary storage with the FileManager API Load the entity from the temp file location using Entity.init (I believe Entity.load is being deprecated in Swift 6 - throws up compiler warning) - https://developer.apple.com/documentation/realitykit/loading-entities-from-a-file Add the entity to content in the Reality View. I'm doing this at runtime on vision os in the simulator. I can get this to work with textures using slightly different APIs so I think the logic is sound but in that case I'm creating the entity with a mesh and material. Not sure if file size has an effect. Is there any official guidance or a code sample for this use case?
Posted
by
Post not yet marked as solved
0 Replies
9 Views
Hi all. I really dont know if this is the place for this question. Shortly, when i go to https://developer.apple.com/account and click "Enroll today" - nothing happens. There's no error in the console, just a 302 redirect to developer.apple.com/account. Is this like a bug or is there something else i need to do?
Posted
by
Post not yet marked as solved
0 Replies
10 Views
I am implementing pan and zoom features for an app using a custom USB camera device, in iPadOS. I am using an update function (shown below) to apply transforms for scale and translation but they are not working. By re-enabling the animation I can see that the scale translation seems to initially take effect but then the image animates back to its original scale. This all happens in a fraction of a second but I can see it. The translation transform seems to have no effect at all. Printing out the value of AVCaptureVideoPreviewLayer.transform before and after does show that my values have been applied. private func updateTransform() { #if false // Disable default animation. CATransaction.begin() CATransaction.setDisableActions(true) defer { CATransaction.commit() } #endif // Apply the transform. logger.debug("\(String(describing: self.videoPreviewLayer.transform))") let transform = CATransform3DIdentity let translate = CATransform3DTranslate(transform, translationX, translationY, 0) let scale = CATransform3DScale(transform, scale, scale, 1) videoPreviewLayer.transform = CATransform3DConcat(translate, scale) logger.debug("\(String(describing: self.videoPreviewLayer.transform))") } My question is this, how can I properly implement pan/zoom for an AVCaptureVideoPreviewLayer? Or even better, if you see a problem with my current approach or understand why the transforms I am applying do not work, please share that information.
Posted
by
Post not yet marked as solved
0 Replies
17 Views
In our implementation of Platform SSO, we would like to show custom UI in both the beginDeviceRegistration call as well as the beginUserRegistration call. It works fine in the beginDeviceRegistration call when we use presentRegistrationViewController. When we try to apply the same logic in beginUserRegistration, the ViewController's view.window object is nil and thus using it to house our custom UI doesn't work. I'm not sure if this is an implementation flaw on our part or if presentRegistrationViewController is only intended to be used in beginDeviceRegistration. The call is only mentioned in the context of registering devices, which makes us wonder if it is limited to that. Any help would be appreciated!
Posted
by
Post not yet marked as solved
0 Replies
17 Views
Hello. I am trying to enable Metal to take advantage of SwiftUI+Shaders in an existing app. In my target, I have added metal.framework, added a .metal file and confirmed I see the Metal Compiler option in my Build Settings. When I add a colorEffect modifier using the ShaderLibrary, the object renders black. I confirmed this is working in a new project so I suspect there are more steps required to get this working in an existing application.
Posted
by
Post not yet marked as solved
0 Replies
15 Views
Hi, I'm trying to get IMessage to display a video as part of a link preview with specific dimensions. The video appears, however the dimensions are incorrect. I've set the following tags: <meta property="og:video:url" content={url} /> <meta property="og:video:secure_url" content={url} /> <meta property="og:video:width" content="600" /> <meta property="og:video:height" content="982" /> The video in question is 600x982, 1.1MB in size and an mp4. I've also tried setting the og dimensions to 390x736 since a separate working example url has those, but no luck. Does anyone know what may be the issue?
Posted
by
Post not yet marked as solved
0 Replies
18 Views
I'm trying to read meta information from MXF files without success. I get an empty AVAsset array. I saw that there are mentions of "MTRegisterProfessionalVideoWorkflowFormatReaders". But there is absolutely no documentation. I don't know where to look. Has anyone encountered this? Please help with any information
Posted
by
Post not yet marked as solved
0 Replies
18 Views
So in looking over the app review guidelines, where it reads, "They may not auto-launch or have other code run automatically at startup or login without consent" We currently present a popup to inform the user if they want to connect to our server. My question is, are we able to provide the user with a way to turn off this startup prompt (thus improving speed of app startup) It would be located within our apps own settings page, upon which the user would have the choice to turn off or leave on this startup prompt. Or would this go against apple's policy in any way?
Posted
by
Post not yet marked as solved
0 Replies
65 Views
During last night, Apple allegedly pushed new XProtect antivirus signatures. After that, I think XProtect found the malware Pirrit in my Xcode Simulator files from Apple. I'm not kidding. This is an excerpt from the XProtect log (notice the NSFilePath!): 2024-05-01 07:54:12.951 Pirrit 👉 no status_message report time 0.0000000 {"action":"report","path":{"modificationDate":732892166.8634809,"path":"\/Library\/Developer\/CoreSimulator\/Images\/1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg","creationDate":732892166.8634809},"status":{"description":"Error deleting path: \/Library\/Developer\/CoreSimulator\/Images\/1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg: Error Domain=NSCocoaErrorDomain Code=513 \"“1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg” couldn’t be removed because you don’t have permission to access it.\" UserInfo={NSUserStringVariant=(\n Remove\n), NSFilePath=\/Library\/Developer\/CoreSimulator\/Images\/1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg, NSUnderlyingError=0x1247612a0 {Error Domain=NSPOSIXErrorDomain Code=1 \"Operation not permitted\"}}.","causedBy":[],"code":24}} 2024-05-01 07:54:13.197 Pirrit message not in JSON format 2024-05-01 07:54:41.125 Pirrit ⚠️ FailedToRemediate time 0.0000280 {"caused_by":[],"execution_duration":2.8014183044433594e-05,"status_code":24,"status_message":"FailedToRemediate"} XProtect also detects another threat on my machine: 2024-05-01 10:09:58.530 BadGacha ⚠️ ThreatDetected time 0.0000120 {"caused_by":[],"execution_duration":1.2040138244628906e-05,"status_message":"ThreatDetected","status_code":21} Please check your XProtect logs. There is an app that can display these logs out there. Or you can use the system logging facility. I have deleted the whole Developer folders (both at / and ~) and reinstalled Xcode (not Beta). But a new XProtect scan finds Pirrit in the Core Simulator file again! I have also attempted to install an anti virus solution (Malwarebytes), but it does not detect anything. I am wondering if we should get someone from Apple involved. I am also wondering if I should reset my whole machine… Is anyone else seeing these issues in the XProtect log? It is unclear at this time whether there really is a Pirrit malware in Apple's Xcode simulator files or if there is some issue with XProtect like a faulty signature. Don't panic.
Posted
by
Post not yet marked as solved
1 Replies
40 Views
Hi, do you guys have any idea why this code block doesn't run properly on a designed iPad app running on a vision pro simulator? I'm trying to add a hovering effect to a view in UIKit but it just doesn't enter this if statement. if #available(iOS 17.0, visionOS 1.0, *) { someView.hoverStyle = .init(effect: .automatic) }
Posted
by
Post not yet marked as solved
0 Replies
29 Views
Hello, i am trying to record logs in my network extension class, and then i want to read it in my application class, i.e. viewModel. However, i am unable to read the data. I have tried different ways like UserDefaults, Keychain, FileManager, NotificationCenter and CoreData. I have also used Appgroups but still there is blocker for reading data outside the scope of Extension class.
Posted
by
Post not yet marked as solved
0 Replies
22 Views
does anyone have an example of the decrypted payload for an interac payment would look like? Couldnt find an example within the apple documentation
Posted
by
Post not yet marked as solved
0 Replies
28 Views
Hi guys, I observed the infinite connection callback(inSelector) for some Bluetooth devices (such as an iPhone SE or Mac Mini) even when I powered off them. However, the issue is not reproducible easily. (IOBluetoothUserNotification *)registerForConnectNotifications:(id)observer selector:(SEL)inSelector ble.txt Looks like there are many -[CBManager xpcConnectionDidReceiveMsg:args:] calls when the issue occurs based on the sample, so it might be caused by the XPC connection with bluetoothd? Has anyone else experienced this issue, or any workaround for it? such as should I restart the bluetoothd?
Posted
by
Post not yet marked as solved
0 Replies
38 Views
Hello, my production app is experiencing some crashes according to app store analytics. I cannot seem to reproduce it. According to Xcode Orginzer the app is crashing 10 SwiftUI 0x000000018ec372a0 PlatformViewHost.updateNestedHosts(_:colorSchemeChanged:) + 332 (PlatformViewHost.swift:699) Distributor ID: com.apple.AppStore Hardware Model: iPhone13,4 Version: 2.0.3 (86) AppStoreTools: 15E204 AppVariant: 1:iPhone13,4:16 Code Type: ARM-64 (Native) Role: Foreground Parent Process: launchd [1] OS Version: iPhone OS 17.4.1 (21E236) Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x0000000000000000, 0x0000000000000000 Termination Reason: SIGNAL 6 Abort trap: 6 Triggered by Thread: 0 Kernel Triage: VM - (arg = 0x3) mach_vm_allocate_kernel failed within call to vm_map_enter VM - (arg = 0x3) mach_vm_allocate_kernel failed within call to vm_map_enter VM - (arg = 0x3) mach_vm_allocate_kernel failed within call to vm_map_enter VM - (arg = 0x3) mach_vm_allocate_kernel failed within call to vm_map_enter VM - (arg = 0x3) mach_vm_allocate_kernel failed within call to vm_map_enter Thread 0 name: Thread 0 Crashed: 0 libsystem_kernel.dylib 0x00000001d1bd6974 __pthread_kill + 8 (:-1) 1 libsystem_pthread.dylib 0x00000001e56590ec pthread_kill + 268 (pthread.c:1717) 2 libsystem_c.dylib 0x0000000191627c14 __abort + 136 (abort.c:159) 3 libsystem_c.dylib 0x0000000191627b8c abort + 192 (abort.c:126) 4 libswiftCore.dylib 0x000000018832a690 swift::fatalErrorv(unsigned int, char const*, char*) + 136 (Errors.cpp:387) 5 libswiftCore.dylib 0x000000018832a6b0 swift::fatalError(unsigned int, char const*, ...) + 32 (Errors.cpp:395) 6 libswiftCore.dylib 0x0000000188324a08 getNonNullSrcObject(swift::OpaqueValue*, swift::TargetMetadata<swift::InProcess> const*, swift::TargetMetadata<swift::InProcess> const*) + 256 (DynamicCast.cpp:144) 7 libswiftCore.dylib 0x0000000188326510 tryCastToObjectiveCClass(swift::OpaqueValue*, swift::TargetMetadata<swift::InProcess> const*, swift::OpaqueValue*, swift::TargetMetadata<swift::InProcess> const*, swift::TargetMetadata<swift::InPro... + 88 (DynamicCast.cpp:510) 8 libswiftCore.dylib 0x0000000188324068 tryCast(swift::OpaqueValue*, swift::TargetMetadata<swift::InProcess> const*, swift::OpaqueValue*, swift::TargetMetadata<swift::InProcess> const*, swift::TargetMetadata<swift::InProcess> const*&, sw... + 992 (DynamicCast.cpp:2281) 9 libswiftCore.dylib 0x0000000188323b14 swift_dynamicCast + 208 (CompatibilityOverrideRuntime.def:109) 10 SwiftUI 0x000000018ec372a0 PlatformViewHost.updateNestedHosts(_:colorSchemeChanged:) + 332 (PlatformViewHost.swift:699) 11 SwiftUI 0x000000018ec36bf4 PlatformViewHost.updateEnvironment(_:viewPhase:) + 412 (PlatformViewHost.swift:690) 12 SwiftUI 0x000000018ec37bf8 PlatformViewHost.init(_:host:environment:viewPhase:importer:) + 808 (PlatformViewHost.swift:132) 13 SwiftUI 0x000000018ec36cf8 PlatformViewHost.__allocating_init(_:host:environment:viewPhase:importer:) + 92 (PlatformViewHost.swift:0) 14 SwiftUI 0x000000018ec0132c closure #1 in closure #1 in closure #4 in closure #1 in PlatformViewChild.updateValue() + 444 (PlatformViewRepresentable.swift:559) 15 SwiftUI 0x000000018ec06c58 partial apply for closure #1 in closure #1 in closure #4 in closure #1 in PlatformViewChild.updateValue() + 24 (<compiler-generated>:0) 16 SwiftUI 0x000000018ea26910 RepresentableContextValues.asCurrent<A>(do:) + 156 (RepresentableContextValues.swift:43) 17 SwiftUI 0x000000018ec01124 closure #1 in closure #4 in closure #1 in PlatformViewChild.updateValue() + 176 (PlatformViewRepresentable.swift:558) 18 SwiftUI 0x000000018ec0104c closure #4 in closure #1 in PlatformViewChild.updateValue() + 128 (PlatformViewRepresentable.swift:557) 19 SwiftUI 0x000000018ec06b2c partial apply for closure #4 in closure #1 in PlatformViewChild.updateValue() + 24 (<compiler-generated>:0) 20 SwiftUI 0x000000018de7b7d0 closure #1 in _withObservation<A>(do:) + 44 (ObservationUtils.swift:26) 21 SwiftUI 0x000000018ec06b50 partial apply for closure #1 in _withObservation<A>(do:) + 24 (<compiler-generated>:0) 22 libswiftCore.dylib 0x0000000187fd0068 withUnsafeMutablePointer<A, B>(to:_:) + 28 (LifetimeManager.swift:82) 23 SwiftUI 0x000000018ebffbdc closure #1 in PlatformViewChild.updateValue() + 3040 (PlatformViewRepresentable.swift:556) 24 SwiftUI 0x000000018d5ecbf8 partial apply for implicit closure #1 in closure #1 in closure #1 in Attribute.init<A>(_:) + 32 (<compiler-generated>:0) 25 AttributeGraph 0x00000001b2150240 AG::Graph::UpdateStack::update() + 512 (ag-graph-update.cc:578) 26 AttributeGraph 0x00000001b2146f38 AG::Graph::update_attribute(AG::data::ptr<AG::Node>, unsigned int) + 424 (ag-graph-update.cc:719) 27 AttributeGraph 0x00000001b2146810 AG::Graph::input_value_ref_slow(AG::data::ptr<AG::Node>, AG::AttributeID, unsigned int, unsigned int, AGSwiftMetadata const*, unsigned char&, long) + 720 (ag-graph.cc:1429)
Posted
by

TestFlight Public Links

Get Started

Pinned Posts

Categories

See all