[Messages] Fix Messages Fragment crash.

This commit is contained in:
Kuba Szczodrzyński 2020-01-05 14:38:20 +01:00
parent 5e9bd98bba
commit 3f19e5d465

View File

@ -9,7 +9,6 @@ import androidx.fragment.app.FragmentManager
import androidx.fragment.app.FragmentPagerAdapter import androidx.fragment.app.FragmentPagerAdapter
import androidx.viewpager.widget.ViewPager import androidx.viewpager.widget.ViewPager
import com.mikepenz.iconics.typeface.library.community.material.CommunityMaterial import com.mikepenz.iconics.typeface.library.community.material.CommunityMaterial
import org.greenrobot.eventbus.EventBus
import pl.szczodrzynski.edziennik.App import pl.szczodrzynski.edziennik.App
import pl.szczodrzynski.edziennik.MainActivity import pl.szczodrzynski.edziennik.MainActivity
import pl.szczodrzynski.edziennik.R import pl.szczodrzynski.edziennik.R
@ -127,16 +126,6 @@ class MessagesFragment : Fragment() {
}*/ }*/
} }
override fun onStart() {
EventBus.getDefault().register(this)
super.onStart()
}
override fun onStop() {
super.onStop()
EventBus.getDefault().unregister(this)
}
internal class Adapter(manager: FragmentManager) : FragmentPagerAdapter(manager) { internal class Adapter(manager: FragmentManager) : FragmentPagerAdapter(manager) {
private val mFragmentList = ArrayList<Fragment>() private val mFragmentList = ArrayList<Fragment>()
private val mFragmentTitleList = ArrayList<String>() private val mFragmentTitleList = ArrayList<String>()