Skip to content

Instantly share code, notes, and snippets.

@jafar260698
Created August 29, 2020 13:22
Show Gist options
  • Save jafar260698/f8a5ee98fdb11617ac3e54f592deb2bf to your computer and use it in GitHub Desktop.
Save jafar260698/f8a5ee98fdb11617ac3e54f592deb2bf to your computer and use it in GitHub Desktop.
class FoodDetailFragment : DialogFragment() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
requireActivity().window.setFlags(WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS, WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS)
setStyle(STYLE_NORMAL, R.style.FullscreenDialogtheme)
}
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View? {
val view:View= inflater.inflate(R.layout.fragment_food_detail, container, false)
// My whole code here
}
override fun onActivityCreated(arg0: Bundle?) {
super.onActivityCreated(arg0)
dialog!!.window!!.attributes.windowAnimations = R.style.DialogAnimation}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment