aboutsummaryrefslogtreecommitdiffstats
path: root/qt-ui/divelistview.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qt-ui/divelistview.cpp')
-rw-r--r--qt-ui/divelistview.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/qt-ui/divelistview.cpp b/qt-ui/divelistview.cpp
index c5ffaaafa..65090e1e8 100644
--- a/qt-ui/divelistview.cpp
+++ b/qt-ui/divelistview.cpp
@@ -824,6 +824,10 @@ void DiveListView::contextMenuEvent(QContextMenuEvent *event)
popup.addAction(tr("Shift times"), this, SLOT(shiftTimes()));
popup.addAction(tr("Load images"), this, SLOT(loadImages()));
}
+ if (prefs.facebook.user_id) {
+ popup.addAction(tr("Publish on Facebook"), this, SLOT(publishFacebook()));
+ }
+
// "collapse all" really closes all trips,
// "collapse" keeps the trip with the selected dive open
QAction *actionTaken = popup.exec(event->globalPos());
@@ -836,6 +840,12 @@ void DiveListView::contextMenuEvent(QContextMenuEvent *event)
event->accept();
}
+void DiveListView::publishFacebook()
+{
+ FacebookManager manager;
+ manager.checkAlbumExists();
+}
+
void DiveListView::shiftTimes()
{
ShiftTimesDialog::instance()->show();