Re: DnD International No symbol
Sorry to rehash an old thread, but just trying this as stated doesn't work for me. Once I set the cursor in this fashion it never changes to what it should do when a valid drag operation is returned. I should point out that I'm linking against the 10.5 SDK though and testing for this method using -respondsToSelector: (which therefore only works on 10.6 anyway). Could that have anything to do with it? Otherwise I need to know a way to turn off this cursor when necessary so that the drag system can do its thing correctly as normal. --Graham On 18/06/2010, at 8:48 AM, Corbin Dunn wrote: > > On Jun 16, 2010, at 7:19 PM, Tony Romano wrote: > >> Hmm... I'm returning the NSDragOperationNone now, all I get is an image of >> what is being dragged no other symbol and the outlineview won't accept the >> drop which is correct. When I have a valid selection, I get the other >> symbol for copy(green circle with plus sign), or for Move, the outlineview >> highlights the drop point. > > Call: > [[NSCursor operationNotAllowedCursor] set]; > before returning NSDragOperationNone. > > corbin > > ___ > > Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) > > Please do not post admin requests or moderator comments to the list. > Contact the moderators at cocoa-dev-admins(at)lists.apple.com > > Help/Unsubscribe/Update your Subscription: > http://lists.apple.com/mailman/options/cocoa-dev/graham.cox%40bigpond.com > > This email sent to graham@bigpond.com ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: DnD International No symbol
> On Wed, Jun 16, 2010 at 7:19 PM, Tony Romano wrote: >> Hmm... I'm returning the NSDragOperationNone now, all I get is an image of >> what is being dragged no other symbol and the outlineview won't accept the >> drop which is correct. When I have a valid selection, I get the other >> symbol for copy(green circle with plus sign), or for Move, the outlineview >> highlights the drop point. > > Right, that's what I would expect. Cocoa doesn't distinguish between > "can't drop" and "can drop" by changing the cursor. I don't know about that. Consider trying to drag and drop a file onto a read-only disk image in the finder... you get the "no smoking" symbol cursor.___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: DnD International No symbol
By 'where' I meant, Cocoa APIs or Documentation. Sorry should have been more clear about that. The docs definitely need an update on the new cursor, the text description is there but the cursor is missing from the table which you may think there aren't anymore defined other that what's in the table. That's a clear doc bug which I will file. -Tony On Jun 17, 2010, at 9:01 PM, Andrew Merenbach wrote: > I think one possible explanation for the lack of cursor changing with > NSDragOperationNone is that [NSCursor operationNotAllowedCursor] appears to > have been introduced in 10.6 (Snow Leopard), so this was not a possibility in > the paradigm contained in prior versions of the API. > > To file an enhancement request, you can go to: http://bugreport.apple.com. > Unless you know that already, and just meant how to phrase it--in that case, > I'm unsure as to the best way and should probably leave it to other > CocoaDevvers to assist you. > > Cheers, > Andrew > > On Jun 17, 2010, at 5:27 PM, Tony Romano wrote: > >> Gotta Love Corbin, works as advertised. >> >> What's inconsistent here though is the copy operation changes the icon so >> you would think the NSDragOperationNone(or better yet the non-existent >> NSDragOperationNotAllowed) would change it as well. OR the return operation >> would not change any of them and then the user knows to use NSCursor through >> clear documentation outlining DnD and cursor management. LOL, i'm not sure >> where to file a enhancement request. >> >> Anyways, thanks >> >> -Tony >> >> On Jun 17, 2010, at 3:48 PM, Corbin Dunn wrote: >> >>> >>> On Jun 16, 2010, at 7:19 PM, Tony Romano wrote: >>> Hmm... I'm returning the NSDragOperationNone now, all I get is an image of what is being dragged no other symbol and the outlineview won't accept the drop which is correct. When I have a valid selection, I get the other symbol for copy(green circle with plus sign), or for Move, the outlineview highlights the drop point. >>> >>> Call: >>> [[NSCursor operationNotAllowedCursor] set]; >>> before returning NSDragOperationNone. >>> >>> corbin >>> >>> >> >> -Tony >> >> ___ >> >> Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) >> >> Please do not post admin requests or moderator comments to the list. >> Contact the moderators at cocoa-dev-admins(at)lists.apple.com >> >> Help/Unsubscribe/Update your Subscription: >> http://lists.apple.com/mailman/options/cocoa-dev/merenbach%40ucla.edu >> >> This email sent to merenb...@ucla.edu > > -Tony ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: DnD International No symbol
I think one possible explanation for the lack of cursor changing with NSDragOperationNone is that [NSCursor operationNotAllowedCursor] appears to have been introduced in 10.6 (Snow Leopard), so this was not a possibility in the paradigm contained in prior versions of the API. To file an enhancement request, you can go to: http://bugreport.apple.com. Unless you know that already, and just meant how to phrase it--in that case, I'm unsure as to the best way and should probably leave it to other CocoaDevvers to assist you. Cheers, Andrew On Jun 17, 2010, at 5:27 PM, Tony Romano wrote: > Gotta Love Corbin, works as advertised. > > What's inconsistent here though is the copy operation changes the icon so you > would think the NSDragOperationNone(or better yet the non-existent > NSDragOperationNotAllowed) would change it as well. OR the return operation > would not change any of them and then the user knows to use NSCursor through > clear documentation outlining DnD and cursor management. LOL, i'm not sure > where to file a enhancement request. > > Anyways, thanks > > -Tony > > On Jun 17, 2010, at 3:48 PM, Corbin Dunn wrote: > >> >> On Jun 16, 2010, at 7:19 PM, Tony Romano wrote: >> >>> Hmm... I'm returning the NSDragOperationNone now, all I get is an image of >>> what is being dragged no other symbol and the outlineview won't accept the >>> drop which is correct. When I have a valid selection, I get the other >>> symbol for copy(green circle with plus sign), or for Move, the outlineview >>> highlights the drop point. >> >> Call: >> [[NSCursor operationNotAllowedCursor] set]; >> before returning NSDragOperationNone. >> >> corbin >> >> > > -Tony > > ___ > > Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) > > Please do not post admin requests or moderator comments to the list. > Contact the moderators at cocoa-dev-admins(at)lists.apple.com > > Help/Unsubscribe/Update your Subscription: > http://lists.apple.com/mailman/options/cocoa-dev/merenbach%40ucla.edu > > This email sent to merenb...@ucla.edu ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: DnD International No symbol
Gotta Love Corbin, works as advertised. What's inconsistent here though is the copy operation changes the icon so you would think the NSDragOperationNone(or better yet the non-existent NSDragOperationNotAllowed) would change it as well. OR the return operation would not change any of them and then the user knows to use NSCursor through clear documentation outlining DnD and cursor management. LOL, i'm not sure where to file a enhancement request. Anyways, thanks -Tony On Jun 17, 2010, at 3:48 PM, Corbin Dunn wrote: > > On Jun 16, 2010, at 7:19 PM, Tony Romano wrote: > >> Hmm... I'm returning the NSDragOperationNone now, all I get is an image of >> what is being dragged no other symbol and the outlineview won't accept the >> drop which is correct. When I have a valid selection, I get the other >> symbol for copy(green circle with plus sign), or for Move, the outlineview >> highlights the drop point. > > Call: > [[NSCursor operationNotAllowedCursor] set]; > before returning NSDragOperationNone. > > corbin > > -Tony ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: DnD International No symbol
On Jun 16, 2010, at 7:19 PM, Tony Romano wrote: > Hmm... I'm returning the NSDragOperationNone now, all I get is an image of > what is being dragged no other symbol and the outlineview won't accept the > drop which is correct. When I have a valid selection, I get the other symbol > for copy(green circle with plus sign), or for Move, the outlineview > highlights the drop point. Call: [[NSCursor operationNotAllowedCursor] set]; before returning NSDragOperationNone. corbin ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: DnD International No symbol
The common behavior is that it will not drop and will (very quickly) snap back to origin. On Jun 16, 2010, at 9:19 PM, Tony Romano wrote: > Hmm... I'm returning the NSDragOperationNone now, all I get is an image of > what is being dragged no other symbol and the outlineview won't accept the > drop which is correct. When I have a valid selection, I get the other symbol > for copy(green circle with plus sign), or for Move, the outlineview > highlights the drop point. > > -Tony > > On Jun 16, 2010, at 7:11 PM, Kyle Sluder wrote: > >> On Wed, Jun 16, 2010 at 6:55 PM, Tony Romano wrote: >>> Briefly, in a DnD operation all the nodes selected need to be siblings of >>> each other. During validateDrop I check for this and it calculates it just >>> fine. However, I need to set the DnD image to something indicating this is >>> not allowed, I thought using the International NO symbol made sense but it >>> is not defined as one of the NSDragOperation... flags. So I am thinking >>> either this is not HIG compliant or it is and I just need to supply my own. >>> I know I have seen other apps do it but it's doesn't been it's HIG >>> compliant. >> >> I believe that's a Carbon thing; there is also no standard "not >> allowed" cursor. Just return NSDragOperationNone and let the >> slide-back animation do its job. >> >> If you want to explain to the user why they can't drag, maybe you >> could use a tooltip? Query the draggingInfo in -draggingUpdated: and >> use it to position a borderless window that describes why the >> operation can't be done. >> >> --Kyle Sluder >> > > -Tony > > ___ > > Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) > > Please do not post admin requests or moderator comments to the list. > Contact the moderators at cocoa-dev-admins(at)lists.apple.com > > Help/Unsubscribe/Update your Subscription: > http://lists.apple.com/mailman/options/cocoa-dev/jjoyce%40apple.com > > This email sent to jjo...@apple.com ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: DnD International No symbol
On Wed, Jun 16, 2010 at 7:19 PM, Tony Romano wrote: > Hmm... I'm returning the NSDragOperationNone now, all I get is an image of > what is being dragged no other symbol and the outlineview won't accept the > drop which is correct. When I have a valid selection, I get the other symbol > for copy(green circle with plus sign), or for Move, the outlineview > highlights the drop point. Right, that's what I would expect. Cocoa doesn't distinguish between "can't drop" and "can drop" by changing the cursor. You might consider this a bug, in which case you should file an enhancement request. In the meantime, if the conditions under which users are permitted to drop things are complex or obscure, you might want to use the method I described before. Or you can use the same technique to put a little "no" icon next to the cursor, but I imagine it would take a bit of work to deduce where to put the icon so as to avoid the cursor image. You can't hardcode it in case the cursor has a custom image. --Kyle Sluder ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: DnD International No symbol
Hmm... I'm returning the NSDragOperationNone now, all I get is an image of what is being dragged no other symbol and the outlineview won't accept the drop which is correct. When I have a valid selection, I get the other symbol for copy(green circle with plus sign), or for Move, the outlineview highlights the drop point. -Tony On Jun 16, 2010, at 7:11 PM, Kyle Sluder wrote: > On Wed, Jun 16, 2010 at 6:55 PM, Tony Romano wrote: >> Briefly, in a DnD operation all the nodes selected need to be siblings of >> each other. During validateDrop I check for this and it calculates it just >> fine. However, I need to set the DnD image to something indicating this is >> not allowed, I thought using the International NO symbol made sense but it >> is not defined as one of the NSDragOperation... flags. So I am thinking >> either this is not HIG compliant or it is and I just need to supply my own. >> I know I have seen other apps do it but it's doesn't been it's HIG compliant. > > I believe that's a Carbon thing; there is also no standard "not > allowed" cursor. Just return NSDragOperationNone and let the > slide-back animation do its job. > > If you want to explain to the user why they can't drag, maybe you > could use a tooltip? Query the draggingInfo in -draggingUpdated: and > use it to position a borderless window that describes why the > operation can't be done. > > --Kyle Sluder > -Tony ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: DnD International No symbol
On Wed, Jun 16, 2010 at 6:55 PM, Tony Romano wrote: > Briefly, in a DnD operation all the nodes selected need to be siblings of > each other. During validateDrop I check for this and it calculates it just > fine. However, I need to set the DnD image to something indicating this is > not allowed, I thought using the International NO symbol made sense but it is > not defined as one of the NSDragOperation... flags. So I am thinking either > this is not HIG compliant or it is and I just need to supply my own. I know > I have seen other apps do it but it's doesn't been it's HIG compliant. I believe that's a Carbon thing; there is also no standard "not allowed" cursor. Just return NSDragOperationNone and let the slide-back animation do its job. If you want to explain to the user why they can't drag, maybe you could use a tooltip? Query the draggingInfo in -draggingUpdated: and use it to position a borderless window that describes why the operation can't be done. --Kyle Sluder ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com