From: Axel S. <si...@co...> - 2008-09-20 20:13:57
|
Sat Sep 20 15:34:54 EDT 2008 A....@ke... * Rename a few function in CustomStore to make the naming more consistent. Add more comments. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 4 --- Author : Duncan Coutts +-- Author : Duncan Coutts, Axel Simon hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 8 --- Copyright (C) 2005 Duncan Coutts +-- Copyright (C) 2005 Duncan Coutts, Axel Simon hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 19 --- +-- #prune + hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 26 --- Allows a custom data structure to be used with the 'TreeView' +-- Allows a custom data structure to be used with the 'TreeView' and other +-- widgets that follow the model-view-controller paradigm. The two models +-- 'Graphics.UI.Gtk.ModelView.ListStore.ListStore' and +-- 'Graphics.UI.Gtk.ModelView.TreeStore.TreeStore' are based on the +-- 'CustomStore'. Even if no application-specific tree model +-- should be implemented, this module is relevant in that it provides the +-- functions 'customStoreSetColumn' and +-- 'customStoreGetRow' functions. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 37 - CustomTreeModel, + CustomStore, hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 42 - customTreeModelNew, + customStoreNew, hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 45 - customTreeModelGetPrivate, - customTreeModelGetStamp, - customTreeModelInvalidateIters, + customStoreGetPrivate, + customStoreGetStamp, + customStoreInvalidateIters, hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 74 --- | These flags indicate various properties of a 'TreeModel'. +-- | These flags indicate various properties of a +-- 'Graphics.UI.Gtk.ModelView.TreeModel.TreeModel'. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 77 --- * If a model has "TreeModelItersPersist" set, iterators remain valid --- after a "TreeModel" signal was emitted. +-- * If a model has 'TreeModelItersPersist' set, iterators remain valid after +-- a 'Graphics.UI.Gtk.ModelView.TreeModel.TreeModel' signal was emitted. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 80 --- * The "TreeModelListOnly" flag is set if the rows are arranged in a --- simple flat list. This is set in the "ListStore" implementation. +-- * The 'TreeModelListOnly' flag is set if the rows are arranged in a simple +-- flat list. This is set in the +-- 'Graphics.UI.Gtk.ModelView.ListStore.ListStore' implementation. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 88 --- | A CustomTreeModel is backed by a Gtk2HsStore +-- A 'CustomStore' is backed by a Gtk2HsStore hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 91 -newtype CustomTreeModel private row = CustomTreeModel (ForeignPtr (CustomTreeModel private row)) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 92 -instance TreeModelClass (CustomTreeModel private row) -instance GObjectClass (CustomTreeModel private row) where - toGObject (CustomTreeModel tm) = mkGObject (castForeignPtr tm) - unsafeCastGObject = CustomTreeModel . castForeignPtr . unGObject +-- | A 'CustomStore' is an instance of a Gtk+ 'TreeModel' and can thus be used +-- for any widget that stores data in a 'TreeModel'. The user may either +-- create an instance of a 'CustomStore' or use one of the pre-defined +-- models 'Graphics.UI.Gtk.ModelView.ListStore.ListStore' of +-- 'Graphics.UI.Gtk.ModelView.TreeStore.TreeStore'. +newtype CustomStore private row = CustomStore (ForeignPtr (CustomStore private row)) + +instance TreeModelClass (CustomStore private row) +instance GObjectClass (CustomStore private row) where + toGObject (CustomStore tm) = mkGObject (castForeignPtr tm) + unsafeCastGObject = CustomStore . castForeignPtr . unGObject hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 125 - let cMap = customTreeModelColumns impl + let cMap = customStoreColumns impl hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 143 -data CustomTreeModelImplementation model row = CustomTreeModelImplementation { - customTreeModelColumns :: ColumnMap row, -- provide access via columns - customTreeModelIface :: TreeModelIface row, -- functions implementing a tree model - customTreeDragSourceIface :: DragSourceIface model row, -- the drag and drop source interface - customTreeDragDestIface :: DragDestIface model row -- the drag and drop dest interface +data CustomStoreImplementation model row = CustomStoreImplementation { + customStoreColumns :: ColumnMap row, -- provide access via columns + customStoreIface :: TreeModelIface row, -- functions implementing a tree model + customTreeDragSourceIface :: DragSourceIface model row, -- the drag and drop source interface + customTreeDragDestIface :: DragDestIface model row -- the drag and drop dest interface hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 150 +-- | The 'TreeModelIface' structure contains all functions that are required +-- to implement an application-specific 'TreeModel'. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 153 + -- | Return the flags that are valid for this model. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 155 + -- | Convert an path into the tree into a more concise 'TreeIter'. + -- Return @Nothing@ if the path does not exit. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 158 + -- | Convert an iterator to a path. The iterator will always be valid. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 160 + -- | Retrieve a row at the given iterator. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 162 + -- | Advance the given iterator to the next node at the same level. + -- Return @Nothing@ if there is no next node at this level. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 165 + -- | Advance the given iterator to the first child of this iterator. + -- Return @Notihing@ if the node at this iterator has no children. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 168 + -- | Check if the node at the given iterator has children. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 170 + -- | Query the number of children the the node at the given iteratore has. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 172 + -- | Ask for an iterator to the @n@th child. Return @Nothing@ if + -- no such child exists. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 175 + -- | Ask for an iterator to the parent of the node. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 177 + -- | Increase a reference count for this node. A positive reference count + -- indicates that the node is used (that is, most likely it is visible) + -- in at least one widget. Tracking reference counts for nodes is + -- optional but may be useful to infer when a given row can be discarded + -- if it was retrieved from an external source. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 183 + -- | Decrement the reference count of the given node. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 187 +-- | A structure containing functions that enable this widget to be used +-- as a source in drag-and-drop. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 190 + -- | Determine if the row at the given path is draggable. Return + -- @False@ if for some reason this row should not be dragged by + -- the user. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 194 + -- | Fill in the 'SelectionDataM' structure with information on + -- the given node using + -- 'Graphics.UI.Gtk.General.Selection.selectionDataSet'. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 198 + -- | The widget is informed that the row at the given path should + -- be deleted as the result of this drag. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 203 +-- | A structure containing functions that enable this widget to be used +-- as a target in drag-and-drop. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 206 + -- | Tell the drag-and-drop mechanism if the row can be dropped at the + -- given path. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 209 + -- | The data in the 'SelectionDataM' structure should be read using + -- 'Graphics.UI.Gtk.General.Selection.selectionDataGet' and + -- its information be used to insert a new row at the given path. hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 219 -customTreeModelNew :: (TreeModelClass (model row), TypedTreeModelClass model) => +customStoreNew :: (TreeModelClass (model row), TypedTreeModelClass model) => hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 221 - -> ((CustomTreeModel private row) -> model row) + -> ((CustomStore private row) -> model row) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 228 -customTreeModelNew priv con tmIface mDragSource mDragDest = do +customStoreNew priv con tmIface mDragSource mDragDest = do hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 235 - implPtr <- newStablePtr CustomTreeModelImplementation { - customTreeModelColumns = cMap, - customTreeModelIface = tmIface, + implPtr <- newStablePtr CustomStoreImplementation { + customStoreColumns = cMap, + customStoreIface = tmIface, hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 241 - liftM con $ makeNewGObject CustomTreeModel $ + liftM con $ makeNewGObject CustomStore $ hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 245 - gtk2hs_store_new :: StablePtr (CustomTreeModelImplementation model row) + gtk2hs_store_new :: StablePtr (CustomStoreImplementation model row) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 247 - -> IO (Ptr (CustomTreeModel private row)) + -> IO (Ptr (CustomStore private row)) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 256 - treeModelIfaceGetRow (customTreeModelIface impl) iter + treeModelIfaceGetRow (customStoreIface impl) iter hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 263 - gtk2hs_store_get_impl :: Ptr (TypedTreeModel row) -> IO (StablePtr (CustomTreeModelImplementation model row)) + gtk2hs_store_get_impl :: Ptr (TypedTreeModel row) -> IO (StablePtr (CustomStoreImplementation model row)) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 265 -customTreeModelGetPrivate :: CustomTreeModel private row -> private -customTreeModelGetPrivate (CustomTreeModel model) = +-- | Return the private data stored in this 'CustomStore'. The private data +-- is meant as a container for the data stored in this model. +customStoreGetPrivate :: CustomStore private row -> private +customStoreGetPrivate (CustomStore model) = hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 274 - gtk2hs_store_get_priv :: Ptr (CustomTreeModel private row) -> IO (StablePtr private) + gtk2hs_store_get_priv :: Ptr (CustomStore private row) -> IO (StablePtr private) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 276 -customTreeModelGetStamp :: CustomTreeModel private row -> IO CInt -customTreeModelGetStamp (CustomTreeModel model) = +-- | Query the current value of the stamp that is used to create +-- 'TreeIter' iterators. The stamp is compared each time a view +-- accesses this store. If the stamp doesn't match, a warning +-- is emitted. The stamp should be updated each time a the data +-- in the model changes. The rationale is that a view should never +-- use a stale 'TreeIter', i.e., one that refers to an old model. +-- +customStoreGetStamp :: CustomStore private row -> IO CInt +customStoreGetStamp (CustomStore model) = hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 288 - gtk2hs_store_get_stamp :: Ptr (CustomTreeModel private row) -> IO CInt + gtk2hs_store_get_stamp :: Ptr (CustomStore private row) -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 290 -customTreeModelInvalidateIters :: CustomTreeModel private row -> IO () -customTreeModelInvalidateIters (CustomTreeModel model) = +-- | Create a new stamp. See 'customStoreGetStamp'. +-- +customStoreInvalidateIters :: CustomStore private row -> IO () +customStoreInvalidateIters (CustomStore model) = hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 297 - gtk2hs_store_increment_stamp :: Ptr (CustomTreeModel private row) -> IO () + gtk2hs_store_increment_stamp :: Ptr (CustomStore private row) -> IO () hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 299 -treeModelIfaceGetNColumns_static :: StablePtr (CustomTreeModelImplementation model row) -> IO CInt +treeModelIfaceGetNColumns_static :: StablePtr (CustomStoreImplementation model row) -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 302 - cmap <- readIORef (customTreeModelColumns store) + cmap <- readIORef (customStoreColumns store) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 306 - treeModelIfaceGetNColumns_static :: StablePtr (CustomTreeModelImplementation model row) -> IO CInt + treeModelIfaceGetNColumns_static :: StablePtr (CustomStoreImplementation model row) -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 316 -treeModelIfaceGetColumnType_static :: StablePtr (CustomTreeModelImplementation model row) -> CInt -> IO GType +treeModelIfaceGetColumnType_static :: StablePtr (CustomStoreImplementation model row) -> CInt -> IO GType hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 319 - cols <- readIORef (customTreeModelColumns store) + cols <- readIORef (customStoreColumns store) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 325 - treeModelIfaceGetColumnType_static :: StablePtr (CustomTreeModelImplementation model row) -> CInt -> IO GType + treeModelIfaceGetColumnType_static :: StablePtr (CustomStoreImplementation model row) -> CInt -> IO GType hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 328 -treeModelIfaceGetFlags_static :: StablePtr (CustomTreeModelImplementation model row) -> IO CInt +treeModelIfaceGetFlags_static :: StablePtr (CustomStoreImplementation model row) -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 330 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 334 - treeModelIfaceGetFlags_static :: StablePtr (CustomTreeModelImplementation model row) -> IO CInt + treeModelIfaceGetFlags_static :: StablePtr (CustomStoreImplementation model row) -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 337 -treeModelIfaceGetIter_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> Ptr NativeTreePath -> IO CInt +treeModelIfaceGetIter_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> Ptr NativeTreePath -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 339 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 348 - treeModelIfaceGetIter_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> Ptr NativeTreePath -> IO CInt + treeModelIfaceGetIter_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> Ptr NativeTreePath -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 350 -treeModelIfaceGetPath_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO (Ptr NativeTreePath) +treeModelIfaceGetPath_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO (Ptr NativeTreePath) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 352 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 359 - treeModelIfaceGetPath_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO (Ptr NativeTreePath) + treeModelIfaceGetPath_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO (Ptr NativeTreePath) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 362 -treeModelIfaceGetValue_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> CInt -> Ptr GValue -> IO () +treeModelIfaceGetValue_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> CInt -> Ptr GValue -> IO () hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 366 - row <- treeModelIfaceGetRow (customTreeModelIface store) iter - cols <- readIORef (customTreeModelColumns store) + row <- treeModelIfaceGetRow (customStoreIface store) iter + cols <- readIORef (customStoreColumns store) hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 381 - treeModelIfaceGetValue_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> CInt -> Ptr GValue -> IO () + treeModelIfaceGetValue_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> CInt -> Ptr GValue -> IO () hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 384 -treeModelIfaceIterNext_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO CInt +treeModelIfaceIterNext_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 386 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 395 - treeModelIfaceIterNext_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO CInt + treeModelIfaceIterNext_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 398 -treeModelIfaceIterChildren_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> IO CInt +treeModelIfaceIterChildren_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 400 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 409 - treeModelIfaceIterChildren_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> IO CInt + treeModelIfaceIterChildren_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 412 -treeModelIfaceIterHasChild_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO CInt +treeModelIfaceIterHasChild_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 414 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 419 - treeModelIfaceIterHasChild_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO CInt + treeModelIfaceIterHasChild_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 422 -treeModelIfaceIterNChildren_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO CInt +treeModelIfaceIterNChildren_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 424 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 429 - treeModelIfaceIterNChildren_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO CInt + treeModelIfaceIterNChildren_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 432 -treeModelIfaceIterNthChild_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> CInt -> IO CInt +treeModelIfaceIterNthChild_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> CInt -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 434 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 443 - treeModelIfaceIterNthChild_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> CInt -> IO CInt + treeModelIfaceIterNthChild_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> CInt -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 446 -treeModelIfaceIterParent_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> IO CInt +treeModelIfaceIterParent_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 448 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 457 - treeModelIfaceIterParent_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> IO CInt + treeModelIfaceIterParent_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> Ptr TreeIter -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 460 -treeModelIfaceRefNode_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO () +treeModelIfaceRefNode_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO () hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 462 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 467 - treeModelIfaceRefNode_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO () + treeModelIfaceRefNode_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO () hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 470 -treeModelIfaceUnrefNode_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO () +treeModelIfaceUnrefNode_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO () hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 472 - store <- liftM customTreeModelIface $ deRefStablePtr storePtr + store <- liftM customStoreIface $ deRefStablePtr storePtr hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 477 - treeModelIfaceUnrefNode_static :: StablePtr (CustomTreeModelImplementation model row) -> Ptr TreeIter -> IO () + treeModelIfaceUnrefNode_static :: StablePtr (CustomStoreImplementation model row) -> Ptr TreeIter -> IO () hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 479 -treeDragSourceRowDraggable_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> IO CInt +treeDragSourceRowDraggable_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 487 - treeDragSourceRowDraggable_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> IO CInt + treeDragSourceRowDraggable_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 489 -treeDragSourceDragDataGet_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt +treeDragSourceDragDataGet_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 497 - treeDragSourceDragDataGet_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt + treeDragSourceDragDataGet_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 499 -treeDragSourceDragDataDelete_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> IO CInt +treeDragSourceDragDataDelete_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 507 - treeDragSourceDragDataDelete_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> IO CInt + treeDragSourceDragDataDelete_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 509 -treeDragDestDragDataReceived_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt +treeDragDestDragDataReceived_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 517 - treeDragDestDragDataReceived_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt + treeDragDestDragDataReceived_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 519 -treeDragDestRowDropPossible_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt +treeDragDestRowDropPossible_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/CustomStore.chs 527 - treeDragDestRowDropPossible_static :: Ptr TreeModel -> StablePtr (CustomTreeModelImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt + treeDragDestRowDropPossible_static :: Ptr TreeModel -> StablePtr (CustomStoreImplementation model row) -> Ptr NativeTreePath -> SelectionData -> IO CInt hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 72 -newtype ListStore a = ListStore (CustomTreeModel (IORef (Seq a)) a) +newtype ListStore a = ListStore (CustomStore (IORef (Seq a)) a) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 95 - customTreeModelNew rows ListStore TreeModelIface { + customStoreNew rows ListStore TreeModelIface { hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 169 - readIORef (customTreeModelGetPrivate model) >>= return . (`Seq.index` index) + readIORef (customStoreGetPrivate model) >>= return . (`Seq.index` index) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 175 - modifyIORef (customTreeModelGetPrivate model) (Seq.update index value) + modifyIORef (customStoreGetPrivate model) (Seq.update index value) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 188 - $ readIORef (customTreeModelGetPrivate model) + $ readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 193 - liftM Seq.length $ readIORef (customTreeModelGetPrivate model) + liftM Seq.length $ readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 199 - seq <- readIORef (customTreeModelGetPrivate model) + seq <- readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 203 - writeIORef (customTreeModelGetPrivate model) (insert index' value seq) - stamp <- customTreeModelGetStamp model + writeIORef (customStoreGetPrivate model) (insert index' value seq) + stamp <- customStoreGetStamp model hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 214 - modifyIORef (customTreeModelGetPrivate model) + modifyIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 216 - stamp <- customTreeModelGetStamp model + stamp <- customStoreGetStamp model hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 228 - index <- atomicModifyIORef (customTreeModelGetPrivate model) + index <- atomicModifyIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 230 - stamp <- customTreeModelGetStamp model + stamp <- customStoreGetStamp model hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 237 - seq <- readIORef (customTreeModelGetPrivate model) + seq <- readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 241 - writeIORef (customTreeModelGetPrivate model) (seq Seq.>< seq') - stamp <- customTreeModelGetStamp model + writeIORef (customStoreGetPrivate model) (seq Seq.>< seq') + stamp <- customStoreGetStamp model hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 251 - seq <- readIORef (customTreeModelGetPrivate model) + seq <- readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 253 - writeIORef (customTreeModelGetPrivate model) (delete index seq) + writeIORef (customStoreGetPrivate model) (delete index seq) hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 274 - writeIORef (customTreeModelGetPrivate model) seq + writeIORef (customStoreGetPrivate model) seq hunk ./gtk/Graphics/UI/Gtk/ModelView/ListStore.hs.pp 278 - in do seq <- readIORef (customTreeModelGetPrivate model) + in do seq <- readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 75 -newtype TreeStore a = TreeStore (CustomTreeModel (IORef (Store a)) a) +newtype TreeStore a = TreeStore (CustomStore (IORef (Store a)) a) hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 127 - customTreeModelNew storeRef TreeStore TreeModelIface { + customStoreNew storeRef TreeStore TreeModelIface { hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 465 - customTreeModelInvalidateIters model - (idx, toggle) <- atomicModifyIORef (customTreeModelGetPrivate model) $ + customStoreInvalidateIters model + (idx, toggle) <- atomicModifyIORef (customStoreGetPrivate model) $ hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 475 - Store { depth = depth } <- readIORef (customTreeModelGetPrivate model) + Store { depth = depth } <- readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 477 - stamp <- customTreeModelGetStamp model + stamp <- customStoreGetStamp model hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 547 - customTreeModelInvalidateIters model - (found, toggle) <- atomicModifyIORef (customTreeModelGetPrivate model) $ + customStoreInvalidateIters model + (found, toggle) <- atomicModifyIORef (customStoreGetPrivate model) $ hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 558 - Store { depth = depth } <- readIORef (customTreeModelGetPrivate model) + Store { depth = depth } <- readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 567 - customTreeModelInvalidateIters model - Store { content = cache } <- readIORef (customTreeModelGetPrivate model) + customStoreInvalidateIters model + Store { content = cache } <- readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 570 - writeIORef (customTreeModelGetPrivate model) Store { + writeIORef (customStoreGetPrivate model) Store { hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 620 - customTreeModelInvalidateIters model + customStoreInvalidateIters model hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 622 - readIORef (customTreeModelGetPrivate model) + readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 629 - writeIORef (customTreeModelGetPrivate model) store' + writeIORef (customStoreGetPrivate model) store' hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 631 - stamp <- customTreeModelGetStamp model + stamp <- customStoreGetStamp model hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 668 - readIORef (customTreeModelGetPrivate model) + readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 672 - writeIORef (customTreeModelGetPrivate model) store { content = cache' } + writeIORef (customStoreGetPrivate model) store { content = cache' } hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 684 - readIORef (customTreeModelGetPrivate model) + readIORef (customStoreGetPrivate model) hunk ./gtk/Graphics/UI/Gtk/ModelView/TreeStore.hs 688 - writeIORef (customTreeModelGetPrivate model) store { content = cache' } + writeIORef (customStoreGetPrivate model) store { content = cache' } |