libos+libui+wind: Use uppercase for static struct IDs to avoid confusion with fields
This commit is contained in:
parent
820b1ae2ba
commit
2328987d81
@ -54,7 +54,7 @@ namespace os
|
||||
*/
|
||||
template <typename Client, typename T> Result<void> send_async(Client& client, const T& message)
|
||||
{
|
||||
u8 id = T::id;
|
||||
u8 id = T::ID;
|
||||
TRY(client.send_typed(id));
|
||||
TRY(client.send_typed(message));
|
||||
return {};
|
||||
@ -90,7 +90,7 @@ namespace os
|
||||
Result<ResponseType> send_sync(os::LocalClient& client, const T& message,
|
||||
decltype(handle_ipc_client_event) handler = handle_ipc_client_event)
|
||||
{
|
||||
u8 id = T::id;
|
||||
u8 id = T::ID;
|
||||
TRY(client.send_typed(id));
|
||||
TRY(client.send_typed(message));
|
||||
|
||||
@ -115,7 +115,7 @@ namespace os
|
||||
}
|
||||
}
|
||||
|
||||
if (response_id != ResponseType::id)
|
||||
if (response_id != ResponseType::ID)
|
||||
{
|
||||
TRY(handler(client, response_id));
|
||||
max_other_messages--;
|
||||
|
@ -20,7 +20,7 @@ namespace ui
|
||||
|
||||
struct CreateWindowResponse
|
||||
{
|
||||
static constexpr u8 id = CREATE_WINDOW_RESPONSE_ID;
|
||||
static constexpr u8 ID = CREATE_WINDOW_RESPONSE_ID;
|
||||
|
||||
int window;
|
||||
IPC_STRING(shm_path);
|
||||
|
@ -26,14 +26,14 @@ namespace ui
|
||||
struct CreateWindowRequest
|
||||
{
|
||||
using ResponseType = CreateWindowResponse;
|
||||
static constexpr u8 id = CREATE_WINDOW_ID;
|
||||
static constexpr u8 ID = CREATE_WINDOW_ID;
|
||||
|
||||
ui::Rect rect;
|
||||
};
|
||||
|
||||
struct SetWindowTitleRequest
|
||||
{
|
||||
static constexpr u8 id = SET_WINDOW_TITLE_ID;
|
||||
static constexpr u8 ID = SET_WINDOW_TITLE_ID;
|
||||
|
||||
int window;
|
||||
IPC_STRING(title);
|
||||
@ -41,7 +41,7 @@ namespace ui
|
||||
|
||||
struct InvalidateRequest
|
||||
{
|
||||
static constexpr u8 id = INVALIDATE_ID;
|
||||
static constexpr u8 ID = INVALIDATE_ID;
|
||||
|
||||
int window;
|
||||
};
|
||||
|
@ -64,7 +64,7 @@ static Result<u32*> create_shm_region(const char* path, int* outfd, ui::Rect rec
|
||||
if (rc.error() == EAGAIN) \
|
||||
{ \
|
||||
client.rpc_in_progress = true; \
|
||||
client.rpc_id = decltype(request)::id; \
|
||||
client.rpc_id = decltype(request)::ID; \
|
||||
return {}; \
|
||||
} \
|
||||
else \
|
||||
|
Loading…
Reference in New Issue
Block a user