mirror of
https://github.com/LNH-team/pico-launcher.git
synced 2026-06-02 00:56:55 +02:00
Add touch input support, add fast scrolling support for coverflow display mode, fix use after free bug in banner list mode
This commit is contained in:
34
arm9/source/romBrowser/views/BottomSheetView.cpp
Normal file
34
arm9/source/romBrowser/views/BottomSheetView.cpp
Normal file
@@ -0,0 +1,34 @@
|
||||
#include "common.h"
|
||||
#include "BottomSheetView.h"
|
||||
|
||||
void BottomSheetView::HandlePenDown(const Point& touchPoint, FocusManager& focusManager)
|
||||
{
|
||||
DialogView::HandlePenDown(touchPoint, focusManager);
|
||||
|
||||
if (!GetBounds().Contains(touchPoint))
|
||||
{
|
||||
_oobPenDown = true;
|
||||
}
|
||||
}
|
||||
|
||||
void BottomSheetView::HandlePenMove(const Point& touchPoint, FocusManager& focusManager)
|
||||
{
|
||||
DialogView::HandlePenMove(touchPoint, focusManager);
|
||||
|
||||
if (GetBounds().Contains(touchPoint))
|
||||
{
|
||||
_oobPenDown = false;
|
||||
}
|
||||
}
|
||||
|
||||
void BottomSheetView::HandlePenUp(const Point& lastTouchPoint, FocusManager& focusManager)
|
||||
{
|
||||
DialogView::HandlePenUp(lastTouchPoint, focusManager);
|
||||
|
||||
if (_oobPenDown && !GetBounds().Contains(lastTouchPoint))
|
||||
{
|
||||
Close();
|
||||
}
|
||||
|
||||
_oobPenDown = false;
|
||||
}
|
||||
Reference in New Issue
Block a user