diff --git a/app/src/main/java/org/ntlab/acanthus_client/views/userpage/followFollower/FollowFollowerActivity.java b/app/src/main/java/org/ntlab/acanthus_client/views/userpage/followFollower/FollowFollowerActivity.java index 1ecd46d..53ebd6a 100644 --- a/app/src/main/java/org/ntlab/acanthus_client/views/userpage/followFollower/FollowFollowerActivity.java +++ b/app/src/main/java/org/ntlab/acanthus_client/views/userpage/followFollower/FollowFollowerActivity.java @@ -2,6 +2,7 @@ import androidx.appcompat.app.AppCompatActivity; import androidx.fragment.app.FragmentActivity; +import androidx.lifecycle.ViewModelProvider; import androidx.navigation.NavController; import androidx.navigation.Navigation; import androidx.navigation.ui.AppBarConfiguration; @@ -9,30 +10,41 @@ import androidx.viewpager2.adapter.FragmentStateAdapter; import androidx.viewpager2.widget.ViewPager2; +import android.content.Intent; import android.os.Bundle; import android.view.View; +import android.widget.TextView; import com.google.android.material.bottomnavigation.BottomNavigationView; import com.google.android.material.tabs.TabLayout; import com.google.android.material.tabs.TabLayoutMediator; +import org.ntlab.acanthus_client.Acanthus; import org.ntlab.acanthus_client.R; import org.ntlab.acanthus_client.databinding.ActivityFollowFollowerBinding; import org.ntlab.acanthus_client.databinding.ActivityMainBinding; +import org.ntlab.acanthus_client.databinding.FragmentFollowerListBinding; +import org.ntlab.acanthus_client.databinding.FragmentMypageBinding; public class FollowFollowerActivity extends AppCompatActivity { private ViewPager2 pager; private FragmentStateAdapter adapter; + private String uname = "a"; private String[] tabText = {"フォロー", "フォロワー"}; private int currentPage; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); - setTitle( "username" ); setContentView(R.layout.activity_follow_follower); + // ユーザーネームを取得 + Acanthus acanthus = (Acanthus) getApplication(); + uname = acanthus.getPreferenceName(); + + setTitle(uname); + pager = findViewById(R.id.pager); adapter = new FollowFollowerAdapter(this);