Search found 164 matches

by livecodeali
Tue Aug 14, 2018 8:52 am
Forum: LiveCode Builder
Topic: Default Script
Replies: 9
Views: 257

Re: Default Script

No, it should happen automatically. However, I'm wondering if there may be a docs issue here - we changed default scripts so that the handlers specified show up in the left hand side, rather than the script actually being automatically filled in - does your default script consist of (a) handler(s) a...
by livecodeali
Mon Aug 13, 2018 10:25 pm
Forum: LiveCode Builder
Topic: Default Script
Replies: 9
Views: 257

Re: Default Script

support should be lowercase, although possibly that isn't the issue if you're on an os with a case insensitive file system. Your default script stack needs to be named "your.widget.identifier.__DefaultScript", eg: script "com.livecode.widget.navbar.__DefaultScript" Other than that, the only reason I...
by livecodeali
Mon Aug 13, 2018 9:33 am
Forum: LiveCode Builder
Topic: One extension with multiple native library implementations
Replies: 4
Views: 153

Re: One extension with multiple native library implementations

Yes, the cross platform button example is how we would recommend structuring such an extension: https://github.com/livecode/livecode/pull/6266 However it does potentially over-complicate things it if the extension is very simple, and you can do as Trevor suggests (in fact the first LiveCode widget t...
by livecodeali
Mon Aug 13, 2018 9:29 am
Forum: LiveCode Builder
Topic: Canvas
Replies: 7
Views: 272

Re: Canvas

Hi Max, I added an overview of the canvas API with examples in the Extending LiveCode document in the 9.0 GM release: https://github.com/livecode/livecode-ide/blob/develop/Documentation/guides/Extending%20LiveCode.md#canvas-api Please give that a read and let me know what we can do to improve it. Th...
by livecodeali
Sun May 20, 2018 9:45 pm
Forum: Android Deployment
Topic: Min Android API vs target Android API in Google Play
Replies: 5
Views: 554

Re: Min Android API vs target Android API in Google Play

Yes, you could change the template manifest - it's at LiveCode Community 9.0.0.app/Contents/Tools/Runtime/Android/Manifest.xml for example on Mac
by livecodeali
Fri May 11, 2018 3:12 pm
Forum: LiveCode Builder
Topic: Testing if a LCB Library or Widget is installed from LCS
Replies: 3
Views: 391

Re: Testing if a LCB Library or Widget is installed from LCS

In the IDE you can do revIDEExtensions() to get an array with all the metdata. You can cut that down with parameters, eg revIDEExtensions("library") or revIDEExtensions("widget", "installed"). For individual extension properties, use revIDEExtensionProperty(<kind>, <propName>) where propName is vari...
by livecodeali
Fri Apr 27, 2018 10:41 pm
Forum: Getting Started with LiveCode - Experienced Developers
Topic: Rotating a text field
Replies: 5
Views: 655

Re: Rotating a text field

The extensions course contains code for a rotated text widget here (click the downloads icon on the right)
by livecodeali
Fri Apr 27, 2018 10:39 pm
Forum: LiveCode Builder
Topic: FFI Help wrapping ObjC
Replies: 16
Views: 1232

Re: FFI Help wrapping ObjC

Hmm, that suggests something is being over-released, which means it is likely being marked as retained when it shouldn't be... I'm sure it will be something simple!
by livecodeali
Fri Apr 27, 2018 1:11 pm
Forum: LiveCode Builder
Topic: Where to put android library files
Replies: 4
Views: 475

Re: Where to put android library files

Your code and everything looks correct, with the exception of __safe foreign handler JNI_SayHello() returns JString binds to "java:com.example.uhfreader816ubt.HelloAndroid>sayHelloAndroid()Ljava/lang/String;" As the sayHelloAndroid method is static, your binding string should be java:com.example.uhf...
by livecodeali
Fri Apr 27, 2018 1:09 pm
Forum: LiveCode Builder
Topic: FFI Help wrapping ObjC
Replies: 16
Views: 1232

Re: FFI Help wrapping ObjC

Ah! Sorry I totally missed a bunch of things. ObjRetainedId should be used only in the places where the call will increase the ref count- in this case the alloc call. Also you should use ObjcObject everywhere except in the actual foreign handler declarations. So: private variable mAVMIDIPlayerInstan...
by livecodeali
Sat Apr 21, 2018 10:02 pm
Forum: LiveCode Builder
Topic: FFI Help wrapping ObjC
Replies: 16
Views: 1232

Re: FFI Help wrapping ObjC

Yes, "objc:NSURL.+URLWithString:" is a good example of one that doesn't require a call to alloc. I did caveat my statement with both 'I think' and 'the majority' (i.e. > 50%) :wink: it's just a sense I get from my use of it and is by no means a statement of fact! I can't remember if I've posted else...
by livecodeali
Tue Apr 17, 2018 11:11 pm
Forum: LiveCode Builder
Topic: Where to put android library files
Replies: 4
Views: 475

Re: Where to put android library files

At the moment, LCB extensions can only interface with compiled java classes through foreign handler bindings. So, you will need to compile all the source files into a .jar file (or download a .jar file provided by the vendor) and put it in a folder code/jvm-android next to the lcb file. Then, you wi...
by livecodeali
Tue Apr 17, 2018 5:59 pm
Forum: LiveCode Builder
Topic: FFI Help wrapping ObjC
Replies: 16
Views: 1232

Re: FFI Help wrapping ObjC

You need to alloc an instance of AVMIDIPlayer and call initWithContentsOfURL on the instance returned from alloc. initWithContentsOfURL is an instance method (- rather than + in objective-c terminology) so it needs to be called on an instance of the class, which should be the first parameter. (I thi...
by livecodeali
Mon Apr 09, 2018 9:24 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: answer "<anything>1234</anything>" is just 1234 ?
Replies: 6
Views: 301

Re: answer "<anything>1234</anything>" is just 1234 ?

The field displayed in the answer dialog uses html text (so you can do answer "<b>This is bold!</b>" And get bold text in the answer dialog. Your tags are being interpreted as html. If you want to use the answer dialog, perhaps use the following instead: command log pValue answer escape(pValue) end ...
by livecodeali
Fri Apr 06, 2018 8:12 am
Forum: Android Deployment
Topic: Foreign Function Interface (FFI) Documentation for Java
Replies: 4
Views: 397

Re: Foreign Function Interface (FFI) Documentation for Java

There's a section in the Extending LiveCode guide now with more detail, in the IDE dictionary guides tab, and also at: https://github.com/livecode/livecode-ide/blob/develop/Documentation/guides/Extending%20LiveCode.md#java Also potentially worth looking at are the java stdlib tests: https://github.c...

Go to advanced search