mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-29 15:52:07 +00:00
Bug 364661 - [cocoa] nsDragService::IsDataFlavorSupported should not throw for unsupported data flavors. r=josh, sr=pink.
This commit is contained in:
parent
57f1bf631c
commit
425b7c9aef
@ -101,8 +101,6 @@ interface nsIDragSession : nsISupports
|
||||
|
||||
/**
|
||||
* Check to set if any of the native data on the clipboard matches this data flavor
|
||||
*
|
||||
* @result NS_OK if if the data flavor is supported and, NS_ERROR_FAILURE is it is not
|
||||
*/
|
||||
boolean isDataFlavorSupported ( in string aDataFlavor ) ;
|
||||
|
||||
|
@ -482,8 +482,6 @@ nsDragService::GetData(nsITransferable* aTransferable, PRUint32 aItemIndex)
|
||||
}
|
||||
|
||||
|
||||
// For some reason this is supposed to return NS_ERROR_FAILURE if the flavor is not
|
||||
// present. Might be good to clean up this API quirk some day.
|
||||
NS_IMETHODIMP
|
||||
nsDragService::IsDataFlavorSupported(const char *aDataFlavor, PRBool *_retval)
|
||||
{
|
||||
@ -509,10 +507,7 @@ nsDragService::IsDataFlavorSupported(const char *aDataFlavor, PRBool *_retval)
|
||||
*_retval = PR_TRUE;
|
||||
}
|
||||
|
||||
if (*_retval)
|
||||
return NS_OK;
|
||||
else
|
||||
return NS_ERROR_FAILURE;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user