Prebuilt Polls Screen
Introduction to Polls in Dyte Meetings
In Dyte meetings, participants can engage in polls to gather opinions or make decisions collectively. Polls enhance the interactive nature of meetings, allowing participants to actively express their views. The ability to create, or interact with polls is determined by the polls permissions set in the participant's preset.
Dyte's Prebuilt Polls Screen
Dyte's Android UI Kit provides a prebuilt Polls screen with the following features:
- Displays all created polls if the participant has permission to view them
- Allows participants to vote by selecting a checkbox for their chosen option
- Shows the number of votes each poll option has received
Usage Options
The prebuilt Polls screen is available in two variants:
- DytePollsBottomSheet: Displays the Polls list as a full-screen bottom sheet that can be dismissed by swiping down.
import dyte.io.uikit.screens.polls.DytePollsBottomSheet
val dytePollsBottomSheet = DytePollsBottomSheet()
dytePollsBottomSheet.show(childFragmentManager, TAG)
- DytePollsFragment: Shows the list of ongoing polls inside an Android fragment, providing flexibility to show the Polls UI fullscreen or in a part of the screen along with other UI elements.
<!-- res/layout/meeting_activity.xml -->
<androidx.fragment.app.FragmentContainerView
android:id="@+id/fragment_container_view"
android:layout_width="match_parent"
android:layout_height="match_parent" />
import dyte.io.uikit.screens.polls.DytePollsFragment
val dytePollsFragment = DytePollsFragment()
supportFragmentManager.beginTransaction()
.replace(R.id.fragment_container_view, dytePollsFragment, TAG)
.commit()
Next Steps
In the next guide, we will explore the "Prebuilt Create Poll screen" which allows participants to create polls if they have permission in their preset.