Fix newInstance

feature/top10
Aurelien Hubert 7 years ago
parent 1dc203fbc2
commit dbaef64e8b
  1. 14
      app/src/main/java/net/pokeranalytics/android/ui/fragment/StatisticDetailsFragment.kt

@ -1,7 +1,5 @@
package net.pokeranalytics.android.ui.fragment package net.pokeranalytics.android.ui.fragment
import android.content.Context
import android.content.Intent
import android.os.Bundle import android.os.Bundle
import android.view.LayoutInflater import android.view.LayoutInflater
import android.view.View import android.view.View
@ -29,9 +27,15 @@ import java.util.*
class StatisticDetailsFragment : PokerAnalyticsFragment() { class StatisticDetailsFragment : PokerAnalyticsFragment() {
companion object { companion object {
fun newInstance(context: Context) {
val intent = Intent(context, StatisticDetailsFragment::class.java) /**
context.startActivity(intent) * Create new instance
*/
fun newInstance(): StatisticDetailsFragment {
val fragment = StatisticDetailsFragment()
val bundle = Bundle()
fragment.arguments = bundle
return fragment
} }
} }

Loading…
Cancel
Save