-
Notifications
You must be signed in to change notification settings - Fork 556
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(api): new api to save input history without cleaning up sessions #766
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need proof it will work in thread-safe manner.
@@ -465,6 +466,7 @@ typedef struct rime_api_t { | |||
Bool (*deploy_config_file)(const char* file_name, const char* version_key); | |||
|
|||
Bool (*sync_user_data)(void); | |||
Bool (*sync_user_dict)(void); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't insert new API functions.
@@ -167,6 +167,11 @@ RIME_API Bool RimeSyncUserData() { | |||
return Bool(deployer.StartMaintenance()); | |||
} | |||
|
|||
RIME_API Bool RimeSyncUserDict() { | |||
Deployer& deployer(Service::instance().deployer()); | |||
return Bool(deployer.ScheduleTask("user_dict_sync")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this safe to do while user input session accesses user dictionary simutaniously?
@@ -167,6 +167,11 @@ RIME_API Bool RimeSyncUserData() { | |||
return Bool(deployer.StartMaintenance()); | |||
} | |||
|
|||
RIME_API Bool RimeSyncUserDict() { | |||
Deployer& deployer(Service::instance().deployer()); | |||
return Bool(deployer.ScheduleTask("user_dict_sync")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it working? It doesn't look like actually running the task.
I believe the code is not working as expected. |
Pull request
Issue tracker
Fixes will automatically close the related issue
Fixes #754
Feature
Describe feature of pull request
Unit test
Manual test
Code Review
Additional Info