masakih

PreviewerSelector (プロジェクト終了)

  • R/O
  • HTTP
  • SSH
  • HTTPS

コミット

よく使われているワード(クリックで追加)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

「プロジェクト終了」 BathyScapheのプレビューアプラグインを複数使用出来るようにするプラグイン


コミットメタ情報

リビジョン11e1eb66a883a2dd341ec6eed1a8455b2793cd4c (tree)
日時2012-07-15 23:21:29
作者masakih <masakih@user...>
コミッターmasakih

ログメッセージ

[Mod] 切り出しやすいように設定用ViewControllerを分離

変更サマリ

差分

--- a/PSPreference.h
+++ b/PSPreference.h
@@ -2,12 +2,10 @@
22
33 #import <Cocoa/Cocoa.h>
44
5+@class PreviewerSelectorPreferenceViewController;
56 @interface PSPreference : NSWindowController
67 {
7- IBOutlet NSTableView *pluginsView;
8- IBOutlet NSArrayController *itemsController;
9-
10- NSMutableArray *plugInList;
8+ PreviewerSelectorPreferenceViewController *viewController;
119 }
1210
1311 + (id)sharedPreference;
--- a/PSPreference.m
+++ b/PSPreference.m
@@ -1,14 +1,9 @@
11 #import "PSPreference.h"
22
3-#import "PreviewerSelector.h"
4-#import "PSPreviewerItem.h"
5-
3+#import "PreviewerSelectorPreferenceViewController.h"
64
75 @implementation PSPreference
86
9-static NSString *const PSPItemPastboardType = @"PSPItemPastboardType";
10-static NSString *const PSPRowIndexType = @"PSPRowIndexType";
11-
127 static PSPreference *sSharedInstance = nil;
138
149 + (PSPreference*)sharedPreference
@@ -51,45 +46,17 @@ static PSPreference *sSharedInstance = nil;
5146 - (void)awakeFromNib
5247 {
5348 [self setWindowFrameAutosaveName:@"PreviewerSelectorPreferenceWindow"];
54-
55- [pluginsView setDoubleAction:@selector(toggleAPlugin:)];
56- [pluginsView setTarget:self];
57-
58- [pluginsView registerForDraggedTypes:[NSArray arrayWithObject:PSPItemPastboardType]];
59-
60- [itemsController addObserver:self forKeyPath:@"selection.tryCheck" options:0 context:itemsController];
61- [itemsController addObserver:self forKeyPath:@"selection.displayInMenu" options:0 context:itemsController];
62-}
63-- (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context
64-{
65- if(context == itemsController) {
66- [[PreviewerSelector sharedInstance] savePlugInsInfo];
67- return;
68- }
69-
70- [super observeValueForKeyPath:keyPath ofObject:object change:change context:context];
49+ viewController = [[PreviewerSelectorPreferenceViewController alloc] init];
50+ [[self window] setContentView:[viewController view]];
7151 }
7252
7353 - (void)setPlugInList:(id)list
7454 {
75- id temp = plugInList;
76- plugInList = [list retain];
77- [temp release];
55+ if(!viewController) [self loadWindow];
56+ [viewController setPlugInList:list];
7857 }
7958
80-- (IBAction)toggleAPlugin:(id)sender
81-{
82- int selectedRow = [pluginsView selectedRow];
83- if(selectedRow == -1) return;
84-
85- id info = [plugInList objectAtIndex:selectedRow];
86- id obj = [info previewer];
87- if(!obj) return;
88-
89- if([obj respondsToSelector:@selector(togglePreviewPanel:)]) {
90- [obj performSelector:@selector(togglePreviewPanel:) withObject:self];
91- }
92-}
59+
9360 - (IBAction)togglePreferencePanel: (id) sender
9461 {
9562 if([[self window] isVisible]) {
@@ -98,133 +65,4 @@ static PSPreference *sSharedInstance = nil;
9865 [self showWindow:self];
9966 }
10067 }
101-- (IBAction)openPreferences:(id)sender
102-{
103- int selectedRow = [pluginsView selectedRow];
104- if(selectedRow == -1) return;
105-
106- id info = [plugInList objectAtIndex:selectedRow];
107- id obj = [info previewer];
108- if(!obj) return;
109-
110- if([obj respondsToSelector:@selector(showPreviewerPreferences:)]) {
111- [obj performSelector:@selector(showPreviewerPreferences:) withObject:self];
112- }
113-}
114-
115-#pragma mark## NSMenu Delegate ##
116-enum _PreferenceMenuTags {
117- kOpenPreviewer = 10000,
118- kOpenPreferences = 10001,
119-};
120-- (BOOL)validateMenuItem:(NSMenuItem *)menuItem
121-{
122- int selectedRow = [pluginsView selectedRow];
123- if(selectedRow == -1) return NO;
124-
125- id info = [plugInList objectAtIndex:selectedRow];
126- id obj = [info previewer];
127- if(!obj) return NO;
128-
129- id displayName = [info displayName];
130-
131- switch([menuItem tag]) {
132- case kOpenPreviewer:
133- {
134- if(displayName) {
135- id title = [NSString stringWithFormat:PSLocalizedString(@"Open %@", @"Open Previewer."), displayName];
136- [menuItem setTitle:title];
137- }
138- if([obj respondsToSelector:@selector(togglePreviewPanel:)]) {
139- return YES;
140- }
141- break;
142- }
143- case kOpenPreferences:
144- if(displayName) {
145- id title = [NSString stringWithFormat:PSLocalizedString(@"Open %@'s Preferences", @"Open Previewer Preferences."), displayName];
146- [menuItem setTitle:title];
147- }
148- if([obj respondsToSelector:@selector(showPreviewerPreferences:)]) {
149- return YES;
150- }
151- break;
152- default:
153- //
154- break;
155- }
156-
157- return NO;
158-}
159-
160-
161-
162-- (BOOL)tableView:(NSTableView *)tableView writeRowsWithIndexes:(NSIndexSet *)rowIndexes toPasteboard:(NSPasteboard*)pboard
163-{
164- if([rowIndexes count] != 1) return NO;
165-
166- NSUInteger index = [rowIndexes firstIndex];
167-
168- [pboard declareTypes:[NSArray arrayWithObjects:PSPItemPastboardType, PSPRowIndexType, nil] owner:nil];
169- [pboard setData:[NSKeyedArchiver archivedDataWithRootObject:[plugInList objectAtIndex:index]]
170- forType:PSPItemPastboardType];
171- [pboard setPropertyList:[NSNumber numberWithUnsignedInteger:index] forType:PSPRowIndexType];
172-
173- return YES;
174-}
175-
176-- (NSDragOperation)tableView:(NSTableView*)targetTableView
177- validateDrop:(id <NSDraggingInfo>)info
178- proposedRow:(NSInteger)row
179- proposedDropOperation:(NSTableViewDropOperation)dropOperation
180-{
181- NSPasteboard *pboard = [info draggingPasteboard];
182- if(![[pboard types] containsObject:PSPItemPastboardType]) {
183- return NSDragOperationNone;
184- }
185-
186- if(dropOperation == NSTableViewDropOn) {
187- [targetTableView setDropRow:row dropOperation:NSTableViewDropAbove];
188- }
189-
190- NSUInteger originalRow = [[pboard propertyListForType:PSPRowIndexType] unsignedIntegerValue];
191- if(row == originalRow || row == originalRow + 1) {
192- return NSDragOperationNone;
193- }
194-
195- return NSDragOperationMove;
196-}
197-
198-- (BOOL)tableView:(NSTableView*)tableView
199- acceptDrop:(id <NSDraggingInfo>)info
200- row:(NSInteger)row
201- dropOperation:(NSTableViewDropOperation)dropOperation
202-{
203- NSPasteboard *pboard = [info draggingPasteboard];
204- if(![[pboard types] containsObject:PSPItemPastboardType]) {
205- return NO;
206- }
207-
208- if(row < 0) row = 0;
209-
210- NSUInteger originalRow = [[pboard propertyListForType:PSPRowIndexType] unsignedIntegerValue];
211-
212- NSData *itemData = [pboard dataForType:PSPItemPastboardType];
213- PSPreviewerItem *item = [NSKeyedUnarchiver unarchiveObjectWithData:itemData];
214- if(![item isKindOfClass:[PSPreviewerItem class]]) {
215- return NO;
216- }
217-
218- [self willChangeValueForKey:@"plugInList"];
219- [plugInList insertObject:item atIndex:row];
220- if(originalRow > row) originalRow++;
221- [plugInList removeObjectAtIndex:originalRow];
222- [self didChangeValueForKey:@"plugInList"];
223-
224- [[PreviewerSelector sharedInstance] savePlugInsInfo];
225-
226- return YES;
227-}
228-
229-
23068 @end
--- a/Preference.xib
+++ b/Preference.xib
@@ -11,19 +11,9 @@
1111 <string key="NS.object.0">2182</string>
1212 </object>
1313 <array key="IBDocument.IntegratedClassDependencies">
14- <string>NSScroller</string>
15- <string>NSArrayController</string>
16- <string>NSMenuItem</string>
17- <string>NSMenu</string>
18- <string>NSScrollView</string>
19- <string>NSTextFieldCell</string>
20- <string>NSButtonCell</string>
21- <string>NSTableHeaderView</string>
22- <string>NSTableView</string>
23- <string>NSCustomObject</string>
24- <string>NSView</string>
2514 <string>NSWindowTemplate</string>
26- <string>NSTableColumn</string>
15+ <string>NSView</string>
16+ <string>NSCustomObject</string>
2717 </array>
2818 <array key="IBDocument.PluginDependencies">
2919 <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
@@ -59,370 +49,20 @@
5949 <object class="NSView" key="NSWindowView" id="992425267">
6050 <reference key="NSNextResponder"/>
6151 <int key="NSvFlags">256</int>
62- <array class="NSMutableArray" key="NSSubviews">
63- <object class="NSScrollView" id="946994194">
64- <reference key="NSNextResponder" ref="992425267"/>
65- <int key="NSvFlags">274</int>
66- <array class="NSMutableArray" key="NSSubviews">
67- <object class="NSClipView" id="235293459">
68- <reference key="NSNextResponder" ref="946994194"/>
69- <int key="NSvFlags">2304</int>
70- <array class="NSMutableArray" key="NSSubviews">
71- <object class="NSTableView" id="391617440">
72- <reference key="NSNextResponder" ref="235293459"/>
73- <int key="NSvFlags">4352</int>
74- <string key="NSFrameSize">{360, 215}</string>
75- <reference key="NSSuperview" ref="235293459"/>
76- <reference key="NSWindow"/>
77- <reference key="NSNextKeyView" ref="661524026"/>
78- <bool key="NSEnabled">YES</bool>
79- <object class="NSTableHeaderView" key="NSHeaderView" id="38036422">
80- <reference key="NSNextResponder" ref="21771984"/>
81- <int key="NSvFlags">256</int>
82- <string key="NSFrameSize">{360, 17}</string>
83- <reference key="NSSuperview" ref="21771984"/>
84- <reference key="NSWindow"/>
85- <reference key="NSNextKeyView" ref="235293459"/>
86- <reference key="NSTableView" ref="391617440"/>
87- </object>
88- <object class="_NSCornerView" key="NSCornerView">
89- <nil key="NSNextResponder"/>
90- <int key="NSvFlags">256</int>
91- <string key="NSFrame">{{346, 0}, {16, 17}}</string>
92- </object>
93- <array class="NSMutableArray" key="NSTableColumns">
94- <object class="NSTableColumn" id="813928279">
95- <string key="NSIdentifier">isUse</string>
96- <double key="NSWidth">64</double>
97- <double key="NSMinWidth">10</double>
98- <double key="NSMaxWidth">1000</double>
99- <object class="NSTableHeaderCell" key="NSHeaderCell">
100- <int key="NSCellFlags">75628096</int>
101- <int key="NSCellFlags2">2048</int>
102- <string key="NSContents">Check Link</string>
103- <object class="NSFont" key="NSSupport" id="26">
104- <string key="NSName">LucidaGrande</string>
105- <double key="NSSize">11</double>
106- <int key="NSfFlags">3100</int>
107- </object>
108- <object class="NSColor" key="NSBackgroundColor" id="235277073">
109- <int key="NSColorSpace">3</int>
110- <bytes key="NSWhite">MC4zMzMzMzI5OQA</bytes>
111- </object>
112- <object class="NSColor" key="NSTextColor" id="244927324">
113- <int key="NSColorSpace">6</int>
114- <string key="NSCatalogName">System</string>
115- <string key="NSColorName">headerTextColor</string>
116- <object class="NSColor" key="NSColor" id="1057627452">
117- <int key="NSColorSpace">3</int>
118- <bytes key="NSWhite">MAA</bytes>
119- </object>
120- </object>
121- </object>
122- <object class="NSButtonCell" key="NSDataCell" id="933097612">
123- <int key="NSCellFlags">67239424</int>
124- <int key="NSCellFlags2">131072</int>
125- <string key="NSContents"/>
126- <object class="NSFont" key="NSSupport">
127- <string key="NSName">LucidaGrande</string>
128- <double key="NSSize">12</double>
129- <int key="NSfFlags">16</int>
130- </object>
131- <reference key="NSControlView" ref="391617440"/>
132- <int key="NSButtonFlags">1215582719</int>
133- <int key="NSButtonFlags2">2</int>
134- <object class="NSButtonImageSource" key="NSAlternateImage" id="507351284">
135- <string key="NSImageName">NSSwitch</string>
136- </object>
137- <string key="NSAlternateContents"/>
138- <string key="NSKeyEquivalent"/>
139- <int key="NSPeriodicDelay">400</int>
140- <int key="NSPeriodicInterval">75</int>
141- </object>
142- <int key="NSResizingMask">3</int>
143- <bool key="NSIsResizeable">YES</bool>
144- <bool key="NSIsEditable">YES</bool>
145- <reference key="NSTableView" ref="391617440"/>
146- </object>
147- <object class="NSTableColumn" id="983541935">
148- <string key="NSIdentifier">Plugin Name</string>
149- <double key="NSWidth">121</double>
150- <double key="NSMinWidth">85</double>
151- <double key="NSMaxWidth">100000</double>
152- <object class="NSTableHeaderCell" key="NSHeaderCell">
153- <int key="NSCellFlags">75628096</int>
154- <int key="NSCellFlags2">2048</int>
155- <string key="NSContents">Plugin Name</string>
156- <reference key="NSSupport" ref="26"/>
157- <reference key="NSBackgroundColor" ref="235277073"/>
158- <reference key="NSTextColor" ref="244927324"/>
159- </object>
160- <object class="NSTextFieldCell" key="NSDataCell" id="620336084">
161- <int key="NSCellFlags">337772096</int>
162- <int key="NSCellFlags2">2048</int>
163- <string key="NSContents">Text Cell</string>
164- <object class="NSFont" key="NSSupport" id="244523014">
165- <string key="NSName">LucidaGrande</string>
166- <double key="NSSize">13</double>
167- <int key="NSfFlags">1044</int>
168- </object>
169- <reference key="NSControlView" ref="391617440"/>
170- <object class="NSColor" key="NSBackgroundColor" id="713374760">
171- <int key="NSColorSpace">6</int>
172- <string key="NSCatalogName">System</string>
173- <string key="NSColorName">controlBackgroundColor</string>
174- <object class="NSColor" key="NSColor">
175- <int key="NSColorSpace">3</int>
176- <bytes key="NSWhite">MC42NjY2NjY2NjY3AA</bytes>
177- </object>
178- </object>
179- <object class="NSColor" key="NSTextColor" id="902115768">
180- <int key="NSColorSpace">6</int>
181- <string key="NSCatalogName">System</string>
182- <string key="NSColorName">controlTextColor</string>
183- <reference key="NSColor" ref="1057627452"/>
184- </object>
185- </object>
186- <int key="NSResizingMask">3</int>
187- <bool key="NSIsResizeable">YES</bool>
188- <reference key="NSTableView" ref="391617440"/>
189- </object>
190- <object class="NSTableColumn" id="593374330">
191- <double key="NSWidth">82</double>
192- <double key="NSMinWidth">10</double>
193- <double key="NSMaxWidth">1000</double>
194- <object class="NSTableHeaderCell" key="NSHeaderCell">
195- <int key="NSCellFlags">75628096</int>
196- <int key="NSCellFlags2">2048</int>
197- <string key="NSContents">Version</string>
198- <reference key="NSSupport" ref="26"/>
199- <object class="NSColor" key="NSBackgroundColor" id="342108981">
200- <int key="NSColorSpace">6</int>
201- <string key="NSCatalogName">System</string>
202- <string key="NSColorName">headerColor</string>
203- <object class="NSColor" key="NSColor" id="117147346">
204- <int key="NSColorSpace">3</int>
205- <bytes key="NSWhite">MQA</bytes>
206- </object>
207- </object>
208- <reference key="NSTextColor" ref="244927324"/>
209- </object>
210- <object class="NSTextFieldCell" key="NSDataCell" id="855612157">
211- <int key="NSCellFlags">337772096</int>
212- <int key="NSCellFlags2">2048</int>
213- <string key="NSContents">Text Cell</string>
214- <reference key="NSSupport" ref="244523014"/>
215- <reference key="NSControlView" ref="391617440"/>
216- <reference key="NSBackgroundColor" ref="713374760"/>
217- <reference key="NSTextColor" ref="902115768"/>
218- </object>
219- <int key="NSResizingMask">3</int>
220- <bool key="NSIsResizeable">YES</bool>
221- <reference key="NSTableView" ref="391617440"/>
222- </object>
223- <object class="NSTableColumn" id="1038076256">
224- <double key="NSWidth">65</double>
225- <double key="NSMinWidth">42.607421875</double>
226- <double key="NSMaxWidth">65</double>
227- <object class="NSTableHeaderCell" key="NSHeaderCell">
228- <int key="NSCellFlags">75628096</int>
229- <int key="NSCellFlags2">2048</int>
230- <string key="NSContents">Use Menu</string>
231- <reference key="NSSupport" ref="26"/>
232- <reference key="NSBackgroundColor" ref="342108981"/>
233- <reference key="NSTextColor" ref="244927324"/>
234- </object>
235- <object class="NSButtonCell" key="NSDataCell" id="146542405">
236- <int key="NSCellFlags">67239424</int>
237- <int key="NSCellFlags2">131072</int>
238- <string key="NSContents">Check</string>
239- <reference key="NSSupport" ref="26"/>
240- <reference key="NSControlView" ref="391617440"/>
241- <int key="NSButtonFlags">1215582719</int>
242- <int key="NSButtonFlags2">130</int>
243- <object class="NSCustomResource" key="NSNormalImage">
244- <string key="NSClassName">NSImage</string>
245- <string key="NSResourceName">NSSwitch</string>
246- </object>
247- <reference key="NSAlternateImage" ref="507351284"/>
248- <string key="NSAlternateContents"/>
249- <string key="NSKeyEquivalent"/>
250- <int key="NSPeriodicDelay">200</int>
251- <int key="NSPeriodicInterval">25</int>
252- </object>
253- <int key="NSResizingMask">3</int>
254- <bool key="NSIsResizeable">YES</bool>
255- <bool key="NSIsEditable">YES</bool>
256- <reference key="NSTableView" ref="391617440"/>
257- </object>
258- </array>
259- <double key="NSIntercellSpacingWidth">3</double>
260- <double key="NSIntercellSpacingHeight">2</double>
261- <reference key="NSBackgroundColor" ref="117147346"/>
262- <object class="NSColor" key="NSGridColor">
263- <int key="NSColorSpace">6</int>
264- <string key="NSCatalogName">System</string>
265- <string key="NSColorName">gridColor</string>
266- <object class="NSColor" key="NSColor">
267- <int key="NSColorSpace">3</int>
268- <bytes key="NSWhite">MC41AA</bytes>
269- </object>
270- </object>
271- <double key="NSRowHeight">17</double>
272- <int key="NSTvFlags">1386217472</int>
273- <reference key="NSDelegate"/>
274- <reference key="NSDataSource"/>
275- <int key="NSColumnAutoresizingStyle">4</int>
276- <int key="NSDraggingSourceMaskForLocal">15</int>
277- <int key="NSDraggingSourceMaskForNonLocal">0</int>
278- <bool key="NSAllowsTypeSelect">YES</bool>
279- <int key="NSTableViewDraggingDestinationStyle">0</int>
280- <int key="NSTableViewGroupRowStyle">1</int>
281- </object>
282- </array>
283- <string key="NSFrame">{{1, 17}, {360, 215}}</string>
284- <reference key="NSSuperview" ref="946994194"/>
285- <reference key="NSWindow"/>
286- <reference key="NSNextKeyView" ref="391617440"/>
287- <reference key="NSDocView" ref="391617440"/>
288- <reference key="NSBGColor" ref="713374760"/>
289- <int key="NScvFlags">4</int>
290- </object>
291- <object class="NSScroller" id="661524026">
292- <reference key="NSNextResponder" ref="946994194"/>
293- <int key="NSvFlags">256</int>
294- <string key="NSFrame">{{346, 17}, {15, 215}}</string>
295- <reference key="NSSuperview" ref="946994194"/>
296- <reference key="NSWindow"/>
297- <reference key="NSTarget" ref="946994194"/>
298- <string key="NSAction">_doScroller:</string>
299- <double key="NSPercent">0.95789474248886108</double>
300- </object>
301- <object class="NSScroller" id="228860257">
302- <reference key="NSNextResponder" ref="946994194"/>
303- <int key="NSvFlags">-2147483392</int>
304- <string key="NSFrame">{{-100, -100}, {303, 15}}</string>
305- <reference key="NSSuperview" ref="946994194"/>
306- <reference key="NSWindow"/>
307- <reference key="NSNextKeyView" ref="21771984"/>
308- <int key="NSsFlags">1</int>
309- <reference key="NSTarget" ref="946994194"/>
310- <string key="NSAction">_doScroller:</string>
311- <double key="NSPercent">0.95283019542694092</double>
312- </object>
313- <object class="NSClipView" id="21771984">
314- <reference key="NSNextResponder" ref="946994194"/>
315- <int key="NSvFlags">2304</int>
316- <array class="NSMutableArray" key="NSSubviews">
317- <reference ref="38036422"/>
318- </array>
319- <string key="NSFrame">{{1, 0}, {360, 17}}</string>
320- <reference key="NSSuperview" ref="946994194"/>
321- <reference key="NSWindow"/>
322- <reference key="NSNextKeyView" ref="38036422"/>
323- <reference key="NSDocView" ref="38036422"/>
324- <reference key="NSBGColor" ref="713374760"/>
325- <int key="NScvFlags">4</int>
326- </object>
327- </array>
328- <string key="NSFrame">{{-1, -1}, {362, 233}}</string>
329- <reference key="NSSuperview" ref="992425267"/>
330- <reference key="NSWindow"/>
331- <reference key="NSNextKeyView" ref="228860257"/>
332- <int key="NSsFlags">133138</int>
333- <reference key="NSVScroller" ref="661524026"/>
334- <reference key="NSHScroller" ref="228860257"/>
335- <reference key="NSContentView" ref="235293459"/>
336- <reference key="NSHeaderClipView" ref="21771984"/>
337- <bytes key="NSScrollAmts">QSAAAEEgAABBmAAAQZgAAA</bytes>
338- </object>
339- </array>
34052 <string key="NSFrameSize">{360, 231}</string>
34153 <reference key="NSSuperview"/>
34254 <reference key="NSWindow"/>
343- <reference key="NSNextKeyView" ref="946994194"/>
55+ <reference key="NSNextKeyView"/>
34456 </object>
345- <string key="NSScreenRect">{{0, 0}, {1440, 878}}</string>
57+ <string key="NSScreenRect">{{0, 0}, {1440, 900}}</string>
34658 <string key="NSMinSize">{213, 129}</string>
34759 <string key="NSMaxSize">{10000000000000, 10000000000000}</string>
34860 <bool key="NSWindowIsRestorable">YES</bool>
34961 </object>
350- <object class="NSArrayController" id="658059958">
351- <array class="NSMutableArray" key="NSDeclaredKeys">
352- <string>version</string>
353- <string>tryCheck</string>
354- <string>displayName</string>
355- <string>displayInMenu</string>
356- </array>
357- <string key="NSObjectClassName">PSPreviewerItem</string>
358- <bool key="NSEditable">YES</bool>
359- <object class="_NSManagedProxy" key="_NSManagedProxy"/>
360- <bool key="NSAvoidsEmptySelection">YES</bool>
361- <bool key="NSPreservesSelection">YES</bool>
362- <bool key="NSSelectsInsertedObjects">YES</bool>
363- <bool key="NSFilterRestrictsInsertion">YES</bool>
364- <bool key="NSClearsFilterPredicateOnInsertion">YES</bool>
365- </object>
366- <object class="NSMenu" id="266224590">
367- <string key="NSTitle">Menu</string>
368- <array class="NSMutableArray" key="NSMenuItems">
369- <object class="NSMenuItem" id="750991086">
370- <reference key="NSMenu" ref="266224590"/>
371- <string key="NSTitle">Open Previewer</string>
372- <string key="NSKeyEquiv"/>
373- <int key="NSKeyEquivModMask">1048576</int>
374- <int key="NSMnemonicLoc">2147483647</int>
375- <object class="NSCustomResource" key="NSOnImage" id="165798480">
376- <string key="NSClassName">NSImage</string>
377- <string key="NSResourceName">NSMenuCheckmark</string>
378- </object>
379- <object class="NSCustomResource" key="NSMixedImage" id="513356057">
380- <string key="NSClassName">NSImage</string>
381- <string key="NSResourceName">NSMenuMixedState</string>
382- </object>
383- <int key="NSTag">10000</int>
384- </object>
385- <object class="NSMenuItem" id="754953227">
386- <reference key="NSMenu" ref="266224590"/>
387- <string key="NSTitle">Open Preference</string>
388- <string key="NSKeyEquiv"/>
389- <int key="NSKeyEquivModMask">1048576</int>
390- <int key="NSMnemonicLoc">2147483647</int>
391- <reference key="NSOnImage" ref="165798480"/>
392- <reference key="NSMixedImage" ref="513356057"/>
393- <int key="NSTag">10001</int>
394- </object>
395- </array>
396- <string key="NSName"/>
397- </object>
39862 </array>
39963 <object class="IBObjectContainer" key="IBDocument.Objects">
40064 <array class="NSMutableArray" key="connectionRecords">
40165 <object class="IBConnectionRecord">
402- <object class="IBActionConnection" key="connection">
403- <string key="label">openPreferences:</string>
404- <reference key="source" ref="221401942"/>
405- <reference key="destination" ref="754953227"/>
406- </object>
407- <int key="connectionID">41</int>
408- </object>
409- <object class="IBConnectionRecord">
410- <object class="IBActionConnection" key="connection">
411- <string key="label">toggleAPlugin:</string>
412- <reference key="source" ref="221401942"/>
413- <reference key="destination" ref="750991086"/>
414- </object>
415- <int key="connectionID">39</int>
416- </object>
417- <object class="IBConnectionRecord">
418- <object class="IBOutletConnection" key="connection">
419- <string key="label">itemsController</string>
420- <reference key="source" ref="221401942"/>
421- <reference key="destination" ref="658059958"/>
422- </object>
423- <int key="connectionID">73</int>
424- </object>
425- <object class="IBConnectionRecord">
42666 <object class="IBOutletConnection" key="connection">
42767 <string key="label">window</string>
42868 <reference key="source" ref="221401942"/>
@@ -432,132 +72,12 @@
43272 </object>
43373 <object class="IBConnectionRecord">
43474 <object class="IBOutletConnection" key="connection">
435- <string key="label">pluginsView</string>
436- <reference key="source" ref="221401942"/>
437- <reference key="destination" ref="391617440"/>
438- </object>
439- <int key="connectionID">27</int>
440- </object>
441- <object class="IBConnectionRecord">
442- <object class="IBOutletConnection" key="connection">
44375 <string key="label">delegate</string>
44476 <reference key="source" ref="945346263"/>
44577 <reference key="destination" ref="221401942"/>
44678 </object>
44779 <int key="connectionID">15</int>
44880 </object>
449- <object class="IBConnectionRecord">
450- <object class="IBOutletConnection" key="connection">
451- <string key="label">menu</string>
452- <reference key="source" ref="391617440"/>
453- <reference key="destination" ref="266224590"/>
454- </object>
455- <int key="connectionID">38</int>
456- </object>
457- <object class="IBConnectionRecord">
458- <object class="IBOutletConnection" key="connection">
459- <string key="label">dataSource</string>
460- <reference key="source" ref="391617440"/>
461- <reference key="destination" ref="221401942"/>
462- </object>
463- <int key="connectionID">54</int>
464- </object>
465- <object class="IBConnectionRecord">
466- <object class="IBBindingConnection" key="connection">
467- <string key="label">value: arrangedObjects.displayName</string>
468- <reference key="source" ref="983541935"/>
469- <reference key="destination" ref="658059958"/>
470- <object class="NSNibBindingConnector" key="connector">
471- <reference key="NSSource" ref="983541935"/>
472- <reference key="NSDestination" ref="658059958"/>
473- <string key="NSLabel">value: arrangedObjects.displayName</string>
474- <string key="NSBinding">value</string>
475- <string key="NSKeyPath">arrangedObjects.displayName</string>
476- <dictionary key="NSOptions">
477- <boolean value="YES" key="NSConditionallySetsEditable"/>
478- <boolean value="NO" key="NSCreatesSortDescriptor"/>
479- </dictionary>
480- <int key="NSNibBindingConnectorVersion">2</int>
481- </object>
482- </object>
483- <int key="connectionID">64</int>
484- </object>
485- <object class="IBConnectionRecord">
486- <object class="IBBindingConnection" key="connection">
487- <string key="label">value: arrangedObjects.tryCheck</string>
488- <reference key="source" ref="813928279"/>
489- <reference key="destination" ref="658059958"/>
490- <object class="NSNibBindingConnector" key="connector">
491- <reference key="NSSource" ref="813928279"/>
492- <reference key="NSDestination" ref="658059958"/>
493- <string key="NSLabel">value: arrangedObjects.tryCheck</string>
494- <string key="NSBinding">value</string>
495- <string key="NSKeyPath">arrangedObjects.tryCheck</string>
496- <object class="NSDictionary" key="NSOptions">
497- <string key="NS.key.0">NSCreatesSortDescriptor</string>
498- <boolean value="NO" key="NS.object.0"/>
499- </object>
500- <int key="NSNibBindingConnectorVersion">2</int>
501- </object>
502- </object>
503- <int key="connectionID">63</int>
504- </object>
505- <object class="IBConnectionRecord">
506- <object class="IBBindingConnection" key="connection">
507- <string key="label">contentArray: plugInList</string>
508- <reference key="source" ref="658059958"/>
509- <reference key="destination" ref="221401942"/>
510- <object class="NSNibBindingConnector" key="connector">
511- <reference key="NSSource" ref="658059958"/>
512- <reference key="NSDestination" ref="221401942"/>
513- <string key="NSLabel">contentArray: plugInList</string>
514- <string key="NSBinding">contentArray</string>
515- <string key="NSKeyPath">plugInList</string>
516- <int key="NSNibBindingConnectorVersion">2</int>
517- </object>
518- </object>
519- <int key="connectionID">18</int>
520- </object>
521- <object class="IBConnectionRecord">
522- <object class="IBBindingConnection" key="connection">
523- <string key="label">value: arrangedObjects.displayInMenu</string>
524- <reference key="source" ref="1038076256"/>
525- <reference key="destination" ref="658059958"/>
526- <object class="NSNibBindingConnector" key="connector">
527- <reference key="NSSource" ref="1038076256"/>
528- <reference key="NSDestination" ref="658059958"/>
529- <string key="NSLabel">value: arrangedObjects.displayInMenu</string>
530- <string key="NSBinding">value</string>
531- <string key="NSKeyPath">arrangedObjects.displayInMenu</string>
532- <object class="NSDictionary" key="NSOptions">
533- <string key="NS.key.0">NSCreatesSortDescriptor</string>
534- <boolean value="NO" key="NS.object.0"/>
535- </object>
536- <int key="NSNibBindingConnectorVersion">2</int>
537- </object>
538- </object>
539- <int key="connectionID">66</int>
540- </object>
541- <object class="IBConnectionRecord">
542- <object class="IBBindingConnection" key="connection">
543- <string key="label">value: arrangedObjects.version</string>
544- <reference key="source" ref="593374330"/>
545- <reference key="destination" ref="658059958"/>
546- <object class="NSNibBindingConnector" key="connector">
547- <reference key="NSSource" ref="593374330"/>
548- <reference key="NSDestination" ref="658059958"/>
549- <string key="NSLabel">value: arrangedObjects.version</string>
550- <string key="NSBinding">value</string>
551- <string key="NSKeyPath">arrangedObjects.version</string>
552- <dictionary key="NSOptions">
553- <boolean value="YES" key="NSConditionallySetsEditable"/>
554- <boolean value="NO" key="NSCreatesSortDescriptor"/>
555- </dictionary>
556- <int key="NSNibBindingConnectorVersion">2</int>
557- </object>
558- </object>
559- <int key="connectionID">65</int>
560- </object>
56181 </array>
56282 <object class="IBMutableOrderedSet" key="objectRecords">
56383 <array key="orderedObjects">
@@ -597,152 +117,17 @@
597117 <object class="IBObjectRecord">
598118 <int key="objectID">8</int>
599119 <reference key="object" ref="992425267"/>
600- <array class="NSMutableArray" key="children">
601- <reference ref="946994194"/>
602- </array>
120+ <array class="NSMutableArray" key="children"/>
603121 <reference key="parent" ref="945346263"/>
604122 </object>
605- <object class="IBObjectRecord">
606- <int key="objectID">9</int>
607- <reference key="object" ref="946994194"/>
608- <array class="NSMutableArray" key="children">
609- <reference ref="391617440"/>
610- <reference ref="228860257"/>
611- <reference ref="38036422"/>
612- <reference ref="661524026"/>
613- </array>
614- <reference key="parent" ref="992425267"/>
615- </object>
616- <object class="IBObjectRecord">
617- <int key="objectID">10</int>
618- <reference key="object" ref="391617440"/>
619- <array class="NSMutableArray" key="children">
620- <reference ref="983541935"/>
621- <reference ref="813928279"/>
622- <reference ref="1038076256"/>
623- <reference ref="593374330"/>
624- </array>
625- <reference key="parent" ref="946994194"/>
626- </object>
627- <object class="IBObjectRecord">
628- <int key="objectID">11</int>
629- <reference key="object" ref="983541935"/>
630- <array class="NSMutableArray" key="children">
631- <reference ref="620336084"/>
632- </array>
633- <reference key="parent" ref="391617440"/>
634- </object>
635- <object class="IBObjectRecord">
636- <int key="objectID">12</int>
637- <reference key="object" ref="813928279"/>
638- <array class="NSMutableArray" key="children">
639- <reference ref="933097612"/>
640- </array>
641- <reference key="parent" ref="391617440"/>
642- </object>
643- <object class="IBObjectRecord">
644- <int key="objectID">13</int>
645- <reference key="object" ref="933097612"/>
646- <reference key="parent" ref="813928279"/>
647- </object>
648- <object class="IBObjectRecord">
649- <int key="objectID">24</int>
650- <reference key="object" ref="1038076256"/>
651- <array class="NSMutableArray" key="children">
652- <reference ref="146542405"/>
653- </array>
654- <reference key="parent" ref="391617440"/>
655- </object>
656- <object class="IBObjectRecord">
657- <int key="objectID">48</int>
658- <reference key="object" ref="146542405"/>
659- <reference key="parent" ref="1038076256"/>
660- </object>
661- <object class="IBObjectRecord">
662- <int key="objectID">29</int>
663- <reference key="object" ref="593374330"/>
664- <array class="NSMutableArray" key="children">
665- <reference ref="855612157"/>
666- </array>
667- <reference key="parent" ref="391617440"/>
668- </object>
669- <object class="IBObjectRecord">
670- <int key="objectID">17</int>
671- <reference key="object" ref="658059958"/>
672- <reference key="parent" ref="0"/>
673- <string key="objectName">PluginList</string>
674- </object>
675- <object class="IBObjectRecord">
676- <int key="objectID">35</int>
677- <reference key="object" ref="266224590"/>
678- <array class="NSMutableArray" key="children">
679- <reference ref="750991086"/>
680- <reference ref="754953227"/>
681- </array>
682- <reference key="parent" ref="0"/>
683- <string key="objectName">Tableview Contextual menu</string>
684- </object>
685- <object class="IBObjectRecord">
686- <int key="objectID">36</int>
687- <reference key="object" ref="750991086"/>
688- <reference key="parent" ref="266224590"/>
689- </object>
690- <object class="IBObjectRecord">
691- <int key="objectID">37</int>
692- <reference key="object" ref="754953227"/>
693- <reference key="parent" ref="266224590"/>
694- </object>
695- <object class="IBObjectRecord">
696- <int key="objectID">75</int>
697- <reference key="object" ref="620336084"/>
698- <reference key="parent" ref="983541935"/>
699- </object>
700- <object class="IBObjectRecord">
701- <int key="objectID">76</int>
702- <reference key="object" ref="855612157"/>
703- <reference key="parent" ref="593374330"/>
704- </object>
705- <object class="IBObjectRecord">
706- <int key="objectID">77</int>
707- <reference key="object" ref="228860257"/>
708- <reference key="parent" ref="946994194"/>
709- </object>
710- <object class="IBObjectRecord">
711- <int key="objectID">78</int>
712- <reference key="object" ref="38036422"/>
713- <reference key="parent" ref="946994194"/>
714- </object>
715- <object class="IBObjectRecord">
716- <int key="objectID">79</int>
717- <reference key="object" ref="661524026"/>
718- <reference key="parent" ref="946994194"/>
719- </object>
720123 </array>
721124 </object>
722125 <dictionary class="NSMutableDictionary" key="flattenedProperties">
723126 <string key="-1.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
724127 <string key="-2.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
725128 <string key="-3.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
726- <string key="10.CustomClassName">PSPPreviewerTableView</string>
727- <string key="10.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
728- <string key="11.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
729- <string key="12.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
730- <string key="13.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
731- <string key="17.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
732- <string key="24.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
733- <string key="29.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
734- <string key="35.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
735- <string key="36.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
736- <string key="37.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
737- <string key="48.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
738129 <string key="7.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
739- <string key="75.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
740- <string key="76.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
741- <string key="77.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
742- <string key="78.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
743- <string key="79.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
744130 <string key="8.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
745- <string key="9.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
746131 </dictionary>
747132 <dictionary class="NSMutableDictionary" key="unlocalizedProperties"/>
748133 <nil key="activeLocalization"/>
@@ -774,14 +159,6 @@
774159 </object>
775160 </object>
776161 <object class="IBPartialClassDescription">
777- <string key="className">PSPPreviewerTableView</string>
778- <string key="superclassName">NSTableView</string>
779- <object class="IBClassDescriptionSource" key="sourceIdentifier">
780- <string key="majorKey">IBProjectSource</string>
781- <string key="minorKey">./Classes/PSPPreviewerTableView.h</string>
782- </object>
783- </object>
784- <object class="IBPartialClassDescription">
785162 <string key="className">PSPreference</string>
786163 <string key="superclassName">NSWindowController</string>
787164 <object class="NSMutableDictionary" key="actions">
@@ -824,10 +201,5 @@
824201 </object>
825202 <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
826203 <int key="IBDocument.defaultPropertyAccessControl">3</int>
827- <dictionary class="NSMutableDictionary" key="IBDocument.LastKnownImageSizes">
828- <string key="NSMenuCheckmark">{11, 11}</string>
829- <string key="NSMenuMixedState">{10, 3}</string>
830- <string key="NSSwitch">{15, 15}</string>
831- </dictionary>
832204 </data>
833205 </archive>
--- a/PreviewerSelector.xcodeproj/project.pbxproj
+++ b/PreviewerSelector.xcodeproj/project.pbxproj
@@ -10,6 +10,8 @@
1010 8D5B49B0048680CD000E48DA /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C167DFE841241C02AAC07 /* InfoPlist.strings */; };
1111 8D5B49B4048680CD000E48DA /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7ADFEA557BF11CA2CBB /* Cocoa.framework */; };
1212 F458F523123CEE0900A546E4 /* PSPreviewerItems.m in Sources */ = {isa = PBXBuildFile; fileRef = F458F522123CEE0900A546E4 /* PSPreviewerItems.m */; };
13+ F46E73B815B2FCB800A4654D /* PreviewerSelectorPreferenceView.xib in Resources */ = {isa = PBXBuildFile; fileRef = F46E73B715B2FCB800A4654D /* PreviewerSelectorPreferenceView.xib */; };
14+ F46E73BF15B2FDDD00A4654D /* PreviewerSelectorPreferenceViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = F46E73BE15B2FDDD00A4654D /* PreviewerSelectorPreferenceViewController.m */; };
1315 F49DF78C15274D3C00F1E0F0 /* Preference.xib in Resources */ = {isa = PBXBuildFile; fileRef = F49DF78B15274D3C00F1E0F0 /* Preference.xib */; };
1416 F4A2FAE50F467CDC00A84E18 /* PSPreviewerItem.m in Sources */ = {isa = PBXBuildFile; fileRef = F4A2FAE40F467CDC00A84E18 /* PSPreviewerItem.m */; };
1517 F4AA26BE123D26C30065CF68 /* PSPreviewerInterface.m in Sources */ = {isa = PBXBuildFile; fileRef = F4AA26BD123D26C30065CF68 /* PSPreviewerInterface.m */; };
@@ -31,6 +33,9 @@
3133 F45032530F669A9500B0B042 /* PSPreviewerInterface.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PSPreviewerInterface.h; sourceTree = "<group>"; };
3234 F458F521123CEE0900A546E4 /* PSPreviewerItems.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PSPreviewerItems.h; sourceTree = "<group>"; };
3335 F458F522123CEE0900A546E4 /* PSPreviewerItems.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PSPreviewerItems.m; sourceTree = "<group>"; };
36+ F46E73B715B2FCB800A4654D /* PreviewerSelectorPreferenceView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = PreviewerSelectorPreferenceView.xib; sourceTree = "<group>"; };
37+ F46E73BD15B2FDDD00A4654D /* PreviewerSelectorPreferenceViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PreviewerSelectorPreferenceViewController.h; sourceTree = "<group>"; };
38+ F46E73BE15B2FDDD00A4654D /* PreviewerSelectorPreferenceViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PreviewerSelectorPreferenceViewController.m; sourceTree = "<group>"; };
3439 F47281760CF48168008E5A5B /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.make; name = English; path = English.lproj/Makefile; sourceTree = "<group>"; };
3540 F49DF78B15274D3C00F1E0F0 /* Preference.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = Preference.xib; sourceTree = "<group>"; };
3641 F4A2FAE30F467CDC00A84E18 /* PSPreviewerItem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PSPreviewerItem.h; sourceTree = "<group>"; };
@@ -88,6 +93,7 @@
8893 children = (
8994 F47281750CF48168008E5A5B /* Makefile */,
9095 F49DF78B15274D3C00F1E0F0 /* Preference.xib */,
96+ F46E73B715B2FCB800A4654D /* PreviewerSelectorPreferenceView.xib */,
9197 8D5B49B7048680CD000E48DA /* Info.plist */,
9298 089C167DFE841241C02AAC07 /* InfoPlist.strings */,
9399 F4E0BA8F0CF7350E003E4686 /* Localizable.strings */,
@@ -106,6 +112,8 @@
106112 F4A2FAE40F467CDC00A84E18 /* PSPreviewerItem.m */,
107113 F4F160350A0D1ED000C7526C /* PSPreference.h */,
108114 F4F160340A0D1ED000C7526C /* PSPreference.m */,
115+ F46E73BD15B2FDDD00A4654D /* PreviewerSelectorPreferenceViewController.h */,
116+ F46E73BE15B2FDDD00A4654D /* PreviewerSelectorPreferenceViewController.m */,
109117 F458F521123CEE0900A546E4 /* PSPreviewerItems.h */,
110118 F458F522123CEE0900A546E4 /* PSPreviewerItems.m */,
111119 F4F160430A0D1FC000C7526C /* PreviewerSelector.h */,
@@ -209,6 +217,7 @@
209217 8D5B49B0048680CD000E48DA /* InfoPlist.strings in Resources */,
210218 F4E0BA900CF7350E003E4686 /* Localizable.strings in Resources */,
211219 F49DF78C15274D3C00F1E0F0 /* Preference.xib in Resources */,
220+ F46E73B815B2FCB800A4654D /* PreviewerSelectorPreferenceView.xib in Resources */,
212221 );
213222 runOnlyForDeploymentPostprocessing = 0;
214223 };
@@ -269,6 +278,7 @@
269278 F4A2FAE50F467CDC00A84E18 /* PSPreviewerItem.m in Sources */,
270279 F458F523123CEE0900A546E4 /* PSPreviewerItems.m in Sources */,
271280 F4AA26BE123D26C30065CF68 /* PSPreviewerInterface.m in Sources */,
281+ F46E73BF15B2FDDD00A4654D /* PreviewerSelectorPreferenceViewController.m in Sources */,
272282 );
273283 runOnlyForDeploymentPostprocessing = 0;
274284 };
--- /dev/null
+++ b/PreviewerSelectorPreferenceView.xib
@@ -0,0 +1,768 @@
1+<?xml version="1.0" encoding="UTF-8"?>
2+<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="8.00">
3+ <data>
4+ <int key="IBDocument.SystemTarget">1050</int>
5+ <string key="IBDocument.SystemVersion">11E53</string>
6+ <string key="IBDocument.InterfaceBuilderVersion">2182</string>
7+ <string key="IBDocument.AppKitVersion">1138.47</string>
8+ <string key="IBDocument.HIToolboxVersion">569.00</string>
9+ <object class="NSMutableDictionary" key="IBDocument.PluginVersions">
10+ <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin</string>
11+ <string key="NS.object.0">2182</string>
12+ </object>
13+ <array key="IBDocument.IntegratedClassDependencies">
14+ <string>NSMenu</string>
15+ <string>NSCustomObject</string>
16+ <string>NSScrollView</string>
17+ <string>NSArrayController</string>
18+ <string>NSMenuItem</string>
19+ <string>NSTextFieldCell</string>
20+ <string>NSTableHeaderView</string>
21+ <string>NSTableColumn</string>
22+ <string>NSButtonCell</string>
23+ <string>NSScroller</string>
24+ <string>NSTableView</string>
25+ </array>
26+ <array key="IBDocument.PluginDependencies">
27+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
28+ </array>
29+ <object class="NSMutableDictionary" key="IBDocument.Metadata">
30+ <string key="NS.key.0">PluginDependencyRecalculationVersion</string>
31+ <integer value="1" key="NS.object.0"/>
32+ </object>
33+ <array class="NSMutableArray" key="IBDocument.RootObjects" id="732609723">
34+ <object class="NSCustomObject" id="221401942">
35+ <string key="NSClassName">PreviewerSelectorPreferenceViewController</string>
36+ </object>
37+ <object class="NSCustomObject" id="911328625">
38+ <string key="NSClassName">FirstResponder</string>
39+ </object>
40+ <object class="NSCustomObject" id="828666789">
41+ <string key="NSClassName">NSApplication</string>
42+ </object>
43+ <object class="NSScrollView" id="796557777">
44+ <reference key="NSNextResponder"/>
45+ <int key="NSvFlags">274</int>
46+ <array class="NSMutableArray" key="NSSubviews">
47+ <object class="NSClipView" id="1036954637">
48+ <reference key="NSNextResponder" ref="796557777"/>
49+ <int key="NSvFlags">2304</int>
50+ <array class="NSMutableArray" key="NSSubviews">
51+ <object class="NSTableView" id="898288516">
52+ <reference key="NSNextResponder" ref="1036954637"/>
53+ <int key="NSvFlags">4352</int>
54+ <string key="NSFrameSize">{360, 215}</string>
55+ <reference key="NSSuperview" ref="1036954637"/>
56+ <reference key="NSWindow"/>
57+ <reference key="NSNextKeyView" ref="134787295"/>
58+ <bool key="NSEnabled">YES</bool>
59+ <object class="NSTableHeaderView" key="NSHeaderView" id="88473654">
60+ <reference key="NSNextResponder" ref="607539563"/>
61+ <int key="NSvFlags">256</int>
62+ <string key="NSFrameSize">{360, 17}</string>
63+ <reference key="NSSuperview" ref="607539563"/>
64+ <reference key="NSWindow"/>
65+ <reference key="NSNextKeyView" ref="1036954637"/>
66+ <reference key="NSTableView" ref="898288516"/>
67+ </object>
68+ <object class="_NSCornerView" key="NSCornerView">
69+ <nil key="NSNextResponder"/>
70+ <int key="NSvFlags">256</int>
71+ <string key="NSFrame">{{346, 0}, {16, 17}}</string>
72+ </object>
73+ <array class="NSMutableArray" key="NSTableColumns">
74+ <object class="NSTableColumn" id="929265257">
75+ <string key="NSIdentifier">isUse</string>
76+ <double key="NSWidth">64</double>
77+ <double key="NSMinWidth">10</double>
78+ <double key="NSMaxWidth">1000</double>
79+ <object class="NSTableHeaderCell" key="NSHeaderCell">
80+ <int key="NSCellFlags">75628096</int>
81+ <int key="NSCellFlags2">2048</int>
82+ <string key="NSContents">Check Link</string>
83+ <object class="NSFont" key="NSSupport" id="26">
84+ <string key="NSName">LucidaGrande</string>
85+ <double key="NSSize">11</double>
86+ <int key="NSfFlags">3100</int>
87+ </object>
88+ <object class="NSColor" key="NSBackgroundColor" id="108760027">
89+ <int key="NSColorSpace">3</int>
90+ <bytes key="NSWhite">MC4zMzMzMzI5OQA</bytes>
91+ </object>
92+ <object class="NSColor" key="NSTextColor" id="244927324">
93+ <int key="NSColorSpace">6</int>
94+ <string key="NSCatalogName">System</string>
95+ <string key="NSColorName">headerTextColor</string>
96+ <object class="NSColor" key="NSColor" id="1057627452">
97+ <int key="NSColorSpace">3</int>
98+ <bytes key="NSWhite">MAA</bytes>
99+ </object>
100+ </object>
101+ </object>
102+ <object class="NSButtonCell" key="NSDataCell" id="631971203">
103+ <int key="NSCellFlags">67239424</int>
104+ <int key="NSCellFlags2">131072</int>
105+ <string key="NSContents"/>
106+ <object class="NSFont" key="NSSupport">
107+ <string key="NSName">LucidaGrande</string>
108+ <double key="NSSize">12</double>
109+ <int key="NSfFlags">16</int>
110+ </object>
111+ <reference key="NSControlView" ref="898288516"/>
112+ <int key="NSButtonFlags">1215582719</int>
113+ <int key="NSButtonFlags2">2</int>
114+ <object class="NSButtonImageSource" key="NSAlternateImage" id="507351284">
115+ <string key="NSImageName">NSSwitch</string>
116+ </object>
117+ <string key="NSAlternateContents"/>
118+ <string key="NSKeyEquivalent"/>
119+ <int key="NSPeriodicDelay">400</int>
120+ <int key="NSPeriodicInterval">75</int>
121+ </object>
122+ <int key="NSResizingMask">3</int>
123+ <bool key="NSIsResizeable">YES</bool>
124+ <bool key="NSIsEditable">YES</bool>
125+ <reference key="NSTableView" ref="898288516"/>
126+ </object>
127+ <object class="NSTableColumn" id="627679061">
128+ <string key="NSIdentifier">Plugin Name</string>
129+ <double key="NSWidth">121</double>
130+ <double key="NSMinWidth">85</double>
131+ <double key="NSMaxWidth">100000</double>
132+ <object class="NSTableHeaderCell" key="NSHeaderCell">
133+ <int key="NSCellFlags">75628096</int>
134+ <int key="NSCellFlags2">2048</int>
135+ <string key="NSContents">Plugin Name</string>
136+ <reference key="NSSupport" ref="26"/>
137+ <reference key="NSBackgroundColor" ref="108760027"/>
138+ <reference key="NSTextColor" ref="244927324"/>
139+ </object>
140+ <object class="NSTextFieldCell" key="NSDataCell" id="976703574">
141+ <int key="NSCellFlags">337772096</int>
142+ <int key="NSCellFlags2">2048</int>
143+ <string key="NSContents">Text Cell</string>
144+ <object class="NSFont" key="NSSupport" id="244523014">
145+ <string key="NSName">LucidaGrande</string>
146+ <double key="NSSize">13</double>
147+ <int key="NSfFlags">1044</int>
148+ </object>
149+ <reference key="NSControlView" ref="898288516"/>
150+ <object class="NSColor" key="NSBackgroundColor" id="713374760">
151+ <int key="NSColorSpace">6</int>
152+ <string key="NSCatalogName">System</string>
153+ <string key="NSColorName">controlBackgroundColor</string>
154+ <object class="NSColor" key="NSColor">
155+ <int key="NSColorSpace">3</int>
156+ <bytes key="NSWhite">MC42NjY2NjY2NjY3AA</bytes>
157+ </object>
158+ </object>
159+ <object class="NSColor" key="NSTextColor" id="902115768">
160+ <int key="NSColorSpace">6</int>
161+ <string key="NSCatalogName">System</string>
162+ <string key="NSColorName">controlTextColor</string>
163+ <reference key="NSColor" ref="1057627452"/>
164+ </object>
165+ </object>
166+ <int key="NSResizingMask">3</int>
167+ <bool key="NSIsResizeable">YES</bool>
168+ <reference key="NSTableView" ref="898288516"/>
169+ </object>
170+ <object class="NSTableColumn" id="181907813">
171+ <double key="NSWidth">82</double>
172+ <double key="NSMinWidth">10</double>
173+ <double key="NSMaxWidth">1000</double>
174+ <object class="NSTableHeaderCell" key="NSHeaderCell">
175+ <int key="NSCellFlags">75628096</int>
176+ <int key="NSCellFlags2">2048</int>
177+ <string key="NSContents">Version</string>
178+ <reference key="NSSupport" ref="26"/>
179+ <object class="NSColor" key="NSBackgroundColor" id="342108981">
180+ <int key="NSColorSpace">6</int>
181+ <string key="NSCatalogName">System</string>
182+ <string key="NSColorName">headerColor</string>
183+ <object class="NSColor" key="NSColor" id="117147346">
184+ <int key="NSColorSpace">3</int>
185+ <bytes key="NSWhite">MQA</bytes>
186+ </object>
187+ </object>
188+ <reference key="NSTextColor" ref="244927324"/>
189+ </object>
190+ <object class="NSTextFieldCell" key="NSDataCell" id="633788753">
191+ <int key="NSCellFlags">337772096</int>
192+ <int key="NSCellFlags2">2048</int>
193+ <string key="NSContents">Text Cell</string>
194+ <reference key="NSSupport" ref="244523014"/>
195+ <reference key="NSControlView" ref="898288516"/>
196+ <reference key="NSBackgroundColor" ref="713374760"/>
197+ <reference key="NSTextColor" ref="902115768"/>
198+ </object>
199+ <int key="NSResizingMask">3</int>
200+ <bool key="NSIsResizeable">YES</bool>
201+ <reference key="NSTableView" ref="898288516"/>
202+ </object>
203+ <object class="NSTableColumn" id="768369937">
204+ <double key="NSWidth">65</double>
205+ <double key="NSMinWidth">42.607421875</double>
206+ <double key="NSMaxWidth">65</double>
207+ <object class="NSTableHeaderCell" key="NSHeaderCell">
208+ <int key="NSCellFlags">75628096</int>
209+ <int key="NSCellFlags2">2048</int>
210+ <string key="NSContents">Use Menu</string>
211+ <reference key="NSSupport" ref="26"/>
212+ <reference key="NSBackgroundColor" ref="342108981"/>
213+ <reference key="NSTextColor" ref="244927324"/>
214+ </object>
215+ <object class="NSButtonCell" key="NSDataCell" id="285659638">
216+ <int key="NSCellFlags">67239424</int>
217+ <int key="NSCellFlags2">131072</int>
218+ <string key="NSContents">Check</string>
219+ <reference key="NSSupport" ref="26"/>
220+ <reference key="NSControlView" ref="898288516"/>
221+ <int key="NSButtonFlags">1215582719</int>
222+ <int key="NSButtonFlags2">130</int>
223+ <object class="NSCustomResource" key="NSNormalImage">
224+ <string key="NSClassName">NSImage</string>
225+ <string key="NSResourceName">NSSwitch</string>
226+ </object>
227+ <reference key="NSAlternateImage" ref="507351284"/>
228+ <string key="NSAlternateContents"/>
229+ <string key="NSKeyEquivalent"/>
230+ <int key="NSPeriodicDelay">200</int>
231+ <int key="NSPeriodicInterval">25</int>
232+ </object>
233+ <int key="NSResizingMask">3</int>
234+ <bool key="NSIsResizeable">YES</bool>
235+ <bool key="NSIsEditable">YES</bool>
236+ <reference key="NSTableView" ref="898288516"/>
237+ </object>
238+ </array>
239+ <double key="NSIntercellSpacingWidth">3</double>
240+ <double key="NSIntercellSpacingHeight">2</double>
241+ <reference key="NSBackgroundColor" ref="117147346"/>
242+ <object class="NSColor" key="NSGridColor">
243+ <int key="NSColorSpace">6</int>
244+ <string key="NSCatalogName">System</string>
245+ <string key="NSColorName">gridColor</string>
246+ <object class="NSColor" key="NSColor">
247+ <int key="NSColorSpace">3</int>
248+ <bytes key="NSWhite">MC41AA</bytes>
249+ </object>
250+ </object>
251+ <double key="NSRowHeight">17</double>
252+ <int key="NSTvFlags">1386217472</int>
253+ <reference key="NSDelegate"/>
254+ <reference key="NSDataSource"/>
255+ <int key="NSColumnAutoresizingStyle">4</int>
256+ <int key="NSDraggingSourceMaskForLocal">15</int>
257+ <int key="NSDraggingSourceMaskForNonLocal">0</int>
258+ <bool key="NSAllowsTypeSelect">YES</bool>
259+ <int key="NSTableViewDraggingDestinationStyle">0</int>
260+ <int key="NSTableViewGroupRowStyle">1</int>
261+ </object>
262+ </array>
263+ <string key="NSFrame">{{1, 17}, {360, 215}}</string>
264+ <reference key="NSSuperview" ref="796557777"/>
265+ <reference key="NSWindow"/>
266+ <reference key="NSNextKeyView" ref="898288516"/>
267+ <reference key="NSDocView" ref="898288516"/>
268+ <reference key="NSBGColor" ref="713374760"/>
269+ <int key="NScvFlags">4</int>
270+ </object>
271+ <object class="NSScroller" id="134787295">
272+ <reference key="NSNextResponder" ref="796557777"/>
273+ <int key="NSvFlags">256</int>
274+ <string key="NSFrame">{{346, 17}, {15, 215}}</string>
275+ <reference key="NSSuperview" ref="796557777"/>
276+ <reference key="NSWindow"/>
277+ <reference key="NSNextKeyView"/>
278+ <reference key="NSTarget" ref="796557777"/>
279+ <string key="NSAction">_doScroller:</string>
280+ <double key="NSPercent">0.95789474248886108</double>
281+ </object>
282+ <object class="NSScroller" id="109043282">
283+ <reference key="NSNextResponder" ref="796557777"/>
284+ <int key="NSvFlags">-2147483392</int>
285+ <string key="NSFrame">{{-100, -100}, {303, 15}}</string>
286+ <reference key="NSSuperview" ref="796557777"/>
287+ <reference key="NSWindow"/>
288+ <reference key="NSNextKeyView" ref="607539563"/>
289+ <int key="NSsFlags">1</int>
290+ <reference key="NSTarget" ref="796557777"/>
291+ <string key="NSAction">_doScroller:</string>
292+ <double key="NSPercent">0.95283019542694092</double>
293+ </object>
294+ <object class="NSClipView" id="607539563">
295+ <reference key="NSNextResponder" ref="796557777"/>
296+ <int key="NSvFlags">2304</int>
297+ <array class="NSMutableArray" key="NSSubviews">
298+ <reference ref="88473654"/>
299+ </array>
300+ <string key="NSFrame">{{1, 0}, {360, 17}}</string>
301+ <reference key="NSSuperview" ref="796557777"/>
302+ <reference key="NSWindow"/>
303+ <reference key="NSNextKeyView" ref="88473654"/>
304+ <reference key="NSDocView" ref="88473654"/>
305+ <reference key="NSBGColor" ref="713374760"/>
306+ <int key="NScvFlags">4</int>
307+ </object>
308+ </array>
309+ <string key="NSFrameSize">{362, 233}</string>
310+ <reference key="NSSuperview"/>
311+ <reference key="NSWindow"/>
312+ <reference key="NSNextKeyView" ref="109043282"/>
313+ <int key="NSsFlags">133138</int>
314+ <reference key="NSVScroller" ref="134787295"/>
315+ <reference key="NSHScroller" ref="109043282"/>
316+ <reference key="NSContentView" ref="1036954637"/>
317+ <reference key="NSHeaderClipView" ref="607539563"/>
318+ <bytes key="NSScrollAmts">QSAAAEEgAABBmAAAQZgAAA</bytes>
319+ </object>
320+ <object class="NSArrayController" id="658059958">
321+ <array class="NSMutableArray" key="NSDeclaredKeys">
322+ <string>version</string>
323+ <string>tryCheck</string>
324+ <string>displayName</string>
325+ <string>displayInMenu</string>
326+ </array>
327+ <string key="NSObjectClassName">PSPreviewerItem</string>
328+ <bool key="NSEditable">YES</bool>
329+ <object class="_NSManagedProxy" key="_NSManagedProxy"/>
330+ <bool key="NSAvoidsEmptySelection">YES</bool>
331+ <bool key="NSPreservesSelection">YES</bool>
332+ <bool key="NSSelectsInsertedObjects">YES</bool>
333+ <bool key="NSFilterRestrictsInsertion">YES</bool>
334+ <bool key="NSClearsFilterPredicateOnInsertion">YES</bool>
335+ </object>
336+ <object class="NSMenu" id="266224590">
337+ <string key="NSTitle">Menu</string>
338+ <array class="NSMutableArray" key="NSMenuItems">
339+ <object class="NSMenuItem" id="750991086">
340+ <reference key="NSMenu" ref="266224590"/>
341+ <string key="NSTitle">Open Previewer</string>
342+ <string key="NSKeyEquiv"/>
343+ <int key="NSKeyEquivModMask">1048576</int>
344+ <int key="NSMnemonicLoc">2147483647</int>
345+ <object class="NSCustomResource" key="NSOnImage" id="165798480">
346+ <string key="NSClassName">NSImage</string>
347+ <string key="NSResourceName">NSMenuCheckmark</string>
348+ </object>
349+ <object class="NSCustomResource" key="NSMixedImage" id="513356057">
350+ <string key="NSClassName">NSImage</string>
351+ <string key="NSResourceName">NSMenuMixedState</string>
352+ </object>
353+ <int key="NSTag">10000</int>
354+ </object>
355+ <object class="NSMenuItem" id="754953227">
356+ <reference key="NSMenu" ref="266224590"/>
357+ <string key="NSTitle">Open Preference</string>
358+ <string key="NSKeyEquiv"/>
359+ <int key="NSKeyEquivModMask">1048576</int>
360+ <int key="NSMnemonicLoc">2147483647</int>
361+ <reference key="NSOnImage" ref="165798480"/>
362+ <reference key="NSMixedImage" ref="513356057"/>
363+ <int key="NSTag">10001</int>
364+ </object>
365+ </array>
366+ <string key="NSName"/>
367+ </object>
368+ </array>
369+ <object class="IBObjectContainer" key="IBDocument.Objects">
370+ <array class="NSMutableArray" key="connectionRecords">
371+ <object class="IBConnectionRecord">
372+ <object class="IBOutletConnection" key="connection">
373+ <string key="label">itemsController</string>
374+ <reference key="source" ref="221401942"/>
375+ <reference key="destination" ref="658059958"/>
376+ </object>
377+ <int key="connectionID">73</int>
378+ </object>
379+ <object class="IBConnectionRecord">
380+ <object class="IBActionConnection" key="connection">
381+ <string key="label">openPreferences:</string>
382+ <reference key="source" ref="221401942"/>
383+ <reference key="destination" ref="754953227"/>
384+ </object>
385+ <int key="connectionID">121</int>
386+ </object>
387+ <object class="IBConnectionRecord">
388+ <object class="IBActionConnection" key="connection">
389+ <string key="label">toggleAPlugin:</string>
390+ <reference key="source" ref="221401942"/>
391+ <reference key="destination" ref="750991086"/>
392+ </object>
393+ <int key="connectionID">122</int>
394+ </object>
395+ <object class="IBConnectionRecord">
396+ <object class="IBOutletConnection" key="connection">
397+ <string key="label">view</string>
398+ <reference key="source" ref="221401942"/>
399+ <reference key="destination" ref="796557777"/>
400+ </object>
401+ <int key="connectionID">123</int>
402+ </object>
403+ <object class="IBConnectionRecord">
404+ <object class="IBBindingConnection" key="connection">
405+ <string key="label">contentArray: plugInList</string>
406+ <reference key="source" ref="658059958"/>
407+ <reference key="destination" ref="221401942"/>
408+ <object class="NSNibBindingConnector" key="connector">
409+ <reference key="NSSource" ref="658059958"/>
410+ <reference key="NSDestination" ref="221401942"/>
411+ <string key="NSLabel">contentArray: plugInList</string>
412+ <string key="NSBinding">contentArray</string>
413+ <string key="NSKeyPath">plugInList</string>
414+ <int key="NSNibBindingConnectorVersion">2</int>
415+ </object>
416+ </object>
417+ <int key="connectionID">18</int>
418+ </object>
419+ <object class="IBConnectionRecord">
420+ <object class="IBOutletConnection" key="connection">
421+ <string key="label">menu</string>
422+ <reference key="source" ref="898288516"/>
423+ <reference key="destination" ref="266224590"/>
424+ </object>
425+ <int key="connectionID">115</int>
426+ </object>
427+ <object class="IBConnectionRecord">
428+ <object class="IBOutletConnection" key="connection">
429+ <string key="label">dataSource</string>
430+ <reference key="source" ref="898288516"/>
431+ <reference key="destination" ref="221401942"/>
432+ </object>
433+ <int key="connectionID">114</int>
434+ </object>
435+ <object class="IBConnectionRecord">
436+ <object class="IBBindingConnection" key="connection">
437+ <string key="label">value: arrangedObjects.version</string>
438+ <reference key="source" ref="181907813"/>
439+ <reference key="destination" ref="658059958"/>
440+ <object class="NSNibBindingConnector" key="connector">
441+ <reference key="NSSource" ref="181907813"/>
442+ <reference key="NSDestination" ref="658059958"/>
443+ <string key="NSLabel">value: arrangedObjects.version</string>
444+ <string key="NSBinding">value</string>
445+ <string key="NSKeyPath">arrangedObjects.version</string>
446+ <dictionary key="NSOptions">
447+ <boolean value="YES" key="NSConditionallySetsEditable"/>
448+ <boolean value="NO" key="NSCreatesSortDescriptor"/>
449+ </dictionary>
450+ <int key="NSNibBindingConnectorVersion">2</int>
451+ </object>
452+ </object>
453+ <int key="connectionID">116</int>
454+ </object>
455+ <object class="IBConnectionRecord">
456+ <object class="IBBindingConnection" key="connection">
457+ <string key="label">value: arrangedObjects.displayInMenu</string>
458+ <reference key="source" ref="768369937"/>
459+ <reference key="destination" ref="658059958"/>
460+ <object class="NSNibBindingConnector" key="connector">
461+ <reference key="NSSource" ref="768369937"/>
462+ <reference key="NSDestination" ref="658059958"/>
463+ <string key="NSLabel">value: arrangedObjects.displayInMenu</string>
464+ <string key="NSBinding">value</string>
465+ <string key="NSKeyPath">arrangedObjects.displayInMenu</string>
466+ <object class="NSDictionary" key="NSOptions">
467+ <string key="NS.key.0">NSCreatesSortDescriptor</string>
468+ <boolean value="NO" key="NS.object.0"/>
469+ </object>
470+ <int key="NSNibBindingConnectorVersion">2</int>
471+ </object>
472+ </object>
473+ <int key="connectionID">119</int>
474+ </object>
475+ <object class="IBConnectionRecord">
476+ <object class="IBBindingConnection" key="connection">
477+ <string key="label">value: arrangedObjects.tryCheck</string>
478+ <reference key="source" ref="929265257"/>
479+ <reference key="destination" ref="658059958"/>
480+ <object class="NSNibBindingConnector" key="connector">
481+ <reference key="NSSource" ref="929265257"/>
482+ <reference key="NSDestination" ref="658059958"/>
483+ <string key="NSLabel">value: arrangedObjects.tryCheck</string>
484+ <string key="NSBinding">value</string>
485+ <string key="NSKeyPath">arrangedObjects.tryCheck</string>
486+ <object class="NSDictionary" key="NSOptions">
487+ <string key="NS.key.0">NSCreatesSortDescriptor</string>
488+ <boolean value="NO" key="NS.object.0"/>
489+ </object>
490+ <int key="NSNibBindingConnectorVersion">2</int>
491+ </object>
492+ </object>
493+ <int key="connectionID">118</int>
494+ </object>
495+ <object class="IBConnectionRecord">
496+ <object class="IBBindingConnection" key="connection">
497+ <string key="label">value: arrangedObjects.displayName</string>
498+ <reference key="source" ref="627679061"/>
499+ <reference key="destination" ref="658059958"/>
500+ <object class="NSNibBindingConnector" key="connector">
501+ <reference key="NSSource" ref="627679061"/>
502+ <reference key="NSDestination" ref="658059958"/>
503+ <string key="NSLabel">value: arrangedObjects.displayName</string>
504+ <string key="NSBinding">value</string>
505+ <string key="NSKeyPath">arrangedObjects.displayName</string>
506+ <dictionary key="NSOptions">
507+ <boolean value="YES" key="NSConditionallySetsEditable"/>
508+ <boolean value="NO" key="NSCreatesSortDescriptor"/>
509+ </dictionary>
510+ <int key="NSNibBindingConnectorVersion">2</int>
511+ </object>
512+ </object>
513+ <int key="connectionID">117</int>
514+ </object>
515+ </array>
516+ <object class="IBMutableOrderedSet" key="objectRecords">
517+ <array key="orderedObjects">
518+ <object class="IBObjectRecord">
519+ <int key="objectID">0</int>
520+ <array key="object" id="0"/>
521+ <reference key="children" ref="732609723"/>
522+ <nil key="parent"/>
523+ </object>
524+ <object class="IBObjectRecord">
525+ <int key="objectID">-2</int>
526+ <reference key="object" ref="221401942"/>
527+ <reference key="parent" ref="0"/>
528+ <string key="objectName">File's Owner</string>
529+ </object>
530+ <object class="IBObjectRecord">
531+ <int key="objectID">-1</int>
532+ <reference key="object" ref="911328625"/>
533+ <reference key="parent" ref="0"/>
534+ <string key="objectName">First Responder</string>
535+ </object>
536+ <object class="IBObjectRecord">
537+ <int key="objectID">-3</int>
538+ <reference key="object" ref="828666789"/>
539+ <reference key="parent" ref="0"/>
540+ <string key="objectName">Application</string>
541+ </object>
542+ <object class="IBObjectRecord">
543+ <int key="objectID">17</int>
544+ <reference key="object" ref="658059958"/>
545+ <reference key="parent" ref="0"/>
546+ <string key="objectName">PluginList</string>
547+ </object>
548+ <object class="IBObjectRecord">
549+ <int key="objectID">35</int>
550+ <reference key="object" ref="266224590"/>
551+ <array class="NSMutableArray" key="children">
552+ <reference ref="750991086"/>
553+ <reference ref="754953227"/>
554+ </array>
555+ <reference key="parent" ref="0"/>
556+ <string key="objectName">Tableview Contextual menu</string>
557+ </object>
558+ <object class="IBObjectRecord">
559+ <int key="objectID">36</int>
560+ <reference key="object" ref="750991086"/>
561+ <reference key="parent" ref="266224590"/>
562+ </object>
563+ <object class="IBObjectRecord">
564+ <int key="objectID">37</int>
565+ <reference key="object" ref="754953227"/>
566+ <reference key="parent" ref="266224590"/>
567+ </object>
568+ <object class="IBObjectRecord">
569+ <int key="objectID">101</int>
570+ <reference key="object" ref="796557777"/>
571+ <array class="NSMutableArray" key="children">
572+ <reference ref="898288516"/>
573+ <reference ref="109043282"/>
574+ <reference ref="88473654"/>
575+ <reference ref="134787295"/>
576+ </array>
577+ <reference key="parent" ref="0"/>
578+ </object>
579+ <object class="IBObjectRecord">
580+ <int key="objectID">105</int>
581+ <reference key="object" ref="898288516"/>
582+ <array class="NSMutableArray" key="children">
583+ <reference ref="627679061"/>
584+ <reference ref="929265257"/>
585+ <reference ref="768369937"/>
586+ <reference ref="181907813"/>
587+ </array>
588+ <reference key="parent" ref="796557777"/>
589+ </object>
590+ <object class="IBObjectRecord">
591+ <int key="objectID">104</int>
592+ <reference key="object" ref="109043282"/>
593+ <reference key="parent" ref="796557777"/>
594+ </object>
595+ <object class="IBObjectRecord">
596+ <int key="objectID">103</int>
597+ <reference key="object" ref="88473654"/>
598+ <reference key="parent" ref="796557777"/>
599+ </object>
600+ <object class="IBObjectRecord">
601+ <int key="objectID">102</int>
602+ <reference key="object" ref="134787295"/>
603+ <reference key="parent" ref="796557777"/>
604+ </object>
605+ <object class="IBObjectRecord">
606+ <int key="objectID">109</int>
607+ <reference key="object" ref="627679061"/>
608+ <array class="NSMutableArray" key="children">
609+ <reference ref="976703574"/>
610+ </array>
611+ <reference key="parent" ref="898288516"/>
612+ </object>
613+ <object class="IBObjectRecord">
614+ <int key="objectID">108</int>
615+ <reference key="object" ref="929265257"/>
616+ <array class="NSMutableArray" key="children">
617+ <reference ref="631971203"/>
618+ </array>
619+ <reference key="parent" ref="898288516"/>
620+ </object>
621+ <object class="IBObjectRecord">
622+ <int key="objectID">107</int>
623+ <reference key="object" ref="768369937"/>
624+ <array class="NSMutableArray" key="children">
625+ <reference ref="285659638"/>
626+ </array>
627+ <reference key="parent" ref="898288516"/>
628+ </object>
629+ <object class="IBObjectRecord">
630+ <int key="objectID">106</int>
631+ <reference key="object" ref="181907813"/>
632+ <array class="NSMutableArray" key="children">
633+ <reference ref="633788753"/>
634+ </array>
635+ <reference key="parent" ref="898288516"/>
636+ </object>
637+ <object class="IBObjectRecord">
638+ <int key="objectID">113</int>
639+ <reference key="object" ref="633788753"/>
640+ <reference key="parent" ref="181907813"/>
641+ </object>
642+ <object class="IBObjectRecord">
643+ <int key="objectID">112</int>
644+ <reference key="object" ref="285659638"/>
645+ <reference key="parent" ref="768369937"/>
646+ </object>
647+ <object class="IBObjectRecord">
648+ <int key="objectID">111</int>
649+ <reference key="object" ref="631971203"/>
650+ <reference key="parent" ref="929265257"/>
651+ </object>
652+ <object class="IBObjectRecord">
653+ <int key="objectID">110</int>
654+ <reference key="object" ref="976703574"/>
655+ <reference key="parent" ref="627679061"/>
656+ </object>
657+ </array>
658+ </object>
659+ <dictionary class="NSMutableDictionary" key="flattenedProperties">
660+ <string key="-1.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
661+ <string key="-2.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
662+ <string key="-3.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
663+ <string key="101.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
664+ <string key="102.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
665+ <string key="103.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
666+ <string key="104.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
667+ <string key="105.CustomClassName">PSPPreviewerTableView</string>
668+ <string key="105.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
669+ <string key="106.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
670+ <string key="107.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
671+ <string key="108.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
672+ <string key="109.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
673+ <string key="110.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
674+ <string key="111.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
675+ <string key="112.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
676+ <string key="113.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
677+ <string key="17.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
678+ <string key="35.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
679+ <string key="36.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
680+ <string key="37.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
681+ </dictionary>
682+ <dictionary class="NSMutableDictionary" key="unlocalizedProperties"/>
683+ <nil key="activeLocalization"/>
684+ <dictionary class="NSMutableDictionary" key="localizations"/>
685+ <nil key="sourceID"/>
686+ <int key="maxID">123</int>
687+ </object>
688+ <object class="IBClassDescriber" key="IBDocument.Classes">
689+ <array class="NSMutableArray" key="referencedPartialClassDescriptions">
690+ <object class="IBPartialClassDescription">
691+ <string key="className">NSObject</string>
692+ <dictionary class="NSMutableDictionary" key="actions">
693+ <string key="showPreviewerPreferences:">id</string>
694+ <string key="togglePreviewPanel:">id</string>
695+ </dictionary>
696+ <dictionary class="NSMutableDictionary" key="actionInfosByName">
697+ <object class="IBActionInfo" key="showPreviewerPreferences:">
698+ <string key="name">showPreviewerPreferences:</string>
699+ <string key="candidateClassName">id</string>
700+ </object>
701+ <object class="IBActionInfo" key="togglePreviewPanel:">
702+ <string key="name">togglePreviewPanel:</string>
703+ <string key="candidateClassName">id</string>
704+ </object>
705+ </dictionary>
706+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
707+ <string key="majorKey">IBProjectSource</string>
708+ <string key="minorKey">./Classes/NSObject.h</string>
709+ </object>
710+ </object>
711+ <object class="IBPartialClassDescription">
712+ <string key="className">PSPPreviewerTableView</string>
713+ <string key="superclassName">NSTableView</string>
714+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
715+ <string key="majorKey">IBProjectSource</string>
716+ <string key="minorKey">./Classes/PSPPreviewerTableView.h</string>
717+ </object>
718+ </object>
719+ <object class="IBPartialClassDescription">
720+ <string key="className">PreviewerSelectorPreferenceViewController</string>
721+ <string key="superclassName">NSViewController</string>
722+ <dictionary class="NSMutableDictionary" key="actions">
723+ <string key="openPreferences:">id</string>
724+ <string key="toggleAPlugin:">id</string>
725+ </dictionary>
726+ <dictionary class="NSMutableDictionary" key="actionInfosByName">
727+ <object class="IBActionInfo" key="openPreferences:">
728+ <string key="name">openPreferences:</string>
729+ <string key="candidateClassName">id</string>
730+ </object>
731+ <object class="IBActionInfo" key="toggleAPlugin:">
732+ <string key="name">toggleAPlugin:</string>
733+ <string key="candidateClassName">id</string>
734+ </object>
735+ </dictionary>
736+ <object class="NSMutableDictionary" key="outlets">
737+ <string key="NS.key.0">itemsController</string>
738+ <string key="NS.object.0">NSArrayController</string>
739+ </object>
740+ <object class="NSMutableDictionary" key="toOneOutletInfosByName">
741+ <string key="NS.key.0">itemsController</string>
742+ <object class="IBToOneOutletInfo" key="NS.object.0">
743+ <string key="name">itemsController</string>
744+ <string key="candidateClassName">NSArrayController</string>
745+ </object>
746+ </object>
747+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
748+ <string key="majorKey">IBProjectSource</string>
749+ <string key="minorKey">./Classes/PreviewerSelectorPreferenceViewController.h</string>
750+ </object>
751+ </object>
752+ </array>
753+ </object>
754+ <int key="IBDocument.localizationMode">0</int>
755+ <string key="IBDocument.TargetRuntimeIdentifier">IBCocoaFramework</string>
756+ <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDependencies">
757+ <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin.macosx</string>
758+ <integer value="1050" key="NS.object.0"/>
759+ </object>
760+ <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
761+ <int key="IBDocument.defaultPropertyAccessControl">3</int>
762+ <dictionary class="NSMutableDictionary" key="IBDocument.LastKnownImageSizes">
763+ <string key="NSMenuCheckmark">{11, 11}</string>
764+ <string key="NSMenuMixedState">{10, 3}</string>
765+ <string key="NSSwitch">{15, 15}</string>
766+ </dictionary>
767+ </data>
768+</archive>
--- /dev/null
+++ b/PreviewerSelectorPreferenceViewController.h
@@ -0,0 +1,25 @@
1+//
2+// PreviewerSelectorPreferenceViewController.h
3+// PreviewerSelector
4+//
5+// Created by 堀 昌樹 on 12/07/15.
6+// Copyright (c) 2012年 __MyCompanyName__. All rights reserved.
7+//
8+
9+#import <Cocoa/Cocoa.h>
10+
11+@interface PreviewerSelectorPreferenceViewController : NSViewController
12+{
13+ IBOutlet NSArrayController *itemsController;
14+
15+ NSMutableArray *plugInList;
16+}
17+@property (readonly) NSTableView *tableView;
18+
19+- (id)init;
20+
21+- (void)setPlugInList:(id)list;
22+
23+- (IBAction)openPreferences:(id)sender;
24+- (IBAction)toggleAPlugin:(id)sender;
25+@end
--- /dev/null
+++ b/PreviewerSelectorPreferenceViewController.m
@@ -0,0 +1,201 @@
1+//
2+// PreviewerSelectorPreferenceViewController.m
3+// PreviewerSelector
4+//
5+// Created by 堀 昌樹 on 12/07/15.
6+// Copyright (c) 2012年 __MyCompanyName__. All rights reserved.
7+//
8+
9+#import "PreviewerSelectorPreferenceViewController.h"
10+
11+#import "PreviewerSelector.h"
12+#import "PSPreviewerItem.h"
13+
14+
15+@implementation PreviewerSelectorPreferenceViewController
16+
17+static NSString *const PSPItemPastboardType = @"PSPItemPastboardType";
18+static NSString *const PSPRowIndexType = @"PSPRowIndexType";
19+
20+- (id)init
21+{
22+ self = [super initWithNibName:@"PreviewerSelectorPreferenceView"
23+ bundle:[NSBundle bundleForClass:[self class]]];
24+ return self;
25+}
26+
27+- (void)awakeFromNib
28+{
29+ [self.tableView setDoubleAction:@selector(toggleAPlugin:)];
30+ [self.tableView setTarget:self];
31+
32+ [self.tableView registerForDraggedTypes:[NSArray arrayWithObject:PSPItemPastboardType]];
33+
34+ [itemsController addObserver:self forKeyPath:@"selection.tryCheck" options:0 context:itemsController];
35+ [itemsController addObserver:self forKeyPath:@"selection.displayInMenu" options:0 context:itemsController];
36+}
37+- (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context
38+{
39+ if(context == itemsController) {
40+ [[PreviewerSelector sharedInstance] savePlugInsInfo];
41+ return;
42+ }
43+
44+ [super observeValueForKeyPath:keyPath ofObject:object change:change context:context];
45+}
46+
47+- (NSTableView *)tableView
48+{
49+ return [(NSScrollView *)self.view documentView];
50+}
51+
52+- (void)setPlugInList:(id)list
53+{
54+ id temp = plugInList;
55+ plugInList = [list retain];
56+ [temp release];
57+}
58+
59+- (IBAction)toggleAPlugin:(id)sender
60+{
61+ int selectedRow = [self.tableView selectedRow];
62+ if(selectedRow == -1) return;
63+
64+ id info = [plugInList objectAtIndex:selectedRow];
65+ id obj = [info previewer];
66+ if(!obj) return;
67+
68+ if([obj respondsToSelector:@selector(togglePreviewPanel:)]) {
69+ [obj performSelector:@selector(togglePreviewPanel:) withObject:self];
70+ }
71+}
72+
73+- (IBAction)openPreferences:(id)sender
74+{
75+ int selectedRow = [self.tableView selectedRow];
76+ if(selectedRow == -1) return;
77+
78+ id info = [plugInList objectAtIndex:selectedRow];
79+ id obj = [info previewer];
80+ if(!obj) return;
81+
82+ if([obj respondsToSelector:@selector(showPreviewerPreferences:)]) {
83+ [obj performSelector:@selector(showPreviewerPreferences:) withObject:self];
84+ }
85+}
86+
87+#pragma mark## NSMenu Delegate ##
88+enum _PreferenceMenuTags {
89+kOpenPreviewer = 10000,
90+kOpenPreferences = 10001,
91+};
92+- (BOOL)validateMenuItem:(NSMenuItem *)menuItem
93+{
94+ int selectedRow = [self.tableView selectedRow];
95+ if(selectedRow == -1) return NO;
96+
97+ id info = [plugInList objectAtIndex:selectedRow];
98+ id obj = [info previewer];
99+ if(!obj) return NO;
100+
101+ id displayName = [info displayName];
102+
103+ switch([menuItem tag]) {
104+ case kOpenPreviewer:
105+ {
106+ if(displayName) {
107+ id title = [NSString stringWithFormat:PSLocalizedString(@"Open %@", @"Open Previewer."), displayName];
108+ [menuItem setTitle:title];
109+ }
110+ if([obj respondsToSelector:@selector(togglePreviewPanel:)]) {
111+ return YES;
112+ }
113+ break;
114+ }
115+ case kOpenPreferences:
116+ if(displayName) {
117+ id title = [NSString stringWithFormat:PSLocalizedString(@"Open %@'s Preferences", @"Open Previewer Preferences."), displayName];
118+ [menuItem setTitle:title];
119+ }
120+ if([obj respondsToSelector:@selector(showPreviewerPreferences:)]) {
121+ return YES;
122+ }
123+ break;
124+ default:
125+ //
126+ break;
127+ }
128+
129+ return NO;
130+}
131+
132+
133+
134+- (BOOL)tableView:(NSTableView *)tableView writeRowsWithIndexes:(NSIndexSet *)rowIndexes toPasteboard:(NSPasteboard*)pboard
135+{
136+ if([rowIndexes count] != 1) return NO;
137+
138+ NSUInteger index = [rowIndexes firstIndex];
139+
140+ [pboard declareTypes:[NSArray arrayWithObjects:PSPItemPastboardType, PSPRowIndexType, nil] owner:nil];
141+ [pboard setData:[NSKeyedArchiver archivedDataWithRootObject:[plugInList objectAtIndex:index]]
142+ forType:PSPItemPastboardType];
143+ [pboard setPropertyList:[NSNumber numberWithUnsignedInteger:index] forType:PSPRowIndexType];
144+
145+ return YES;
146+}
147+
148+- (NSDragOperation)tableView:(NSTableView*)targetTableView
149+ validateDrop:(id <NSDraggingInfo>)info
150+ proposedRow:(NSInteger)row
151+ proposedDropOperation:(NSTableViewDropOperation)dropOperation
152+{
153+ NSPasteboard *pboard = [info draggingPasteboard];
154+ if(![[pboard types] containsObject:PSPItemPastboardType]) {
155+ return NSDragOperationNone;
156+ }
157+
158+ if(dropOperation == NSTableViewDropOn) {
159+ [targetTableView setDropRow:row dropOperation:NSTableViewDropAbove];
160+ }
161+
162+ NSUInteger originalRow = [[pboard propertyListForType:PSPRowIndexType] unsignedIntegerValue];
163+ if(row == originalRow || row == originalRow + 1) {
164+ return NSDragOperationNone;
165+ }
166+
167+ return NSDragOperationMove;
168+}
169+
170+- (BOOL)tableView:(NSTableView*)tableView
171+ acceptDrop:(id <NSDraggingInfo>)info
172+ row:(NSInteger)row
173+ dropOperation:(NSTableViewDropOperation)dropOperation
174+{
175+ NSPasteboard *pboard = [info draggingPasteboard];
176+ if(![[pboard types] containsObject:PSPItemPastboardType]) {
177+ return NO;
178+ }
179+
180+ if(row < 0) row = 0;
181+
182+ NSUInteger originalRow = [[pboard propertyListForType:PSPRowIndexType] unsignedIntegerValue];
183+
184+ NSData *itemData = [pboard dataForType:PSPItemPastboardType];
185+ PSPreviewerItem *item = [NSKeyedUnarchiver unarchiveObjectWithData:itemData];
186+ if(![item isKindOfClass:[PSPreviewerItem class]]) {
187+ return NO;
188+ }
189+
190+ [self willChangeValueForKey:@"plugInList"];
191+ [plugInList insertObject:item atIndex:row];
192+ if(originalRow > row) originalRow++;
193+ [plugInList removeObjectAtIndex:originalRow];
194+ [self didChangeValueForKey:@"plugInList"];
195+
196+ [[PreviewerSelector sharedInstance] savePlugInsInfo];
197+
198+ return YES;
199+}
200+
201+@end