Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| SHA1 Hash: | 9906e9c622b5099a89649dfbbab24367a74da5da |
|---|---|
| Date: | 2009-10-30 23:45:17 |
| User: | dmitry |
| Comment: | Remove some comments |
Tags And Properties
- branch=trunk inherited from [813a778bdc]
- sym-trunk inherited from [813a778bdc]
Changes
Changes to GenerateThumbnailForURL.m
| Old (940295dfbb3e7fc3) | New (37fe85a052998a0c) | |||
|---|---|---|---|---|
| 1 | #import <QuickLook/QuickLook.h> | 1 | #import <QuickLook/QuickLook.h> | |
| 2 | #import <Foundation/Foundation.h> | 2 | #import <Foundation/Foundation.h> | |
| 3 | #import <WebKit/WebKit.h> | 3 | #import <WebKit/WebKit.h> | |
| 4 | #import <AppKit/AppKit.h> | 4 | #import <AppKit/AppKit.h> | |
| 5 | #import "TimelineGenerator.h" | 5 | #import "TimelineGenerator.h" | |
| 10 hidden lines | ||||
| 16 | CFDictionaryRef options, CGSize maxSize) | 16 | CFDictionaryRef options, CGSize maxSize) | |
| 17 | { | 17 | { | |
| 18 | NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; | 18 | NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; | |
| 19 | 19 | |||
| 20 | 20 | |||
| 21 | // Use webkit render | < | ||
| 22 | < | |||
| 23 | NSMutableString *html = HTMLTimelineForDatabase( | 21 | NSMutableString *html = HTMLTimelineForDatabase( | |
| 24 | [[(NSURL*)url path] fileSystemRepresentation], | 22 | [[(NSURL*)url path] fileSystemRepresentation], | |
| 25 | 12); | 23 | 12); | |
| 26 | [html appendString:@"<div style='font-size: 120px; position: absolute; " | 24 | [html appendString:@"<div style='font-size: 120px; position: absolute; " | |
| 27 | " bottom: 0; background: white; width: 100%; color: #555;" | 25 | " bottom: 0; background: white; width: 100%; color: #555;" | |
| 17 hidden lines | ||||
| 45 | 43 | |||
| 46 | while([webView isLoading]) { | 44 | while([webView isLoading]) { | |
| 47 | CFRunLoopRunInMode(kCFRunLoopDefaultMode, 0, true); | 45 | CFRunLoopRunInMode(kCFRunLoopDefaultMode, 0, true); | |
| 48 | } | 46 | } | |
| 49 | 47 | |||
| 50 | // Get a context to render into | < | ||
| 51 | CGContextRef cgContext = | 48 | CGContextRef cgContext = | |
| 52 | QLThumbnailRequestCreateContext(thumbnail, thumbSize, false, NULL); | 49 | QLThumbnailRequestCreateContext(thumbnail, thumbSize, false, NULL); | |
| 53 | NSGraphicsContext* context = | 50 | NSGraphicsContext* context = | |
| 54 | [NSGraphicsContext graphicsContextWithGraphicsPort:(void *)cgContext | 51 | [NSGraphicsContext graphicsContextWithGraphicsPort:(void *)cgContext | |
| 55 | flipped:[webView isFlipped]]; | 52 | flipped:[webView isFlipped]]; | |
| 23 hidden lines | ||||
| 79 | 76 | |||
| 80 | void CancelThumbnailGeneration(void* thisInterface, QLThumbnailRequestRef thumbnail) | 77 | void CancelThumbnailGeneration(void* thisInterface, QLThumbnailRequestRef thumbnail) | |
| 81 | { | 78 | { | |
| 82 | // implement only if supported | 79 | // implement only if supported | |
| 83 | } | 80 | } | |