Support erasing with stylus button (#286)
This commit is contained in:
parent
d7a9cae9e1
commit
88c7fa7b5c
3 changed files with 11 additions and 2 deletions
|
|
@ -539,6 +539,7 @@ internal fun PdfPageComposable(
|
|||
isActivePage: Boolean = true,
|
||||
isBubbleZoomModeActive: Boolean = false,
|
||||
isStylusOnlyMode: Boolean = false,
|
||||
stylusButtonHovering: Boolean = false,
|
||||
isAutoScrollPlaying: Boolean = false,
|
||||
isHighlighterSnapEnabled: Boolean = false,
|
||||
userHighlights: List<PdfUserHighlight> = emptyList(),
|
||||
|
|
@ -3335,7 +3336,7 @@ internal fun PdfPageComposable(
|
|||
"Page $pageIndex | Type: ${down.type} | isPrimary: ${buttons.isPrimaryPressed} | isSecondary: ${buttons.isSecondaryPressed} | isTertiary: ${buttons.isTertiaryPressed} | buttonsString: $buttons"
|
||||
)
|
||||
|
||||
val isEraserOverride = down.type == PointerType.Eraser || (down.type == PointerType.Stylus && currentEvent.buttons.isSecondaryPressed)
|
||||
val isEraserOverride = down.type == PointerType.Eraser || (down.type == PointerType.Stylus && (currentEvent.buttons.isSecondaryPressed || currentEvent.buttons.isPrimaryPressed || stylusButtonHovering))
|
||||
isStylusEraserOverride = isEraserOverride
|
||||
|
||||
val dragPointerId = down.id
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue