Jump to content

alejandro.sawers

Members
  • Content Count

    25
  • Joined

  • Last visited

Community Reputation

11 Good

About alejandro.sawers

Technical Information

  • Delphi-Version
    Delphi 12 Athens

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. alejandro.sawers

    Delphi 12.1 CE with Android 14

    A common issue when compiling the same Android project between Delphi versions is that system libraries change, but the project doesn't update them automatically (by design apparently) so try that first. Also check if your project has custom versions of Delphi units and delete/update them as these can be a source of incompatibility issues.
  2. alejandro.sawers

    Delphi 12.1 CE with Android 14

    There are multiple issues here, but let's start with this one: From Android 11 onwards the storage permissions model has changed. Please see the official documentation about WRITE_EXTERNAL_STORAGE and, depending on your app's specific needs, you should not have problem on finding and implementing an alternate solution for modern Android versions.
  3. alejandro.sawers

    Installing the Android SDK/NDK

    You can safely ignore the warning as long as the command completes successfully. That's expected as the command fixes issues with the SDK, not with the NDK. Given that you copied SDK/NDK files from another machine and also updated from 11.2 to 11.3 (and your NDK seems to be missing now) your best bet would be reinstall Delphi from scratch and only then apply the command-line (if needed at all of course). It is not. The link contains a workaround just in case you decide to update to Delphi 12 and use the offline ISO installer to do so. It also contains notes for several platforms so look carefully.
  4. alejandro.sawers

    Installing the Android SDK/NDK

    I remember the Android SDK installation failing here and there, sometimes for unknown reasons. Luckily I have and old VM with Delphi 11.1 installed and it seems that the Android SDK also failed here (red underline is mine): If this is how your installation looks then doing a command-line install of the missing tools should solve the issue. On the SDK folder you should have a "cmdline-tools" folder, go inside to "latest\bin" and locate "sdkmanager.bat". Open a command line window in the folder that contains "sdkmanager.bat" and run a command like this one (note the versions of "build-tools" and "platforms" on red that your IDE demands and adjust the command accordingly): sdkmanager.bat --install "build-tools;30.0.3" "platform-tools" "platforms;android-30" After the command completes refresh the SDK Manager page. Unless you use the ISO installer, which causes a very similar issue but easier to fix.
  5. alejandro.sawers

    New patch is coming ?

    Seems like the NDK is being bumped to r27, which aligns to the official recommendations to support 16 KB page size Android devices in the near future. But it could also be just a coincidence.
  6. alejandro.sawers

    Delphi 12.2 Patch 1

    I think I will skip 12.2 Patch 1 because RSS-1840 was the only issue resolved with significant impact for me but there is a good enough workaround for 12.2 already, so reinstalling everything (that I have compiled with 12.2) is not worth the hassle right now. Waiting for 12.3 instead.
  7. alejandro.sawers

    Delphi 12.2 TMEMO - indexoutofbounds

    Just as a follow-up the workaround posted by @Borni has the side-effect of sending the caret to the end of the line when deleting a character using the soft keyboard, so I ended up changing this: To this: FTextView.setSelection(SelStart); Additionally there is another exception thrown when moving the caret with selected text to a line with less characters than the current selection (this happens on Samsung and non-Samsung devices alike). To mitigate that I had to add a couple of lines just before the if SelEnd - SelStart > 0 then check (line 1953) in the same procedure: // Normalize selection indexes SelStart:=Min(SelStart, JCharSequenceToStr(FTextView.getText).length); SelEnd:=Min(SelEnd, JCharSequenceToStr(FTextView.getText).length);
  8. alejandro.sawers

    Delphi 12.2 and MacOS Sequoia (15.0) : No provisioning profile

    As @Dave Nottage says this is a change introduced on macOS 15, most specifically a "fix" for XCode 16. Alternatively to Dave's solution, if there is no Apple ID linked to Xcode and you can't/don't want to link it you could also copy all the profiles from the old location to the new one: cp -R ~/Library/MobileDevice/Provisioning\ Profiles ~/Library/Developer/Xcode/UserData This was tested on a Mac with no profiles installed on the new folder whatsoever. This command shows on the PAServer terminal with verbose mode enabled, but its output is consumed internally by PAServer and not printed. You can always run the same command on another Terminal to explore the output.
  9. alejandro.sawers

    Android 5 and Firebase support

    Even though Delphi 12.x officially only supports Android 10+ devices as targets its actually possible to compile for lower Android versions with some tweaks on the NDK and the app Manifest. So far, so good it works as expected, but seems like there is an incompatibility when trying to add Firebase Messaging support and running it on an Android 5 device (i.e. API level 21, the lowest supported so far) : java.lang.NoSuchMethodError: No virtual method detectResourceMismatches()Landroid/os/StrictMode$ThreadPolicy$Builder; ... at com.google.firebase.FirebaseApp.initializeApp(FirebaseApp.java:264) at com.embarcadero.firebase.provider.FirebaseInitProvider.onCreate(FirebaseInitProvider.java:67) Effectively detectResourceMismatches() was introduced later, on API level 23, so this explains the crash at app startup on Firebase initialization. Now what puzzles me is while Firebase docs claim to offer support to Android versions as low as API level 19 (4.4), Firebase on Delphi calls an API level 23 method on initialization. By the way the same docs also say that "some products might have stricter requirements", so to be sure I checked the Release Notes to see if Messaging requires a higher API level to run, but apparently API level 19 is OK for the Firebase libraries included with Delphi 12.2: For now I'm disabling automatic Firebase initialization for Android 5 devices to avoid the startup crash (using the tools:node method didn't work, removing the <%provider%> tag from the Manifest template did). Hope a workaround (maybe downgrading some Firebase dependencies) is found before having to drop the Lollipop 🍭.
  10. alejandro.sawers

    Delphi 12.2 TMEMO - indexoutofbounds

    Put my hands on a Samsung A12 and can confirm the issue when pressing the return key: Testing on a Redmi Note 11 doesn't cause the exception, but by @havrlisan's comment it does happen when tapping on the memo to move the caret from a non-empty line to an empty one. This change seems to solve the issue on both Samsung and non-Samsung devices.
  11. alejandro.sawers

    Delphi 12.2 TMEMO - indexoutofbounds

    A quick test on a Delphi 12.2 blank FMX app with only a TMemo, compiled for Android 64, running on an Android 13 device doesn't show such error. Maybe test with a blank project to discard issues with your Delphi/Android SDK installation.
  12. alejandro.sawers

    Android SDK incomplete in 12.2 ?

    If you are using the offline ISO installer then you might need to reinstall the Android SDK alone.
  13. alejandro.sawers

    Delphi 12.2 available for download

    Seems like the issue with Android SDK when using ISO installer is still present on the latest ISO. The same workaround as for the 12.1 ISO still works.
  14. alejandro.sawers

    Kasti for iOS + Firebase Cloud Messaging issue

    I think the best you could have done is to post in advance what you have tried to do and how far you reached on your implementation, along with technical details as what Delphi version you use, if you test on device or simulator, etc. Anyway the best you could do to find the culprit on your own is to test with the Kastri supplied demo and/or a blank project, then: - If that works check what is different between the working project and your old project. - If that doesn't work then the issue could be elsewhere (Firebase project config, APN certificates, FCM backend giving errors, etc.)
  15. alejandro.sawers

    iOS: Check granted accuracy authorization level

    Thanks Dave, this works like a charm and without patching anything. Hope Embarcadero adds an attribute/function to TLocationSensor (much like Authorized) to consolidate this.
×