{- |
Copyright  : Will Thompson, Iñaki García Etxebarria and Jonas Platte
License    : LGPL-2.1
Maintainer : Iñaki García Etxebarria (garetxe@gmail.com)
-}

module GI.Gtk.Objects.RecentChooserWidget
    ( 

-- * Exported types
    RecentChooserWidget(..)                 ,
    RecentChooserWidgetK                    ,
    toRecentChooserWidget                   ,
    noRecentChooserWidget                   ,


 -- * Methods
-- ** recentChooserWidgetNew
    recentChooserWidgetNew                  ,


-- ** recentChooserWidgetNewForManager
    recentChooserWidgetNewForManager        ,




    ) where

import Prelude ()
import Data.GI.Base.ShortPrelude

import qualified Data.Text as T
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map

import GI.Gtk.Types
import GI.Gtk.Callbacks
import qualified GI.Atk as Atk
import qualified GI.GObject as GObject

newtype RecentChooserWidget = RecentChooserWidget (ForeignPtr RecentChooserWidget)
foreign import ccall "gtk_recent_chooser_widget_get_type"
    c_gtk_recent_chooser_widget_get_type :: IO GType

type instance ParentTypes RecentChooserWidget = RecentChooserWidgetParentTypes
type RecentChooserWidgetParentTypes = '[Box, Container, Widget, GObject.Object, Atk.ImplementorIface, Buildable, Orientable, RecentChooser]

instance GObject RecentChooserWidget where
    gobjectIsInitiallyUnowned _ = True
    gobjectType _ = c_gtk_recent_chooser_widget_get_type
    

class GObject o => RecentChooserWidgetK o
instance (GObject o, IsDescendantOf RecentChooserWidget o) => RecentChooserWidgetK o

toRecentChooserWidget :: RecentChooserWidgetK o => o -> IO RecentChooserWidget
toRecentChooserWidget = unsafeCastTo RecentChooserWidget

noRecentChooserWidget :: Maybe RecentChooserWidget
noRecentChooserWidget = Nothing

type instance AttributeList RecentChooserWidget = RecentChooserWidgetAttributeList
type RecentChooserWidgetAttributeList = ('[ '("app-paintable", WidgetAppPaintablePropertyInfo), '("baseline-position", BoxBaselinePositionPropertyInfo), '("border-width", ContainerBorderWidthPropertyInfo), '("can-default", WidgetCanDefaultPropertyInfo), '("can-focus", WidgetCanFocusPropertyInfo), '("child", ContainerChildPropertyInfo), '("composite-child", WidgetCompositeChildPropertyInfo), '("double-buffered", WidgetDoubleBufferedPropertyInfo), '("events", WidgetEventsPropertyInfo), '("expand", WidgetExpandPropertyInfo), '("filter", RecentChooserFilterPropertyInfo), '("halign", WidgetHalignPropertyInfo), '("has-default", WidgetHasDefaultPropertyInfo), '("has-focus", WidgetHasFocusPropertyInfo), '("has-tooltip", WidgetHasTooltipPropertyInfo), '("height-request", WidgetHeightRequestPropertyInfo), '("hexpand", WidgetHexpandPropertyInfo), '("hexpand-set", WidgetHexpandSetPropertyInfo), '("homogeneous", BoxHomogeneousPropertyInfo), '("is-focus", WidgetIsFocusPropertyInfo), '("limit", RecentChooserLimitPropertyInfo), '("local-only", RecentChooserLocalOnlyPropertyInfo), '("margin", WidgetMarginPropertyInfo), '("margin-bottom", WidgetMarginBottomPropertyInfo), '("margin-end", WidgetMarginEndPropertyInfo), '("margin-left", WidgetMarginLeftPropertyInfo), '("margin-right", WidgetMarginRightPropertyInfo), '("margin-start", WidgetMarginStartPropertyInfo), '("margin-top", WidgetMarginTopPropertyInfo), '("name", WidgetNamePropertyInfo), '("no-show-all", WidgetNoShowAllPropertyInfo), '("opacity", WidgetOpacityPropertyInfo), '("orientation", OrientableOrientationPropertyInfo), '("parent", WidgetParentPropertyInfo), '("receives-default", WidgetReceivesDefaultPropertyInfo), '("recent-manager", RecentChooserRecentManagerPropertyInfo), '("resize-mode", ContainerResizeModePropertyInfo), '("scale-factor", WidgetScaleFactorPropertyInfo), '("select-multiple", RecentChooserSelectMultiplePropertyInfo), '("sensitive", WidgetSensitivePropertyInfo), '("show-icons", RecentChooserShowIconsPropertyInfo), '("show-not-found", RecentChooserShowNotFoundPropertyInfo), '("show-private", RecentChooserShowPrivatePropertyInfo), '("show-tips", RecentChooserShowTipsPropertyInfo), '("sort-type", RecentChooserSortTypePropertyInfo), '("spacing", BoxSpacingPropertyInfo), '("style", WidgetStylePropertyInfo), '("tooltip-markup", WidgetTooltipMarkupPropertyInfo), '("tooltip-text", WidgetTooltipTextPropertyInfo), '("valign", WidgetValignPropertyInfo), '("vexpand", WidgetVexpandPropertyInfo), '("vexpand-set", WidgetVexpandSetPropertyInfo), '("visible", WidgetVisiblePropertyInfo), '("width-request", WidgetWidthRequestPropertyInfo), '("window", WidgetWindowPropertyInfo)] :: [(Symbol, *)])

