{-# LANGUAGE DeriveDataTypeable #-}

{-# LINE 2 "./System/GIO/Enums.chs" #-}
-- GIMP Toolkit (GTK) Binding for Haskell: binding to gio -*-haskell-*-
--
-- Author : Andy Stewart
-- Created: 30-April-2010
--
-- Copyright (c) 2010 Andy Stewart
--
-- This library is free software: you can redistribute it and/or
-- modify it under the terms of the GNU Lesser General Public License
-- as published by the Free Software Foundation, either version 3 of
-- the License, or (at your option) any later version.
--
-- This library is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-- Lesser General Public License for more details.
--
-- You should have received a copy of the GNU Lesser General Public
-- License along with this program. If not, see
-- <http:
--
-- GIO, the C library which this Haskell library depends on, is
-- available under LGPL Version 2. The documentation included with
-- this library is based on the original GIO documentation.
--
-- | Maintainer : gtk2hs-devel@lists.sourceforge.net
-- Stability : alpha
-- Portability : portable (depends on GHC)
module System.GIO.Enums (
-- * Enums
    FileQueryInfoFlags(..),
    FileCreateFlags(..),
    FileCopyFlags(..),
    FileMonitorFlags(..),
    FilesystemPreviewType(..),
    FileType(..),
    FileAttributeStatus(..),
    FileAttributeInfoFlags(..),

    AskPasswordFlags(..),
    PasswordSave(..),
    MountOperationResult(..),

    IOErrorEnum(..),

    FileMonitorEvent(..),
    MountMountFlags(..),
    MountUnmountFlags(..),


    DriveStartFlags(..),
    DriveStartStopType(..),



    EmblemOrigin(..),


    AppInfoCreateFlags(..),
    ) where

import Control.Monad
import Data.Typeable
import System.Glib.FFI
import System.Glib.Flags
import System.Glib.GError
import System.Glib.GObject
import System.Glib.UTFString


{-# LINE 72 "./System/GIO/Enums.chs" #-}

-- | Flags used when querying a 'FileInfo'.
data FileQueryInfoFlags = FileQueryInfoNone
                        | FileQueryInfoNofollowSymlinks
                        deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum FileQueryInfoFlags where
  fromEnum FileQueryInfoNone = 0
  fromEnum FileQueryInfoNofollowSymlinks = 1

  toEnum 0 = FileQueryInfoNone
  toEnum 1 = FileQueryInfoNofollowSymlinks
  toEnum unmatched = error ("FileQueryInfoFlags.toEnum: Cannot match " ++ show unmatched)

  succ FileQueryInfoNone = FileQueryInfoNofollowSymlinks
  succ _ = undefined

  pred FileQueryInfoNofollowSymlinks = FileQueryInfoNone
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x FileQueryInfoNofollowSymlinks
  enumFromThen _ _ =     error "Enum FileQueryInfoFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum FileQueryInfoFlags: enumFromThenTo not implemented"

{-# LINE 75 "./System/GIO/Enums.chs" #-}
instance Flags FileQueryInfoFlags

-- | Flags used when an operation may create a file.
data FileCreateFlags = FileCreateNone
                     | FileCreatePrivate
                     | FileCreateReplaceDestination
                     deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum FileCreateFlags where
  fromEnum FileCreateNone = 0
  fromEnum FileCreatePrivate = 1
  fromEnum FileCreateReplaceDestination = 2

  toEnum 0 = FileCreateNone
  toEnum 1 = FileCreatePrivate
  toEnum 2 = FileCreateReplaceDestination
  toEnum unmatched = error ("FileCreateFlags.toEnum: Cannot match " ++ show unmatched)

  succ FileCreateNone = FileCreatePrivate
  succ FileCreatePrivate = FileCreateReplaceDestination
  succ _ = undefined

  pred FileCreatePrivate = FileCreateNone
  pred FileCreateReplaceDestination = FileCreatePrivate
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x FileCreateReplaceDestination
  enumFromThen _ _ =     error "Enum FileCreateFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum FileCreateFlags: enumFromThenTo not implemented"

{-# LINE 79 "./System/GIO/Enums.chs" #-}
instance Flags FileCreateFlags

-- | Flags used when copying or moving files.
data FileCopyFlags = FileCopyNone
                   | FileCopyOverwrite
                   | FileCopyBackup
                   | FileCopyNofollowSymlinks
                   | FileCopyAllMetadata
                   | FileCopyNoFallbackForMove
                   | FileCopyTargetDefaultPerms
                   deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum FileCopyFlags where
  fromEnum FileCopyNone = 0
  fromEnum FileCopyOverwrite = 1
  fromEnum FileCopyBackup = 2
  fromEnum FileCopyNofollowSymlinks = 4
  fromEnum FileCopyAllMetadata = 8
  fromEnum FileCopyNoFallbackForMove = 16
  fromEnum FileCopyTargetDefaultPerms = 32

  toEnum 0 = FileCopyNone
  toEnum 1 = FileCopyOverwrite
  toEnum 2 = FileCopyBackup
  toEnum 4 = FileCopyNofollowSymlinks
  toEnum 8 = FileCopyAllMetadata
  toEnum 16 = FileCopyNoFallbackForMove
  toEnum 32 = FileCopyTargetDefaultPerms
  toEnum unmatched = error ("FileCopyFlags.toEnum: Cannot match " ++ show unmatched)

  succ FileCopyNone = FileCopyOverwrite
  succ FileCopyOverwrite = FileCopyBackup
  succ FileCopyBackup = FileCopyNofollowSymlinks
  succ FileCopyNofollowSymlinks = FileCopyAllMetadata
  succ FileCopyAllMetadata = FileCopyNoFallbackForMove
  succ FileCopyNoFallbackForMove = FileCopyTargetDefaultPerms
  succ _ = undefined

  pred FileCopyOverwrite = FileCopyNone
  pred FileCopyBackup = FileCopyOverwrite
  pred FileCopyNofollowSymlinks = FileCopyBackup
  pred FileCopyAllMetadata = FileCopyNofollowSymlinks
  pred FileCopyNoFallbackForMove = FileCopyAllMetadata
  pred FileCopyTargetDefaultPerms = FileCopyNoFallbackForMove
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x FileCopyTargetDefaultPerms
  enumFromThen _ _ =     error "Enum FileCopyFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum FileCopyFlags: enumFromThenTo not implemented"

{-# LINE 83 "./System/GIO/Enums.chs" #-}
instance Flags FileCopyFlags

-- | Flags used to set what a 'FileMonitor' will watch for.
data FileMonitorFlags = FileMonitorNone
                      | FileMonitorWatchMounts
                      | FileMonitorSendMoved
                      deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum FileMonitorFlags where
  fromEnum FileMonitorNone = 0
  fromEnum FileMonitorWatchMounts = 1
  fromEnum FileMonitorSendMoved = 2

  toEnum 0 = FileMonitorNone
  toEnum 1 = FileMonitorWatchMounts
  toEnum 2 = FileMonitorSendMoved
  toEnum unmatched = error ("FileMonitorFlags.toEnum: Cannot match " ++ show unmatched)

  succ FileMonitorNone = FileMonitorWatchMounts
  succ FileMonitorWatchMounts = FileMonitorSendMoved
  succ _ = undefined

  pred FileMonitorWatchMounts = FileMonitorNone
  pred FileMonitorSendMoved = FileMonitorWatchMounts
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x FileMonitorSendMoved
  enumFromThen _ _ =     error "Enum FileMonitorFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum FileMonitorFlags: enumFromThenTo not implemented"

{-# LINE 87 "./System/GIO/Enums.chs" #-}
instance Flags FileMonitorFlags

-- | Indicates a hint from the file system whether files should be previewed in a file manager. Returned
-- as the value of the key 'FileAttributeFilesystemUsePreview'.
data FilesystemPreviewType = FilesystemPreviewTypeIfAlways
                           | FilesystemPreviewTypeIfLocal
                           | FilesystemPreviewTypeNever
                           deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum FilesystemPreviewType where
  fromEnum FilesystemPreviewTypeIfAlways = 0
  fromEnum FilesystemPreviewTypeIfLocal = 1
  fromEnum FilesystemPreviewTypeNever = 2

  toEnum 0 = FilesystemPreviewTypeIfAlways
  toEnum 1 = FilesystemPreviewTypeIfLocal
  toEnum 2 = FilesystemPreviewTypeNever
  toEnum unmatched = error ("FilesystemPreviewType.toEnum: Cannot match " ++ show unmatched)

  succ FilesystemPreviewTypeIfAlways = FilesystemPreviewTypeIfLocal
  succ FilesystemPreviewTypeIfLocal = FilesystemPreviewTypeNever
  succ _ = undefined

  pred FilesystemPreviewTypeIfLocal = FilesystemPreviewTypeIfAlways
  pred FilesystemPreviewTypeNever = FilesystemPreviewTypeIfLocal
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x FilesystemPreviewTypeNever
  enumFromThen _ _ =     error "Enum FilesystemPreviewType: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum FilesystemPreviewType: enumFromThenTo not implemented"

{-# LINE 92 "./System/GIO/Enums.chs" #-}

-- | Indicates the file's on-disk type.
data FileType = FileTypeUnknown
              | FileTypeRegular
              | FileTypeDirectory
              | FileTypeSymbolicLink
              | FileTypeSpecial
              | FileTypeShortcut
              | FileTypeMountable
              deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum FileType where
  fromEnum FileTypeUnknown = 0
  fromEnum FileTypeRegular = 1
  fromEnum FileTypeDirectory = 2
  fromEnum FileTypeSymbolicLink = 3
  fromEnum FileTypeSpecial = 4
  fromEnum FileTypeShortcut = 5
  fromEnum FileTypeMountable = 6

  toEnum 0 = FileTypeUnknown
  toEnum 1 = FileTypeRegular
  toEnum 2 = FileTypeDirectory
  toEnum 3 = FileTypeSymbolicLink
  toEnum 4 = FileTypeSpecial
  toEnum 5 = FileTypeShortcut
  toEnum 6 = FileTypeMountable
  toEnum unmatched = error ("FileType.toEnum: Cannot match " ++ show unmatched)

  succ FileTypeUnknown = FileTypeRegular
  succ FileTypeRegular = FileTypeDirectory
  succ FileTypeDirectory = FileTypeSymbolicLink
  succ FileTypeSymbolicLink = FileTypeSpecial
  succ FileTypeSpecial = FileTypeShortcut
  succ FileTypeShortcut = FileTypeMountable
  succ _ = undefined

  pred FileTypeRegular = FileTypeUnknown
  pred FileTypeDirectory = FileTypeRegular
  pred FileTypeSymbolicLink = FileTypeDirectory
  pred FileTypeSpecial = FileTypeSymbolicLink
  pred FileTypeShortcut = FileTypeSpecial
  pred FileTypeMountable = FileTypeShortcut
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x FileTypeMountable
  enumFromThen _ _ =     error "Enum FileType: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum FileType: enumFromThenTo not implemented"

{-# LINE 95 "./System/GIO/Enums.chs" #-}

-- | Used by 'fileSetAttributesFromInfo' when setting file attributes.
data FileAttributeStatus = FileAttributeStatusUnset
                         | FileAttributeStatusSet
                         | FileAttributeStatusErrorSetting
                         deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum FileAttributeStatus where
  fromEnum FileAttributeStatusUnset = 0
  fromEnum FileAttributeStatusSet = 1
  fromEnum FileAttributeStatusErrorSetting = 2

  toEnum 0 = FileAttributeStatusUnset
  toEnum 1 = FileAttributeStatusSet
  toEnum 2 = FileAttributeStatusErrorSetting
  toEnum unmatched = error ("FileAttributeStatus.toEnum: Cannot match " ++ show unmatched)

  succ FileAttributeStatusUnset = FileAttributeStatusSet
  succ FileAttributeStatusSet = FileAttributeStatusErrorSetting
  succ _ = undefined

  pred FileAttributeStatusSet = FileAttributeStatusUnset
  pred FileAttributeStatusErrorSetting = FileAttributeStatusSet
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x FileAttributeStatusErrorSetting
  enumFromThen _ _ =     error "Enum FileAttributeStatus: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum FileAttributeStatus: enumFromThenTo not implemented"

{-# LINE 98 "./System/GIO/Enums.chs" #-}

-- | Flags specifying the behaviour of an attribute.
data FileAttributeInfoFlags = FileAttributeInfoNone
                            | FileAttributeInfoCopyWithFile
                            | FileAttributeInfoCopyWhenMoved
                            deriving (Eq,Ord,Bounded,Read,Show)
instance Enum FileAttributeInfoFlags where
  fromEnum FileAttributeInfoNone = 0
  fromEnum FileAttributeInfoCopyWithFile = 1
  fromEnum FileAttributeInfoCopyWhenMoved = 2

  toEnum 0 = FileAttributeInfoNone
  toEnum 1 = FileAttributeInfoCopyWithFile
  toEnum 2 = FileAttributeInfoCopyWhenMoved
  toEnum unmatched = error ("FileAttributeInfoFlags.toEnum: Cannot match " ++ show unmatched)

  succ FileAttributeInfoNone = FileAttributeInfoCopyWithFile
  succ FileAttributeInfoCopyWithFile = FileAttributeInfoCopyWhenMoved
  succ _ = undefined

  pred FileAttributeInfoCopyWithFile = FileAttributeInfoNone
  pred FileAttributeInfoCopyWhenMoved = FileAttributeInfoCopyWithFile
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x FileAttributeInfoCopyWhenMoved
  enumFromThen _ _ =     error "Enum FileAttributeInfoFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum FileAttributeInfoFlags: enumFromThenTo not implemented"

{-# LINE 101 "./System/GIO/Enums.chs" #-}
instance Flags FileAttributeInfoFlags

-- | 'AskPasswordFlags' are used to request specific information from the user, or to notify the user of
-- their choices in an authentication situation.
data AskPasswordFlags = AskPasswordNeedPassword
                      | AskPasswordNeedUsername
                      | AskPasswordNeedDomain
                      | AskPasswordSavingSupported
                      | AskPasswordAnonymousSupported
                      deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum AskPasswordFlags where
  fromEnum AskPasswordNeedPassword = 1
  fromEnum AskPasswordNeedUsername = 2
  fromEnum AskPasswordNeedDomain = 4
  fromEnum AskPasswordSavingSupported = 8
  fromEnum AskPasswordAnonymousSupported = 16

  toEnum 1 = AskPasswordNeedPassword
  toEnum 2 = AskPasswordNeedUsername
  toEnum 4 = AskPasswordNeedDomain
  toEnum 8 = AskPasswordSavingSupported
  toEnum 16 = AskPasswordAnonymousSupported
  toEnum unmatched = error ("AskPasswordFlags.toEnum: Cannot match " ++ show unmatched)

  succ AskPasswordNeedPassword = AskPasswordNeedUsername
  succ AskPasswordNeedUsername = AskPasswordNeedDomain
  succ AskPasswordNeedDomain = AskPasswordSavingSupported
  succ AskPasswordSavingSupported = AskPasswordAnonymousSupported
  succ _ = undefined

  pred AskPasswordNeedUsername = AskPasswordNeedPassword
  pred AskPasswordNeedDomain = AskPasswordNeedUsername
  pred AskPasswordSavingSupported = AskPasswordNeedDomain
  pred AskPasswordAnonymousSupported = AskPasswordSavingSupported
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x AskPasswordAnonymousSupported
  enumFromThen _ _ =     error "Enum AskPasswordFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum AskPasswordFlags: enumFromThenTo not implemented"

{-# LINE 106 "./System/GIO/Enums.chs" #-}
instance Flags AskPasswordFlags

-- | 'PasswordSave' is used to indicate the lifespan of a saved password.
data PasswordSave = PasswordSaveNever
                  | PasswordSaveForSession
                  | PasswordSavePermanently
                  deriving (Enum,Eq,Ord,Bounded,Show,Typeable)

{-# LINE 110 "./System/GIO/Enums.chs" #-}

-- | 'MountOperationResult' is returned as a result when a request for information is send by the mounting
-- operation.
data MountOperationResult = MountOperationHandled
                          | MountOperationAborted
                          | MountOperationUnhandled
                          deriving (Enum,Eq,Ord,Bounded,Show,Typeable)

{-# LINE 114 "./System/GIO/Enums.chs" #-}

-- | Error codes returned by GIO functions.
data IOErrorEnum = IoErrorFailed
                 | IoErrorNotFound
                 | IoErrorExists
                 | IoErrorIsDirectory
                 | IoErrorNotDirectory
                 | IoErrorNotEmpty
                 | IoErrorNotRegularFile
                 | IoErrorNotSymbolicLink
                 | IoErrorNotMountableFile
                 | IoErrorFilenameTooLong
                 | IoErrorInvalidFilename
                 | IoErrorTooManyLinks
                 | IoErrorNoSpace
                 | IoErrorInvalidArgument
                 | IoErrorPermissionDenied
                 | IoErrorNotSupported
                 | IoErrorNotMounted
                 | IoErrorAlreadyMounted
                 | IoErrorClosed
                 | IoErrorCancelled
                 | IoErrorPending
                 | IoErrorReadOnly
                 | IoErrorCantCreateBackup
                 | IoErrorWrongEtag
                 | IoErrorTimedOut
                 | IoErrorWouldRecurse
                 | IoErrorBusy
                 | IoErrorWouldBlock
                 | IoErrorHostNotFound
                 | IoErrorWouldMerge
                 | IoErrorFailedHandled
                 | IoErrorTooManyOpenFiles
                 | IoErrorNotInitialized
                 | IoErrorAddressInUse
                 | IoErrorPartialInput
                 | IoErrorInvalidData
                 | IoErrorDbusError
                 | IoErrorHostUnreachable
                 | IoErrorNetworkUnreachable
                 | IoErrorConnectionRefused
                 | IoErrorProxyFailed
                 | IoErrorProxyAuthFailed
                 | IoErrorProxyNeedAuth
                 | IoErrorProxyNotAllowed
                 deriving (Enum,Eq,Ord,Bounded,Show,Typeable)

{-# LINE 117 "./System/GIO/Enums.chs" #-}

-- | Specifies what type of event a monitor event is.
data FileMonitorEvent = FileMonitorEventChanged
                      | FileMonitorEventChangesDoneHint
                      | FileMonitorEventDeleted
                      | FileMonitorEventCreated
                      | FileMonitorEventAttributeChanged
                      | FileMonitorEventPreUnmount
                      | FileMonitorEventUnmounted
                      | FileMonitorEventMoved
                      deriving (Enum,Eq,Ord,Bounded,Show,Typeable)

{-# LINE 120 "./System/GIO/Enums.chs" #-}

-- | Flags used when mounting a mount.
data MountMountFlags = MountMountNone
                     deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum MountMountFlags where
  fromEnum MountMountNone = 0

  toEnum 0 = MountMountNone
  toEnum unmatched = error ("MountMountFlags.toEnum: Cannot match " ++ show unmatched)

  succ _ = undefined

  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x MountMountNone
  enumFromThen _ _ =     error "Enum MountMountFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum MountMountFlags: enumFromThenTo not implemented"

{-# LINE 123 "./System/GIO/Enums.chs" #-}
instance Flags MountMountFlags

-- | Flags used when an unmounting a mount.
data MountUnmountFlags = MountUnmountNone
                       | MountUnmountForce
                       deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum MountUnmountFlags where
  fromEnum MountUnmountNone = 0
  fromEnum MountUnmountForce = 1

  toEnum 0 = MountUnmountNone
  toEnum 1 = MountUnmountForce
  toEnum unmatched = error ("MountUnmountFlags.toEnum: Cannot match " ++ show unmatched)

  succ MountUnmountNone = MountUnmountForce
  succ _ = undefined

  pred MountUnmountForce = MountUnmountNone
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x MountUnmountForce
  enumFromThen _ _ =     error "Enum MountUnmountFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum MountUnmountFlags: enumFromThenTo not implemented"

{-# LINE 127 "./System/GIO/Enums.chs" #-}
instance Flags MountUnmountFlags


-- | Flags used when starting a drive.
data DriveStartFlags = DriveStartNone
                     deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum DriveStartFlags where
  fromEnum DriveStartNone = 0

  toEnum 0 = DriveStartNone
  toEnum unmatched = error ("DriveStartFlags.toEnum: Cannot match " ++ show unmatched)

  succ _ = undefined

  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x DriveStartNone
  enumFromThen _ _ =     error "Enum DriveStartFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum DriveStartFlags: enumFromThenTo not implemented"

{-# LINE 132 "./System/GIO/Enums.chs" #-}
instance Flags DriveStartFlags

-- | Enumeration describing how a drive can be started/stopped.
data DriveStartStopType = DriveStartStopTypeUnknown
                        | DriveStartStopTypeShutdown
                        | DriveStartStopTypeNetwork
                        | DriveStartStopTypeMultidisk
                        | DriveStartStopTypePassword
                        deriving (Enum,Eq,Ord,Bounded,Show,Typeable)

{-# LINE 136 "./System/GIO/Enums.chs" #-}



-- | 'EmblemOrigin' is used to add information about the origin of the emblem to 'Emblem'.
data EmblemOrigin = EmblemOriginUnknown
                  | EmblemOriginDevice
                  | EmblemOriginLivemetadata
                  | EmblemOriginTag
                  deriving (Enum,Eq,Ord,Bounded,Show,Typeable)

{-# LINE 141 "./System/GIO/Enums.chs" #-}


-- | Flags used when creating a 'AppInfo'.
data AppInfoCreateFlags = AppInfoCreateNone
                        | AppInfoCreateNeedsTerminal
                        | AppInfoCreateSupportsUris
                        | AppInfoCreateSupportsStartupNotification
                        deriving (Eq,Ord,Bounded,Show,Typeable)
instance Enum AppInfoCreateFlags where
  fromEnum AppInfoCreateNone = 0
  fromEnum AppInfoCreateNeedsTerminal = 1
  fromEnum AppInfoCreateSupportsUris = 2
  fromEnum AppInfoCreateSupportsStartupNotification = 4

  toEnum 0 = AppInfoCreateNone
  toEnum 1 = AppInfoCreateNeedsTerminal
  toEnum 2 = AppInfoCreateSupportsUris
  toEnum 4 = AppInfoCreateSupportsStartupNotification
  toEnum unmatched = error ("AppInfoCreateFlags.toEnum: Cannot match " ++ show unmatched)

  succ AppInfoCreateNone = AppInfoCreateNeedsTerminal
  succ AppInfoCreateNeedsTerminal = AppInfoCreateSupportsUris
  succ AppInfoCreateSupportsUris = AppInfoCreateSupportsStartupNotification
  succ _ = undefined

  pred AppInfoCreateNeedsTerminal = AppInfoCreateNone
  pred AppInfoCreateSupportsUris = AppInfoCreateNeedsTerminal
  pred AppInfoCreateSupportsStartupNotification = AppInfoCreateSupportsUris
  pred _ = undefined

  enumFromTo x y | fromEnum x == fromEnum y = [ y ]
                 | otherwise = x : enumFromTo (succ x) y
  enumFrom x = enumFromTo x AppInfoCreateSupportsStartupNotification
  enumFromThen _ _ =     error "Enum AppInfoCreateFlags: enumFromThen not implemented"
  enumFromThenTo _ _ _ =     error "Enum AppInfoCreateFlags: enumFromThenTo not implemented"

{-# LINE 145 "./System/GIO/Enums.chs" #-}
instance Flags AppInfoCreateFlags