Dockyard > Objective-C Classes > DockyardPlugin
Class Description
Central class for the Dockyard Widget Plugin. DockyardPlugin sets up the preferences instance, controls the list of docks on the reverse side of the widget, and is responsible for the rename, delete, and create actions, as well as providing a beep effect for JavaScript to use.
By
Methods
- createDockWithName:dockTemplate:dashboardTemplate:
+ isSelectorExcludedFromWebScript:
- windowScriptObjectAvailable:
Method Detail
+ (BOOL)isKeyExcludedFromWebScript:(SEL)sel
Forbids the widget from accessing any properties.
isSelectorExcludedFromWebScript:
+ (BOOL)isSelectorExcludedFromWebScript:(SEL)sel
Limits the widget to seven methods: showBackSide, hideBackSide, deleteDocks, createDockWithName:dockTemplate:dashboardTemplate:, and beep.
See also: DockyardPreferences+WebKitAdditions.isSelectorExcludedFromWebScript:
+ (NSString *)webScriptNameForSelector:(SEL)sel
Changes Objective-C selectors into JavaScript method names: deleteDocks: becomes deleteDocks (no colon), and createDockWithName:dockTemplate:dashboardTemplate: becomes createDockWithNameAndFiles.
createDockWithName:dockTemplate:dashboardTemplate:
- (void)createDockWithName:(NSString *)name dockTemplate:(NSString *)dockTemplate dashboardTemplate:(NSString *)dashboardTemplate
Called by the widget when the user clicks the "create" button. First matches up the given template names with the dock files, then calls createDockWithName:fromFile:dashboardFile: on DockyardPreferences.
- (void)deleteDocks:(WebScriptObject *)javascriptIndexArray
Called by the widget when the user clicks the "delete" button. Fetches the selected docks, then calls deleteDocksAtIndexes: on DockyardPreferences.
- (void)hideBackSide
Called when the widget hides the back side. Hides the table of docks.
- (void)showBackSide
Called when the widget shows the back side. Unhides the table of docks.
- (void)updateTables
Forwards the message to the widget to inform it that the list of docks needs updating.
- (void)windowScriptObjectAvailable:(WebScriptObject *)windowScriptObject
When this method is called, DockyardPlugin makes both itself and its instance of DockyardPreferences available in JavaScript.
This page was generated with DocYouMeant, a program created by Belkadan Software