-
Content Count
293 -
Joined
-
Last visited
-
Days Won
2
Everything posted by Yaron
-
It would be nice if Embarcadero handled it in-house, considering it's a bug that existed for years and is pretty straight-forward to reproduce.
-
This issue still exists and every so often pops-up, you would think it's a somewhat simple fix.
-
Detecting when an Android app finishes resizing to fullscreen mode
Yaron posted a topic in Cross-platform
I am creating an Android application that scales images based on the device's fullscreen resolution. To enable fullscreen, I do: 1. In "Project Options / Application / Version Info" I set the theme to "No TitleBar". 2. Set "Form.Fullscreen" to enabled in the main form's "OnCreate" event. However, I'm having problems detecting when my App is finally fullscreen, I suspect there may be a rounding error in Delphi's function, here is the log: 05-17 03:56:36.660: I/info(15344): FMX: ZP Remote: ZPR_DBG: Screen Scale : 1.3125 05-17 03:56:36.666: I/info(15344): FMX: ZP Remote: ZPR_DBG: IFMXScreenService.GetScreenSize : 1280x736 (with screen scale) 05-17 03:56:36.666: I/info(15344): FMX: ZP Remote: ZPR_DBG: IFMXScreenService.GetScreenSize : 975x561 (original) 05-17 03:56:36.666: I/info(15344): FMX: ZP Remote: ZPR_DBG: Screen : 975x561 05-17 03:56:36.664: I/info(15344): FMX: ZP Remote: ZPR_DBG: Client : 975x537 05-17 03:56:36.724: I/info(15344): FMX: ZP Remote: ZPR_DBG: Client : 975x537 05-17 03:56:36.940: I/info(15344): FMX: ZP Remote: ZPR_DBG: Client : 975x562 The first 4 lines give system detail from IFMXScreenService.GetScreenScale, IFMXScreenService.GetScreenSize and Screen.Width/Screen.Height. Each "client" line shows the values of "ClientWidth/ClientHeight" on a FormResize event. As you can see, the ClientHeight value is higher than the Screen.Height value, which doesm't make sense. -
Detecting when an Android app finishes resizing to fullscreen mode
Yaron replied to Yaron's topic in Cross-platform
Just for reference, my current logic is to resize the UI after an OnIdle event but not before an "TApplicationEvent.BecameActive" event triggers first. Seems to work, but I'm not perfectly confident that it works across every device. Oh, you may also notice something odd with the last resize event, the form's WindowState value was changed to "TWindowState.wsMinimized" even though the app is fullscreen. Perhaps this has something to do with the app being run on a phone with a notch. -
Detecting when an Android app finishes resizing to fullscreen mode
Yaron replied to Yaron's topic in Cross-platform
That doesn't work, check out this log, a form resize event is triggered AFTER the first OnIdle event. -
You are right, I was able to fix this de-sync issue by going line by line doing cut, paste, cut, paste (copy/paste entire blocks did not work). Strangely enough, I compared the file before/after the fix and the files are identical?!
-
I'm also experiencing this issue, at first I thought it was the issue where unicode characters entered the code by a copy & paste operation (which in the past lead to cases where the debug/code got desynched by a few lines). However, I did my usual fix for that issue (Copy/paste/convert to ascii), but it didn't work this time. The strange thing for me is that this de-sync starts to happens BEFORE any actual functional code and the increases further down the code, check out the included screenshot.
-
I'm getting a new issue with the debugger, it's reproducible for me every time (in a specific bit of code in a larger project) and freezes the IDE with the "Local Variables" pane flickering like crazy until I terminate the process. 1. I Call this function "PrepareURL('mailto:bla@bla.org',URLTypeEMail)" (see below). 2. Place a breakpoint before the case in the function below. 3. Open the "Evaluate/Modify window" and type in "sURL". 4. Change the value of sURL from "mailto:bla@bla.org" to "bla@bla.org". 5. IDE freaks out. function PrepareURL(sURL : String; sURLType : Integer) : String; begin Case sURLType of URLTypeWebSite : If Pos('://',sURL) = 0 then Result := 'https://'+sURL else Result := sURL; URLTypeEMail : If Pos('mailto:',Lowercase(sURL)) = 0 then Result := 'mailto:'+sURL else Result := sURL; URLTypePhone : If Pos('tel:',Lowercase(sURL)) = 0 then Result := 'tel:'+sURL else Result := sURL; else Result := ''; End; end; However, it doesn't happen in a clean project, something else is involved too and I'm not sure what.
-
In my limited testing so far on an existing project, trying to run the project (on a connected 64bit device) just freezes during the splash screen. If I then run the same app from the device directly after terminating the debug session and it runs with no issues.
-
Added mine to the report (OnePlus7/Android10 if anyone wondering).
-
I used the option from the control panel.
-
https://quality.embarcadero.com/browse/RSP-26980
-
Due to Delphi's inability to register changes in included ({$I filename}) files when performing a standard compile, I am forced to do a full build which brings up warning/hints from underlying units. With MARS, I always see these 9 Hints: [dcc32 Hint] MARS.Core.JSON.pas(264): H2443 Inline function 'TJSONArray.GetValue' has not been expanded because unit 'System.Generics.Collections' is not specified in USES list [dcc32 Hint] MARS.Core.JSON.pas(384): H2443 Inline function 'TJSONArray.GetValue' has not been expanded because unit 'System.Generics.Collections' is not specified in USES list [dcc32 Hint] MARS.Core.JSON.pas(473): H2443 Inline function 'TJSONObject.GetPair' has not been expanded because unit 'System.Generics.Collections' is not specified in USES list [dcc32 Hint] MARS.Core.JSON.pas(822): H2443 Inline function 'TJSONArray.GetValue' has not been expanded because unit 'System.Generics.Collections' is not specified in USES list [dcc32 Hint] MARS.Core.MessageBodyWriters.pas(129): H2443 Inline function 'TJSONArray.AddElement' has not been expanded because unit 'System.JSON' is not specified in USES list [dcc32 Hint] MARS.Core.MessageBodyWriters.pas(275): H2443 Inline function 'TJSONArray.AddElement' has not been expanded because unit 'System.JSON' is not specified in USES list [dcc32 Hint] MARS.Core.MessageBodyReaders.pas(302): H2443 Inline function 'TJSONArray.GetValue' has not been expanded because unit 'System.Generics.Collections' is not specified in USES list [dcc32 Hint] MARS.Core.MessageBodyReaders.pas(366): H2443 Inline function 'TJSONArray.GetValue' has not been expanded because unit 'System.Generics.Collections' is not specified in USES list [dcc32 Hint] MARS.Data.Utils.pas(213): H2443 Inline function 'TJSONArray.AddElement' has not been expanded because unit 'System.JSON' is not specified in USES list Any merit to these hints?
-
After doing a clean install of Delphi 10.3.3, I had to re-install mars, so I did a zip download directly from GitHub and on a re-compile, it still shows 3 hints: [dcc32 Hint] MARS.Core.MessageBodyReaders.pas(302): H2443 Inline function 'TJSONArray.GetValue' has not been expanded because unit 'System.Generics.Collections' is not specified in USES list [dcc32 Hint] MARS.Core.MessageBodyReaders.pas(366): H2443 Inline function 'TJSONArray.GetValue' has not been expanded because unit 'System.Generics.Collections' is not specified in USES list [dcc32 Hint] MARS.Data.Utils.pas(213): H2443 Inline function 'TJSONArray.AddElement' has not been expanded because unit 'System.JSON' is not specified in USES list I of course fixed it myself in a few seconds, just an FYI.
-
FYI for people re-installing: After a complete uninstall, I did a search of *embarcadero*.* on my system drive and found over 30GB of left-overs (from v10.2 and 10.3), which included a copy of interbase, the entire rad studio and sample files I choose to install in a non-default folder. I actually did several install/uninstall cycles with just v10.3.3 and each time it left a large group of files behind (~2.5gb), so the uninstall process is far from clean. Just be careful when erasing some of these folders as they may contain your license information.
-
I eventually had to uninstall, including registry and reinstalled using the web installer to get things working again. Now I need to re-configure Delphi from scratch, *yay*
-
I thought I may try the web installer as that worked for me well under a VM with the beta version, but since I originally installed through the ISO on my real PC, it warns me that the registry settings are incompatible and that I should use the ISO.
-
I uninstalled everything (including java) and installed clean from the ISO, at the end it was written to click finish and the microsoft sdk installer will execute, but it didn't. I then tried to compile an Android application that compiled just fine with the 10.3.3 beta and I get this: Do I need to install Java separately from the Delphi ISO? Under "c:\Program Files\Java\" I can see "jdk1.8.0_60" and "jre1.8.0_60" populated folders that were created by the Delphi installer.
-
Recently upgrading to Android 10, I notice a few weird inconsistencies with the various App icons. It seems that the icon embedded in the App's APK is either ignored (replaced by an icon from an icon pack depending on whichever launcher is in use), shrunk down and fitting into some shape (circle, round-rect, etc) and even when shrunk into a shape, some icons are circle-cropped while other are just squares (with the embedded icon being either a square or a round-rect). Is there a manifest entry that lets the launchers know I just want my app's icon to display as-designed?
-
I doubt it will override the 64bit version, they request the version be the same to prevent people from releasing mismatched versions by accident.
-
Then using Android Tools, how should we configure an emulator? I assume none of the x86 images would work (e.g. "Google APIs Intel x86 Atom_64 System Image"). This leaves the latest ARM system image, which only supports Android 7.1.1.
-
This is probably not high priority, but I thought I'd make a note of it, If the drive running the application version of a mars project is removed, trying to close the app crashes, even if the drive is re-attached before closing. I suspect it's due to the file handles being invalidated. It happens to me because I debug mars from an encrypted drive that is automatically detached after several hours.
-
Regardless of the upcoming version, you must include both 32bit and 64bit APK files otherwise your app will not work on some devices. I'm not sure if the play store allows you to upload separate APK files or you must upload an AppBundle.
-
So far I tried the following emulators: 1. Nox 6 (Android 7.1.x) 2. BlueStacks 4 (Android 7.1.x) 3. VirtualBox with Android v8.1 64bit image (https://www.osboxes.org/android-x86/) For some strange reason, none of them will even run the 32bit versions of a blank Delphi cross-platform app. This is on a clean install of Delphi with a clean install of a fully patched Win10 running in a VM. I guess my only course of action right now would be to buy a somewhat high-end device to be able to test 64bit development, but I would welcome any suggestions of a cheaper course.
-
Are you running Nox with the Android 7 image? By default Nox will run with older versions of Android.