2

我从以下链接下载了 facebook 示例代码:https ://github.com/facebook/facebook-android-sdk 。我正在尝试运行该示例代码,并且我在该登录屏幕左角十字图像按钮中获得了登录屏幕。并且当我单击该按钮时,登录屏幕已关闭。我的问题是如何删除交叉图像按钮

4

1 回答 1

2

在这个 SDK 中有一个名为FbDialog.java

在该文件中有名为 MethodCreateCrossImage()

在这个文件中它自己有新的 90 到 95 行号

mContent.addView(mCrossImage, new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));

只需评论此行并忘记授予权限...并取消评论最后评论的行...。

这是权限...

private String[] permissions = { "user_about_me",
    "user_activities", "user_birthday", "user_hometown", "user_likes",
    "user_photos", "user_status", "user_events", "user_groups",
    "user_location", "user_website", "offline_access", "read_mailbox",
    "read_stream", "email", "publish_stream", "user_location",
    "publish_checkins", "user_work_history", "friends_likes",
    "friends_hometown", "friends_birthday", "friends_hometown",
    "friends_location", "friends_photos", "friends_website" };

mFacebook = new Facebook("FaceBookApplicationId");

    mFacebook.authorize(Sample.this, permissions,
            new DialogListener() {
        @Override
        public void onComplete(Bundle values) {
            Toast.makeText(Sample.this, "Facebook Connected", Toast.LENGTH_SHORT).show();
        }

        @Override
        public void onFacebookError(FacebookError e) {
            Toast.makeText(Sample.this, e.getMessage(), Toast.LENGTH_SHORT).show();
        }

        @Override
        public void onError(DialogError e) {
            Toast.makeText(Sample.this, e.getMessage(), Toast.LENGTH_SHORT).show();
        }

        @Override
        public void onCancel() {
            Toast.makeText(Sample.this, "Connection Canceled", Toast.LENGTH_SHORT).show();
        }
    });
于 2012-10-10T10:03:45.067 回答