{-# LANGUAGE TypeApplications #-}
#if (MIN_VERSION_haskell_gi_overloading(1,0,0) && !defined(__HADDOCK_VERSION__))
#define ENABLE_OVERLOADING
#endif
module GI.Gtk.Interfaces.Actionable
(
Actionable(..) ,
IsActionable ,
toActionable ,
#if defined(ENABLE_OVERLOADING)
ResolveActionableMethod ,
#endif
#if defined(ENABLE_OVERLOADING)
ActionableGetActionNameMethodInfo ,
#endif
actionableGetActionName ,
#if defined(ENABLE_OVERLOADING)
ActionableGetActionTargetValueMethodInfo,
#endif
actionableGetActionTargetValue ,
#if defined(ENABLE_OVERLOADING)
ActionableSetActionNameMethodInfo ,
#endif
actionableSetActionName ,
#if defined(ENABLE_OVERLOADING)
ActionableSetActionTargetValueMethodInfo,
#endif
actionableSetActionTargetValue ,
#if defined(ENABLE_OVERLOADING)
ActionableSetDetailedActionNameMethodInfo,
#endif
actionableSetDetailedActionName ,
#if defined(ENABLE_OVERLOADING)
ActionableActionNamePropertyInfo ,
#endif
#if defined(ENABLE_OVERLOADING)
actionableActionName ,
#endif
clearActionableActionName ,
constructActionableActionName ,
getActionableActionName ,
setActionableActionName ,
#if defined(ENABLE_OVERLOADING)
ActionableActionTargetPropertyInfo ,
#endif
#if defined(ENABLE_OVERLOADING)
actionableActionTarget ,
#endif
clearActionableActionTarget ,
constructActionableActionTarget ,
getActionableActionTarget ,
setActionableActionTarget ,
) where
import Data.GI.Base.ShortPrelude
import qualified Data.GI.Base.ShortPrelude as SP
import qualified Data.GI.Base.Overloading as O
import qualified Prelude as P
import qualified Data.GI.Base.Attributes as GI.Attributes
import qualified Data.GI.Base.BasicTypes as B.Types
import qualified Data.GI.Base.ManagedPtr as B.ManagedPtr
import qualified Data.GI.Base.GArray as B.GArray
import qualified Data.GI.Base.GClosure as B.GClosure
import qualified Data.GI.Base.GError as B.GError
import qualified Data.GI.Base.GVariant as B.GVariant
import qualified Data.GI.Base.GValue as B.GValue
import qualified Data.GI.Base.GParamSpec as B.GParamSpec
import qualified Data.GI.Base.CallStack as B.CallStack
import qualified Data.GI.Base.Properties as B.Properties
import qualified Data.GI.Base.Signals as B.Signals
import qualified Control.Monad.IO.Class as MIO
import qualified Data.Text as T
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map
import qualified Foreign.Ptr as FP
import qualified GHC.OverloadedLabels as OL
import qualified GHC.Records as R
import qualified GI.GObject.Objects.Object as GObject.Object
import {-# SOURCE #-} qualified GI.Gtk.Interfaces.Accessible as Gtk.Accessible
import {-# SOURCE #-} qualified GI.Gtk.Interfaces.Buildable as Gtk.Buildable
import {-# SOURCE #-} qualified GI.Gtk.Objects.Widget as Gtk.Widget
newtype Actionable = Actionable (SP.ManagedPtr Actionable)
deriving (Actionable -> Actionable -> Bool
(Actionable -> Actionable -> Bool)
-> (Actionable -> Actionable -> Bool) -> Eq Actionable
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Actionable -> Actionable -> Bool
$c/= :: Actionable -> Actionable -> Bool
== :: Actionable -> Actionable -> Bool
$c== :: Actionable -> Actionable -> Bool
Eq)
instance SP.ManagedPtrNewtype Actionable where
toManagedPtr :: Actionable -> ManagedPtr Actionable
toManagedPtr (Actionable ManagedPtr Actionable
p) = ManagedPtr Actionable
p
foreign import ccall "gtk_actionable_get_type"
c_gtk_actionable_get_type :: IO B.Types.GType
instance B.Types.TypedObject Actionable where
glibType :: IO GType
glibType = IO GType
c_gtk_actionable_get_type
instance B.Types.GObject Actionable
class (SP.GObject o, O.IsDescendantOf Actionable o) => IsActionable o
instance (SP.GObject o, O.IsDescendantOf Actionable o) => IsActionable o
instance O.HasParentTypes Actionable
type instance O.ParentTypes Actionable = '[GObject.Object.Object, Gtk.Widget.Widget]
toActionable :: (MIO.MonadIO m, IsActionable o) => o -> m Actionable
toActionable :: forall (m :: * -> *) o.
(MonadIO m, IsActionable o) =>
o -> m Actionable
toActionable = IO Actionable -> m Actionable
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO Actionable -> m Actionable)
-> (o -> IO Actionable) -> o -> m Actionable
forall b c a. (b -> c) -> (a -> b) -> a -> c
. (ManagedPtr Actionable -> Actionable) -> o -> IO Actionable
forall o o'.
(HasCallStack, ManagedPtrNewtype o, TypedObject o,
ManagedPtrNewtype o', TypedObject o') =>
(ManagedPtr o' -> o') -> o -> IO o'
B.ManagedPtr.unsafeCastTo ManagedPtr Actionable -> Actionable
Actionable
instance B.GValue.IsGValue (Maybe Actionable) where
gvalueGType_ :: IO GType
gvalueGType_ = IO GType
c_gtk_actionable_get_type
gvalueSet_ :: Ptr GValue -> Maybe Actionable -> IO ()
gvalueSet_ Ptr GValue
gv Maybe Actionable
P.Nothing = Ptr GValue -> Ptr Actionable -> IO ()
forall a. GObject a => Ptr GValue -> Ptr a -> IO ()
B.GValue.set_object Ptr GValue
gv (Ptr Actionable
forall a. Ptr a
FP.nullPtr :: FP.Ptr Actionable)
gvalueSet_ Ptr GValue
gv (P.Just Actionable
obj) = Actionable -> (Ptr Actionable -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
B.ManagedPtr.withManagedPtr Actionable
obj (Ptr GValue -> Ptr Actionable -> IO ()
forall a. GObject a => Ptr GValue -> Ptr a -> IO ()
B.GValue.set_object Ptr GValue
gv)
gvalueGet_ :: Ptr GValue -> IO (Maybe Actionable)
gvalueGet_ Ptr GValue
gv = do
Ptr Actionable
ptr <- Ptr GValue -> IO (Ptr Actionable)
forall a. GObject a => Ptr GValue -> IO (Ptr a)
B.GValue.get_object Ptr GValue
gv :: IO (FP.Ptr Actionable)
if Ptr Actionable
ptr Ptr Actionable -> Ptr Actionable -> Bool
forall a. Eq a => a -> a -> Bool
/= Ptr Actionable
forall a. Ptr a
FP.nullPtr
then Actionable -> Maybe Actionable
forall a. a -> Maybe a
P.Just (Actionable -> Maybe Actionable)
-> IO Actionable -> IO (Maybe Actionable)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> (ManagedPtr Actionable -> Actionable)
-> Ptr Actionable -> IO Actionable
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
B.ManagedPtr.newObject ManagedPtr Actionable -> Actionable
Actionable Ptr Actionable
ptr
else Maybe Actionable -> IO (Maybe Actionable)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Actionable
forall a. Maybe a
P.Nothing
getActionableActionName :: (MonadIO m, IsActionable o) => o -> m (Maybe T.Text)
getActionableActionName :: forall (m :: * -> *) o.
(MonadIO m, IsActionable o) =>
o -> m (Maybe Text)
getActionableActionName o
obj = IO (Maybe Text) -> m (Maybe Text)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (Maybe Text) -> m (Maybe Text))
-> IO (Maybe Text) -> m (Maybe Text)
forall a b. (a -> b) -> a -> b
$ o -> String -> IO (Maybe Text)
forall a. GObject a => a -> String -> IO (Maybe Text)
B.Properties.getObjectPropertyString o
obj String
"action-name"
setActionableActionName :: (MonadIO m, IsActionable o) => o -> T.Text -> m ()
setActionableActionName :: forall (m :: * -> *) o.
(MonadIO m, IsActionable o) =>
o -> Text -> m ()
setActionableActionName o
obj Text
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
o -> String -> Maybe Text -> IO ()
forall a. GObject a => a -> String -> Maybe Text -> IO ()
B.Properties.setObjectPropertyString o
obj String
"action-name" (Text -> Maybe Text
forall a. a -> Maybe a
Just Text
val)
constructActionableActionName :: (IsActionable o, MIO.MonadIO m) => T.Text -> m (GValueConstruct o)
constructActionableActionName :: forall o (m :: * -> *).
(IsActionable o, MonadIO m) =>
Text -> m (GValueConstruct o)
constructActionableActionName Text
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
IO (GValueConstruct o) -> IO (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Maybe Text -> IO (GValueConstruct o)
forall o. String -> Maybe Text -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyString String
"action-name" (Text -> Maybe Text
forall a. a -> Maybe a
P.Just Text
val)
clearActionableActionName :: (MonadIO m, IsActionable o) => o -> m ()
clearActionableActionName :: forall (m :: * -> *) o. (MonadIO m, IsActionable o) => o -> m ()
clearActionableActionName o
obj = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ o -> String -> Maybe Text -> IO ()
forall a. GObject a => a -> String -> Maybe Text -> IO ()
B.Properties.setObjectPropertyString o
obj String
"action-name" (Maybe Text
forall a. Maybe a
Nothing :: Maybe T.Text)
#if defined(ENABLE_OVERLOADING)
data ActionableActionNamePropertyInfo
instance AttrInfo ActionableActionNamePropertyInfo where
type AttrAllowedOps ActionableActionNamePropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet, 'AttrClear]
type AttrBaseTypeConstraint ActionableActionNamePropertyInfo = IsActionable
type AttrSetTypeConstraint ActionableActionNamePropertyInfo = (~) T.Text
type AttrTransferTypeConstraint ActionableActionNamePropertyInfo = (~) T.Text
type AttrTransferType ActionableActionNamePropertyInfo = T.Text
type AttrGetType ActionableActionNamePropertyInfo = (Maybe T.Text)
type AttrLabel ActionableActionNamePropertyInfo = "action-name"
type AttrOrigin ActionableActionNamePropertyInfo = Actionable
attrGet = getActionableActionName
attrSet = setActionableActionName
attrTransfer _ v = do
return v
attrConstruct = constructActionableActionName
attrClear = clearActionableActionName
#endif
getActionableActionTarget :: (MonadIO m, IsActionable o) => o -> m (Maybe GVariant)
getActionableActionTarget :: forall (m :: * -> *) o.
(MonadIO m, IsActionable o) =>
o -> m (Maybe GVariant)
getActionableActionTarget o
obj = IO (Maybe GVariant) -> m (Maybe GVariant)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (Maybe GVariant) -> m (Maybe GVariant))
-> IO (Maybe GVariant) -> m (Maybe GVariant)
forall a b. (a -> b) -> a -> b
$ o -> String -> IO (Maybe GVariant)
forall a. GObject a => a -> String -> IO (Maybe GVariant)
B.Properties.getObjectPropertyVariant o
obj String
"action-target"
setActionableActionTarget :: (MonadIO m, IsActionable o) => o -> GVariant -> m ()
setActionableActionTarget :: forall (m :: * -> *) o.
(MonadIO m, IsActionable o) =>
o -> GVariant -> m ()
setActionableActionTarget o
obj GVariant
val = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
o -> String -> Maybe GVariant -> IO ()
forall a. GObject a => a -> String -> Maybe GVariant -> IO ()
B.Properties.setObjectPropertyVariant o
obj String
"action-target" (GVariant -> Maybe GVariant
forall a. a -> Maybe a
Just GVariant
val)
constructActionableActionTarget :: (IsActionable o, MIO.MonadIO m) => GVariant -> m (GValueConstruct o)
constructActionableActionTarget :: forall o (m :: * -> *).
(IsActionable o, MonadIO m) =>
GVariant -> m (GValueConstruct o)
constructActionableActionTarget GVariant
val = IO (GValueConstruct o) -> m (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> m (GValueConstruct o))
-> IO (GValueConstruct o) -> m (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ do
IO (GValueConstruct o) -> IO (GValueConstruct o)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO (GValueConstruct o) -> IO (GValueConstruct o))
-> IO (GValueConstruct o) -> IO (GValueConstruct o)
forall a b. (a -> b) -> a -> b
$ String -> Maybe GVariant -> IO (GValueConstruct o)
forall o. String -> Maybe GVariant -> IO (GValueConstruct o)
B.Properties.constructObjectPropertyVariant String
"action-target" (GVariant -> Maybe GVariant
forall a. a -> Maybe a
P.Just GVariant
val)
clearActionableActionTarget :: (MonadIO m, IsActionable o) => o -> m ()
clearActionableActionTarget :: forall (m :: * -> *) o. (MonadIO m, IsActionable o) => o -> m ()
clearActionableActionTarget o
obj = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ o -> String -> Maybe GVariant -> IO ()
forall a. GObject a => a -> String -> Maybe GVariant -> IO ()
B.Properties.setObjectPropertyVariant o
obj String
"action-target" (Maybe GVariant
forall a. Maybe a
Nothing :: Maybe GVariant)
#if defined(ENABLE_OVERLOADING)
data ActionableActionTargetPropertyInfo
instance AttrInfo ActionableActionTargetPropertyInfo where
type AttrAllowedOps ActionableActionTargetPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet, 'AttrClear]
type AttrBaseTypeConstraint ActionableActionTargetPropertyInfo = IsActionable
type AttrSetTypeConstraint ActionableActionTargetPropertyInfo = (~) GVariant
type AttrTransferTypeConstraint ActionableActionTargetPropertyInfo = (~) GVariant
type AttrTransferType ActionableActionTargetPropertyInfo = GVariant
type AttrGetType ActionableActionTargetPropertyInfo = (Maybe GVariant)
type AttrLabel ActionableActionTargetPropertyInfo = "action-target"
type AttrOrigin ActionableActionTargetPropertyInfo = Actionable
attrGet = getActionableActionTarget
attrSet = setActionableActionTarget
attrTransfer _ v = do
return v
attrConstruct = constructActionableActionTarget
attrClear = clearActionableActionTarget
#endif
#if defined(ENABLE_OVERLOADING)
instance O.HasAttributeList Actionable
type instance O.AttributeList Actionable = ActionableAttributeList
type ActionableAttributeList = ('[ '("accessibleRole", Gtk.Accessible.AccessibleAccessibleRolePropertyInfo), '("actionName", ActionableActionNamePropertyInfo), '("actionTarget", ActionableActionTargetPropertyInfo), '("canFocus", Gtk.Widget.WidgetCanFocusPropertyInfo), '("canTarget", Gtk.Widget.WidgetCanTargetPropertyInfo), '("cssClasses", Gtk.Widget.WidgetCssClassesPropertyInfo), '("cssName", Gtk.Widget.WidgetCssNamePropertyInfo), '("cursor", Gtk.Widget.WidgetCursorPropertyInfo), '("focusOnClick", Gtk.Widget.WidgetFocusOnClickPropertyInfo), '("focusable", Gtk.Widget.WidgetFocusablePropertyInfo), '("halign", Gtk.Widget.WidgetHalignPropertyInfo), '("hasDefault", Gtk.Widget.WidgetHasDefaultPropertyInfo), '("hasFocus", Gtk.Widget.WidgetHasFocusPropertyInfo), '("hasTooltip", Gtk.Widget.WidgetHasTooltipPropertyInfo), '("heightRequest", Gtk.Widget.WidgetHeightRequestPropertyInfo), '("hexpand", Gtk.Widget.WidgetHexpandPropertyInfo), '("hexpandSet", Gtk.Widget.WidgetHexpandSetPropertyInfo), '("layoutManager", Gtk.Widget.WidgetLayoutManagerPropertyInfo), '("marginBottom", Gtk.Widget.WidgetMarginBottomPropertyInfo), '("marginEnd", Gtk.Widget.WidgetMarginEndPropertyInfo), '("marginStart", Gtk.Widget.WidgetMarginStartPropertyInfo), '("marginTop", Gtk.Widget.WidgetMarginTopPropertyInfo), '("name", Gtk.Widget.WidgetNamePropertyInfo), '("opacity", Gtk.Widget.WidgetOpacityPropertyInfo), '("overflow", Gtk.Widget.WidgetOverflowPropertyInfo), '("parent", Gtk.Widget.WidgetParentPropertyInfo), '("receivesDefault", Gtk.Widget.WidgetReceivesDefaultPropertyInfo), '("root", Gtk.Widget.WidgetRootPropertyInfo), '("scaleFactor", Gtk.Widget.WidgetScaleFactorPropertyInfo), '("sensitive", Gtk.Widget.WidgetSensitivePropertyInfo), '("tooltipMarkup", Gtk.Widget.WidgetTooltipMarkupPropertyInfo), '("tooltipText", Gtk.Widget.WidgetTooltipTextPropertyInfo), '("valign", Gtk.Widget.WidgetValignPropertyInfo), '("vexpand", Gtk.Widget.WidgetVexpandPropertyInfo), '("vexpandSet", Gtk.Widget.WidgetVexpandSetPropertyInfo), '("visible", Gtk.Widget.WidgetVisiblePropertyInfo), '("widthRequest", Gtk.Widget.WidgetWidthRequestPropertyInfo)] :: [(Symbol, *)])
#endif
#if defined(ENABLE_OVERLOADING)
actionableActionName :: AttrLabelProxy "actionName"
actionableActionName = AttrLabelProxy
actionableActionTarget :: AttrLabelProxy "actionTarget"
actionableActionTarget = AttrLabelProxy
#endif
#if defined(ENABLE_OVERLOADING)
type family ResolveActionableMethod (t :: Symbol) (o :: *) :: * where
ResolveActionableMethod "actionSetEnabled" o = Gtk.Widget.WidgetActionSetEnabledMethodInfo
ResolveActionableMethod "activate" o = Gtk.Widget.WidgetActivateMethodInfo
ResolveActionableMethod "activateAction" o = Gtk.Widget.WidgetActivateActionMethodInfo
ResolveActionableMethod "activateDefault" o = Gtk.Widget.WidgetActivateDefaultMethodInfo
ResolveActionableMethod "addController" o = Gtk.Widget.WidgetAddControllerMethodInfo
ResolveActionableMethod "addCssClass" o = Gtk.Widget.WidgetAddCssClassMethodInfo
ResolveActionableMethod "addMnemonicLabel" o = Gtk.Widget.WidgetAddMnemonicLabelMethodInfo
ResolveActionableMethod "addTickCallback" o = Gtk.Widget.WidgetAddTickCallbackMethodInfo
ResolveActionableMethod "allocate" o = Gtk.Widget.WidgetAllocateMethodInfo
ResolveActionableMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
ResolveActionableMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
ResolveActionableMethod "childFocus" o = Gtk.Widget.WidgetChildFocusMethodInfo
ResolveActionableMethod "computeBounds" o = Gtk.Widget.WidgetComputeBoundsMethodInfo
ResolveActionableMethod "computeExpand" o = Gtk.Widget.WidgetComputeExpandMethodInfo
ResolveActionableMethod "computePoint" o = Gtk.Widget.WidgetComputePointMethodInfo
ResolveActionableMethod "computeTransform" o = Gtk.Widget.WidgetComputeTransformMethodInfo
ResolveActionableMethod "contains" o = Gtk.Widget.WidgetContainsMethodInfo
ResolveActionableMethod "createPangoContext" o = Gtk.Widget.WidgetCreatePangoContextMethodInfo
ResolveActionableMethod "createPangoLayout" o = Gtk.Widget.WidgetCreatePangoLayoutMethodInfo
ResolveActionableMethod "dragCheckThreshold" o = Gtk.Widget.WidgetDragCheckThresholdMethodInfo
ResolveActionableMethod "errorBell" o = Gtk.Widget.WidgetErrorBellMethodInfo
ResolveActionableMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
ResolveActionableMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
ResolveActionableMethod "getv" o = GObject.Object.ObjectGetvMethodInfo
ResolveActionableMethod "grabFocus" o = Gtk.Widget.WidgetGrabFocusMethodInfo
ResolveActionableMethod "hasCssClass" o = Gtk.Widget.WidgetHasCssClassMethodInfo
ResolveActionableMethod "hasDefault" o = Gtk.Widget.WidgetHasDefaultMethodInfo
ResolveActionableMethod "hasFocus" o = Gtk.Widget.WidgetHasFocusMethodInfo
ResolveActionableMethod "hasVisibleFocus" o = Gtk.Widget.WidgetHasVisibleFocusMethodInfo
ResolveActionableMethod "hide" o = Gtk.Widget.WidgetHideMethodInfo
ResolveActionableMethod "inDestruction" o = Gtk.Widget.WidgetInDestructionMethodInfo
ResolveActionableMethod "initTemplate" o = Gtk.Widget.WidgetInitTemplateMethodInfo
ResolveActionableMethod "insertActionGroup" o = Gtk.Widget.WidgetInsertActionGroupMethodInfo
ResolveActionableMethod "insertAfter" o = Gtk.Widget.WidgetInsertAfterMethodInfo
ResolveActionableMethod "insertBefore" o = Gtk.Widget.WidgetInsertBeforeMethodInfo
ResolveActionableMethod "isAncestor" o = Gtk.Widget.WidgetIsAncestorMethodInfo
ResolveActionableMethod "isDrawable" o = Gtk.Widget.WidgetIsDrawableMethodInfo
ResolveActionableMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
ResolveActionableMethod "isFocus" o = Gtk.Widget.WidgetIsFocusMethodInfo
ResolveActionableMethod "isSensitive" o = Gtk.Widget.WidgetIsSensitiveMethodInfo
ResolveActionableMethod "isVisible" o = Gtk.Widget.WidgetIsVisibleMethodInfo
ResolveActionableMethod "keynavFailed" o = Gtk.Widget.WidgetKeynavFailedMethodInfo
ResolveActionableMethod "listMnemonicLabels" o = Gtk.Widget.WidgetListMnemonicLabelsMethodInfo
ResolveActionableMethod "map" o = Gtk.Widget.WidgetMapMethodInfo
ResolveActionableMethod "measure" o = Gtk.Widget.WidgetMeasureMethodInfo
ResolveActionableMethod "mnemonicActivate" o = Gtk.Widget.WidgetMnemonicActivateMethodInfo
ResolveActionableMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
ResolveActionableMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
ResolveActionableMethod "observeChildren" o = Gtk.Widget.WidgetObserveChildrenMethodInfo
ResolveActionableMethod "observeControllers" o = Gtk.Widget.WidgetObserveControllersMethodInfo
ResolveActionableMethod "pick" o = Gtk.Widget.WidgetPickMethodInfo
ResolveActionableMethod "queueAllocate" o = Gtk.Widget.WidgetQueueAllocateMethodInfo
ResolveActionableMethod "queueDraw" o = Gtk.Widget.WidgetQueueDrawMethodInfo
ResolveActionableMethod "queueResize" o = Gtk.Widget.WidgetQueueResizeMethodInfo
ResolveActionableMethod "realize" o = Gtk.Widget.WidgetRealizeMethodInfo
ResolveActionableMethod "ref" o = GObject.Object.ObjectRefMethodInfo
ResolveActionableMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
ResolveActionableMethod "removeController" o = Gtk.Widget.WidgetRemoveControllerMethodInfo
ResolveActionableMethod "removeCssClass" o = Gtk.Widget.WidgetRemoveCssClassMethodInfo
ResolveActionableMethod "removeMnemonicLabel" o = Gtk.Widget.WidgetRemoveMnemonicLabelMethodInfo
ResolveActionableMethod "removeTickCallback" o = Gtk.Widget.WidgetRemoveTickCallbackMethodInfo
ResolveActionableMethod "resetProperty" o = Gtk.Accessible.AccessibleResetPropertyMethodInfo
ResolveActionableMethod "resetRelation" o = Gtk.Accessible.AccessibleResetRelationMethodInfo
ResolveActionableMethod "resetState" o = Gtk.Accessible.AccessibleResetStateMethodInfo
ResolveActionableMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
ResolveActionableMethod "shouldLayout" o = Gtk.Widget.WidgetShouldLayoutMethodInfo
ResolveActionableMethod "show" o = Gtk.Widget.WidgetShowMethodInfo
ResolveActionableMethod "sizeAllocate" o = Gtk.Widget.WidgetSizeAllocateMethodInfo
ResolveActionableMethod "snapshotChild" o = Gtk.Widget.WidgetSnapshotChildMethodInfo
ResolveActionableMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
ResolveActionableMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
ResolveActionableMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
ResolveActionableMethod "translateCoordinates" o = Gtk.Widget.WidgetTranslateCoordinatesMethodInfo
ResolveActionableMethod "triggerTooltipQuery" o = Gtk.Widget.WidgetTriggerTooltipQueryMethodInfo
ResolveActionableMethod "unmap" o = Gtk.Widget.WidgetUnmapMethodInfo
ResolveActionableMethod "unparent" o = Gtk.Widget.WidgetUnparentMethodInfo
ResolveActionableMethod "unrealize" o = Gtk.Widget.WidgetUnrealizeMethodInfo
ResolveActionableMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
ResolveActionableMethod "unsetStateFlags" o = Gtk.Widget.WidgetUnsetStateFlagsMethodInfo
ResolveActionableMethod "updateProperty" o = Gtk.Accessible.AccessibleUpdatePropertyMethodInfo
ResolveActionableMethod "updateRelation" o = Gtk.Accessible.AccessibleUpdateRelationMethodInfo
ResolveActionableMethod "updateState" o = Gtk.Accessible.AccessibleUpdateStateMethodInfo
ResolveActionableMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
ResolveActionableMethod "getAccessibleRole" o = Gtk.Accessible.AccessibleGetAccessibleRoleMethodInfo
ResolveActionableMethod "getActionName" o = ActionableGetActionNameMethodInfo
ResolveActionableMethod "getActionTargetValue" o = ActionableGetActionTargetValueMethodInfo
ResolveActionableMethod "getAllocatedBaseline" o = Gtk.Widget.WidgetGetAllocatedBaselineMethodInfo
ResolveActionableMethod "getAllocatedHeight" o = Gtk.Widget.WidgetGetAllocatedHeightMethodInfo
ResolveActionableMethod "getAllocatedWidth" o = Gtk.Widget.WidgetGetAllocatedWidthMethodInfo
ResolveActionableMethod "getAllocation" o = Gtk.Widget.WidgetGetAllocationMethodInfo
ResolveActionableMethod "getAncestor" o = Gtk.Widget.WidgetGetAncestorMethodInfo
ResolveActionableMethod "getBuildableId" o = Gtk.Buildable.BuildableGetBuildableIdMethodInfo
ResolveActionableMethod "getCanFocus" o = Gtk.Widget.WidgetGetCanFocusMethodInfo
ResolveActionableMethod "getCanTarget" o = Gtk.Widget.WidgetGetCanTargetMethodInfo
ResolveActionableMethod "getChildVisible" o = Gtk.Widget.WidgetGetChildVisibleMethodInfo
ResolveActionableMethod "getClipboard" o = Gtk.Widget.WidgetGetClipboardMethodInfo
ResolveActionableMethod "getCssClasses" o = Gtk.Widget.WidgetGetCssClassesMethodInfo
ResolveActionableMethod "getCssName" o = Gtk.Widget.WidgetGetCssNameMethodInfo
ResolveActionableMethod "getCursor" o = Gtk.Widget.WidgetGetCursorMethodInfo
ResolveActionableMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
ResolveActionableMethod "getDirection" o = Gtk.Widget.WidgetGetDirectionMethodInfo
ResolveActionableMethod "getDisplay" o = Gtk.Widget.WidgetGetDisplayMethodInfo
ResolveActionableMethod "getFirstChild" o = Gtk.Widget.WidgetGetFirstChildMethodInfo
ResolveActionableMethod "getFocusChild" o = Gtk.Widget.WidgetGetFocusChildMethodInfo
ResolveActionableMethod "getFocusOnClick" o = Gtk.Widget.WidgetGetFocusOnClickMethodInfo
ResolveActionableMethod "getFocusable" o = Gtk.Widget.WidgetGetFocusableMethodInfo
ResolveActionableMethod "getFontMap" o = Gtk.Widget.WidgetGetFontMapMethodInfo
ResolveActionableMethod "getFontOptions" o = Gtk.Widget.WidgetGetFontOptionsMethodInfo
ResolveActionableMethod "getFrameClock" o = Gtk.Widget.WidgetGetFrameClockMethodInfo
ResolveActionableMethod "getHalign" o = Gtk.Widget.WidgetGetHalignMethodInfo
ResolveActionableMethod "getHasTooltip" o = Gtk.Widget.WidgetGetHasTooltipMethodInfo
ResolveActionableMethod "getHeight" o = Gtk.Widget.WidgetGetHeightMethodInfo
ResolveActionableMethod "getHexpand" o = Gtk.Widget.WidgetGetHexpandMethodInfo
ResolveActionableMethod "getHexpandSet" o = Gtk.Widget.WidgetGetHexpandSetMethodInfo
ResolveActionableMethod "getLastChild" o = Gtk.Widget.WidgetGetLastChildMethodInfo
ResolveActionableMethod "getLayoutManager" o = Gtk.Widget.WidgetGetLayoutManagerMethodInfo
ResolveActionableMethod "getMapped" o = Gtk.Widget.WidgetGetMappedMethodInfo
ResolveActionableMethod "getMarginBottom" o = Gtk.Widget.WidgetGetMarginBottomMethodInfo
ResolveActionableMethod "getMarginEnd" o = Gtk.Widget.WidgetGetMarginEndMethodInfo
ResolveActionableMethod "getMarginStart" o = Gtk.Widget.WidgetGetMarginStartMethodInfo
ResolveActionableMethod "getMarginTop" o = Gtk.Widget.WidgetGetMarginTopMethodInfo
ResolveActionableMethod "getName" o = Gtk.Widget.WidgetGetNameMethodInfo
ResolveActionableMethod "getNative" o = Gtk.Widget.WidgetGetNativeMethodInfo
ResolveActionableMethod "getNextSibling" o = Gtk.Widget.WidgetGetNextSiblingMethodInfo
ResolveActionableMethod "getOpacity" o = Gtk.Widget.WidgetGetOpacityMethodInfo
ResolveActionableMethod "getOverflow" o = Gtk.Widget.WidgetGetOverflowMethodInfo
ResolveActionableMethod "getPangoContext" o = Gtk.Widget.WidgetGetPangoContextMethodInfo
ResolveActionableMethod "getParent" o = Gtk.Widget.WidgetGetParentMethodInfo
ResolveActionableMethod "getPreferredSize" o = Gtk.Widget.WidgetGetPreferredSizeMethodInfo
ResolveActionableMethod "getPrevSibling" o = Gtk.Widget.WidgetGetPrevSiblingMethodInfo
ResolveActionableMethod "getPrimaryClipboard" o = Gtk.Widget.WidgetGetPrimaryClipboardMethodInfo
ResolveActionableMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
ResolveActionableMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
ResolveActionableMethod "getRealized" o = Gtk.Widget.WidgetGetRealizedMethodInfo
ResolveActionableMethod "getReceivesDefault" o = Gtk.Widget.WidgetGetReceivesDefaultMethodInfo
ResolveActionableMethod "getRequestMode" o = Gtk.Widget.WidgetGetRequestModeMethodInfo
ResolveActionableMethod "getRoot" o = Gtk.Widget.WidgetGetRootMethodInfo
ResolveActionableMethod "getScaleFactor" o = Gtk.Widget.WidgetGetScaleFactorMethodInfo
ResolveActionableMethod "getSensitive" o = Gtk.Widget.WidgetGetSensitiveMethodInfo
ResolveActionableMethod "getSettings" o = Gtk.Widget.WidgetGetSettingsMethodInfo
ResolveActionableMethod "getSize" o = Gtk.Widget.WidgetGetSizeMethodInfo
ResolveActionableMethod "getSizeRequest" o = Gtk.Widget.WidgetGetSizeRequestMethodInfo
ResolveActionableMethod "getStateFlags" o = Gtk.Widget.WidgetGetStateFlagsMethodInfo
ResolveActionableMethod "getStyleContext" o = Gtk.Widget.WidgetGetStyleContextMethodInfo
ResolveActionableMethod "getTemplateChild" o = Gtk.Widget.WidgetGetTemplateChildMethodInfo
ResolveActionableMethod "getTooltipMarkup" o = Gtk.Widget.WidgetGetTooltipMarkupMethodInfo
ResolveActionableMethod "getTooltipText" o = Gtk.Widget.WidgetGetTooltipTextMethodInfo
ResolveActionableMethod "getValign" o = Gtk.Widget.WidgetGetValignMethodInfo
ResolveActionableMethod "getVexpand" o = Gtk.Widget.WidgetGetVexpandMethodInfo
ResolveActionableMethod "getVexpandSet" o = Gtk.Widget.WidgetGetVexpandSetMethodInfo
ResolveActionableMethod "getVisible" o = Gtk.Widget.WidgetGetVisibleMethodInfo
ResolveActionableMethod "getWidth" o = Gtk.Widget.WidgetGetWidthMethodInfo
ResolveActionableMethod "setActionName" o = ActionableSetActionNameMethodInfo
ResolveActionableMethod "setActionTargetValue" o = ActionableSetActionTargetValueMethodInfo
ResolveActionableMethod "setCanFocus" o = Gtk.Widget.WidgetSetCanFocusMethodInfo
ResolveActionableMethod "setCanTarget" o = Gtk.Widget.WidgetSetCanTargetMethodInfo
ResolveActionableMethod "setChildVisible" o = Gtk.Widget.WidgetSetChildVisibleMethodInfo
ResolveActionableMethod "setCssClasses" o = Gtk.Widget.WidgetSetCssClassesMethodInfo
ResolveActionableMethod "setCursor" o = Gtk.Widget.WidgetSetCursorMethodInfo
ResolveActionableMethod "setCursorFromName" o = Gtk.Widget.WidgetSetCursorFromNameMethodInfo
ResolveActionableMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
ResolveActionableMethod "setDataFull" o = GObject.Object.ObjectSetDataFullMethodInfo
ResolveActionableMethod "setDetailedActionName" o = ActionableSetDetailedActionNameMethodInfo
ResolveActionableMethod "setDirection" o = Gtk.Widget.WidgetSetDirectionMethodInfo
ResolveActionableMethod "setFocusChild" o = Gtk.Widget.WidgetSetFocusChildMethodInfo
ResolveActionableMethod "setFocusOnClick" o = Gtk.Widget.WidgetSetFocusOnClickMethodInfo
ResolveActionableMethod "setFocusable" o = Gtk.Widget.WidgetSetFocusableMethodInfo
ResolveActionableMethod "setFontMap" o = Gtk.Widget.WidgetSetFontMapMethodInfo
ResolveActionableMethod "setFontOptions" o = Gtk.Widget.WidgetSetFontOptionsMethodInfo
ResolveActionableMethod "setHalign" o = Gtk.Widget.WidgetSetHalignMethodInfo
ResolveActionableMethod "setHasTooltip" o = Gtk.Widget.WidgetSetHasTooltipMethodInfo
ResolveActionableMethod "setHexpand" o = Gtk.Widget.WidgetSetHexpandMethodInfo
ResolveActionableMethod "setHexpandSet" o = Gtk.Widget.WidgetSetHexpandSetMethodInfo
ResolveActionableMethod "setLayoutManager" o = Gtk.Widget.WidgetSetLayoutManagerMethodInfo
ResolveActionableMethod "setMarginBottom" o = Gtk.Widget.WidgetSetMarginBottomMethodInfo
ResolveActionableMethod "setMarginEnd" o = Gtk.Widget.WidgetSetMarginEndMethodInfo
ResolveActionableMethod "setMarginStart" o = Gtk.Widget.WidgetSetMarginStartMethodInfo
ResolveActionableMethod "setMarginTop" o = Gtk.Widget.WidgetSetMarginTopMethodInfo
ResolveActionableMethod "setName" o = Gtk.Widget.WidgetSetNameMethodInfo
ResolveActionableMethod "setOpacity" o = Gtk.Widget.WidgetSetOpacityMethodInfo
ResolveActionableMethod "setOverflow" o = Gtk.Widget.WidgetSetOverflowMethodInfo
ResolveActionableMethod "setParent" o = Gtk.Widget.WidgetSetParentMethodInfo
ResolveActionableMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
ResolveActionableMethod "setReceivesDefault" o = Gtk.Widget.WidgetSetReceivesDefaultMethodInfo
ResolveActionableMethod "setSensitive" o = Gtk.Widget.WidgetSetSensitiveMethodInfo
ResolveActionableMethod "setSizeRequest" o = Gtk.Widget.WidgetSetSizeRequestMethodInfo
ResolveActionableMethod "setStateFlags" o = Gtk.Widget.WidgetSetStateFlagsMethodInfo
ResolveActionableMethod "setTooltipMarkup" o = Gtk.Widget.WidgetSetTooltipMarkupMethodInfo
ResolveActionableMethod "setTooltipText" o = Gtk.Widget.WidgetSetTooltipTextMethodInfo
ResolveActionableMethod "setValign" o = Gtk.Widget.WidgetSetValignMethodInfo
ResolveActionableMethod "setVexpand" o = Gtk.Widget.WidgetSetVexpandMethodInfo
ResolveActionableMethod "setVexpandSet" o = Gtk.Widget.WidgetSetVexpandSetMethodInfo
ResolveActionableMethod "setVisible" o = Gtk.Widget.WidgetSetVisibleMethodInfo
ResolveActionableMethod l o = O.MethodResolutionFailed l o
instance (info ~ ResolveActionableMethod t Actionable, O.OverloadedMethod info Actionable p) => OL.IsLabel t (Actionable -> p) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.overloadedMethod @info
#else
fromLabel _ = O.overloadedMethod @info
#endif
#if MIN_VERSION_base(4,13,0)
instance (info ~ ResolveActionableMethod t Actionable, O.OverloadedMethod info Actionable p, R.HasField t Actionable p) => R.HasField t Actionable p where
getField = O.overloadedMethod @info
#endif
instance (info ~ ResolveActionableMethod t Actionable, O.OverloadedMethodInfo info Actionable) => OL.IsLabel t (O.MethodProxy info Actionable) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.MethodProxy
#else
fromLabel _ = O.MethodProxy
#endif
#endif
foreign import ccall "gtk_actionable_get_action_name" gtk_actionable_get_action_name ::
Ptr Actionable ->
IO CString
actionableGetActionName ::
(B.CallStack.HasCallStack, MonadIO m, IsActionable a) =>
a
-> m (Maybe T.Text)
actionableGetActionName :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsActionable a) =>
a -> m (Maybe Text)
actionableGetActionName a
actionable = IO (Maybe Text) -> m (Maybe Text)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (Maybe Text) -> m (Maybe Text))
-> IO (Maybe Text) -> m (Maybe Text)
forall a b. (a -> b) -> a -> b
$ do
Ptr Actionable
actionable' <- a -> IO (Ptr Actionable)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
actionable
CString
result <- Ptr Actionable -> IO CString
gtk_actionable_get_action_name Ptr Actionable
actionable'
Maybe Text
maybeResult <- CString -> (CString -> IO Text) -> IO (Maybe Text)
forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
convertIfNonNull CString
result ((CString -> IO Text) -> IO (Maybe Text))
-> (CString -> IO Text) -> IO (Maybe Text)
forall a b. (a -> b) -> a -> b
$ \CString
result' -> do
Text
result'' <- HasCallStack => CString -> IO Text
CString -> IO Text
cstringToText CString
result'
Text -> IO Text
forall (m :: * -> *) a. Monad m => a -> m a
return Text
result''
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
actionable
Maybe Text -> IO (Maybe Text)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe Text
maybeResult
#if defined(ENABLE_OVERLOADING)
data ActionableGetActionNameMethodInfo
instance (signature ~ (m (Maybe T.Text)), MonadIO m, IsActionable a) => O.OverloadedMethod ActionableGetActionNameMethodInfo a signature where
overloadedMethod = actionableGetActionName
instance O.OverloadedMethodInfo ActionableGetActionNameMethodInfo a where
overloadedMethodInfo = O.MethodInfo {
O.overloadedMethodName = "GI.Gtk.Interfaces.Actionable.actionableGetActionName",
O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Interfaces-Actionable.html#v:actionableGetActionName"
}
#endif
foreign import ccall "gtk_actionable_get_action_target_value" gtk_actionable_get_action_target_value ::
Ptr Actionable ->
IO (Ptr GVariant)
actionableGetActionTargetValue ::
(B.CallStack.HasCallStack, MonadIO m, IsActionable a) =>
a
-> m (Maybe GVariant)
actionableGetActionTargetValue :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsActionable a) =>
a -> m (Maybe GVariant)
actionableGetActionTargetValue a
actionable = IO (Maybe GVariant) -> m (Maybe GVariant)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (Maybe GVariant) -> m (Maybe GVariant))
-> IO (Maybe GVariant) -> m (Maybe GVariant)
forall a b. (a -> b) -> a -> b
$ do
Ptr Actionable
actionable' <- a -> IO (Ptr Actionable)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
actionable
Ptr GVariant
result <- Ptr Actionable -> IO (Ptr GVariant)
gtk_actionable_get_action_target_value Ptr Actionable
actionable'
Maybe GVariant
maybeResult <- Ptr GVariant
-> (Ptr GVariant -> IO GVariant) -> IO (Maybe GVariant)
forall a b. Ptr a -> (Ptr a -> IO b) -> IO (Maybe b)
convertIfNonNull Ptr GVariant
result ((Ptr GVariant -> IO GVariant) -> IO (Maybe GVariant))
-> (Ptr GVariant -> IO GVariant) -> IO (Maybe GVariant)
forall a b. (a -> b) -> a -> b
$ \Ptr GVariant
result' -> do
GVariant
result'' <- Ptr GVariant -> IO GVariant
B.GVariant.newGVariantFromPtr Ptr GVariant
result'
GVariant -> IO GVariant
forall (m :: * -> *) a. Monad m => a -> m a
return GVariant
result''
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
actionable
Maybe GVariant -> IO (Maybe GVariant)
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe GVariant
maybeResult
#if defined(ENABLE_OVERLOADING)
data ActionableGetActionTargetValueMethodInfo
instance (signature ~ (m (Maybe GVariant)), MonadIO m, IsActionable a) => O.OverloadedMethod ActionableGetActionTargetValueMethodInfo a signature where
overloadedMethod = actionableGetActionTargetValue
instance O.OverloadedMethodInfo ActionableGetActionTargetValueMethodInfo a where
overloadedMethodInfo = O.MethodInfo {
O.overloadedMethodName = "GI.Gtk.Interfaces.Actionable.actionableGetActionTargetValue",
O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Interfaces-Actionable.html#v:actionableGetActionTargetValue"
}
#endif
foreign import ccall "gtk_actionable_set_action_name" gtk_actionable_set_action_name ::
Ptr Actionable ->
CString ->
IO ()
actionableSetActionName ::
(B.CallStack.HasCallStack, MonadIO m, IsActionable a) =>
a
-> Maybe (T.Text)
-> m ()
actionableSetActionName :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsActionable a) =>
a -> Maybe Text -> m ()
actionableSetActionName a
actionable Maybe Text
actionName = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr Actionable
actionable' <- a -> IO (Ptr Actionable)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
actionable
CString
maybeActionName <- case Maybe Text
actionName of
Maybe Text
Nothing -> CString -> IO CString
forall (m :: * -> *) a. Monad m => a -> m a
return CString
forall a. Ptr a
nullPtr
Just Text
jActionName -> do
CString
jActionName' <- Text -> IO CString
textToCString Text
jActionName
CString -> IO CString
forall (m :: * -> *) a. Monad m => a -> m a
return CString
jActionName'
Ptr Actionable -> CString -> IO ()
gtk_actionable_set_action_name Ptr Actionable
actionable' CString
maybeActionName
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
actionable
CString -> IO ()
forall a. Ptr a -> IO ()
freeMem CString
maybeActionName
() -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data ActionableSetActionNameMethodInfo
instance (signature ~ (Maybe (T.Text) -> m ()), MonadIO m, IsActionable a) => O.OverloadedMethod ActionableSetActionNameMethodInfo a signature where
overloadedMethod = actionableSetActionName
instance O.OverloadedMethodInfo ActionableSetActionNameMethodInfo a where
overloadedMethodInfo = O.MethodInfo {
O.overloadedMethodName = "GI.Gtk.Interfaces.Actionable.actionableSetActionName",
O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Interfaces-Actionable.html#v:actionableSetActionName"
}
#endif
foreign import ccall "gtk_actionable_set_action_target_value" gtk_actionable_set_action_target_value ::
Ptr Actionable ->
Ptr GVariant ->
IO ()
actionableSetActionTargetValue ::
(B.CallStack.HasCallStack, MonadIO m, IsActionable a) =>
a
-> Maybe (GVariant)
-> m ()
actionableSetActionTargetValue :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsActionable a) =>
a -> Maybe GVariant -> m ()
actionableSetActionTargetValue a
actionable Maybe GVariant
targetValue = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr Actionable
actionable' <- a -> IO (Ptr Actionable)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
actionable
Ptr GVariant
maybeTargetValue <- case Maybe GVariant
targetValue of
Maybe GVariant
Nothing -> Ptr GVariant -> IO (Ptr GVariant)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr GVariant
forall a. Ptr a
nullPtr
Just GVariant
jTargetValue -> do
Ptr GVariant
jTargetValue' <- GVariant -> IO (Ptr GVariant)
forall a. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr a)
unsafeManagedPtrGetPtr GVariant
jTargetValue
Ptr GVariant -> IO (Ptr GVariant)
forall (m :: * -> *) a. Monad m => a -> m a
return Ptr GVariant
jTargetValue'
Ptr Actionable -> Ptr GVariant -> IO ()
gtk_actionable_set_action_target_value Ptr Actionable
actionable' Ptr GVariant
maybeTargetValue
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
actionable
Maybe GVariant -> (GVariant -> IO ()) -> IO ()
forall (m :: * -> *) a. Monad m => Maybe a -> (a -> m ()) -> m ()
whenJust Maybe GVariant
targetValue GVariant -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr
() -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data ActionableSetActionTargetValueMethodInfo
instance (signature ~ (Maybe (GVariant) -> m ()), MonadIO m, IsActionable a) => O.OverloadedMethod ActionableSetActionTargetValueMethodInfo a signature where
overloadedMethod = actionableSetActionTargetValue
instance O.OverloadedMethodInfo ActionableSetActionTargetValueMethodInfo a where
overloadedMethodInfo = O.MethodInfo {
O.overloadedMethodName = "GI.Gtk.Interfaces.Actionable.actionableSetActionTargetValue",
O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Interfaces-Actionable.html#v:actionableSetActionTargetValue"
}
#endif
foreign import ccall "gtk_actionable_set_detailed_action_name" gtk_actionable_set_detailed_action_name ::
Ptr Actionable ->
CString ->
IO ()
actionableSetDetailedActionName ::
(B.CallStack.HasCallStack, MonadIO m, IsActionable a) =>
a
-> T.Text
-> m ()
actionableSetDetailedActionName :: forall (m :: * -> *) a.
(HasCallStack, MonadIO m, IsActionable a) =>
a -> Text -> m ()
actionableSetDetailedActionName a
actionable Text
detailedActionName = IO () -> m ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> m ()) -> IO () -> m ()
forall a b. (a -> b) -> a -> b
$ do
Ptr Actionable
actionable' <- a -> IO (Ptr Actionable)
forall a b. (HasCallStack, ManagedPtrNewtype a) => a -> IO (Ptr b)
unsafeManagedPtrCastPtr a
actionable
CString
detailedActionName' <- Text -> IO CString
textToCString Text
detailedActionName
Ptr Actionable -> CString -> IO ()
gtk_actionable_set_detailed_action_name Ptr Actionable
actionable' CString
detailedActionName'
a -> IO ()
forall a. ManagedPtrNewtype a => a -> IO ()
touchManagedPtr a
actionable
CString -> IO ()
forall a. Ptr a -> IO ()
freeMem CString
detailedActionName'
() -> IO ()
forall (m :: * -> *) a. Monad m => a -> m a
return ()
#if defined(ENABLE_OVERLOADING)
data ActionableSetDetailedActionNameMethodInfo
instance (signature ~ (T.Text -> m ()), MonadIO m, IsActionable a) => O.OverloadedMethod ActionableSetDetailedActionNameMethodInfo a signature where
overloadedMethod = actionableSetDetailedActionName
instance O.OverloadedMethodInfo ActionableSetDetailedActionNameMethodInfo a where
overloadedMethodInfo = O.MethodInfo {
O.overloadedMethodName = "GI.Gtk.Interfaces.Actionable.actionableSetDetailedActionName",
O.overloadedMethodURL = "https://hackage.haskell.org/package/gi-gtk-4.0.4/docs/GI-Gtk-Interfaces-Actionable.html#v:actionableSetDetailedActionName"
}
#endif
#if defined(ENABLE_OVERLOADING)
type instance O.SignalList Actionable = ActionableSignalList
type ActionableSignalList = ('[ '("destroy", Gtk.Widget.WidgetDestroySignalInfo), '("directionChanged", Gtk.Widget.WidgetDirectionChangedSignalInfo), '("hide", Gtk.Widget.WidgetHideSignalInfo), '("keynavFailed", Gtk.Widget.WidgetKeynavFailedSignalInfo), '("map", Gtk.Widget.WidgetMapSignalInfo), '("mnemonicActivate", Gtk.Widget.WidgetMnemonicActivateSignalInfo), '("moveFocus", Gtk.Widget.WidgetMoveFocusSignalInfo), '("notify", GObject.Object.ObjectNotifySignalInfo), '("queryTooltip", Gtk.Widget.WidgetQueryTooltipSignalInfo), '("realize", Gtk.Widget.WidgetRealizeSignalInfo), '("show", Gtk.Widget.WidgetShowSignalInfo), '("stateFlagsChanged", Gtk.Widget.WidgetStateFlagsChangedSignalInfo), '("unmap", Gtk.Widget.WidgetUnmapSignalInfo), '("unrealize", Gtk.Widget.WidgetUnrealizeSignalInfo)] :: [(Symbol, *)])
#endif