type instance SignalList RecentChooserWidget = RecentChooserWidgetSignalList
type RecentChooserWidgetSignalList = ('[ '("accel-closures-changed", WidgetAccelClosuresChangedSignalInfo), '("add", ContainerAddSignalInfo), '("button-press-event", WidgetButtonPressEventSignalInfo), '("button-release-event", WidgetButtonReleaseEventSignalInfo), '("can-activate-accel", WidgetCanActivateAccelSignalInfo), '("check-resize", ContainerCheckResizeSignalInfo), '("child-notify", WidgetChildNotifySignalInfo), '("composited-changed", WidgetCompositedChangedSignalInfo), '("configure-event", WidgetConfigureEventSignalInfo), '("damage-event", WidgetDamageEventSignalInfo), '("delete-event", WidgetDeleteEventSignalInfo), '("destroy", WidgetDestroySignalInfo), '("destroy-event", WidgetDestroyEventSignalInfo), '("direction-changed", WidgetDirectionChangedSignalInfo), '("drag-begin", WidgetDragBeginSignalInfo), '("drag-data-delete", WidgetDragDataDeleteSignalInfo), '("drag-data-get", WidgetDragDataGetSignalInfo), '("drag-data-received", WidgetDragDataReceivedSignalInfo), '("drag-drop", WidgetDragDropSignalInfo), '("drag-end", WidgetDragEndSignalInfo), '("drag-failed", WidgetDragFailedSignalInfo), '("drag-leave", WidgetDragLeaveSignalInfo), '("drag-motion", WidgetDragMotionSignalInfo), '("draw", WidgetDrawSignalInfo), '("enter-notify-event", WidgetEnterNotifyEventSignalInfo), '("event", WidgetEventSignalInfo), '("event-after", WidgetEventAfterSignalInfo), '("focus", WidgetFocusSignalInfo), '("focus-in-event", WidgetFocusInEventSignalInfo), '("focus-out-event", WidgetFocusOutEventSignalInfo), '("grab-broken-event", WidgetGrabBrokenEventSignalInfo), '("grab-focus", WidgetGrabFocusSignalInfo), '("grab-notify", WidgetGrabNotifySignalInfo), '("hide", WidgetHideSignalInfo), '("hierarchy-changed", WidgetHierarchyChangedSignalInfo), '("item-activated", RecentChooserItemActivatedSignalInfo), '("key-press-event", WidgetKeyPressEventSignalInfo), '("key-release-event", WidgetKeyReleaseEventSignalInfo), '("keynav-failed", WidgetKeynavFailedSignalInfo), '("leave-notify-event", WidgetLeaveNotifyEventSignalInfo), '("map", WidgetMapSignalInfo), '("map-event", WidgetMapEventSignalInfo), '("mnemonic-activate", WidgetMnemonicActivateSignalInfo), '("motion-notify-event", WidgetMotionNotifyEventSignalInfo), '("move-focus", WidgetMoveFocusSignalInfo), '("notify", GObject.ObjectNotifySignalInfo), '("parent-set", WidgetParentSetSignalInfo), '("popup-menu", WidgetPopupMenuSignalInfo), '("property-notify-event", WidgetPropertyNotifyEventSignalInfo), '("proximity-in-event", WidgetProximityInEventSignalInfo), '("proximity-out-event", WidgetProximityOutEventSignalInfo), '("query-tooltip", WidgetQueryTooltipSignalInfo), '("realize", WidgetRealizeSignalInfo), '("remove", ContainerRemoveSignalInfo), '("screen-changed", WidgetScreenChangedSignalInfo), '("scroll-event", WidgetScrollEventSignalInfo), '("selection-changed", RecentChooserSelectionChangedSignalInfo), '("selection-clear-event", WidgetSelectionClearEventSignalInfo), '("selection-get", WidgetSelectionGetSignalInfo), '("selection-notify-event", WidgetSelectionNotifyEventSignalInfo), '("selection-received", WidgetSelectionReceivedSignalInfo), '("selection-request-event", WidgetSelectionRequestEventSignalInfo), '("set-focus-child", ContainerSetFocusChildSignalInfo), '("show", WidgetShowSignalInfo), '("show-help", WidgetShowHelpSignalInfo), '("size-allocate", WidgetSizeAllocateSignalInfo), '("state-changed", WidgetStateChangedSignalInfo), '("state-flags-changed", WidgetStateFlagsChangedSignalInfo), '("style-set", WidgetStyleSetSignalInfo), '("style-updated", WidgetStyleUpdatedSignalInfo), '("touch-event", WidgetTouchEventSignalInfo), '("unmap", WidgetUnmapSignalInfo), '("unmap-event", WidgetUnmapEventSignalInfo), '("unrealize", WidgetUnrealizeSignalInfo), '("visibility-notify-event", WidgetVisibilityNotifyEventSignalInfo), '("window-state-event", WidgetWindowStateEventSignalInfo), '("notify::[property]", GObjectNotifySignalInfo)] :: [(Symbol, *)])

