digiKam
|
Marker model for storing data needed to display markers on the map. The data is retrieved from Digikam's database. More...
Public Types | |
enum | TilerFlag { FlagNull = 0 , FlagMovable = 1 } |
Public Slots | |
void | slotNewModelData (const QList< ItemInfo > &infoList) |
Receives notifications from the album model about new items. More... | |
Signals | |
void | signalModelFilteredImages (const QList< qlonglong > &imagesId) |
void | signalThumbnailAvailableForIndex (const QVariant &index, const QPixmap &pixmap) |
void | signalTilesOrSelectionChanged () |
Public Member Functions | |
QVariant | bestRepresentativeIndexFromList (const QList< QVariant > &indices, const int sortKey) override |
This function finds the best representative marker from a group of markers. This is needed to display a thumbnail for a marker group. More... | |
GeoGroupState | getGlobalGroupState () override |
AbstractMarkerTiler::Tile * | getTile (const TileIndex &tileIndex, const bool stopIfEmpty) override |
Returns a pointer to a tile. More... | |
GeoGroupState | getTileGroupState (const TileIndex &tileIndex) override |
int | getTileMarkerCount (const TileIndex &tileIndex) override |
QVariant | getTileRepresentativeMarker (const TileIndex &tileIndex, const int sortKey) override |
This function finds the best representative marker from a tile of markers. More... | |
int | getTileSelectedCount (const TileIndex &tileIndex) override |
GPSMarkerTiler (QObject *const parent, ItemFilterModel *const imageFilterModel, QItemSelectionModel *const selectionModel) | |
Constructor. More... | |
bool | indicesEqual (const QIntList &a, const QIntList &b, const int upToLevel) const |
bool | indicesEqual (const QVariant &a, const QVariant &b) const override |
This function compares two marker indices. More... | |
bool | isDirty () const |
void | onIndicesClicked (const ClickInfo &clickInfo) override |
these can be implemented if you want to react to actions in geolocation interface More... | |
virtual void | onIndicesMoved (const TileIndex::List &tileIndicesList, const GeoCoordinates &targetCoordinates, const QPersistentModelIndex &targetSnapIndex) |
QPixmap | pixmapFromRepresentativeIndex (const QVariant &index, const QSize &size) override |
This function retrieves the thumbnail for an index. More... | |
void | prepareTiles (const GeoCoordinates &upperLeft, const GeoCoordinates &lowerRight, int level) override |
Requests all images inside a given rectangle from the database. More... | |
void | regenerateTiles () override |
void | removeCurrentRegionSelection () |
void | resetRootTile () |
Tile * | rootTile () |
void | setActive (const bool state) override |
Sets the map active/inactive. More... | |
void | setDirty (const bool state=true) |
void | setPositiveFilterIsActive (const bool state) |
void | setRegionSelection (const GeoCoordinates::Pair &sel) |
Tile * | tileNew () override |
virtual TilerFlags | tilerFlags () const |
these have to be implemented More... | |
~GPSMarkerTiler () override | |
Destructor. More... | |
Marker model for storing data needed to display markers on the map. The data is retrieved from Digikam's database.
|
inherited |
|
explicit |
Constructor.
parent | the parent object |
References Digikam::CoreDbAccess::databaseWatch(), Digikam::AbstractMarkerTiler::resetRootTile(), and slotNewModelData().
|
override |
Destructor.
|
overridevirtual |
This function finds the best representative marker from a group of markers. This is needed to display a thumbnail for a marker group.
indices | A list containing markers, obtained by getTileRepresentativeMarker. |
sortKey | Sets the criteria for selecting the representative thumbnail, a combination of the SortOptions bits. |
Implements Digikam::AbstractMarkerTiler.
References Digikam::GPSItemInfoSorter::fitsBetter(), and getGlobalGroupState().
|
overridevirtual |
Implements Digikam::AbstractMarkerTiler.
Referenced by bestRepresentativeIndexFromList(), and getTileRepresentativeMarker().
|
overridevirtual |
Returns a pointer to a tile.
tileIndex | The index of a tile. |
stopIfEmpty | Determines whether child tiles are also created for empty tiles. |
Implements Digikam::AbstractMarkerTiler.
References Digikam::GPSItemInfo::coordinates, Digikam::TileIndex::fromCoordinates(), Digikam::TileIndex::indexCount(), Digikam::TileIndex::lastIndex(), Digikam::TileIndex::level(), Digikam::TileIndex::linearIndex(), Digikam::TileIndex::MaxLevel, Digikam::AbstractMarkerTiler::rootTile(), and tileNew().
Referenced by getTileGroupState(), getTileMarkerCount(), and getTileRepresentativeMarker().
|
overridevirtual |
|
overridevirtual |
Implements Digikam::AbstractMarkerTiler.
References getTile().
|
overridevirtual |
This function finds the best representative marker from a tile of markers.
tileIndex | Index of the tile from which the best marker should be found. |
sortKey | Sets the criteria for selecting the representative thumbnail, a combination of the SortOptions bits. |
Implements Digikam::AbstractMarkerTiler.
References Digikam::GPSItemInfoSorter::fitsBetter(), getGlobalGroupState(), getTile(), and Digikam::GPSItemInfo::id.
|
overridevirtual |
Implements Digikam::AbstractMarkerTiler.
|
inherited |
|
overridevirtual |
This function compares two marker indices.
Implements Digikam::AbstractMarkerTiler.
|
inherited |
Referenced by Digikam::ItemMarkerTiler::addMarkerIndexToGrid(), Digikam::ItemMarkerTiler::getTile(), Digikam::ItemMarkerTiler::getTileGroupState(), Digikam::ItemMarkerTiler::getTileMarkerCount(), Digikam::ItemMarkerTiler::getTileSelectedCount(), Digikam::ItemMarkerTiler::removeMarkerIndexFromGrid(), and Digikam::AbstractMarkerTiler::rootTile().
|
overridevirtual |
these can be implemented if you want to react to actions in geolocation interface
Reimplemented from Digikam::AbstractMarkerTiler.
References Digikam::AbstractMarkerTiler::ClickInfo::currentMouseMode, Digikam::AbstractMarkerTiler::ClickInfo::groupSelectionState, Digikam::MouseModeFilter, Digikam::MouseModeSelectThumbnail, Digikam::AbstractMarkerTiler::ClickInfo::representativeIndex, Digikam::SelectedAll, Digikam::SelectedMask, setPositiveFilterIsActive(), signalModelFilteredImages(), and Digikam::AbstractMarkerTiler::ClickInfo::tileIndicesList.
|
virtualinherited |
Reimplemented in Digikam::ItemMarkerTiler.
|
overridevirtual |
This function retrieves the thumbnail for an index.
index | The marker's index. |
size | The size of the thumbnail. |
Implements Digikam::AbstractMarkerTiler.
References Digikam::ItemInfo::id(), and Digikam::ItemInfo::thumbnailIdentifier().
|
overridevirtual |
Requests all images inside a given rectangle from the database.
This function calls the database for the images found inside a rectangle defined by upperLeft and lowerRight points. The images are returned from the database in batches.
upperLeft | The North-West point. |
lowerRight | The South-East point. |
level | The requested tiling level. |
Implements Digikam::AbstractMarkerTiler.
References Digikam::DBJobsManager::instance(), Digikam::GeoCoordinates::lat(), Digikam::GeoCoordinates::lon(), Digikam::GPSDBJobInfo::setLat1(), Digikam::GPSDBJobInfo::setLat2(), Digikam::GPSDBJobInfo::setLng1(), Digikam::GPSDBJobInfo::setLng2(), and Digikam::DBJobsManager::startGPSJobThread().
|
overridevirtual |
Implements Digikam::AbstractMarkerTiler.
void Digikam::GPSMarkerTiler::removeCurrentRegionSelection | ( | ) |
|
inherited |
References Digikam::AbstractMarkerTiler::tileNew().
Referenced by GPSMarkerTiler(), Digikam::ItemMarkerTiler::ItemMarkerTiler(), and Digikam::ItemMarkerTiler::regenerateTiles().
|
inherited |
|
overridevirtual |
Sets the map active/inactive.
state | New state of the map, true means active. |
Implements Digikam::AbstractMarkerTiler.
|
inherited |
void Digikam::GPSMarkerTiler::setPositiveFilterIsActive | ( | const bool | state | ) |
References Digikam::FilteredPositiveMask, and Digikam::AbstractMarkerTiler::signalTilesOrSelectionChanged().
Referenced by onIndicesClicked().
void Digikam::GPSMarkerTiler::setRegionSelection | ( | const GeoCoordinates::Pair & | sel | ) |
|
signal |
Referenced by onIndicesClicked().
|
signalinherited |
|
signalinherited |
Receives notifications from the album model about new items.
References Digikam::AbstractMarkerTiler::signalTilesOrSelectionChanged().
Referenced by GPSMarkerTiler().
|
overridevirtual |
Implements Digikam::AbstractMarkerTiler.
Referenced by getTile().
|
virtualinherited |
these have to be implemented
Reimplemented in Digikam::ItemMarkerTiler.
References Digikam::AbstractMarkerTiler::FlagNull.