Add FlutterDesktopWindowProperties to the public API#133
Add FlutterDesktopWindowProperties to the public API#133swift-kim merged 8 commits intoflutter-tizen:flutter-2.2.1-tizenfrom
Conversation
|
The relative path thing doesn't work in case of the .NET app type because the executable path resolves to edit) It can't be applied to the native app case either because the executable path appears to be |
|
I just removed the relative path support to avoid any confusion. |
|
I'll rebase and resolve any conflict when #125 is merged. You can still review the change. |
| int32_t width, height; | ||
| if (!SetupDisplay(width, height)) { | ||
| FT_LOGE("SetupDisplay fail"); | ||
| if (!SetupDisplay(&width, &height)) { |
There was a problem hiding this comment.
if you use initial_geometry, maybe you don't really need this "width" and "height".
There was a problem hiding this comment.
As you can see in the documentation of FlutterDesktopWindowProperties, if the width and height are not provided by the app explicitly, the values are obtained from the current display just as usual.
| if (!engine->RunEngine(engine_properties)) { | ||
| flutter::FlutterProjectBundle project(engine_properties); | ||
| auto engine = std::make_unique<flutter::FlutterTizenEngine>(project); | ||
| if (window_properties.headed) { |
There was a problem hiding this comment.
I love this part! ❤️ It's much more intuitive. Thanks
|
|
||
| void OnTerminate() { | ||
| printf("Shutting down the application..."); | ||
| printf("Shutting down the application...\n"); |
There was a problem hiding this comment.
What do you think about modifying it as below and using the log macros?
--- a/shell/platform/tizen/tizen_log_stub.cc
+++ b/shell/platform/tizen/tizen_log_stub.cc
@@ -19,7 +19,7 @@ namespace flutter {
void SetMinLoggingLevel(log_priority p){};
log_priority GetMinLoggingLevel() {
- return DLOG_ERROR;
+ return DLOG_DEBUG;
};There was a problem hiding this comment.
As we're already passing --verbose-logging as an engine argument, there's no need to change GetMinLoggingLevel.
I don't think it makes sense to use printf in OnCretae and FT_LOGI in OnTerminate. I think it's better to leave them as they are or remove both from OnCreate and OnTerminate.
There was a problem hiding this comment.
Yes, you can remove both and it's better than the current.
There was a problem hiding this comment.
yes, we can remove both and it is nice rather then as it is
* Refactor using FlutterProjectBundle * Unsupport relative paths * Reland the support for relative paths * Add FlutterDesktopWindowProperties to the public API * Document undocumented public APIs * Rebase and resolve conflicts * Enable FlutterTizenEngineTest.Run_Twice * Add documentation
* Refactor using FlutterProjectBundle * Unsupport relative paths * Reland the support for relative paths * Add FlutterDesktopWindowProperties to the public API * Document undocumented public APIs * Rebase and resolve conflicts * Enable FlutterTizenEngineTest.Run_Twice * Add documentation
* Refactor using FlutterProjectBundle * Unsupport relative paths * Reland the support for relative paths * Add FlutterDesktopWindowProperties to the public API * Document undocumented public APIs * Rebase and resolve conflicts * Enable FlutterTizenEngineTest.Run_Twice * Add documentation
* Refactor using FlutterProjectBundle * Unsupport relative paths * Reland the support for relative paths * Add FlutterDesktopWindowProperties to the public API * Document undocumented public APIs * Rebase and resolve conflicts * Enable FlutterTizenEngineTest.Run_Twice * Add documentation
* Refactor using FlutterProjectBundle * Unsupport relative paths * Reland the support for relative paths * Add FlutterDesktopWindowProperties to the public API * Document undocumented public APIs * Rebase and resolve conflicts * Enable FlutterTizenEngineTest.Run_Twice * Add documentation
* Refactor using FlutterProjectBundle * Unsupport relative paths * Reland the support for relative paths * Add FlutterDesktopWindowProperties to the public API * Document undocumented public APIs * Rebase and resolve conflicts * Enable FlutterTizenEngineTest.Run_Twice * Add documentation
* Refactor using FlutterProjectBundle * Unsupport relative paths * Reland the support for relative paths * Add FlutterDesktopWindowProperties to the public API * Document undocumented public APIs * Rebase and resolve conflicts * Enable FlutterTizenEngineTest.Run_Twice * Add documentation
* Refactor using FlutterProjectBundle * Unsupport relative paths * Reland the support for relative paths * Add FlutterDesktopWindowProperties to the public API * Document undocumented public APIs * Rebase and resolve conflicts * Enable FlutterTizenEngineTest.Run_Twice * Add documentation
* Refactor using FlutterProjectBundle * Unsupport relative paths * Reland the support for relative paths * Add FlutterDesktopWindowProperties to the public API * Document undocumented public APIs * Rebase and resolve conflicts * Enable FlutterTizenEngineTest.Run_Twice * Add documentation
FlutterProjectBundleand refactor similarly to the Windows embedder.assets_path,icu_data_path, andaot_library_path.FlutterDesktopWindowPropertiesto flutter_tizen.h. This might be used in the future.Caveats:
widthorheightinFlutterDesktopWindowPropertiesis set to non-zero, it is assumed that the screen is not resizable. Attempting to resize or rotate the screen is an undefined behavior.This depends on #131 and should be rebased after #131 is merged.