File tree Expand file tree Collapse file tree 2 files changed +9
-9
lines changed
src/main/java/com/imgbuffersave Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change 11cmake_minimum_required (VERSION 3.4.1)
2- project (saveimagetogallery )
2+ project (imgbuffersave )
33
44set (CMAKE_VERBOSE_MAKEFILE ON )
55set (CMAKE_CXX_STANDARD 17)
66
77
8- add_library (saveimagetogallery SHARED
8+ add_library (imgbuffersave SHARED
99 cpp-adapter.cpp
1010)
1111
@@ -15,7 +15,7 @@ find_package(ReactAndroid REQUIRED CONFIG)
1515find_package (fbjni REQUIRED CONFIG)
1616
1717target_include_directories (
18- saveimagetogallery PRIVATE
18+ imgbuffersave PRIVATE
1919 "${NODE_MODULES_DIR} /react-native/React"
2020 "${NODE_MODULES_DIR} /react-native/React/Base"
2121 "${NODE_MODULES_DIR} /react-native/ReactCommon"
@@ -25,7 +25,7 @@ target_include_directories(
2525 "${NODE_MODULES_DIR} /react-native/ReactCommon/runtimeexecutor"
2626)
2727
28- target_link_libraries (saveimagetogallery
28+ target_link_libraries (imgbuffersave
2929 ReactAndroid::jsi
3030 log
3131 ReactAndroid::reactnative
Original file line number Diff line number Diff line change @@ -11,19 +11,19 @@ import kotlinx.coroutines.CoroutineScope
1111import kotlinx.coroutines.Dispatchers
1212import kotlinx.coroutines.launch
1313
14- @ReactModule(name = ImgBufferSaveModule . NAME )
15- class ImgBufferSaveModule ( reactContext : ReactApplicationContext ) :
16- NativeImgBufferSaveSpec (reactContext ) {
14+ @OptIn( FrameworkAPI :: class )
15+ class ImgBufferSaveModule internal constructor( val context : ReactApplicationContext ) :
16+ ReactContextBaseJavaModule (context ) {
1717
1818 companion object {
1919
2020 const val NAME = " ImgBufferSave"
2121
2222 init {
23- System .loadLibrary(" saveimagetogallery " )
23+ System .loadLibrary(" imgbuffersave " )
2424 }
2525
26- lateinit var instance: SaveImageToGalleryModule private set
26+ lateinit var instance: ImgBufferSaveModule private set
2727
2828
2929 @OptIn(FrameworkAPI ::class )
You can’t perform that action at this time.
0 commit comments