osx - Drag "functionality" from within a Mac App window onto the dock -
i have mac app , need able drag , drop "functionality" within app onto main application dock. when user later clicks dock icon, should launch of bundled applications. how can implement that?
i know how create new dock icons using terminal script, stuck part need animate icon drag app window , onto dock.
by looks of it, need initiate drag-and-drop operation file url of bundled application. dock automatically accept application urls.
nsview has convenience method performing file drag operations:
@implementation myview - (void)mousedown:(nsevent*)theevent { [self dragfile:@"/applications/itunes.app" fromrect:self.bounds slideback:yes event:theevent]; } @end see dragging files reference further info.
Comments
Post a Comment