config: rename private command messages
This commit is contained in:
parent
87de5fcca3
commit
a8176b96c3
8 changed files with 12 additions and 12 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
pub mod client;
|
pub mod client;
|
||||||
pub mod ipc;
|
pub mod messages;
|
||||||
mod logging;
|
mod logging;
|
||||||
|
|
||||||
use {
|
use {
|
||||||
|
|
@ -16,8 +16,8 @@ use {
|
||||||
|
|
||||||
pub const VERSION: u32 = 1;
|
pub const VERSION: u32 = 1;
|
||||||
|
|
||||||
pub type ServerHandler = unsafe fn(data: *const u8, msg: &ipc::ClientMessage<'_>);
|
pub type ServerHandler = unsafe fn(data: *const u8, msg: &messages::ClientMessage<'_>);
|
||||||
pub type ConfigHandler = unsafe fn(data: *const u8, msg: &ipc::ServerMessage);
|
pub type ConfigHandler = unsafe fn(data: *const u8, msg: &messages::ServerMessage);
|
||||||
pub type Unref = unsafe fn(data: *const u8);
|
pub type Unref = unsafe fn(data: *const u8);
|
||||||
|
|
||||||
pub struct ConfigEntry {
|
pub struct ConfigEntry {
|
||||||
|
|
@ -26,7 +26,7 @@ pub struct ConfigEntry {
|
||||||
srv_data: *const u8,
|
srv_data: *const u8,
|
||||||
srv_unref: Unref,
|
srv_unref: Unref,
|
||||||
srv_handler: ServerHandler,
|
srv_handler: ServerHandler,
|
||||||
msg: ipc::InitMessage,
|
msg: messages::InitMessage,
|
||||||
) -> *const u8,
|
) -> *const u8,
|
||||||
pub unref: Unref,
|
pub unref: Unref,
|
||||||
pub handle_msg: ConfigHandler,
|
pub handle_msg: ConfigHandler,
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ use {
|
||||||
_private::{
|
_private::{
|
||||||
ClientCriterionIpc, ClientCriterionStringField, GenericCriterionIpc, PollableId,
|
ClientCriterionIpc, ClientCriterionStringField, GenericCriterionIpc, PollableId,
|
||||||
ServerHandler, Unref, WindowCriterionIpc, WindowCriterionStringField, WireMode,
|
ServerHandler, Unref, WindowCriterionIpc, WindowCriterionStringField, WireMode,
|
||||||
ipc::{
|
messages::{
|
||||||
ClientMessage, InitMessage, Response, ServerFeature, ServerMessage, WorkspaceSource,
|
ClientMessage, InitMessage, Response, ServerFeature, ServerMessage, WorkspaceSource,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ pub mod clickmethod;
|
||||||
|
|
||||||
use {
|
use {
|
||||||
crate::{
|
crate::{
|
||||||
_private::{DEFAULT_SEAT_NAME, ipc::WorkspaceSource},
|
_private::{DEFAULT_SEAT_NAME, messages::WorkspaceSource},
|
||||||
Axis, Direction, ModifiedKeySym, Workspace,
|
Axis, Direction, ModifiedKeySym, Workspace,
|
||||||
input::{acceleration::AccelProfile, capability::Capability, clickmethod::ClickMethod},
|
input::{acceleration::AccelProfile, capability::Capability, clickmethod::ClickMethod},
|
||||||
keyboard::{Keymap, mods::Modifiers, syms::KeySym},
|
keyboard::{Keymap, mods::Modifiers, syms::KeySym},
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ use crate::input::Seat;
|
||||||
|
|
||||||
use {
|
use {
|
||||||
crate::{
|
crate::{
|
||||||
_private::ipc::WorkspaceSource, keyboard::ModifiedKeySym, video::Connector, window::Window,
|
_private::messages::WorkspaceSource, keyboard::ModifiedKeySym, video::Connector, window::Window,
|
||||||
},
|
},
|
||||||
serde::{Deserialize, Serialize},
|
serde::{Deserialize, Serialize},
|
||||||
std::{
|
std::{
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ use {
|
||||||
jay_config::{
|
jay_config::{
|
||||||
_private::{
|
_private::{
|
||||||
ConfigEntry, VERSION,
|
ConfigEntry, VERSION,
|
||||||
ipc::{InitMessage, ServerFeature, ServerMessage, V1InitMessage},
|
messages::{InitMessage, ServerFeature, ServerMessage, V1InitMessage},
|
||||||
},
|
},
|
||||||
input::{InputDevice, Seat, SwitchEvent},
|
input::{InputDevice, Seat, SwitchEvent},
|
||||||
keyboard::{mods::Modifiers, syms::KeySym},
|
keyboard::{mods::Modifiers, syms::KeySym},
|
||||||
|
|
@ -260,7 +260,7 @@ unsafe fn unref(data: *const u8) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
unsafe fn handle_msg(data: *const u8, msg: &jay_config::_private::ipc::ClientMessage<'_>) {
|
unsafe fn handle_msg(data: *const u8, msg: &jay_config::_private::messages::ClientMessage<'_>) {
|
||||||
unsafe {
|
unsafe {
|
||||||
let server = (data as *const ConfigProxyHandler).deref();
|
let server = (data as *const ConfigProxyHandler).deref();
|
||||||
if server.dropped.get() {
|
if server.dropped.get() {
|
||||||
|
|
|
||||||
|
|
@ -44,7 +44,7 @@ use {
|
||||||
_private::{
|
_private::{
|
||||||
ClientCriterionIpc, ClientCriterionStringField, GenericCriterionIpc, PollableId,
|
ClientCriterionIpc, ClientCriterionStringField, GenericCriterionIpc, PollableId,
|
||||||
ConfigHandler, Unref, WindowCriterionIpc, WindowCriterionStringField, WireMode,
|
ConfigHandler, Unref, WindowCriterionIpc, WindowCriterionStringField, WireMode,
|
||||||
ipc::{ClientMessage, Response, ServerMessage, WorkspaceSource},
|
messages::{ClientMessage, Response, ServerMessage, WorkspaceSource},
|
||||||
},
|
},
|
||||||
Axis, Direction, Workspace,
|
Axis, Direction, Workspace,
|
||||||
client::{Client as ConfigClient, ClientMatcher},
|
client::{Client as ConfigClient, ClientMatcher},
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,7 @@ use {
|
||||||
jay_config::{
|
jay_config::{
|
||||||
_private::{
|
_private::{
|
||||||
ConfigEntry, VERSION,
|
ConfigEntry, VERSION,
|
||||||
ipc::{ClientMessage, Response, ServerMessage},
|
messages::{ClientMessage, Response, ServerMessage},
|
||||||
},
|
},
|
||||||
Axis, Direction,
|
Axis, Direction,
|
||||||
input::{InputDevice, Seat},
|
input::{InputDevice, Seat},
|
||||||
|
|
@ -56,7 +56,7 @@ unsafe fn init(
|
||||||
srv_data: *const u8,
|
srv_data: *const u8,
|
||||||
srv_unref: jay_config::_private::Unref,
|
srv_unref: jay_config::_private::Unref,
|
||||||
srv_handler: jay_config::_private::ServerHandler,
|
srv_handler: jay_config::_private::ServerHandler,
|
||||||
_msg: jay_config::_private::ipc::InitMessage,
|
_msg: jay_config::_private::messages::InitMessage,
|
||||||
) -> *const u8 {
|
) -> *const u8 {
|
||||||
let tc = CONFIG.get();
|
let tc = CONFIG.get();
|
||||||
assert!(tc.is_not_null());
|
assert!(tc.is_not_null());
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue