Skip to content
Snippets Groups Projects
Commit ce5531ff authored by Jens Nolte's avatar Jens Nolte
Browse files

Rename Fixed to WlFixed

parent 899979e2
No related branches found
No related tags found
No related merge requests found
......@@ -10,7 +10,7 @@ module Quasar.Wayland.Protocol (
getMessageHandler,
-- ** Wayland types
Fixed(..),
WlFixed(..),
WlString(..),
toString,
......
......@@ -6,7 +6,7 @@ module Quasar.Wayland.Protocol.Core (
NewId,
GenericNewId,
Opcode,
Fixed(..),
WlFixed(..),
WlString(..),
toString,
fromString,
......@@ -115,10 +115,10 @@ data GenericNewId = GenericNewId WlString Version Word32
-- | Signed 24.8 decimal numbers.
newtype Fixed = Fixed Word32
newtype WlFixed = WlFixed Word32
deriving newtype Eq
instance Show Fixed where
instance Show WlFixed where
show x = "[fixed " <> show x <> "]"
......@@ -162,9 +162,9 @@ instance WireFormat Word32 where
getArgument = pure <$> getWord32host
showArgument = show
instance WireFormat Fixed where
putArgument (Fixed repr) = pure $ MessagePart (putWord32host repr) 4 mempty
getArgument = pure . Fixed <$> getWord32host
instance WireFormat WlFixed where
putArgument (WlFixed repr) = pure $ MessagePart (putWord32host repr) 4 mempty
getArgument = pure . WlFixed <$> getWord32host
showArgument = show
instance WireFormat WlString where
......
......@@ -498,7 +498,7 @@ argumentWireType argSpec = liftArgumentWireType argSpec.argType
liftArgumentWireType :: ArgumentType -> Q Type
liftArgumentWireType IntArgument = [t|Int32|]
liftArgumentWireType UIntArgument = [t|Word32|]
liftArgumentWireType FixedArgument = [t|Fixed|]
liftArgumentWireType FixedArgument = [t|WlFixed|]
liftArgumentWireType StringArgument = [t|WlString|]
liftArgumentWireType ArrayArgument = [t|BS.ByteString|]
liftArgumentWireType (ObjectArgument iName) = [t|ObjectId $(litT (strTyLit iName))|]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment