Added some empty methods for ownCloud.

This commit is contained in:
Martin Rotter 2016-02-09 13:53:09 +01:00
parent 5f5e7a1f89
commit 10a135d570
4 changed files with 30 additions and 6 deletions

View File

@ -21,7 +21,7 @@
#include "miscellaneous/application.h"
#include "miscellaneous/iconfactory.h"
#include "services/owncloud/definitions.h"
#include "services/owncloud/owncloudserviceroot.h"
OwnCloudServiceEntryPoint::OwnCloudServiceEntryPoint() {
}
@ -31,6 +31,12 @@ OwnCloudServiceEntryPoint::~OwnCloudServiceEntryPoint() {
ServiceRoot *OwnCloudServiceEntryPoint::createNewRoot() const {
// TODO: TODO
//QPointer<FormEditAccount> form_acc = new FormEditAccount(qApp->mainForm());
//OwnCloudServiceRoot *new_root = form_acc.data()->execForCreate();
//delete form_acc.data();
//return new_root;
return NULL;
}

View File

@ -26,6 +26,22 @@ OwnCloudServiceRoot::OwnCloudServiceRoot(RootItem *parent) : ServiceRoot(parent)
OwnCloudServiceRoot::~OwnCloudServiceRoot() {
}
bool OwnCloudServiceRoot::canBeEdited() const {
return true;
}
bool OwnCloudServiceRoot::canBeDeleted() const {
return true;
}
bool OwnCloudServiceRoot::editViaGui() {
return false;
}
bool OwnCloudServiceRoot::deleteViaGui() {
return false;
}
bool OwnCloudServiceRoot::supportsFeedAdding() const {
// TODO: TODO
return false;

View File

@ -26,6 +26,11 @@ class OwnCloudServiceRoot : public ServiceRoot {
explicit OwnCloudServiceRoot(RootItem *parent = NULL);
virtual ~OwnCloudServiceRoot();
bool canBeEdited() const;
bool canBeDeleted() const;
bool editViaGui();
bool deleteViaGui();
bool supportsFeedAdding() const;
bool supportsCategoryAdding() const;

View File

@ -72,11 +72,8 @@ QString TtRssServiceEntryPoint::code() const {
}
ServiceRoot *TtRssServiceEntryPoint::createNewRoot() const {
QPointer<FormEditAccount> form_acc = new FormEditAccount(qApp->mainForm());
TtRssServiceRoot *new_root = form_acc.data()->execForCreate();
delete form_acc.data();
return new_root;
QScopedPointer<FormEditAccount> form_acc(new FormEditAccount(qApp->mainForm()));
return form_acc->execForCreate();
}
QList<ServiceRoot*> TtRssServiceEntryPoint::initializeSubtree() const {