Facebook的LoginActivity未正确显示 [英] Facebook LoginActivity is not shown properly

查看:137
本文介绍了Facebook的LoginActivity未正确显示的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个使用Facebook登录的应用程序。我有FacebookSDK我用com.facebook.LoginActivity。

I have an application that uses Facebook login. I have the FacebookSDK and I use com.facebook.LoginActivity.

问题是,在10粒没有正确显示的softkeybord显示时,我使用的活性三星Galaxy Tab 2(10.1)(OS 4.0.2)。

The problem is that on 10" tablets the activity is not shown properly when the softkeybord is shown. I'm using a Samsung Galaxy Tab 2 (10.1) (OS 4.0.2).

这是我点击一项的EditText在Facebook的LoginActivity后看到:

This is what I see after clicking on one EditText in the Facebook LoginActivity:

在清单文件我有:

<activity
    android:name="com.facebook.LoginActivity"
    android:windowSoftInputMode="adjustResize"
    android:theme="@android:style/Theme.Translucent.NoTitleBar"
    android:label="@string/app_name" >
</activity>

是其他任何人有这个问题吗? 使用LoginActivity没有任何人有问题?

Is anyone else having this problem too? Is anyone using LoginActivity without having problems?

还有什么我需要做什么?

Is there anything else I need to do?

为什么没有Facebook的活动采取全屏?

And why does not the Facebook activity take the full screen ?

推荐答案

快速修复将要求您修改SDK code。

The quick fix will require you to modify the SDK code.

看在WebDialog.java文件,在OnCreate()方法中,super.onCreate()调用后,补充一点:

Look in the WebDialog.java file, in the onCreate() method, after the super.onCreate() call, add this:

getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_ADJUST_PAN);

这将平移软键盘在该对话框的顶部。如果这还不够,那么你可能想玩弄于getMargins边缘()方法。在最坏的情况下,你可以有getMargins返回:

This will pan the soft keyboard over top of the dialog. If that's still not enough, then you might want to play around with the margins in the getMargins() method. In the worst case, you can just have getMargins return:

return new Pair<Integer, Integer>(1, 1);

这篇关于Facebook的LoginActivity未正确显示的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