-- method RecentChooserWidget::new
-- method type : Constructor
-- Args : []
-- Lengths : []
-- hInArgs : []
-- returnType : TInterface "Gtk" "RecentChooserWidget"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_recent_chooser_widget_new" gtk_recent_chooser_widget_new :: 
    IO (Ptr RecentChooserWidget)


recentChooserWidgetNew ::
    (MonadIO m) =>
    m RecentChooserWidget
recentChooserWidgetNew  = liftIO $ do
    result <- gtk_recent_chooser_widget_new
    checkUnexpectedReturnNULL "gtk_recent_chooser_widget_new" result
    result' <- (newObject RecentChooserWidget) result
    return result'

-- method RecentChooserWidget::new_for_manager
-- method type : Constructor
-- Args : [Arg {argName = "manager", argType = TInterface "Gtk" "RecentManager", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- Lengths : []
-- hInArgs : [Arg {argName = "manager", argType = TInterface "Gtk" "RecentManager", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}]
-- returnType : TInterface "Gtk" "RecentChooserWidget"
-- throws : False
-- Skip return : False

foreign import ccall "gtk_recent_chooser_widget_new_for_manager" gtk_recent_chooser_widget_new_for_manager :: 
    Ptr RecentManager ->                    -- manager : TInterface "Gtk" "RecentManager"
    IO (Ptr RecentChooserWidget)


recentChooserWidgetNewForManager ::
    (MonadIO m, RecentManagerK a) =>
    a ->                                    -- manager
    m RecentChooserWidget
recentChooserWidgetNewForManager manager = liftIO $ do
    let manager' = unsafeManagedPtrCastPtr manager
    result <- gtk_recent_chooser_widget_new_for_manager manager'
    checkUnexpectedReturnNULL "gtk_recent_chooser_widget_new_for_manager" result
    result' <- (newObject RecentChooserWidget) result
    touchManagedPtr manager
    return result'