Mark Gorst
Members-
Content Count
9 -
Joined
-
Last visited
Everything posted by Mark Gorst
-
I think this is an IDE topic and not cross platform as the problem lies in the IDE setup/installation. In particular the installation of Android SDK/NDK I have two copies of Delphi 11.2 - effectively one in the office and one on the home office PC. Both run Windows 10 (I know this problem could go away with updating to Delphi 12 and/or Windows 11 - but it's case of our development platforms being consistent across the team). This problem has turned up in Delphi 11* versions, everything was fine in 10.4 In one case everything has installed absolutely fine and in both cases I installed the Android SDK/NDK from the platform manager. On one machine everything is fine, on the other machine SDK "build-tools" folder did not install and therefore I cannot deploy an Android version of my code from that machine (I could in 10.4). The Platform manager does not offer and "uninstall", removing the SDK/NDK folders under Public/Documents/... did not encourage it to let me re-install. I tried upgrading from 11.2 to 11.3 - and still missing folders... So I have copied across the SDK/NDK folders that work to the failing installation and tried to add this using the Deployment | SDK manager - but I get an orange triangle with an exclamation mark next to the NDK path.....and so cannot continue. I presume it means there's something it doesn't like in that folder. I have found other SDK/NDK versions I can download from the Embarcadero website, and the method for installing is to use the GetIt Manager - except they are not listed in the GetIt Manager. So I can't do that. I've got the latest Java updates installed. I'm guessing that there is something else that needs to be configured after copying across the SDK/NDK folders - a path ? an environmental variable ? but I've not been able to discover anything suitable. The folders that worked on one machine are AndroidSDK-2525-22.0.46141.0937 (10,950 files) and AndroidSDK-NDK-22.0.46141.0937 (4 files) Can anyone help ?
-
I have however dug a little deeper and found a possible problem. With my 10.4 installation I was configured with the SDK and NDK folders as AndroidSDK-2525-21.0.40680.4203 AndroidNDK-21-21.0.40680.4203 and I've realised that I don't have an NDK equivalent installed in the CatalogRepository I had been trying to use AndroidSDK-2525-22.0.46141.0937 AndroidSDK-NDK-22.0.46141.0937 I don't have a matching SDK/NDK pair, only SDK/SDK-NDK : so I will need to return to my other machine and see if there is an AndroidNDK-2525* folder - will be following this up in a few days.
-
Thanks very much for this reply. Greatly appreciated. With regards to the second suggestion, the link to fixing the ISO installer issue links to fixing it for 64bit Linux and I need to fix it for 32bit Android - so I'm not sure if that's the solution. Back to the first suggestion of running sdkmanager.bat. I did run this but ran into a problem which gave me a warning : Info: Parsing C:\Users\Public\Documents\Embarcadero\Studio\22.0\CatalogRepository\AndroidSDK-2525-22.0.46141.0937\platform-tools\package.xml Info: Parsing C:\Users\Public\Documents\Embarcadero\Studio\22.0\CatalogRepository\AndroidSDK-2525-22.0.46141.0937\platforms\android-32\package.xml Warning: Errors during XML parse: Warning: Additionally, the fallback loader failed to parse the XML. I'm not sure how significant this is, as it's a warning, and with 10,950 files guessing the solution isn't easy. The end result, however, is that it makes no difference, I still get the orange triangle/exclamation mark next to the NDK path.
-
I'm trying to replicate some behavior I have in VCL Form. I have video updating in a TForm and when I resize that form I want to stop the video updating until the resize is complete. The Resize() is working fine, but I want to use FMX.Forms.TCommonCustomForm.StartWindowResize(). I have created an override function, but resizing the window does not seem to call my code. Everything else seems to work. If I make StartWindowResize() protected rather than public the compiler warns me about this having lower visibility - so that means that it is overriding the virtual stub. csDesigning is not in the component state, Does anyone have any suggestions, There seems to be almost no mention of using StartWindowResize() anywhere.... Mark type TForm1 = class(TForm) Label1: TLabel; Timer1: TTimer; procedure FormResize(Sender: TObject); procedure Timer1Timer(Sender: TObject); public procedure StartWindowResize;override; end; var Form1: TForm1; implementation {$R *.fmx} procedure TForm1.StartWindowResize; begin timer1.Enabled:=false; ShowMessage('StartWindowResize'); inherited; end; procedure TForm1.Timer1Timer(Sender: TObject); begin label1.text:=FormatDateTime('hh:nn:ss.zzz',now); end;
-
I eventually found a way to deal with this. I stopped trying to capture the resize of the form and instead moved to the TPanel on which all the components are placed. The TPanel is client aligned to the TForm and so when the form is resized, the TPanel is always resized and I can capture the OnResize and OnResized events. If you drag the edge of the form then it will trigger a lot of pairs of these events. As I want to resize and restart my video which has a modest overhead, I use the OnResize to reset and start a TTimer so if resizing has has stopped for around 400ms then I resize and restart my video stream. Works on Windows, I'm not working with this on other platforms as the video is only supported on a single platform.
-
As a follow up to this "StartWindowResize" is only called when you MouseDown on a control that supports an ISizeGrip interface. It doesn't get called (on a Windows platform) when you drag the form edge, use the size icon, or change the width or height values. I have yet found out how to do the equivalent of the Windows WM_ENTERSIZEMOVE/WM_EXITSIZEMOVE messages.
-
Ok. I'll address this as best I can - and I'm only interested in FMX in the Windows environment. On the basis of what you tell me the StartWindowResize is of little use, because if you resize your window using the mouse to drag the border or use the minimise/maximise icon - then this will never be called, even worse on the same basis StartWindowDrag will never be called because it's not called in FMX.Forms at all. So as functions they are off little use. I understand that FMX and VCL are not the same framework and will do different things. I simply mention the VCL messaging as that's the functionality I was hoping to reproduce. Thank you for your tip about a flag to start/stop a task, however it's not quite that simple with the devices I'm using. I have got a different way of programming around the issue, It's just I thought that these two functions might do what the documentation implies, rather than StartWindowResize() only be called in a subset of resize circumstances and StartWindowDrag() never being used at all.
-
I can see this is one way it is called. However a MouseDown() event is not the only way to resize a TForm. For instance maximising a window causes a Resize event to occur, but it is not a mouse down event, nor is dragging the border, this does not cause a MouseDown event. I need to be able to avoid updating my TForm whilst it is being resized by the user. The call in MouseDown() is only triggered if you put the mouse down over an object [ ObjectAtPoint() <> nil] Similarly with StartWindowDrag whereby you can override to have your own code once you have started to drag the window, and that is not called at all in FMX.Forms directly, but I also have tried my own override on that and it does not get called when there is a drag event. What I am trying to get at is the equivalent of a WMEnterSizeMove message in VCL So either the system is not calling StartWindowResize() for some reason, or my override is incorrect, I'm not expecting to call this manually, if so what's the point in having the virtual stub for TComonCustomForm ?
-
Thanks. I have read the help, and you'll note that I said "csDesigning is not in the component state," in mypost. That is to say I did a break in TForm1.FormResize() when runing and the WatchList shows that "componentState = []" I'm assuming that is what the documentation is referring to ?