mercredi 4 mars 2015

Facebook OpenGraphActionDialog ignores the "is user generated image" flag

I'm currently trying to create a FacebookDialog that posts with a local image. I am able to create the dialog with the image and post it, but the "user generated" flag appears to be ignored.


What I'm getting is this:

facebook small image


...when it should look like this:


enter image description here


The NativeAppCallContentProvider has been set in the manifest and the "User Generated Photos" option has been enabled in the Open Graph Action


Here is the code I'm using...



OpenGraphObject ogObject = OpenGraphObject.Factory.createForPost("app:objectName");
ogObject.setTitle("title");
ogObject.setDescription("description");

// Prepare the action
OpenGraphAction ogAction = OpenGraphAction.Factory.createForPost("app:actionName");
ogAction.setProperty("objectName", ogObject);

// Prepare the image
Bitmap imageBitmap = ...
List<Bitmap> photoBitmaps = new ArrayList<>();
photoBitmaps.add(imageBitmap);

FacebookDialog shareDialog = new FacebookDialog.OpenGraphActionDialogBuilder(this, ogAction, "objectName")
.setImageAttachmentsForObject("objectName", photoBitmaps, true) // user generated is set 'true'
.build();
mUiHelper.trackPendingDialogCall(shareDialog.present());


edit:


I ran the Scrumptious sample app from the Facebook SDK and it's the exactly the same. The "user_generated" property is set to "true", but the picture still appears as a thumbnail.


Aucun commentaire:

Enregistrer un commentaire