How to link fragments menus in android studio

0

So guys ... I have an app that works with an activity in sliding tab and I decided to implement a side menu and until it worked out, I just do not know how to link the menus with other activities or fragments ... menu below ...

//===================================================================================

        headerNavigationLeft = new AccountHeader()
                .withActivity(this)
                .withCompactStyle(false)
                .withSavedInstance(savedInstanceState)
                .withHeaderBackground(R.color.colorPrimary)
                .addProfiles(
                        new ProfileDrawerItem().withName("123123 2018").withEmail("[email protected]").withIcon(getResources().getDrawable(R.drawable.icon))
                )
                .build();
        navigationDrawerLeft = new Drawer()
                .withActivity(this)
                .withToolbar(toolbar)
                .withDisplayBelowToolbar(false)
                .withActionBarDrawerToggleAnimated(true)
                .withDrawerGravity(Gravity.LEFT)
                .withSavedInstance(savedInstanceState)
                .withAccountHeader(headerNavigationLeft)
                .withSelectedItem(0)
                .build();

        navigationDrawerLeft.addItem(new PrimaryDrawerItem().withName("Home").withIcon(getResources().getDrawable(R.drawable.ic_home_white_24dp)));
        navigationDrawerLeft.addItem(new PrimaryDrawerItem().withName("MENU 1").withIcon(getResources().getDrawable(R.drawable.ic_explore_white_24dp)));
        navigationDrawerLeft.addItem(new PrimaryDrawerItem().withName("MENU 2 Voluntário").withIcon(getResources().getDrawable(R.drawable.ic_explore_white_24dp)));
        navigationDrawerLeft.addItem(new PrimaryDrawerItem().withName("MENU 3").withIcon(getResources().getDrawable(R.drawable.ic_event_note_white_24dp)));
    }
    
asked by anonymous 12.01.2018 / 11:06

0 answers