Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
Native Facebook share — Gideros Forum

Native Facebook share

totebototebo Member
edited August 2014 in Plugins
I've started integrating this plugin:

http://giderosmobile.com/labs/facebook

On iOS it seems to do the authentication through the web browser. Is there support for native sharing like in the attached screenshot?

IMG_0556.PNG
1024 x 768 - 148K
My Gideros games: www.totebo.com

Comments

  • Hi @totebo
    Do you have facebook app installed on your testing device?
    have fun with our games~
    http://www.nightspade.com
  • I used something like this on the plugin :
     
    - (void) fbshare:(const char*)score
    {
      if([SLComposeViewController isAvailableForServiceType:SLServiceTypeFacebook]) {
            SLComposeViewController *controller = [SLComposeViewController composeViewControllerForServiceType:SLServiceTypeFacebook];
     
            [controller setInitialText:[[[NSString alloc] initWithUTF8String:score] autorelease]];
            //[controller addURL:[NSURL URLWithString:@"<a href="http://somewhere.com"]]" rel="nofollow">http://somewhere.com"]]</a>;
            //[controller addImage:[UIImage imageNamed:<a href="https://forum.giderosmobile.com/profile/ball.png" rel="nofollow">@ball.png</a>]];
     
            UIViewController* rootVC = g_getRootViewController();
            [rootVC presentModalViewController:controller animated:YES];
     
            controller.completionHandler = ^(SLComposeViewControllerResult result)
            {
                [rootVC dismissModalViewControllerAnimated:YES];
            };
        }
     
     
    }

    Though, i'm not sure about the "memory alloc" and such at iOS, never learn about that.
    Also can't provide a singular plug-in for this, mine is too messed up with so many things.
Sign In or Register to comment.