RSS

(root)/iphone/tappity : 61 : source/TappityClient.m

To get this branch, use:
bzr branch /browse/iphone/tappity

« back to all changes in this revision

Viewing changes to source/TappityClient.m

Dömötör Gulyás
2010-01-28 15:50:50
Revision ID: dognotdog@gmail.com-20100128145050-mogyehpg1eif15uq
fixes bug in server side data reception; feedback images are no reduced to a fixed size to improve network load;variably sized GL framebuffers now supported; adds 'placed screenshot' in addition to raw screenshot message, for non full screen GL; no longer sends suspend/quit events to the server when client is quit, which caused the server to quit, too, even though that was most likely not intended

Show diffs side-by-side

added added

removed removed

115
115
- (void) recordApplicationEvent: (NSDictionary*) event
116
116
{
117
117
//      NSLog(@"%@", event);
 
118
        
 
119
        long type = [[event objectForKey: @"Type"] integerValue];
 
120
        if ((type == 2005) || (type == 2007)) // suspend and quit events
 
121
                return;
118
122
 
119
123
        NSData* data = [NSPropertyListSerialization dataFromPropertyList: event format: NSPropertyListBinaryFormat_v1_0 errorDescription: nil];
120
124
        assert(data);
307
311
 
308
312
                        break;
309
313
                }
 
314
                case kTapPlacedScreenshot:
 
315
                {
 
316
                        NSDictionary* dict = [NSPropertyListSerialization propertyListFromData: data mutabilityOption: NSPropertyListImmutable format: nil errorDescription: nil];
 
317
                        
 
318
                        UIImage* img = [UIImage imageWithData: [dict objectForKey: TapImageDataKey]];
 
319
                //      NSLog(@"got image %@", img);
 
320
 
 
321
                        if(delegate)
 
322
                                [delegate setImage: img];
 
323
 
 
324
                        break;
 
325
                }
310
326
                case kTapStartUpdatingHeading:
311
327
                        [self performSelectorOnMainThread: @selector(startUpdatingHeading) withObject: nil waitUntilDone: NO];
312
328
                        break;

Loggerhead 1.17 is a web-based interface for Bazaar branches