Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
￴￴ committed Nov 14, 2024
1 parent 076509d commit fa85799
Show file tree
Hide file tree
Showing 11 changed files with 124 additions and 236 deletions.
12 changes: 3 additions & 9 deletions package/general/.flutter-plugins
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,11 @@ camera=/home/galaxeus/.pub-cache/hosted/pub.dev/camera-0.11.0+2/
camera_android_camerax=/home/galaxeus/.pub-cache/hosted/pub.dev/camera_android_camerax-0.6.9+2/
camera_avfoundation=/home/galaxeus/.pub-cache/hosted/pub.dev/camera_avfoundation-0.9.17+4/
camera_web=/home/galaxeus/.pub-cache/hosted/pub.dev/camera_web-0.3.5/
camera_windows=/home/galaxeus/.pub-cache/hosted/pub.dev/camera_windows-0.2.5/
file_picker=/home/galaxeus/.pub-cache/hosted/pub.dev/file_picker-8.1.3/
camera_windows=/home/galaxeus/.pub-cache/hosted/pub.dev/camera_windows-0.2.6+1/
file_picker=/home/galaxeus/.pub-cache/hosted/pub.dev/file_picker-8.1.4/
flutter_background=/home/galaxeus/.pub-cache/hosted/pub.dev/flutter_background-1.3.0+1/
flutter_plugin_android_lifecycle=/home/galaxeus/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.23/
flutter_tts=/home/galaxeus/.pub-cache/hosted/pub.dev/flutter_tts-4.0.2/
gamepads=/home/galaxeus/.pub-cache/hosted/pub.dev/gamepads-0.1.3/
gamepads_android=/home/galaxeus/.pub-cache/hosted/pub.dev/gamepads_android-0.1.2+1/
gamepads_darwin=/home/galaxeus/.pub-cache/hosted/pub.dev/gamepads_darwin-0.1.2+1/
gamepads_ios=/home/galaxeus/.pub-cache/hosted/pub.dev/gamepads_ios-0.1.2+1/
gamepads_linux=/home/galaxeus/.pub-cache/hosted/pub.dev/gamepads_linux-0.1.1+2/
gamepads_windows=/home/galaxeus/.pub-cache/hosted/pub.dev/gamepads_windows-0.1.1+2/
flutter_tts=/home/galaxeus/.pub-cache/hosted/pub.dev/flutter_tts-4.2.0/
local_auth=/home/galaxeus/.pub-cache/hosted/pub.dev/local_auth-2.3.0/
local_auth_android=/home/galaxeus/.pub-cache/hosted/pub.dev/local_auth_android-1.0.46/
local_auth_darwin=/home/galaxeus/.pub-cache/hosted/pub.dev/local_auth_darwin-1.4.1/
Expand Down
2 changes: 1 addition & 1 deletion package/general/.flutter-plugins-dependencies

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,37 +1,6 @@
package com.example.example

import android.hardware.input.InputManager
import android.os.Handler
import android.view.InputDevice
import android.view.KeyEvent
import android.view.MotionEvent
import io.flutter.embedding.android.FlutterActivity
import org.flame_engine.gamepads_android.GamepadsCompatibleActivity
import io.flutter.embedding.android.FlutterFragmentActivity

class MainActivity: FlutterFragmentActivity(), GamepadsCompatibleActivity {
var keyListener: ((KeyEvent) -> Boolean)? = null
var motionListener: ((MotionEvent) -> Boolean)? = null

override fun dispatchGenericMotionEvent(motionEvent: MotionEvent): Boolean {
return motionListener?.invoke(motionEvent) ?: false
}

override fun dispatchKeyEvent(keyEvent: KeyEvent): Boolean {
return keyListener?.invoke(keyEvent) ?: false
}

override fun registerInputDeviceListener(
listener: InputManager.InputDeviceListener, handler: Handler?) {
val inputManager = getSystemService(INPUT_SERVICE) as InputManager
inputManager.registerInputDeviceListener(listener, null)
}

override fun registerKeyEventHandler(handler: (KeyEvent) -> Boolean) {
keyListener = handler
}

override fun registerMotionEventHandler(handler: (MotionEvent) -> Boolean) {
motionListener = handler
}
class MainActivity: FlutterFragmentActivity() {
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,10 @@

#include "generated_plugin_registrant.h"

#include <gamepads_linux/gamepads_linux_plugin.h>
#include <media_kit_video/media_kit_video_plugin.h>
#include <sim_card_info/sim_card_info_plugin.h>

void fl_register_plugins(FlPluginRegistry* registry) {
g_autoptr(FlPluginRegistrar) gamepads_linux_registrar =
fl_plugin_registry_get_registrar_for_plugin(registry, "GamepadsLinuxPlugin");
gamepads_linux_plugin_register_with_registrar(gamepads_linux_registrar);
g_autoptr(FlPluginRegistrar) media_kit_video_registrar =
fl_plugin_registry_get_registrar_for_plugin(registry, "MediaKitVideoPlugin");
media_kit_video_plugin_register_with_registrar(media_kit_video_registrar);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
#

list(APPEND FLUTTER_PLUGIN_LIST
gamepads_linux
media_kit_video
sim_card_info
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import FlutterMacOS
import Foundation

import flutter_tts
import gamepads_darwin
import local_auth_darwin
import media_kit_video
import package_info_plus
Expand All @@ -17,7 +16,6 @@ import wakelock_plus

func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
FlutterTtsPlugin.register(with: registry.registrar(forPlugin: "FlutterTtsPlugin"))
GamepadsDarwinPlugin.register(with: registry.registrar(forPlugin: "GamepadsDarwinPlugin"))
FLALocalAuthPlugin.register(with: registry.registrar(forPlugin: "FLALocalAuthPlugin"))
MediaKitVideoPlugin.register(with: registry.registrar(forPlugin: "MediaKitVideoPlugin"))
FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@

#include <camera_windows/camera_windows.h>
#include <flutter_tts/flutter_tts_plugin.h>
#include <gamepads_windows/gamepads_windows_plugin_c_api.h>
#include <local_auth_windows/local_auth_plugin.h>
#include <media_kit_video/media_kit_video_plugin_c_api.h>
#include <permission_handler_windows/permission_handler_windows_plugin.h>
Expand All @@ -20,8 +19,6 @@ void RegisterPlugins(flutter::PluginRegistry* registry) {
registry->GetRegistrarForPlugin("CameraWindows"));
FlutterTtsPluginRegisterWithRegistrar(
registry->GetRegistrarForPlugin("FlutterTtsPlugin"));
GamepadsWindowsPluginCApiRegisterWithRegistrar(
registry->GetRegistrarForPlugin("GamepadsWindowsPluginCApi"));
LocalAuthPluginRegisterWithRegistrar(
registry->GetRegistrarForPlugin("LocalAuthPlugin"));
MediaKitVideoPluginCApiRegisterWithRegistrar(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
list(APPEND FLUTTER_PLUGIN_LIST
camera_windows
flutter_tts
gamepads_windows
local_auth_windows
media_kit_video
permission_handler_windows
Expand Down
Loading

0 comments on commit fa85799

Please sign in to comment.