Skip to content

Commit

Permalink
Merge pull request #2680 from mikepenz/feature/remove_experimental_flag
Browse files Browse the repository at this point in the history
Nav API considered stable
  • Loading branch information
mikepenz committed Nov 23, 2020
2 parents 9fd756a + 75d2e17 commit 8f3f82b
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,11 @@ import com.mikepenz.materialdrawer.model.DividerDrawerItem
import com.mikepenz.materialdrawer.model.NavigationDrawerItem
import com.mikepenz.materialdrawer.model.PrimaryDrawerItem
import com.mikepenz.materialdrawer.model.interfaces.withName
import com.mikepenz.materialdrawer.util.ExperimentalNavController
import com.mikepenz.materialdrawer.util.addItems
import com.mikepenz.materialdrawer.util.addStickyDrawerItems
import com.mikepenz.materialdrawer.util.setupWithNavController
import kotlinx.android.synthetic.main.activity_sample.*

@UseExperimental(ExperimentalNavController::class)
class NavControllerActivity : AppCompatActivity() {

override fun onCreate(savedInstanceState: Bundle?) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ import androidx.navigation.NavOptions
import androidx.recyclerview.widget.RecyclerView
import com.mikepenz.materialdrawer.R
import com.mikepenz.materialdrawer.model.interfaces.IDrawerItem
import com.mikepenz.materialdrawer.util.ExperimentalNavController

@ExperimentalNavController
class NavigationDrawerItem<VH : RecyclerView.ViewHolder>(
@IdRes val resId: Int,
val item: IDrawerItem<VH>,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,6 @@ import com.mikepenz.materialdrawer.model.interfaces.IDrawerItem
import com.mikepenz.materialdrawer.widget.MaterialDrawerSliderView
import java.lang.ref.WeakReference

// Notify user that the DSL is currently experimental
@Experimental(level = Experimental.Level.WARNING)
annotation class ExperimentalNavController

/**
* Sets up a {@link Drawer} for use with a {@link NavController}.
* The selected item in the Drawer will automatically be updated when the destination
Expand All @@ -21,15 +17,13 @@ annotation class ExperimentalNavController
* @param navController The NavController that hosts the destination.
* @return
*/
@ExperimentalNavController
fun MaterialDrawerSliderView.setupWithNavController(navController: NavController) {
DrawerNavigationUI.setupWithNavController(this, navController)
}

/**
* Created by petretiandrea on 19.07.19.
*/
@ExperimentalNavController
object DrawerNavigationUI {

/**
Expand Down

0 comments on commit 8f3f82b

Please sign in to comment.