-
Content Count
275 -
Joined
-
Last visited
-
Days Won
2
Everything posted by Yaron
-
For me "View - Tool Windows - Palette" shows a new project selection palette window (similar to File -> New) and not the components palette.
-
I would actually like to switch to the new component pallet, but for the life of me, I can't find the setting that switches between the old and new layouts.
-
When is a Delphi form actually visible to the user on Android?
Yaron replied to Yaron's topic in Cross-platform
The last time I suffered from TBitmap threading instability was in v10.2, so perhaps that's been resolved. -
When is a Delphi form actually visible to the user on Android?
Yaron replied to Yaron's topic in Cross-platform
Something weird happened in the post above, I can't edit it for some reason. I tried doing the pre-calculations in a thread, but it resulted in instability. what I'm doing is resizing graphic elements and I simply can't get TBitmap to work without throwing exceptions in a thread on Android. -
When is a Delphi form actually visible to the user on Android?
Yaron replied to Yaron's topic in Cross-platform
@Remy Lebeau -
I am trying to write a very basic Android app that will receive a share from the YouTube app and show the data in a memo. I tried basing it on Embarcadero's Receive Intent sample: https://sourceforge.net/p/radstudiodemos/code/HEAD/tree/branches/RADStudio_Seattle/Object Pascal/Mobile Snippets/AndroidIntents/ReceiveIntent/ The only thing I did to the sample was to change a line in AndroidManifest.template.xml from: To: However, I'm encountering two issues: 1. After installing the app on an Android device, it isn't listed in the app list. I can see it on the "application manager" settings page, but not in the main app list. 2. YouTube is not listing the app as an option on the share dialog. How can I resolve these 2 issues?
-
The problem causing my app not to show was that I had to create a separate "<intent-filter>" block, after doing that it seems to function correctly.
-
I managed to get the app listed in YouTube by modifying the manifest's intent using: <action android:name="android.intent.action.SEND" /> <category android:name="android.intent.category.DEFAULT" /> <data android:mimeType="text/plain" /> However my app still doesn't show up on the device's app page.
-
When is a Delphi form actually visible to the user on Android?
Yaron replied to Yaron's topic in Cross-platform
Just to make sure I understand, this implies I can't do UI updates in my main thread in the middle of a function? -
I am trying to save an image to the photo gallery using Delphi 10.3 and Android 6+ However, when the user accepts the access request prompt on the very first call, my entire app restarts all on it's own, is there any way to disable this behavior so my app doesn't restart? I implemented the code based on this blog post: http://blong.com/Articles/AndroidPermissions/DelphiAppPermissions.htm After calling (on form create): FPermission_READ_EXTERNAL_STORAGE := JStringToString(TJManifest_permission.JavaClass.READ_EXTERNAL_STORAGE); FPermission_WRITE_EXTERNAL_STORAGE := JStringToString(TJManifest_permission.JavaClass.WRITE_EXTERNAL_STORAGE); I am calling this code to show the prompt and save the image: // Request permission PermissionsService.RequestPermissions([FPermission_WRITE_EXTERNAL_STORAGE, FPermission_READ_EXTERNAL_STORAGE], procedure(const APermissions: TArray<string>; const AGrantResults: TArray<TPermissionStatus>) begin if (Length(AGrantResults) = 2) and (AGrantResults[0] = TPermissionStatus.Granted) and (AGrantResults[1] = TPermissionStatus.Granted) then Begin { Save file } BaseFolder := System.IOUtils.TPath.GetSharedPicturesPath; If DirectoryExists(BaseFolder) = True then Begin PIKAFolder := BaseFolder+System.IOUtils.TPath.DirectorySeparatorChar+clientGameName; If DirectoryExists(PIKAFolder) = False then ForceDirectories(PIKAFolder); PIKAFile := PIKAFolder+System.IOUtils.TPath.DirectorySeparatorChar+clientGameName+'_'+ReplaceStr(ReplaceStr(DateTimeToStr(Now),':','.'),'/','.')+saveImageFileExt; Try MyImage.SaveToFile(PIKAFile); Except clientFadingMessage := strErrorSavingPicture; End; If FileExists(PIKAFile) = True then clientFadingMessage := strPictureSaved else If clientFadingMessage = '' then clientFadingMessage := strErrorSavingPicture2; End Else clientFadingMessage := strPictureFolderNotFound; End else begin clientFadingMessage := strErrorSavingPicture; end; end );
-
@Dave Nottage I can't really debug since I constantly suffer from the "Unable to start gdbserver on port '64311'. Port is already in use.", so instead I've added many more debug output lines. I finally figured out what was going on, I was creating my bitmap inside a function that was triggered by a timage-clicked, that function then called the permission request with an anonymous function. However, once the anonymous function was triggered, the bitmap var was no longer valid. I fixed the issue by creating the bitmap within the anonymous function.
-
Can you post a link to one, I tried a search on the google play store and it only came back with text viewers. Yes, created a new multi-platform project, compiled & deployed it without any changes, installed the APK on Nox and it crashes with "Project1 keeps stopping" instantly when executed.
-
I am not trying to use NOX as the debugger, I'm trying to get it to run my compiled APKs simply by dragging the APK onto the NOX window which installs just fine. But as soon as I try to run any Delphi 10.3 app on NOX, it instantly closes with an error message that the app has closed. And I use it on my main PC, no virtual machines (other than NOX of course)
-
Which log are you referring to? The app closes before it reaches my first line of code?
-
I believe it does, other apps and games work fine, my own apps used to work fine on v10.2 ...
-
Delphi 10.3 and AdMob blocking UI updates on older versions of Android
Yaron posted a topic in Cross-platform
Are you experiencing this issue? Android apps compiled with Delphi 10.3 running on older Android versions(v5, v4.4), stop updating the UI when an AdMob banner appears (using standard TBannerAd component). The game I wrote is not frozen, I can hear menu action audio when I click known button positions and using the back button exits the game cleanly. If an interstitial ad is shown (using JInterstitialAd), after the ad is closed the game returns to a black screen (again, only the UI updates being frozen). I installed the game on several of these older devices through the google play store. If you would like to test it on your own devices, the name of the game is "RGBquick" (still in beta). -
Delphi 10.3 and AdMob blocking UI updates on older versions of Android
Yaron replied to Yaron's topic in Cross-platform
Has anyone else experienced this or found a solution? If there is no solution, how do I modify the XML manifest so the google play store only allows Android 6+ devices to install the app? -
I want to port my app to iOS, but the up-front financial requirements seem to be quite high. After doing some research on the web, it seems it may there may be alternatives to purchasing an iMac computer (like running in a virtual machine instead of actual hardware). Does anyone have any experience with this? Can anyone recommend the cheapest iOS development route using Delphi 10.3?
-
But how do you apply it to use with Delphi which in the docs says that the PAserver needs to be in a local network? Is there some help/docs on Delphi integration with such services for iOS development?
-
Delphi 10.3 and AdMob blocking UI updates on older versions of Android
Yaron replied to Yaron's topic in Cross-platform
I tried it on Galaxy S2 (Android 4.0.4) and Galaxy S4 (Android 5.0), both had UI lockup issues, no issue with Galaxy S5 or Galaxy Note 4 (Android 6). It may be possible that the problem is with Android 5.0 and older, I don't have a 5.1 device to test. -
Delphi 10.3 and AdMob blocking UI updates on older versions of Android
Yaron replied to Yaron's topic in Cross-platform
The reason I wrote that AdMob was the issue was that the game is running just fine up until the point an Ad shows (either a banner at the bottom or a fullscreen Interstitial ad) at which point UI updates stop functioning. However, My app design doesn't use a TButton or TMemo (it's only using TRectangle, TImage & TLabel), so it's possible that the issue is also triggered by other components. -
Delphi 10.3 and AdMob blocking UI updates on older versions of Android
Yaron replied to Yaron's topic in Cross-platform
I used a slightly modified version of this sample code to show the JInterstitialAd (the only changes I made was to update the depreciated functions) : https://github.com/sadettinpolat/delphi/tree/master/interstitialAds In RGBquick the Interstitial ad is triggered when you open one of the leaderboard (the crown icons on the main screen). The TBannerAd component is always visible at the bottom. And remember, the issue is not particular to Interstitial ads, Delphi's (v10.3) bundled TBannerAd component freezes the entire UI. This only seems to affect Android versions earlier than v6 (no issues with v6). -
@Dalija Prasnikar Thank you for the detailed information.
-
I'm not sure you're correct. From this: https://developer.android.com/distribute/best-practices/develop/target-sdk I think by that they mean that the app is aware of API 26 and may have to specifically support API 26 functionality (like the new method to request user permissions), but that doesn't mean it can't support earlier versions of Android... am I missing something?
-
Unable to deploy after unchecking 'include splash image'
Yaron posted a topic in Delphi IDE and APIs
Has anyone else encountered this? Delphi 10.3: I have a project with specified splash images. I simply uncheck "include splash image" in the project's options and try to run the app under Android and I get an error about missing files/entries. If I check "include splash image" it all works fine, but I have no way of getting rid of the splash image.