Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


TurboMagic last won the day on March 18

TurboMagic had the most liked content!

Community Reputation

43 Excellent

Recent Profile Visitors

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

  1. TurboMagic

    Sharing a file

    Hello, I've got trouble sharing a file which is local to my app now. Code previously worked before migrating to 10.4.1 and moving the file to the app local directory to make it Android 10+ compatible. Before showing the code I'd like to know if the following path I see in the Android logcat log is correct or who it would need to look like: 04-07 12:10:09.190: I/ActivityTaskManager(1352): START u0 {act=android.intent.action.SEND dat=content://com.mycompany.MyApp.fileprovider/root/data/data/com.mycompany.MyApp/files/1.dat typ=*/* flg=0x1 cmp=android/com.android.internal.app.ResolverActivity} from uid 10269 I have the suspicion that this one is a concatenation of two things and thus wrong: content://com.mycompany.MyApp.fileprovider/root/data/data/com.mycompany.MyApp/files/1.dat When trying to share it with GMail I do get an empty mail composer screen, but no attachment. Cheers TurboMagic
  2. TurboMagic

    New/old component re-released: TComPortDrv

    Small update: it is available via GetIt now for users of 10.4.1 and 10.4.2. Enjoy!
  3. TurboMagic

    New/old component re-released: TComPortDrv

    Thanks for notifying me. Fixed now, so you can enjoy it now 😉
  4. Hello, this is the announcement that I just re-released a classic Delphi component called TComPortDrv. The new release is in agreement of the original author and the license was changed to Apache 2.0 by this. What is this non-visual VCL component about? It is an encapsulation of the Windows RS232 API so you can send and receive data via real and virtual COM-ports. The new version works from 10.4.1 Sydney onwards (due to the use of $(Auto) for the LibSuffix setting of the packages. You should get it compile on older versions though as well. Where can I get it from? https://github.com/MHumm/ComPortDriver/releases/tag/V3.0 What got changed in this V3.0 * made compilable with Unicode Delphi * fixed a severe bug in the data receive event which would overflow the internal buffer when using this component with a high baudrate (over 230400) * changed all external comments to XMLDOC * added a method to get a list of available COM-ports (only as COM3, COM4 etc. as of now) * added SetCommBreak and ClearCommBreak methods * made DelayForRX function a method now and based its calculation on the current serial settings * changed the component Icon Enjoy TurboMagic
  5. TurboMagic

    DEC 6.x issue

    Somebody else found that out meanwhile as well and Development branch contains fixes for most known issues already. And yes I agreed: we shouldn't try to support every old Delphi version. I had rised this to D2009 with V6.0. I am not sure what the minimum version was before I took over. Maybe D5. I will raise it further in the future.
  6. TurboMagic

    DEC 6.x issue

    The compilation incompatibility issue was fixed with a new release 6.1.1 now: https://github.com/MHumm/DelphiEncryptionCompendium/releases/tag/V6.1.1 So users of older compilers may enjoy this library as well, but I'd still suggest to them to upgrade their Delphi version where possible to enjoy the benefits of newer Delphi versions... 😉
  7. TurboMagic

    DEC 6.x issue

    Somebody found out, that DEC only compiled in XE7 or newer due to the use of new array syntax. Development branch contains a version now which should be fixed. I have no old Delphi installed, so this is not testest yet.
  8. TurboMagic

    DEC 6.1 released

    Hello, there is a new release 6.1 of DEC available . It is located here: https://github.com/MHumm/DelphiEncryptionCompendium/releases/tag/V6.1 WHat's new since V6.0? * x64 compilation works out of the box now, some unit had not been properly listed for x64 * fixed the following cipher algorithms which were broken on x64: Blowfish, RC6 and Q128 * the Sapphire cipher did work with the unit test vectors but failed for some others * added SHA2-224 hash algorithm * added HMAC and pbkdf2 algorithms * somebody provided a build batch file * there is a command line application included now for setting the IDE's library path * progress even got changed and a VCL demo for that one was added * version history is a separate document in docs folder now Cheers TurboMagic
  9. TurboMagic

    Bugs in DEC library II

    Hello, this is the report of yes another bug a user has found (interestingly the unit tests for the cipher run flawlessly): Sapphire cipher didn't work properly for some data at least. The user thankfully did some investigation and I checked in his proposed fixes in the development branch. Note that the documentation got a small change: version history is a separate document now. So have fun using it TurboMagic
  10. TurboMagic

    XLS 2 XLSX

    He didn't state what those files contain in terms of formatting or charts etc. Maybe the xls only contains values?
  11. TurboMagic

    Bugs in DEC library

    Sorry, but I have to report a few bugs/regressions which have crept into DEC: These led for the following cipher algorithms failing their unit tests on x64: Blowfish RC6 Q128 In addition there was a bug which prevented compilation on x64 completely. Good news is: these are all fixed and available in development branch on GitHub (see above link). Have a nice evening TurboMagic
  12. In photo editors you usually have a histogram function which gives a distribution of the brightnes levels as a curve. With that you could find out whether more of the image is dark or bright. Most such photo editors can calculate this really quicky. So histogram might be a keyword to look for.
  13. Today I fixed a few bugs regarding use for storing objects in the buffer in the Remove and Delete methods and I fixed all memory leaks in the unit tests. The GitHub repository is up to date. Does anybody spot any bugs I have missed? Or is the source now "ok" so that the public should be "safe" when using it?
  14. TurboMagic

    Android 11 Emulator image

    Hello, I do not have an Android 11 capable Android device yet but need to test some things on Android 11 (scoped storage). Now I had the idea to test in an emulator, even if that's quite slow. I started SDK manager to install an emulator image and set one up, but cannot find anything related to Android 11 there. SDK manager is version 25.2.5 and displays the list shown in the attachment. Android 11 is SDK level 30, but nowhere to be seen. How to get this?
  15. TurboMagic

    Android JInputStream wrapper?

    Hello, since Android 10 we've got this nasty problem of no longer having direct file access to such folders like TPath.GetSharedDownloadsDir. Now I have managed via some intent call to either ACTION_OPEN_DOCUMENT or ACTION_GET_CONTENT to display some file chooser and when the user selects one I get the Uri of the selected file. With that I can get at an JInputStream and could read out the individual bytes of that stream. But: how to get at the file size properly to know when to stop reading? The Available method should, as per Android's documentation https://developer.android.com/reference/java/io/InputStream#available() rather not be used. Is there any "wraper" available which properly/nicely wrapt this in a TFileStream or something similar? A quick search didn't turn up anything yet. TurboMagic