Skip to content
Snippets Groups Projects
Commit dbc72029 authored by George Nachman's avatar George Nachman
Browse files

Adhoc build 3.1.20171129_215341

parent be6ca896
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -7,6 +7,7 @@
//
 
#import "iTermQuickLookController.h"
#import "DebugLogging.h"
#import "QLPreviewPanel+iTerm.h"
 
@interface iTermQuickLookController() <QLPreviewPanelDataSource, QLPreviewPanelDelegate>
Loading
Loading
@@ -22,12 +23,14 @@
@implementation iTermQuickLookController
 
+ (void)dismissSharedPanel {
DLog(@"dismiss from %@", [NSThread callStackSymbols]);
if ([[QLPreviewPanel sharedPreviewPanelIfExists] isVisible]) {
[[QLPreviewPanel sharedPreviewPanel] orderOut:nil];
}
}
 
- (void)dealloc {
DLog(@"dealloc from %@", [NSThread callStackSymbols]);
[_files release];
[super dealloc];
}
Loading
Loading
@@ -40,6 +43,7 @@
}
 
- (void)showWithSourceRect:(NSRect)sourceRect controller:(id)controller {
DLog(@"show from %@", [NSThread callStackSymbols]);
self.sourceRect = sourceRect;
QLPreviewPanel *panel = [QLPreviewPanel sharedPreviewPanel];
if (panel.currentController == controller) {
Loading
Loading
@@ -60,6 +64,7 @@
}
 
- (void)close {
DLog(@"close from %@", [NSThread callStackSymbols]);
QLPreviewPanel *panel = [QLPreviewPanel sharedPreviewPanelIfExists];
if ([panel isVisible] &&
[panel delegate] == self) {
Loading
Loading
@@ -68,6 +73,7 @@
}
 
- (void)takeControl {
DLog(@"takeControl from %@", [NSThread callStackSymbols]);
QLPreviewPanel *panel = [QLPreviewPanel sharedPreviewPanel];
if (panel.delegate != self || panel.dataSource != self) {
panel.delegate = self;
Loading
Loading
@@ -90,6 +96,7 @@
#pragma mark - QLPreviewPanelDelegate
 
- (BOOL)previewPanel:(QLPreviewPanel *)panel handleEvent:(NSEvent *)event {
DLog(@"handle event %@ from %@", event, [NSThread callStackSymbols]);
if ([event type] == NSKeyDown &&
event.charactersIgnoringModifiers.length == 1 &&
[event.charactersIgnoringModifiers characterAtIndex:0] == 27) {
Loading
Loading
@@ -115,12 +122,14 @@
}
 
- (void)beginPreviewPanelControl:(QLPreviewPanel *)panel {
DLog(@"begin preview panel control from %@", [NSThread callStackSymbols]);
panel.delegate = self;
panel.dataSource = self;
[panel reloadData];
}
 
- (void)endPreviewPanelControl:(QLPreviewPanel *)panel {
DLog(@"end preview panel control from %@", [NSThread callStackSymbols]);
}
 
@end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment