当前位置: 首页>>代码示例>>Java>>正文


Java ProfilePictureView类代码示例

本文整理汇总了Java中com.facebook.login.widget.ProfilePictureView的典型用法代码示例。如果您正苦于以下问题:Java ProfilePictureView类的具体用法?Java ProfilePictureView怎么用?Java ProfilePictureView使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


ProfilePictureView类属于com.facebook.login.widget包,在下文中一共展示了ProfilePictureView类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: CustomViewHolder

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
public CustomViewHolder(View itemView) {
    super(itemView);
    this.txtView = (TextView) itemView.findViewById(R.id.listText);
    this.txtLocate = (TextView) itemView.findViewById(R.id.listLocate);
    this.txtName = (TextView) itemView.findViewById(R.id.name);
    this.proFile = (ProfilePictureView) itemView.findViewById(R.id.profile_picturefeed);
    this.smile = (ImageButton) itemView.findViewById(R.id.smile);
    this.sad = (ImageButton) itemView.findViewById(R.id.sad);
    this.comment = (ImageButton) itemView.findViewById(R.id.commentbtn);
    this.smileCount = (TextView) itemView.findViewById(R.id.smilecount);
    this.sadCount = (TextView) itemView.findViewById(R.id.sadcount);
    this.pic = (ImageView) itemView.findViewById(R.id.imagetest);
    this.commentView = (RecyclerView) itemView.findViewById(R.id.recycler_viewcomment);
    this.proFileCom = (ProfilePictureView) itemView.findViewById(R.id.profile_picturecommentself);
    this.send = (Button) itemView.findViewById(R.id.commentsendbtn);
    this.txtComment = (EditText) itemView.findViewById(R.id.commenttext);
    this.rl = (RelativeLayout) itemView.findViewById(R.id.relative);
    this.commentCount = (TextView) itemView.findViewById(R.id.commentcount);
    this.setting = (ImageButton) itemView.findViewById(R.id.setting);
    this.time = (TextView) itemView.findViewById(R.id.time);
}
 
开发者ID:CE-KMITL-OOAD-2015,项目名称:make-me-smile,代码行数:22,代码来源:CustomViewHolder.java

示例2: onCreate

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.addproject_layout);

    Intent intent = getIntent();
    String name = intent.getExtras().getString("name");
    String email = intent.getExtras().getString("email");
    String userId = intent.getExtras().getString("userid");


    profilePictureView = (ProfilePictureView) findViewById(R.id.friendProfilePicture);
    profilePictureView.setProfileId(userId);
    txtName = (TextView)findViewById(R.id.textViewName);
    txtName.setText(name);
    txtEmail = (TextView)findViewById(R.id.textViewEmail);
    txtEmail.setText(email);

    btnProject = (Button)findViewById(R.id.buttonProject);

    btnProject.setOnClickListener(new View.OnClickListener() {
        @Override
        public void onClick(View v) {

            Intent createIntent = new Intent(AddProject.this, CreateProject.class);
            startActivity(createIntent);
        }

    });

}
 
开发者ID:AswinVasudevan21,项目名称:MobileProjectManagement,代码行数:32,代码来源:AddProject.java

示例3: initComponents

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
/**
 * Initialises buttons on this xml with their respective elements. Updates facebook profile if
 * changed because the Profile is loaded asynchronously so it returns null right after log in.
 */
private void initComponents() {
    playButton = (Button) findViewById(R.id.playButton);
    solveButton = (Button) findViewById(R.id.solveButton);
    logOutButton = (Button) findViewById(R.id.log_out_button);
    welcomeView = (TextView) findViewById(R.id.user_name);
    profilePictureView = (ProfilePictureView) findViewById(R.id.profile_picture);

    // Checks if the profile is changed and hence current profile is null. If so updates the profile
    if (Profile.getCurrentProfile() != null) {
        welcomeView.setText(WELCOME_TAG + Profile.getCurrentProfile().getName());
        profilePictureView.setProfileId(Profile.getCurrentProfile().getId());
    } else {
        ProfileTracker profileTracker = new ProfileTracker() {
            @Override
            protected void onCurrentProfileChanged(Profile oldProfile, Profile currentProfile) {
                this.stopTracking();
                Profile.setCurrentProfile(currentProfile);
                profilePictureView.setProfileId(currentProfile.getId());
                welcomeView.setText(WELCOME_TAG + currentProfile.getName());
            }
        };
        profileTracker.startTracking();
    }

    intentPlay = new Intent(this, PlayActivity.class);
    intentSolve = new Intent(this, SolveActivity.class);
    intentLogIn = new Intent(this, LogInActivity.class);
}
 
开发者ID:ayushr2,项目名称:PlaySoduko,代码行数:33,代码来源:HomeActivity.java

示例4: getView

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
public View getView(int position, View convertView, ViewGroup parent) {
    FbPage page = getItem(position);
    if (convertView == null) {
        convertView = LayoutInflater.from(getContext()).inflate(R.layout.item_page, parent, false);
    }

    TextView tvName = (TextView) convertView.findViewById(R.id.page_name_tv);
    ProfilePictureView pagePicture = (ProfilePictureView) convertView.findViewById(R.id.pageItemPicture);
    tvName.setText(page.getName());
    pagePicture.setProfileId(page.getID());
    return convertView;
}
 
开发者ID:mdamis,项目名称:journal,代码行数:14,代码来源:PageAdapter.java

示例5: getView

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
public View getView(int position, View convertView, ViewGroup parent) {
    final FbUserComment comment = getItem(position);

    if (convertView == null) {
        convertView = LayoutInflater.from(getContext()).inflate(R.layout.item_user_feed_comment, parent, false);
    }


    //region init
    comment_tv = (TextView)convertView.findViewById(R.id.user_feed_comment_mess_tv);
    created_tv = (TextView)convertView.findViewById(R.id.user_feed_comment_created_tv);
    profilePictureView = (ProfilePictureView)convertView.findViewById(R.id.user_comment_picture);
    user_name = (TextView)convertView.findViewById(R.id.fb_user_name);
    //endregion init

    //region get mess, user,..
    comment_tv.setText(comment.getMessage());
    created_tv.setText(comment.getCreated_time());
    profilePictureView.setProfileId(comment.getUser());
    GraphRequest request = GraphRequest.newGraphPathRequest(
            AccessToken.getCurrentAccessToken(),
            "/" + comment.getUser(),
            new GraphRequest.Callback() {
                @Override
                public void onCompleted(GraphResponse response) {
                    try {
                        user_name.setText(response.getJSONObject().getString("name"));
                    } catch (JSONException e) {
                        e.printStackTrace();
                    }
                }
            });

    request.executeAsync();
    //endregion get mess, user,..

    return convertView;
}
 
开发者ID:mdamis,项目名称:journal,代码行数:40,代码来源:FbUserFeedCommentAdapter.java

示例6: onCreate

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_scar);
   // Intent i = getIntent();
   //  latit = i.getStringExtra("lati");
  //   longtit = i.getStringExtra("longti");
   // System.out.println(latit + longtit);
    Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
    setSupportActionBar(toolbar);


    DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
    ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(
            this, drawer, toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close);
    drawer.setDrawerListener(toggle);
    toggle.syncState();

    NavigationView navigationView = (NavigationView) findViewById(R.id.nav_view);
    navigationView.setNavigationItemSelectedListener(this);
    View nav_header = LayoutInflater.from(this).inflate(R.layout.nav_header_main, null);
    profile = Profile.getCurrentProfile();
    ((TextView)nav_header.findViewById(R.id.data_ffffffname)).setText(profile.getName());
    ((ProfilePictureView)nav_header.findViewById(R.id.profile_picture)).setProfileId(profile.getId());
    navigationView.addHeaderView(nav_header);

    mSectionsPagerAdapter = new SectionsPagerAdapter(getSupportFragmentManager());
    // Set up the ViewPager with the sections adapter.
    mViewPager = (ViewPager) findViewById(R.id.container);
    mViewPager.setAdapter(mSectionsPagerAdapter);
    tabLayout = (TabLayout) findViewById(R.id.tabs);
    tabLayout.setupWithViewPager(mViewPager);
    new SimpleTask().execute("http://203.151.92.179:8080/getuserprofile?id=" + MemberStatic.getFbID());
}
 
开发者ID:CE-KMITL-OOAD-2015,项目名称:Walk-Ranger,代码行数:35,代码来源:ScarActivity.java

示例7: onCreate

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_bgroup);
    Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
    setSupportActionBar(toolbar);


    DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
    ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(
            this, drawer, toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close);
    drawer.setDrawerListener(toggle);
    toggle.syncState();

    NavigationView navigationView = (NavigationView) findViewById(R.id.nav_view);
    navigationView.setNavigationItemSelectedListener(this);
    View nav_header = LayoutInflater.from(this).inflate(R.layout.nav_header_main, null);
    profile = Profile.getCurrentProfile();
    ((TextView)nav_header.findViewById(R.id.data_ffffffname)).setText(profile.getName());
    ((ProfilePictureView)nav_header.findViewById(R.id.profile_picture)).setProfileId(profile.getId());
    navigationView.addHeaderView(nav_header);

    jG = (Button) findViewById(R.id.joinG);
    cG = (Button) findViewById(R.id.createG);
    join();
    create();
}
 
开发者ID:CE-KMITL-OOAD-2015,项目名称:Walk-Ranger,代码行数:28,代码来源:BgroupActivity.java

示例8: onCreate

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_user);



    Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
    setSupportActionBar(toolbar);

    DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
    ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(
            this, drawer, toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close);
    drawer.setDrawerListener(toggle);
    toggle.syncState();

    NavigationView navigationView = (NavigationView) findViewById(R.id.nav_view);
    navigationView.setNavigationItemSelectedListener(this);
    View nav_header = LayoutInflater.from(this).inflate(R.layout.nav_header_main, null);
    profile = Profile.getCurrentProfile();
    ((TextView)nav_header.findViewById(R.id.data_ffffffname)).setText(profile.getName());
    ((ProfilePictureView)nav_header.findViewById(R.id.profile_picture)).setProfileId(profile.getId());
    navigationView.addHeaderView(nav_header);


    profile = Profile.getCurrentProfile();

    new SimpleTask().execute("http://203.151.92.179:8080/getuserprofile?id=" + MemberStatic.getFbID());
    profileSet( profile);

    rs = (ImageView)findViewById(R.id.reset);
    reset();

}
 
开发者ID:CE-KMITL-OOAD-2015,项目名称:Walk-Ranger,代码行数:35,代码来源:UserActivity.java

示例9: onCreate

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_group);
    Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
    setSupportActionBar(toolbar);


    DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
    ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(
            this, drawer, toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close);
    drawer.setDrawerListener(toggle);
    toggle.syncState();

    NavigationView navigationView = (NavigationView) findViewById(R.id.nav_view);
    navigationView.setNavigationItemSelectedListener(this);
    View nav_header = LayoutInflater.from(this).inflate(R.layout.nav_header_main, null);
    profile = Profile.getCurrentProfile();
    ((TextView)nav_header.findViewById(R.id.data_ffffffname)).setText(profile.getName());
    ((ProfilePictureView)nav_header.findViewById(R.id.profile_picture)).setProfileId(profile.getId());
    navigationView.addHeaderView(nav_header);

    mSectionsPagerAdapter = new SectionsPagerAdapter(getSupportFragmentManager());
    // Set up the ViewPager with the sections adapter.
    mViewPager = (ViewPager) findViewById(R.id.container);
    mViewPager.setAdapter(mSectionsPagerAdapter);
    tabLayout = (TabLayout) findViewById(R.id.tabs);
    tabLayout.setupWithViewPager(mViewPager);

    new SimpleTaskG().execute("http://203.151.92.179:8080/getgroupprofile?id=" + MemberStatic.getFbID());

   // lG = (Button)findViewById(R.id.leaveG);
   // leave();
}
 
开发者ID:CE-KMITL-OOAD-2015,项目名称:Walk-Ranger,代码行数:35,代码来源:GroupActivity.java

示例10: onCreate

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_leagroup);
    Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
    setSupportActionBar(toolbar);


    DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
    ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(
            this, drawer, toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close);
    drawer.setDrawerListener(toggle);
    toggle.syncState();

    NavigationView navigationView = (NavigationView) findViewById(R.id.nav_view);
    navigationView.setNavigationItemSelectedListener(this);
    View nav_header = LayoutInflater.from(this).inflate(R.layout.nav_header_main, null);
    profile = Profile.getCurrentProfile();
    ((TextView)nav_header.findViewById(R.id.data_ffffffname)).setText(profile.getName());
    ((ProfilePictureView)nav_header.findViewById(R.id.profile_picture)).setProfileId(profile.getId());
    navigationView.addHeaderView(nav_header);

    mSectionsPagerAdapter = new SectionsPagerAdapter(getSupportFragmentManager());
    // Set up the ViewPager with the sections adapter.
    mViewPager = (ViewPager) findViewById(R.id.container);
    mViewPager.setAdapter(mSectionsPagerAdapter);
    tabLayout = (TabLayout) findViewById(R.id.tabs);
    tabLayout.setupWithViewPager(mViewPager);

    new SimpleTaskG().execute("http://203.151.92.179:8080/getgroupprofile?id=" + MemberStatic.getFbID());

    //  dG = (Button)findViewById(R.id.disbandG);
    // disband();
}
 
开发者ID:CE-KMITL-OOAD-2015,项目名称:Walk-Ranger,代码行数:35,代码来源:LeagroupActivity.java

示例11: onCreate

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_board);
    Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
    setSupportActionBar(toolbar);

    DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
    ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(
            this, drawer, toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close);
    drawer.setDrawerListener(toggle);
    toggle.syncState();

    NavigationView navigationView = (NavigationView) findViewById(R.id.nav_view);
    navigationView.setNavigationItemSelectedListener(this);
    View nav_header = LayoutInflater.from(this).inflate(R.layout.nav_header_main, null);
    profile = Profile.getCurrentProfile();
    ((TextView)nav_header.findViewById(R.id.data_ffffffname)).setText(profile.getName());
    ((ProfilePictureView)nav_header.findViewById(R.id.profile_picture)).setProfileId(profile.getId());
    navigationView.addHeaderView(nav_header);

    mSectionsPagerAdapter = new SectionsPagerAdapter(getSupportFragmentManager());
    // Set up the ViewPager with the sections adapter.
    mViewPager = (ViewPager) findViewById(R.id.container);
    mViewPager.setAdapter(mSectionsPagerAdapter);
    tabLayout = (TabLayout) findViewById(R.id.tabs);
    tabLayout.setupWithViewPager(mViewPager);
    new SimpleTask().execute("http://203.151.92.179:8080/getuserprofile?id=" + MemberStatic.getFbID());
}
 
开发者ID:CE-KMITL-OOAD-2015,项目名称:Walk-Ranger,代码行数:30,代码来源:BoardActivity.java

示例12: CommentHolder

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
public CommentHolder(View itemView) {
    super(itemView);
    this.pictureView = (ProfilePictureView) itemView.findViewById(R.id.profile_picturecomment);
    this.txtName = (TextView) itemView.findViewById(R.id.namecomment);
    this.txtTime = (TextView) itemView.findViewById(R.id.time);
    this.txtComment = (TextView) itemView.findViewById(R.id.comment);
    this.setting = (ImageButton) itemView.findViewById(R.id.settingcom);
}
 
开发者ID:CE-KMITL-OOAD-2015,项目名称:make-me-smile,代码行数:9,代码来源:CommentHolder.java

示例13: updateSessionInfo

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
private void updateSessionInfo() {
//		GraphRequest meRequest = GraphRequest.newMeRequest(AccessToken.getCurrentAccessToken(), new GraphRequest.GraphJSONObjectCallback() {
//			@Override
//			public void onCompleted(JSONObject object, GraphResponse response) {
//
//			}
//		});
//		Bundle parameters = new Bundle();
//		parameters.putString(FIELDS_PARAM, "id,name,link");
//		meRequest.setParameters(parameters);
//		meRequest.executeAsync();

		Profile profile = Profile.getCurrentProfile();
		if (profile != null) {
			findViewById(R.id.activity_facebook_information_container).setVisibility(View.VISIBLE);
			findViewById(R.id.activity_facebook_login_button).setVisibility(View.GONE);
			ProfilePictureView profilePictureView = (ProfilePictureView) findViewById(R.id.activity_facebook_profile_picture);
			profilePictureView.setProfileId(profile.getId());
			TextView informationTextView = (TextView) findViewById(R.id.activity_facebook_information);
			StringBuilder infoBuilder = new StringBuilder()
				.append("ID: ").append(profile.getId()).append("\n\n")
				.append("Username: ").append(profile.getName()).append("\n\n")
				.append("Full name: ").append(profile.getName()).append("\n\n")
				.append("Composed Name: ").append(
					TextUtils.join(" ",
						new String[]{
							profile.getFirstName(),
							profile.getMiddleName(),
							profile.getLastName()}))
				.append("\n\n");
			informationTextView.setText(infoBuilder.toString());
		} else {
			findViewById(R.id.activity_facebook_information_container).setVisibility(View.GONE);
			findViewById(R.id.activity_facebook_login_button).setVisibility(View.VISIBLE);
		}

	}
 
开发者ID:joaocsousa,项目名称:OAuth,代码行数:38,代码来源:FacebookActivity.java

示例14: onCreateView

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
                         Bundle savedInstanceState) {
    final View view = inflater.inflate(R.layout.fb_page_info, container, false);
    Intent intent = getActivity().getIntent();
    String pageId = intent.getStringExtra("pageId");
    final String pageName = intent.getStringExtra("pageName");
    pagePicture = (ProfilePictureView) view.findViewById(R.id.pagePicture);

    pageName_tv = (TextView)view.findViewById(R.id.pageName);


    pagePicture.setProfileId(pageId);
    pageName_tv.setText(pageName);

    pageAbout(pageId);



    return view;
}
 
开发者ID:mdamis,项目名称:journal,代码行数:22,代码来源:FbPageInfoFragment.java

示例15: onCreate

import com.facebook.login.widget.ProfilePictureView; //导入依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    FacebookSdk.sdkInitialize(this.getApplicationContext());

    callbackManager = CallbackManager.Factory.create();

    LoginManager.getInstance().registerCallback(callbackManager, new FacebookCallback<LoginResult>() {
        @Override
        public void onSuccess(LoginResult loginResult) {
            updateUI();
        }

        @Override
        public void onCancel() {
            updateUI();
        }

        @Override
        public void onError(FacebookException e) {
            updateUI();
        }
    });
    setContentView(R.layout.activity_laun);

    userName = (TextView) findViewById(R.id.user_name);
    profilePicture = (ProfilePictureView) findViewById(R.id.profile_picture);
    profileTracker = new ProfileTracker() {
        @Override
        protected void onCurrentProfileChanged(Profile profile, Profile profile1) {
            updateUI();
        }
    };

    mainMenu = (Button) findViewById(R.id.main_menu);
    mainMenu.setOnClickListener(new View.OnClickListener(){
        @Override
        public void onClick(View V){
            profile = Profile.getCurrentProfile();
            MemberStatic.setFbID(profile.getId());
            new SimpleTask().execute("http://203.151.92.179:8080/fblogin?name="+profile.getFirstName() + "%20" + profile.getLastName() +"&fb-code="+profile.getId());


        }
    });
}
 
开发者ID:CE-KMITL-OOAD-2015,项目名称:Walk-Ranger,代码行数:47,代码来源:LaunActivity.java


注:本文中的com.facebook.login.widget.ProfilePictureView类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。