Using facebook FriendPickerFragment to find friends with the same application

On the Facebook SDK page, under the “What's New in Facebook SDK 3.0 for Android” section, the “Ready to Use User Interfaces” section, it says: “Friend Picker allows people to tag friends in an Open Graph action or find other people who installed your app . " This is very useful, but there is no information on the FriendPickerFragment links page about what information to include in the Bundle arg for more configuration information. I am working on an Android game, and I want to allow users to run the game with other USERS who are also friends on Facebook but cannot figure out how to get a list of friends with the same installed application. Does anyone know what arguments can be passed to FriendPickerFragment to get a list of other users of the application? Thank you for your attention in advance, please let me know if additional information is required to make this issue more relevant / make more sense.

+4
source share
4 answers
friendPickerFragment.setFilter(new GraphObjectFilter<GraphUser>() { @Override public boolean includeItem(GraphUser graphObject) { if(graphObject.asMap().containsKey("installed") && (Boolean) graphObject.asMap().get("installed")) return false; else{ return true; } } }); 
+2
source

Check out the sample BooleanOG application that comes with the SDK. It shows an example of how to filter results based on friends with the application you installed.

+3
source

By default, FriendPickerFragment displays a list of friends who installed your application. You can change the display list defining the type (setFriendPickerType ()).

+1
source

Facebook Accounts API does it for you

The list is sorted in descending order by grade value, so it first returns friends with the highest scores.


RF: API Points

0
source

All Articles