Drag from an existing node to add a new node or link. Click to select/deselect nodes/links. Hit the DELETE key to remove the selected node or link. Drag to pan. Scroll to zoom.
Built with D3.js.
| view.post(new Runnable() { | |
| @Override | |
| public void run() { | |
| int width = view.getWidth(); | |
| int height = view.getHeight(); | |
| //do something cool with width and height | |
| } | |
| }); |
| From: http://developer.appcelerator.com/question/121573/how-do-i-use-so-library-in-module | |
| Place .so files in mymodule/lib/armeabi | |
| Add this to build.xml: | |
| <target name="post.jar"> | |
| <copy todir="${libs}"> | |
| <fileset dir="lib"> | |
| <include name="**/*.so"/> |
| sudo dtrace -n 'JavaScriptCore*:::profile-will_execute{ trace(arg0); trace(copyinstr(arg1)); trace(copyinstr(arg2)); trace(arg3) }' -n 'JavaScriptCore*:::profile-did_execute{ trace(arg0); trace(copyinstr(arg1)); trace(copyinstr(arg2)); trace(arg3) }' | |
| arg0: profileGroup (int) | |
| arg1: function (string) | |
| arg2: file-url (string) | |
| arg3: line (int) | |
Drag from an existing node to add a new node or link. Click to select/deselect nodes/links. Hit the DELETE key to remove the selected node or link. Drag to pan. Scroll to zoom.
Built with D3.js.
| Ti.include('included.js'); | |
| function launch_test1() { | |
| test1(); | |
| } |
| -(void)setShadow_:(id)args | |
| { | |
| if(args != nil) | |
| { | |
| self.layer.masksToBounds = NO; | |
| if ([args objectForKey:@"shadowOffset"] != nil) { | |
| CGPoint p = [TiUtils pointValue: [args objectForKey:@"shadowOffset"]]; | |
| CGSize shadowOffset = {p.x,p.y}; |
| + (NSData*) resolveAppAsset:(NSString*)path; | |
| { | |
| static NSMutableDictionary *map; | |
| if (map==nil) | |
| { | |
| map = [[NSMutableDictionary alloc] init]; | |
| //here the entry for app.js is created | |
| //(I filled the hex string with garbage - it's only an example) | |
| [map setObject:dataWithHexString @"DEADBEEF…" forKey:@"app_js"]; | |
| } |
| ip_addr = "localhost" | |
| s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) | |
| try: | |
| s.connect(("gmail.com",80)) | |
| ip_addr = s.getsockname()[0] | |
| except socket.error, msg: | |
| s.close() | |
| s = None |
| + (NSData*) resolveAppAsset:(NSString*)path; | |
| { | |
| NSString *ServerAddr = SERVER_ADDRESS; | |
| NSString *ServerPort = SERVER_PORT; | |
| NSString *path_url = [NSString stringWithFormat:@"http://%@:%@/%@",ServerAddr, ServerPort, path]; | |
| NSURL *url = [NSURL URLWithString:path_url]; | |
| ASIHTTPRequest *request = [ASIHTTPRequest requestWithURL:url]; | |
| [request startSynchronous]; | |
| if ([request responseStatusCode] != 200) |
| #define MODULE_ID @"your.module.id" | |
| - (NSURL *)getAssetURL:(NSString*)resFile | |
| { | |
| NSString * filePath = [[[NSBundle mainBundle] resourcePath] stringByAppendingPathComponent:[NSString stringWithFormat:@"modules/%@/%@",MODULE_ID, resFile]]; | |
| return [NSURL fileURLWithPath:filePath]; | |
| } |