I have just started experimenting with B4i and the first function I have tried to implement is the ability for the user to select multiple photos from various sources. I couldn't find anything that met my requirements within the B4X forums so went Googling. I came across QBImagePicker https://github.com/questbeat/QBImagePicker. I have generated QBImagePicker.framework and it works well with a small test harness written in Objective C with Xcode. However, I am having problems with getting it working with B4i. In fact I have failed at the very first step.
Using a wrapper no more complicated than:
i.e. The wrapper doesn't yet expose any functionality of QBImagePicker, but just adds the dependsOn.
Running a B4i app that includes the test library, the app compiles without error, starts executing the app on the simulator, the simulator loads up a white screen which then closes immediately. B4i meanwhile is "Trying to connect to the simulator" which eventually times-out.
Removing the DependsOn line and everything works as expected, i.e. the app starts running on the simulator and 'load' is written to the log.
It is as if when the simulator tries to load QBImagePicker.framework, it hates what it sees and gives up immediately without any error message. I don't see any error message in the B4i log or the simulator's log.
Using lipo I have confirmed that QBImagePicker.framework and libtest.a use the x86_64 architecture.
Can anyone provide some points? Thanks.
Using a wrapper no more complicated than:
B4X:
test.h
#import <Foundation/Foundation.h>
//~shortname:test
//~version:1.00
//~dependsOn:QBImagePicker.framework.3
@interface test : NSObject
- (void) load;
@end
B4X:
test.m
#import "test.h"
@implementation test
- (void) load
{
NSLog(@"load");
};
@end
i.e. The wrapper doesn't yet expose any functionality of QBImagePicker, but just adds the dependsOn.
Running a B4i app that includes the test library, the app compiles without error, starts executing the app on the simulator, the simulator loads up a white screen which then closes immediately. B4i meanwhile is "Trying to connect to the simulator" which eventually times-out.
Removing the DependsOn line and everything works as expected, i.e. the app starts running on the simulator and 'load' is written to the log.
It is as if when the simulator tries to load QBImagePicker.framework, it hates what it sees and gives up immediately without any error message. I don't see any error message in the B4i log or the simulator's log.
Using lipo I have confirmed that QBImagePicker.framework and libtest.a use the x86_64 architecture.
Can anyone provide some points? Thanks.
Last edited: