kennylerma / facebook-actionscript-api

Automatically exported from code.google.com/p/facebook-actionscript-api
0 stars 0 forks source link

viewPort for stageWebView not honored in MobileFacebook.login() #359

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Create a stageWebView
2. Set viewPort
3. Pass it into FacebookMobile.login()

What is the expected output? What do you see instead?
I expect to see the viewPort honored for the stageWebView, that
I passed in, however, the viewPort is set to full screen.

What version of the product are you using? On what operating system?
Flex 4.5.1 / Air 2.6 / deployed on Android.

Please provide any additional information below.

By setting the viewPort only if the webView is null,
in FacebookMobile.as fixed the issue for me:

Original code:
    if (!webView) {
        this.webView = this.createWebView();
    } else {
        this.webView = webView;
        this.webView.stage = this.stageRef;
    }
    this.webView.assignFocus();
    this.webView.viewPort = new Rectangle(0, 0,
             this.stageRef.stageWidth, this.stageRef.stageHeight);

Modified code:
    if (!webView) {
        this.webView = this.createWebView();
        this.webView.viewPort = new Rectangle(0, 0, this.stageRef.stageWidth, this.stageRef.stageHeight);
    } else {
        this.webView = webView;
        this.webView.stage = this.stageRef;
    }
    this.webView.assignFocus();

Regards,
Rajesh

Original issue reported on code.google.com by rajesh.c...@gmail.com on 22 Sep 2011 at 12:34

GoogleCodeExporter commented 9 years ago
Thanks, this fix is in the latest version 1.8

Original comment by edwar...@gmail.com on 11 Oct 2011 at 10:11