mirror of
https://github.com/keymanapp/keyman.git
synced 2026-08-09 10:25:32 +00:00
Fixes #10582. Returned struct from the `km_core_state_get_actions()` API is now owned by the state object. This is a change in API contract. The corresponding `km_core_actions_dispose()` API has been made private, because there is never any need for API consumers to call it. As this change is happening in alpha, we won't bump the ABI version. `state->app_context` is now guaranteed to be in sync with `state->context` after `km_core_process_event()`, with the actions struct populated at that point. The next and final step in this refactor is to remove the actions queue altogether from the Core and make that a kmn-only concept, but that will wait until 18.0. The only consumers of the actions queue are the kmn-specific interactive debugger in Keyman Developer, and kmn-specific Input Method eXtensions in Keyman Engine for Windows.
43 lines
964 B
C++
43 lines
964 B
C++
/*
|
|
Copyright: © 2023 SIL International.
|
|
Description: Internal actions methods for Keyman Core
|
|
Create Date: 23 Oct 2023
|
|
Authors: Marc Durdin (MCD)
|
|
History: 23 Oct 2023 - MCD - Initial implementation
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "keyman_core.h"
|
|
#include <state.hpp>
|
|
|
|
namespace km {
|
|
namespace core
|
|
{
|
|
bool action_item_list_to_actions_object(
|
|
km_core_action_item const *action_items,
|
|
km_core_actions *actions
|
|
);
|
|
|
|
bool actions_normalize(
|
|
/* in */ context const *cached_context,
|
|
/* in, out */ context *app_context,
|
|
/* in, out */ km_core_actions &actions
|
|
);
|
|
|
|
bool actions_update_app_context_nfu(
|
|
/* in */ context const *cached_context,
|
|
/* in, out */ context *app_context
|
|
);
|
|
|
|
void actions_dispose(
|
|
km_core_actions const & actions
|
|
);
|
|
|
|
km_core_usv const *get_deleted_context(
|
|
context const &app_context,
|
|
unsigned int code_points_to_delete
|
|
);
|
|
|
|
} // namespace core
|
|
} // namespace km
|