-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathCodaPlugInsController.h
1268 lines (751 loc) · 27.7 KB
/
CodaPlugInsController.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/** This header provides protocols and facilities to implement Coda text-based,
syntax validator and sidebar plug-in.
Version 7
*/
#ifndef HEADER_ENVELOPE_CODA_PLUGIN
#define HEADER_ENVELOPE_CODA_PLUGIN
#import <Cocoa/Cocoa.h>
#if defined (CODA)
#import "SidebarPlacardView.h"
#endif
@class CodaTextView;
@protocol CodaValidator, CodaValidatorDelegate;
/** `CodaPlugInsController` is the principal way of communicating with Coda.
You must register your available functionality with one of the methods
implemented by the plug-in controller.
@availability Coda 1.6 and later.
*/
@interface CodaPlugInsController : NSObject
///-------------------------
/// @name Determaining Versions
///-------------------------
/**
The version of Coda that is hosting the plug-in.
@return A string such as "2.5.1".
*/
- (NSString*)codaVersion;
/**
The current API version of Coda.
The versions are as follows:
Coda Version | API Version
--- | ---
1.6 | 2
1.6.1 | 3
1.6.3 | 4
1.6.8 | 5
2.0 | 5
2.0.1 | 6
2.5 | 7
@return 7 as of Coda 2.5.
*/
- (NSUInteger)apiVersion;
///-------------------------
/// @name Creating Menu Items
///-------------------------
/** Registering new menu items with Coda.
Exposes to the user a plug-in action (a menu item) with the given title, that
will perform the given selector on the target.
@param title Title of the menu item.
@param target The object to send the selector message.
@param selector Action of the menu item.
*/
- (void)registerActionWithTitle:(NSString*)title target:(id)target selector:(SEL)selector;
/** Registering new menu items with Coda with advanced options.
Allows further customization of the registered menu items, including submenu title,
represented object, keyEquivalent and custom plug-in name.
@see registerActionWithTitle:target:selector:
@param title Title of the menu item.
@param submenuTitle Parent menu to add menu item.
@param target The object to send the selector message.
@param selector Action of the menu item.
@param repOb An object to be assocated with the menu item.
@param keyEquivalent Sets the key equivalent character of the receiver to the given character. Can include modifier characters as follows: $ = shift, ~ = option, @ = cmd, ^ = ctrl
@param aName The display name of the plug-in.
*/
- (void)registerActionWithTitle:(NSString*)title
underSubmenuWithTitle:(NSString*)submenuTitle
target:(id)target
selector:(SEL)selector
representedObject:(id)repOb
keyEquivalent:(NSString*)keyEquivalent
pluginName:(NSString*)aName;
///-------------------------
/// @name Text Editor
///-------------------------
/** Returns the receiver's current focused text view.
An abstract object representing the text view in Coda which currently has focus.
@return The receiver's text view.
*/
- (CodaTextView*)focusedTextView;
///-------------------------
/// @name Actions
///-------------------------
/**
Displays an html formatted string in a new tab.
@param html The html formatted string to be shown.
*/
- (void)displayHTMLString:(NSString*)html;
/**
Create a new text document.
Creates a new unsaved document in the frontmost Coda window and returns the text view associated with it.
The text view provided is autoreleased; the caller should not explicitly release it.
@return A CodaTextView object associated with the new document.
*/
- (CodaTextView*)makeUntitledDocument;
/**
Saves all files.
Causes the frontmost Coda window to save all documents that have unsaved changes.
*/
- (void)saveAll;
/**
Displays an html formatted string in a new tab.
Displays an html formatted string in a new tab with a specific base URL.
@param html The html formatted string to be shown.
@param baseURL The base URL to be used when showing the html string.
@availability Coda 2.0 and later.
*/
- (void)displayHTMLString:(NSString*)html baseURL:(NSURL*)baseURL;
/**
Open a File.
Opens text file at path, returning CodaTextView if successful.
@param path The file path to open.
@param error If non-nil, result is a filled error if an error occurred while opening the file at path.
@return
A CodaTextView of the resulting open file's text.
@availability Coda 2.0 and later.
*/
- (CodaTextView*)openFileAtPath:(NSString*)path error:(NSError**)error;
///-------------------------
/// @name Site Settings
///-------------------------
/**
Returns the root local path of the current site.
@return
The Local path of the site in the frontmost window, may be nil if unspecified or a site is not loaded.
@availability Coda 2.5 and later.
*/
- (NSString*)siteLocalPath;
/**
Returns the URL of the current site.
@return
The URL of the site in the frontmost window, may be nil if unspecified or a site is not loaded.
@availability Coda 2.5 and later.
*/
- (NSString*)siteURL;
/**
Returns the local URL of the current site.
@return
The local URL of the site in the frontmost window, may be nil if unspecified or a site is not loaded.
@availability Coda 2.5 and later.
*/
- (NSString*)siteLocalURL;
/**
Returns the root remote path of the the current site.
@return
The root remote path of the site in the frontmost window, may be nil if unspecified or a site is not loaded.
@availability Coda 2.5 and later.
*/
- (NSString*)siteRemotePath;
/**
Returns the nickname of the current site.
@return
The nickname of the site in the frontmost window, may be nil if a site is not loaded.
@availability Coda 2.5 and later.
*/
- (NSString*)siteNickname;
/**
Returns the current site UUID.
The site UUID will not change during the lifetime of the site.
This value may be used for tracking specific preferences for the site.
@return
The UUID of the current site, may be nil if no site is loaded.
@availability Coda 2.5 and later.
*/
- (NSString*)siteUUID;
@end
@class CodaPlainTextEditor;
/**
This is an opaque object representing the text view in Coda.
This is your hook to a text view in Coda. You can use this to provide
manipulation of files.
*/
@interface CodaTextView : NSObject
{
CodaPlainTextEditor* editor;
}
/**
Inserts into the receiver the inText at the current insertion point.
@param inText The string to insert, must be non-nil.
*/
- (void)insertText:(NSString*)inText;
/**
Replaces the characters from aRange with those in aString.
Replaces characters in the given range with the given string.
@param aRange The range of characters to replace. aRange must not exceed the bounds of the receiver.
@param aString The string with which to replace the characters in aRange. aString must not be nil.
*/
- (void)replaceCharactersInRange:(NSRange)aRange withString:(NSString *)aString;
/**
@return Returns the range of selected characters.
*/
- (NSRange)selectedRange;
/**
@return The currently selected text, or nil if none.
*/
- (NSString*)selectedText;
/**
Selects the given character range.
@param range The range of characters to select. range must not exceed the bounds of the receiver.
*/
- (void)setSelectedRange:(NSRange)range;
/**
Returns a string containing the entire content of the line that the insertion point is on.
*/
- (NSString*)currentLine;
/**
The line number corresponding to the location of the insertion point.
*/
- (NSUInteger)currentLineNumber;
/**
Deletes the characters in the current selected range.
*/
- (void)deleteSelection;
/**
The current line ending of the file.
*/
- (NSString*)lineEnding;
/**
The character range of the entire line the insertion point is on.
*/
- (NSRange)rangeOfCurrentLine;
/**
Returns the starting character index of the current line.
The character index (relative to the beginning of the document) of the start of the line the insertion point is on.
@return
a character index.
*/
- (NSUInteger)startOfLine;
/**
The entire document as plain text.
*/
- (NSString*)string;
/**
Returns a substring in range of the entire text string.
@param range The range of characters in the substring; range must not exceed the bounds of the receiver.
@return
The specified substring.
*/
- (NSString*)stringWithRange:(NSRange)range;
/**
Returns the width of tabs as spaces.
*/
- (NSInteger)tabWidth;
/**
Returns the range of the word previous to the insertion point.
If there is no previous word range, it may return {NSNotFound, 0} range.
@return
The range of the previous word.
*/
- (NSRange)previousWordRange;
/**
Returns if the editor is currently uses tabs instead of spaces for indentation.
@return
YES if is currently using tabs, NO otherwise.
*/
- (BOOL)usesTabs;
/**
Saves the current focused document.
*/
- (void)save;
/**
Saves the current focused document to a specific location.
@param aPath A complete local path to save the file to.
@return
YES if successful, NO if not.
*/
- (BOOL)saveToPath:(NSString*)aPath;
/**
Begins a text undo group.
Allows for multiple text manipulations to be considered one "undo/redo" operation.
*/
- (void)beginUndoGrouping;
/**
Ends a text undo group.
Allows for multiple text manipulations to be considered one "undo/redo" operation.
*/
- (void)endUndoGrouping;
/**
Returns the window the editor is located in (useful for showing sheets).
*/
- (NSWindow*)window;
/**
The path to the text view's file.
@return
A file path, may be nil if the file is unsaved.
*/
- (NSString*)path;
/**
Returns the range of the word containing the insertion point.
@availability Coda 1.6.1 and later.
*/
- (NSRange)currentWordRange;
/**
Moves insertion point to specified line and column.
Line and column must be within the bounds of the receiver. The text view will scroll if needed.
@param line The line to move the insertion point.
@param column The column to move the insertion point.
@availability Coda 2.0 and later.
*/
- (void)goToLine:(NSInteger)line column:(NSInteger)column;
/**
Returns the text encoding of the text view.
@availability Coda 2.0 and later.
*/
- (NSStringEncoding)encoding;
/**
Returns the mode identifier of of the current text view syntax.
This value is the CFBundleIdentifier for a mode. For example, the HTML mode returns "SEEMode.HTML".
@availability Coda 2.5 and later.
*/
- (NSString*)modeIdentifier;
/**
Returns the current line and column at the insertion point by reference.
@param line NSInteger pointer to insert line value.
@param column NSInteger pointer to insert the column value.
@availability Coda 2.5 and later.
*/
- (void)getLine:(NSInteger*)line column:(NSInteger*)column;
/**
Returns the text view file name, even if unsaved.
@availability Coda 2.5 and later.
*/
- (NSString*)filename;
/**
Replaces the characters from aRange with a named placeholder with the value name.
@param aRange The character range to be replaced by the placeholder; aRange must not exceed the bounds of the receiver.
@param name The name of the placeholder to insert, must contain at least one character.
@availability Coda 2.5 and later.
*/
- (void)replaceCharactersInRange:(NSRange)aRange withPlaceholderNamed:(NSString*)name;
/**
Returns the remote URL of the focused editor document based on the site remote URL.
@return
The remote URL, may be nil if unspecified or a site is not loaded.
@availability Coda 2.0 and later.
*/
- (NSString*)remoteURL;
/**
Sets the editors line ending string
@param ending A string represending the line ending string
@discussion
Valid options are:
U+000A (\n or LF)
U+000D (\r or CR)
U+2028 (Unicode line separator)
U+2029 (Unicode paragraph separator)
\r\n, in that order (also known as CRLF)
@availability Coda 2.5 and later.
*/
- (void)setLineEnding:(NSString*)ending;
/**
Sets the editor to use tabs instead of spaces for indentation.
@param useTabs whether to use tabs instead of spaces.
@availability Coda 2.5 and later.
*/
- (void)setUsesTabs:(BOOL)useTabs;
/**
Sets the editor tab width when using spaces.
@param width value of the number of spaces inserted per tab press.
@availability Coda 2.5 and later.
*/
- (void)setTabWidth:(NSInteger)width;
/**
Returns the root local path of the current site.
@deprecated in 2.5, use CodaPluginsController siteLocalPath.
@return
The local path of the current site, may be nil if unspecified or a site is not loaded.
*/
- (NSString*)siteLocalPath DEPRECATED_ATTRIBUTE;
/**
Returns the URL of the current site.
@deprecated in 2.5, use CodaPluginsController siteURL.
@return
The URL of the current site, may be nil if unspecified or a site is not loaded.
@availability Coda 1.6.3 and later.
*/
- (NSString*)siteURL DEPRECATED_ATTRIBUTE;
/**
Returns the local URL of the current site.
@deprecated in 2.5, use CodaPluginsController siteLocalPath.
@return
The local URL of the current site, may be nil if unspecified or a site is not loaded.
@availability Coda 1.6.3 and later.
*/
- (NSString*)siteLocalURL DEPRECATED_ATTRIBUTE;
/**
Returns the root remote path of the the current site.
@deprecated in 2.5, use CodaPluginsController siteRemotePath.
@return
The root remote path of the current site, may be nil if unspecified or a site is not loaded.
@availability Coda 1.6.3 and later.
*/
- (NSString*)siteRemotePath DEPRECATED_ATTRIBUTE;
/**
Returns the nickname of the current site.
@deprecated in 2.5, use CodaPluginsController siteNickname.
@return
The nickname of the current site, may be nil if a site is not loaded.
@availability Coda 1.6.3 and later.
*/
- (NSString*)siteNickname DEPRECATED_ATTRIBUTE;
@end
/**
An opaque object which represents the plug-in bundle.
Similar to NSBundle, CodaPlugInBundle is an object which represents your plug-in on disk.
@availability Coda 2.0.1 and later.
*/
@protocol CodaPlugInBundle <NSObject>
@required
/** The unique identifier for the bundle */
@property (copy, readonly) NSString *bundleIdentifier;
/** The URL of the bundle on disk */
@property (copy, readonly) NSURL *bundleURL;
/** The path of the bundle on disk */
@property (copy, readonly) NSString *bundlePath;
/** The principal class of the bundle */
@property (readonly) Class principalClass;
/** The (unlocalized) info dictionary */
@property (copy, readonly) NSDictionary *infoDictionary;
/** The localized info dictionary */
@property (copy, readonly) NSDictionary *localizedInfoDictionary;
/** Gets the (localized, when possible) value of an info dictionary key
@param key info dictionary key
*/
- (id)objectForInfoDictionaryKey:(NSString *)key;
/** The URL of the bundle's executable file */
@property (copy, readonly) NSURL *executableURL;
/** The path of the bundle's executable file */
@property (copy, readonly) NSString *executablePath;
/** An array of numbers indicating the architecture types supported by the bundle’s executable */
@property (copy, readonly) NSArray *executableArchitectures;
/** Gets the URL for an auxiliary executable in the bundle
@param executableName The filename of the executable
*/
- (NSURL *)URLForAuxiliaryExecutable:(NSString *)executableName;
/** Gets the path for an auxiliary executable in the bundle
@param executableName The filename of the executable
*/
- (NSString *)pathForAuxiliaryExecutable:(NSString *)executableName;
/** The URL of the bundle's resource directory */
@property (copy, readonly) NSURL *resourceURL;
/** The path of the bundle's resource directory */
@property (copy, readonly) NSString *resourcePath;
/** Gets the URL for a bundle resource
@param name The name of the resource
@param extension The extension of the resource
*/
- (NSURL *)URLForResource:(NSString *)name withExtension:(NSString *)extension;
/** Gets the URL for a bundle resource located within a bundle subdirectory
@param name The name of the resource
@param extension The extension of the resource
@param subpath The subpath
*/
- (NSURL *)URLForResource:(NSString *)name withExtension:(NSString *)extension subdirectory:(NSString *)subpath;
/** Gets the URL for a bundle resource located within a bundle subdirectory and localization
@param name The name of the resource
@param extension The extension of the resource
@param subpath The subpath
@param localizationName The localization name
*/
- (NSURL *)URLForResource:(NSString *)name withExtension:(NSString *)extension subdirectory:(NSString *)subpath localization:(NSString *)localizationName;
/** Gets the URL for a bundle resource
@param name The name of the resource
@param extension The extension of the resource
*/
- (NSString *)pathForResource:(NSString *)name ofType:(NSString *)extension;
/** Gets the URL for a bundle resource located within a bundle subdirectory
@param name The name of the resource
@param extension The extension of the resource
@param subpath The subpath
*/
- (NSString *)pathForResource:(NSString *)name ofType:(NSString *)extension inDirectory:(NSString *)subpath;
/** Gets the URL for a bundle resource located within a bundle subdirectory and localization
@param name The name of the resource
@param extension The extension of the resource
@param subpath The subpath
@param localizationName The localization name
*/
- (NSString *)pathForResource:(NSString *)name ofType:(NSString *)extension inDirectory:(NSString *)subpath forLocalization:(NSString *)localizationName;
/** A list of all the localizations contained within the receiver's bundle */
@property (copy, readonly) NSArray *localizations;
/** A list of the preferred localizations contained within the receiver's bundle */
@property (copy, readonly) NSArray *preferredLocalizations;
/** The localization used to create the bundle */
@property (copy, readonly) NSArray *developmentLocalization;
/** Gets the localized string for a given key, value and table
@param key a key
@param value a value
@param tableName The table name
*/
- (NSString *)localizedStringForKey:(NSString *)key value:(NSString *)value table:(NSString *)tableName;
@end
/**
CodaPlugIn
The principal plug-in object protocol.
The plug-in's principal class must conform to this protocol to be loaded.
@availability Coda 1.6 and later
*/
@protocol CodaPlugIn <NSObject>
@required
/**
Gets the name of your plug-in.
@return name the human-readable name of your plug-in.
If your plug-in has menu items, this name will be shown as the top-level menu item.
*/
- (NSString*)name;
@optional
/**
The default initalization method for your plug-in's principal class.
@param aController The singleton instance of the CodaPlugInsController.
@param plugInBundle A reference to your plug-in bundle.
@warning The initializer can (and most likely will) be called from a secondary thread. If your plugin utilizes a
shared language bridge that requires initialization on the main thread (like PyObjC), then add the
CodaPlugInRequiresInitOnMainThread key to your Info.plist with a value of YES.
@availability Coda 2.0.1 and later.
@note CodaPlugInSupportedAPIVersion and/or CodaPlugInMinimumAPIVersion info.plist key must be set to 6 or higher.
@return a new plug-in instance.
*/
- (id)initWithPlugInController:(CodaPlugInsController*)aController plugInBundle:(id <CodaPlugInBundle>)plugInBundle;
/**
Default initalization method for your plug-in's principal class.
@param aController The singleton instance of the CodaPlugInsController.
@param plugInBundle A reference to your plug-in bundle.
@note Deprecated in Coda API v6 (2.0.1) and later in favor of initWithPlugInController:pluginBundle:
@return a new plug-in instance.
*/
- (id)initWithPlugInController:(CodaPlugInsController*)aController bundle:(NSBundle*)plugInBundle DEPRECATED_ATTRIBUTE;
/**
A callback to be notified when the text view will save.
This method will be called before a text view's contents will be saved to disk.
This allows processing of the text at save time.
@param textView The text view which is in the process of being saved to disk.
*/
- (void)textViewWillSave:(CodaTextView*)textView;
/**
A callback to be notified when the text view did save.
This method will be called after a text view's contents are saved to disk.
This allows processing of the text after save time.
@param textView The text view whose contents where saved to disk.
*/
- (void)textViewDidSave:(CodaTextView*)textView;
/**
A callback when a text view is focused/opened.
@param textView The text view which now focused.
@warning This method is time sensitive and should return quickly.
*/
- (void)textViewDidFocus:(CodaTextView*)textView;
/**
A callback when a file at a specific path will be published.
This callback allows the plug-in a chance to modify files
just before publishing. The result is the new path to the actual file to publish.
This is useful for minifying or otherwise processing files before uploading them to a server.
@important This method will be called on a non-main thread.
@param inputPath The file path which is being saved.
@warning This method is time sensitive and should return quickly.
@return The file path in which to publish in place of the original file.
*/
- (NSString*)willPublishFileAtPath:(NSString*)inputPath;
/**
A callback when a site is loaded
This callback allows a plug-in to be notified when a site is loaded.
Name may be nil if a site has just been unloaded.
@param name The name of the site which was opened, may be nil.
@availability Coda 2.5 and later.
*/
- (void)didLoadSiteNamed:(NSString*)name;
@end
/**
@const CodaPluginKeyLoopDidChangeNotification
Notify Coda when the user interface of the plug-in changes.
Post this notification if the top/bottom most views in the plugin user interface change,
so tabbing through the UI will traverse through the plugin correctly.
*/
static NSString* const CodaPluginKeyLoopDidChangeNotification = @"CodaPluginKeyLoopDidChangeNotification";
/**
@const CodaPluginErrorDomain
Domain for generating errors from plug-ins.
*/
static NSString* const CodaPluginErrorDomain = @"CodaPluginErrorDomain";
/**
CodaSidebarViewController
Protocol for Sidebar Plug-in View Controllers.
A protocol the plug-in view controller must implement to be a sidebar plug-in.
@availability Coda 2.5 and later.
*/
@protocol CodaSidebarViewController <NSObject>
@optional
/**
A callback when the plug-in should unload the sidebar view.
A sidebar should do whatever clean up is necessary when this method is called.
*/
- (void)unloadView;
@end
/**
CodaSidebarPlugIn