digiKam
|
Public Types | |
enum | PropertyFlag { FlagNull = 0 , FlagVisible = 1 , FlagMovable = 2 , FlagSnaps = 4 } |
Signals | |
void | signalFilteredImages (const QList< qlonglong > &idList) |
void | signalModelChangedDrastically () |
void | signalThumbnailAvailableForIndex (const QPersistentModelIndex &index, const QPixmap &pixmap) |
void | signalVisibilityChanged () |
Public Member Functions | |
QPersistentModelIndex | bestRepresentativeIndexFromList (const QList< QPersistentModelIndex > &list, 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... | |
bool | itemCoordinates (const QModelIndex &index, GeoCoordinates *const coordinates) const override |
Gets the coordinates of a marker found at current model index. More... | |
virtual PropertyFlags | itemFlags (const QModelIndex &index) const |
virtual bool | itemIcon (const QModelIndex &index, QPoint *const offset, QSize *const size, QPixmap *const pixmap, QUrl *const url) const |
these are necessary for ungrouped models More... | |
MapViewModelHelper (QItemSelectionModel *const selection, DCategorizedSortFilterProxyModel *const filterModel, QObject *const parent, const MapWidgetView::Application application) | |
QAbstractItemModel * | model () const override |
virtual PropertyFlags | modelFlags () const |
void | onIndicesClicked (const QList< QPersistentModelIndex > &clickedIndices) override |
virtual void | onIndicesMoved (const QList< QPersistentModelIndex > &movedIndices, const GeoCoordinates &targetCoordinates, const QPersistentModelIndex &targetSnapIndex) |
QPixmap | pixmapFromRepresentativeIndex (const QPersistentModelIndex &index, const QSize &size) override |
This function retrieves the thumbnail for an index. More... | |
QItemSelectionModel * | selectionModel () const override |
virtual void | snapItemsTo (const QModelIndex &targetIndex, const QList< QModelIndex > &snappedIndices) |
void | snapItemsTo (const QModelIndex &targetIndex, const QList< QPersistentModelIndex > &snappedIndices) |
~MapViewModelHelper () override | |
Destructor. More... | |
|
inherited |
|
explicit |
|
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. |
sortKey | Determines the sorting options and is actually of type GPSItemInfoSorter::SortOptions |
Reimplemented from Digikam::GeoModelHelper.
References Digikam::MapWidgetView::ApplicationDigikam, Digikam::MapWidgetView::ApplicationImportUI, Digikam::GPSItemInfo::coordinates, Digikam::GPSItemInfo::dateTime, Digikam::GPSItemInfoSorter::fitsBetter(), Digikam::GPSItemInfo::rating, Digikam::SelectedNone, Digikam::GeoCoordinates::setAlt(), Digikam::GPSItemInfo::url, and Digikam::CamItemInfo::url().
|
overridevirtual |
Gets the coordinates of a marker found at current model index.
index | Current model index. |
coordinates | Here will be returned the coordinates of the current marker. |
Implements Digikam::GeoModelHelper.
References Digikam::MapWidgetView::ApplicationDigikam, Digikam::MapWidgetView::ApplicationImportUI, Digikam::ItemInfo::hasCoordinates(), Digikam::ItemInfo::isNull(), Digikam::CamItemInfo::isNull(), Digikam::ItemInfo::latitudeNumber(), Digikam::ItemInfo::longitudeNumber(), Digikam::GeoCoordinates::setAlt(), and Digikam::CamItemInfo::url().
|
virtualinherited |
Reimplemented in Digikam::GPSBookmarkModelHelper, and DigikamGenericGeolocationEditPlugin::SearchResultModelHelper.
Referenced by Digikam::BackendGoogleMaps::slotUngroupedModelChanged().
|
virtualinherited |
these are necessary for ungrouped models
Returns the icon for an ungrouped marker.
The icon can either be returned as a URL to an image, or as a QPixmap. If the caller can handle URLs (for example, to display them in HTML), he can provide the URL parameter. However, the GeoModelHelper may still choose to return a QPixmap instead, if no URL is available.
index | Modelindex of the marker. |
offset | Offset of the zero point in the icon, given from the top-left. |
size | the size of the icon, only populated if a URL is returned. |
pixmap | Holder for the pixmap of the icon. |
url | URL of the icon if available. |
Reimplemented in Digikam::GPSBookmarkModelHelper, and DigikamGenericGeolocationEditPlugin::SearchResultModelHelper.
Referenced by Digikam::BackendMarble::marbleCustomPaint(), and Digikam::BackendGoogleMaps::slotUngroupedModelChanged().
|
overridevirtual |
Implements Digikam::GeoModelHelper.
References Digikam::MapWidgetView::ApplicationDigikam, and Digikam::MapWidgetView::ApplicationImportUI.
|
virtualinherited |
Reimplemented in Digikam::GPSGeoIfaceModelHelper, Digikam::GPSBookmarkModelHelper, and DigikamGenericGeolocationEditPlugin::SearchResultModelHelper.
Referenced by Digikam::BackendMarble::findSnapPoint(), Digikam::BackendMarble::marbleCustomPaint(), and Digikam::BackendGoogleMaps::slotUngroupedModelChanged().
|
overridevirtual |
This functions is called when one clicks on a thumbnail.
clickedIndices | A list containing the marker indices belonging the group whose thumbnail has been clicked. |
Reimplemented from Digikam::GeoModelHelper.
References signalFilteredImages().
|
virtualinherited |
Reimplemented in Digikam::GPSGeoIfaceModelHelper.
|
overridevirtual |
This function retrieves the thumbnail for an index.
index | The marker's index. |
size | The size of the thumbnail. |
Reimplemented from Digikam::GeoModelHelper.
References Digikam::MapWidgetView::ApplicationDigikam, Digikam::MapWidgetView::ApplicationImportUI, Digikam::ItemInfo::isNull(), Digikam::ItemInfo::thumbnailIdentifier(), and Digikam::ImportItemModel::ThumbnailRole.
|
overridevirtual |
Implements Digikam::GeoModelHelper.
|
signal |
Referenced by onIndicesClicked().
|
signalinherited |
|
signalinherited |
Referenced by Digikam::ItemMarkerTiler::setMarkerGeoModelHelper().
|
signalinherited |
|
virtualinherited |
Reimplemented in Digikam::GPSBookmarkModelHelper, and DigikamGenericGeolocationEditPlugin::SearchResultModelHelper.
|
inherited |
Referenced by Digikam::GPSGeoIfaceModelHelper::onIndicesMoved().