Commit Graph

94 Commits

Author SHA1 Message Date
lynxnb
86364a84a2 Allow content to be drawn behind the navigation bar 2022-11-09 23:07:23 +05:30
lynxnb
f63fdf26c9 Partially revert 'Make all Dialogs use @color/backgroundColor as the background color'
This partially reverts commit 36a1f2a2ec.
2022-11-09 23:07:23 +05:30
lynxnb
cfa5f0e030 Fix OSC alpha not changing on button press 2022-08-20 17:00:40 +02:00
KikiManjaro
3407f6d530 Add OSC opacity adjustment 2022-08-20 13:46:17 +02:00
lynxnb
c4bf92a49f Fix Kotlin compilation errors from incorrect overloading of null-safe types 2022-08-17 12:16:26 +02:00
lynxnb
5b4ca79dc8 Rename Settings Kotlin class to PreferenceSettings
SharedPreferences will be partially swapped out in the future to support per-game settings. In the meantime, make it clear from which class settings are coming from.
2022-07-26 20:16:24 +05:30
PixelyIon
36a7ad06bd Use built-in vibrator by default for controller #0
The vibration device had to be set manually prior which led to it generally not being set at all even though a user might want vibration, this commit fixes that by making controller #0 use the built-in vibrator by default.
2022-04-14 14:14:52 +05:30
lynxnb
08e24915d8 Add support for drawing inside the display cutout areas 2022-04-14 14:14:52 +05:30
PixelyIon
5dea15632c Add Controller Setup Guide
A setup guide for controllers that goes through every available button/stick sequentially and opens up a corresponding dialog to map them.
2022-04-14 14:14:52 +05:30
PixelyIon
e2cae74425 Fix RecyclerView height in CoordinatorLayout for non touch-mode
Any `RecyclerView`s with an app bar in a `CoordinatorLayout` would end up going off-screen due to the layout behavior implementing an offset by using a transform which would not correctly handle focusing on off-screen objects. This has now been fixed by manually adjusting height to be clipped to what is visible on the screen.
2022-04-14 14:14:52 +05:30
PixelyIon
8f0db18624 Fix ControllerActivity Controller Type Change Crash
If the controller type was changed from a type with a larger amount of buttons/axes to one with a fewer amount, a crash would occur due to the transition animation retaining those elements as children yet returning `NO_POSITION` from `getChildAdapterPosition` in `DividerItemDecoration` which was an unhandled case and led to an OOB array access.
2022-04-14 14:14:52 +05:30
PixelyIon
69ef93bfa8 Add Dividers to ControllerActivity's RecyclerView
Dividers after titles were missing in `ControllerActivity` which made it look inconsistent with `SettingsActivity` which did have them. They have now been added by extending `DividerItemDecoration` to be drawn before any `ControllerHeaderItem`.
2021-11-11 20:20:19 +05:30
PixelyIon
36a1f2a2ec Make all Dialogs use @color/backgroundColor as the background color
We wanted the color of the modals used by the dialogs to be the same as our regular background color rather than a lighter grey. This has now been enforced with style attributes in the case of `AlertDialog` and `setBackground` in the case of `BottomSheetDialog`.
2021-11-11 16:34:38 +05:30
lynxnb
df120ab76d Fix unicode characters being turned into emojis for some vendors 2021-11-10 17:41:07 +01:00
PixelyIon
bed9fbf5e7 Fix EmulationActivity.vibrateDevice assert due to null Vibrator
`EmulationActivity.vibrateDevice` would assert when a `null` Vibrator is provided due to one not being set in the controller configuration. This has now been fixed by the code not playing a vibration when a vibration device isn't selected.
2021-11-01 00:28:11 +05:30
PixelyIon
a7548c79a0 Android 12 Support + Update Libraries + Include Khronos Validation Layer
* Fix handling `SA_EXPOSE_TAGBITS` bit being set in Android 12 `sigaction`
* Fix CMake bug using `CMAKE_INTERPROCEDURAL_OPTIMIZATION_RELEASE` when not supported causing `-fuse-ld=gold` to be emitted as a linker flag
* Support using `VIBRATOR_MANAGER_SERVICE` rather than `VIBRATOR_SERVICE` on Android 12
* Optimize Imports for Kotlin code
* Move away from deprecated APIs in Kotlin or explicitly mark where it's not possible
* Update SDK, NDK and libraries
* Enable Gradle Configuration Cache
2021-10-26 10:46:36 +05:30
Willi Ye
bf2e20565f Check if fragment is attached when doing animations 2021-06-17 20:30:22 +05:30
Willi Ye
ce60101989 Filter on screen buttons by controller type 2021-06-17 20:30:22 +05:30
Willi Ye
2ff06d5421 Apply changed layout to all items
* Fix memory leaks
2021-06-17 20:30:22 +05:30
Willi Ye
e50f5a5d72 Make controller layout more preferences like 2021-06-17 20:30:22 +05:30
Willi Ye
8f3390f073 Use activity contracts for callbacks 2021-06-17 20:30:22 +05:30
Willi Ye
479209886b Rework search
* Call search once for all formats
2021-06-17 20:30:22 +05:30
Willi Ye
571e189ecd Make serialVersionUID static
* Some minor cleanup
2021-06-17 20:30:22 +05:30
Willi Ye
dca632d0d8 Correct reset value of global scale 2021-06-17 20:30:22 +05:30
Willi Ye
4b53a3b1a6 Enable full screen on resume
* Fix registering of buttons pairs in OSC with multiple fingers
* Enable OSC by default
* Increased OSC scale by default
2021-06-17 20:30:22 +05:30
Willi Ye
1fae3488ad Add button pairings to allow simultaneous pressing 2021-06-17 20:30:22 +05:30
Willi Ye
696f0c7769 Remove injection in dialog fragments
* Set result code in document activity
2021-06-17 20:30:22 +05:30
Willi Ye
f5d5caf939 Switch to viewbinding and di with hilt 2021-06-17 20:30:22 +05:30
Willi Ye
b12b4df35b Assign recenter setting to osc
* Make handheld/pro controller default for controller id 0
2021-06-17 20:30:22 +05:30
Willi Ye
71ca46fe1a Update dependencies and gradle
* Enable OSC if controller id is 0
* Fix night colors
2021-06-17 20:30:22 +05:30
Willi Ye
9f6a5df5e0 Redesign UI
* Change colors
* Replace toolbar in main activity
* Initial implementation of ViewModel
2021-06-17 20:30:22 +05:30
Willi Ye
f479aeb4ac Add comments 2020-11-12 22:19:55 +05:30
Willi Ye
7526a985fb Use property delegate to handle preferences
* Add option to disable joystick recentering
2020-11-12 22:19:55 +05:30
Willi Ye
5c4aa95da6 Add on screen controls layout edit settings 2020-11-12 22:19:55 +05:30
Willi Ye
22140defae Rewrite adapter to handle any layout 2020-11-12 22:19:55 +05:30
Willi Ye
e023dbbf0a Add joystick press and general clean up 2020-11-12 22:19:55 +05:30
Willi Ye
3057e4b29a Add on screen controls
* Fix missing default constructor for dialog fragments
2020-11-12 22:19:55 +05:30
Willi Ye
4076d84efc
NCA decryption (#99)
* NCA decryption
* Remove unnecessary new lines
* Remove loader error dialog
* Always show ROMs
* Address CRs
* Add subtitle padding in grid mode
2020-09-14 19:23:40 +05:30
◱ PixelyIon
1a58a2e967 Implement Rumble Support for Controllers and Device Vibrators 2020-09-06 15:31:20 +00:00
◱ PixelyIon
ee2fdbdf6a Fix Joy-Con Pair Crash + Implement More HID Service Functions
This fixes a Joy-Con Pair bug which caused a crash when a partner device was set to none while being set as a partner. In addition, the following HID service functions were implemented:
* GetSupportedNpadStyleSet
* ActivateNpadWithRevision
* GetNpadJoyHoldType
* AcquireNpadStyleSetUpdateEventHandle
2020-08-21 11:48:29 +00:00
◱ PixelyIon
6a931b95b0 Implement C++ Support for Controller Configuration
This commit adds support to the C++ end of things for controller configuration. It isn't targeting being 1:1 to HOS for controller assignment but is rather based on intuition of how things should be.
2020-08-21 11:48:29 +00:00
◱ PixelyIon
75d485a9a7 Addition of Controller Configuration UI
This commit adds in the UI for Controller Configuration to Settings, in addition to introducing the storage and loading of aforementioned configurations to a file that can be saved/loaded at runtime. This commit also fixes updating of individual fields in Settings when changed from an external activity.
2020-08-21 11:48:29 +00:00
◱ PixelyIon
5fec7eefd0 Refactor HID Shared Memory
This commit refactors and reorders a lot of the HID Shared Memory from the previous commits to be in line with the rest of the codebase.
2020-08-21 11:48:29 +00:00
Billy Laws
b167abcdb7 Initial Kotlin Input Implementation
This commit contains the Kotlin side of the initial Input implementation, this is based on the work done in the `hid` branch in `bylaws/skyline`.
Co-authored-by: ◱ PixelyIon <pixelyion@protonmail.com>
2020-08-21 11:48:29 +00:00