Android Week 13

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/20

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

21 Terms

1
New cards

What is the approach Jetpack Compose uses for handling UI and gestures?

A declarative, modular, and coroutine-frinedly approach using modifiers

2
New cards

What is used instead of XML event listeners in Compose?

Gesture detectors and modifiers like pointerInput

3
New cards

What does Modifier.pointerInput do?

Defines custom gesture detectors inside a coroutine scope

4
New cards

What does Modifier.clickable detect?

Click (tap) gestures

5
New cards

What does modifier.draggable detect?

Drag gestures

6
New cards

What does Modifier.scrollable handle?

Scroller interactions

7
New cards

What is Modifier.swipeable used for?

Complex swipe gestures (e.g., bottom sheets, toggles

8
New cards

What key does pointerInput usually take?

Unit or a state key

9
New cards

Name gesture detection APIs used inside pointerInput

awaitPointerEventScope{}, detectTapGestures, detectDragGestures

10
New cards

What does detectTapGestures support?

onTap, onLongPress, and onDoubleTap

11
New cards

What API is used for detecting drag gestures?

detectDragGestures

12
New cards

How do you update drag position in Compose?

Use Offset, remember, and update offset.value inside detectDragGestures

13
New cards

which modifiers handle vertical and horizontal scrolls?

verticalScroll(rememberScrollState()) and horizontalScroll(rememberScrollState())

14
New cards

What is used for efficent scrolling lists in compose?

LazyColumn or LazyRow

15
New cards

What gesture detector handles pinch, zoom, rotate, and pan?

detectTransformGestures

16
New cards

What are transform gestures useful for?

Image zooming, maps, photo editors

17
New cards

What does swipeable require?

A state (rememberSwipeableState), anchors, thresholds, and orientation

18
New cards

Name UI features that use swipeable

Bottom sheets, swipe-to-dismiss, toggle switches

19
New cards

What functions help with nesting gestures?

awaitFirstDown, awaitTouchSlopOrCancellation, consumeAllChanges()

20
New cards

Which modifier helps with nested scroll behaviors?

nestedScroll() and NestedScrollConnection

21
New cards

How do you animate gestures in Compose?

Use Animatable, coroutine launch, and snapTo() inside gesture detectors