This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
AppState appReducer(AppState state, action) { | |
return AppState( | |
isLoading: loadingReducer(state.isLoading, action), | |
games: gamesReducer(state.games, action), | |
route: navigationReducer(state.route, action) | |
); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main() => runApp(MyApp()); | |
final GlobalKey<NavigatorState> navigatorKey = new GlobalKey<NavigatorState>(); | |
class MyApp extends StatelessWidget { | |
final store = Store<AppState>(appReducer, | |
initialState: AppState.loading(), | |
middleware: createNavigationMiddleware()); | |
MaterialPageRoute _getRoute(RouteSettings settings) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class AppRoutes { | |
static const home = "/"; | |
static const addGame = "/addGame"; | |
static const history = "/history"; | |
static const money = "/money"; | |
static const profile = "/profile"; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@immutable | |
class AppState { | |
final bool isLoading; | |
final List<Game> games; | |
final List<String> route; | |
... | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
external override fun cropSelectedArea(bitmap: Bitmap, points: FloatArray): Bitmap |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
companion object { | |
init { | |
System.loadLibrary("native-lib") | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extern "C" JNIEXPORT jobject JNICALL | |
Java_co_netguru_vrhouseframework_NativeRecognizer_cropSelectedArea( | |
JNIEnv *env, | |
jobject _this, | |
jobject bitmap, | |
jfloatArray points) {... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set(OpenCV_DIR "../opencv/src/sdk/native/jni") | |
find_package(OpenCV REQUIRED) | |
message(STATUS "OpenCV libraries: ${OpenCV_LIBS}") | |
target_link_libraries(native-lib ${OpenCV_LIBS}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_library( # Sets the name of the library. | |
native-lib | |
# Sets the library as a shared library. | |
SHARED | |
# Provides a relative path to your source file(s). | |
src/main/cpp/native-lib.cpp | |
../../Shared/SheetDetection.cpp | |
) |