summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMateusz Piekos <mateuszpiekos@gmail.com>2012-07-24 08:47:30 (GMT)
committerMateusz Piekos <mateuszpiekos@gmail.com>2012-07-24 08:47:30 (GMT)
commit8b01b8de0477d7c6bb8dd7dd834fd147c7f9b86d (patch)
treef23ad13684e1d97e6d7c2a647de8f03b9569f034 /Swiften/Whiteboard/WhiteboardTransformer.cpp
parent60f389c0efd76c3866d6c9c236fe7d370f584839 (diff)
downloadswift-contrib-8b01b8de0477d7c6bb8dd7dd834fd147c7f9b86d.zip
swift-contrib-8b01b8de0477d7c6bb8dd7dd834fd147c7f9b86d.tar.bz2
Modified code to use *name instead of *name.get()
Diffstat (limited to 'Swiften/Whiteboard/WhiteboardTransformer.cpp')
-rw-r--r--Swiften/Whiteboard/WhiteboardTransformer.cpp38
1 files changed, 19 insertions, 19 deletions
diff --git a/Swiften/Whiteboard/WhiteboardTransformer.cpp b/Swiften/Whiteboard/WhiteboardTransformer.cpp
index 30450c1..8ee206b 100644
--- a/Swiften/Whiteboard/WhiteboardTransformer.cpp
+++ b/Swiften/Whiteboard/WhiteboardTransformer.cpp
@@ -40,25 +40,25 @@ namespace Swift {
std::pair<WhiteboardOperation::ref, WhiteboardOperation::ref> WhiteboardTransformer::transform(WhiteboardInsertOperation::ref clientOp, WhiteboardInsertOperation::ref serverOp) {
std::pair<WhiteboardInsertOperation::ref, WhiteboardInsertOperation::ref> result;
- result.first = boost::make_shared<WhiteboardInsertOperation>(*serverOp.get());
+ result.first = boost::make_shared<WhiteboardInsertOperation>(*serverOp);
result.first->setParentID(clientOp->getID());
result.first->setPos(result.first->getPos()+1);
- result.second = boost::make_shared<WhiteboardInsertOperation>(*clientOp.get());
+ result.second = boost::make_shared<WhiteboardInsertOperation>(*clientOp);
result.second->setParentID(serverOp->getID());
return result;
}
std::pair<WhiteboardOperation::ref, WhiteboardOperation::ref> WhiteboardTransformer::transform(WhiteboardUpdateOperation::ref clientOp, WhiteboardUpdateOperation::ref serverOp) {
std::pair<WhiteboardUpdateOperation::ref, WhiteboardUpdateOperation::ref> result;
- result.first = boost::make_shared<WhiteboardUpdateOperation>(*serverOp.get());
+ result.first = boost::make_shared<WhiteboardUpdateOperation>(*serverOp);
result.first->setParentID(clientOp->getID());
if (clientOp->getPos() == serverOp->getPos()) {
- result.second = boost::make_shared<WhiteboardUpdateOperation>(*serverOp.get());
+ result.second = boost::make_shared<WhiteboardUpdateOperation>(*serverOp);
result.second->setID(clientOp->getID());
result.second->setParentID(serverOp->getID());
} else {
- result.second = boost::make_shared<WhiteboardUpdateOperation>(*clientOp.get());
+ result.second = boost::make_shared<WhiteboardUpdateOperation>(*clientOp);
result.second->setParentID(serverOp->getID());
}
return result;
@@ -66,9 +66,9 @@ namespace Swift {
std::pair<WhiteboardOperation::ref, WhiteboardOperation::ref> WhiteboardTransformer::transform(WhiteboardUpdateOperation::ref clientOp, WhiteboardInsertOperation::ref serverOp) {
std::pair<WhiteboardInsertOperation::ref, WhiteboardUpdateOperation::ref> result;
- result.first = boost::make_shared<WhiteboardInsertOperation>(*serverOp.get());
+ result.first = boost::make_shared<WhiteboardInsertOperation>(*serverOp);
result.first->setParentID(clientOp->getID());
- result.second = boost::make_shared<WhiteboardUpdateOperation>(*clientOp.get());
+ result.second = boost::make_shared<WhiteboardUpdateOperation>(*clientOp);
result.second->setParentID(serverOp->getID());
if (serverOp->getPos() <= clientOp->getPos()) {
result.second->setPos(result.second->getPos()+1);
@@ -78,9 +78,9 @@ namespace Swift {
std::pair<WhiteboardOperation::ref, WhiteboardOperation::ref> WhiteboardTransformer::transform(WhiteboardInsertOperation::ref clientOp, WhiteboardUpdateOperation::ref serverOp) {
std::pair<WhiteboardUpdateOperation::ref, WhiteboardInsertOperation::ref> result;
- result.first = boost::make_shared<WhiteboardUpdateOperation>(*serverOp.get());
+ result.first = boost::make_shared<WhiteboardUpdateOperation>(*serverOp);
result.first->setParentID(clientOp->getID());
- result.second = boost::make_shared<WhiteboardInsertOperation>(*clientOp.get());
+ result.second = boost::make_shared<WhiteboardInsertOperation>(*clientOp);
result.second->setParentID(serverOp->getID());
if (serverOp->getPos() >= clientOp->getPos()) {
result.first->setPos(result.first->getPos()+1);
@@ -90,9 +90,9 @@ namespace Swift {
std::pair<WhiteboardOperation::ref, WhiteboardOperation::ref> WhiteboardTransformer::transform(WhiteboardDeleteOperation::ref clientOp, WhiteboardDeleteOperation::ref serverOp) {
std::pair<WhiteboardDeleteOperation::ref, WhiteboardDeleteOperation::ref> result;
- result.first = boost::make_shared<WhiteboardDeleteOperation>(*serverOp.get());
+ result.first = boost::make_shared<WhiteboardDeleteOperation>(*serverOp);
result.first->setParentID(clientOp->getID());
- result.second = boost::make_shared<WhiteboardDeleteOperation>(*clientOp.get());
+ result.second = boost::make_shared<WhiteboardDeleteOperation>(*clientOp);
result.second->setParentID(serverOp->getID());
if (clientOp->getPos() < serverOp->getPos()) {
result.first->setPos(result.first->getPos()-1);
@@ -105,9 +105,9 @@ namespace Swift {
std::pair<WhiteboardOperation::ref, WhiteboardOperation::ref> WhiteboardTransformer::transform(WhiteboardInsertOperation::ref clientOp, WhiteboardDeleteOperation::ref serverOp) {
std::pair<WhiteboardDeleteOperation::ref, WhiteboardInsertOperation::ref> result;
- result.first = boost::make_shared<WhiteboardDeleteOperation>(*serverOp.get());
+ result.first = boost::make_shared<WhiteboardDeleteOperation>(*serverOp);
result.first->setParentID(clientOp->getID());
- result.second = boost::make_shared<WhiteboardInsertOperation>(*clientOp.get());
+ result.second = boost::make_shared<WhiteboardInsertOperation>(*clientOp);
result.second->setParentID(serverOp->getID());
if (clientOp->getPos() <= serverOp->getPos()) {
result.first->setPos(result.first->getPos()+1);
@@ -119,9 +119,9 @@ namespace Swift {
std::pair<WhiteboardOperation::ref, WhiteboardOperation::ref> WhiteboardTransformer::transform(WhiteboardDeleteOperation::ref clientOp, WhiteboardInsertOperation::ref serverOp) {
std::pair<WhiteboardInsertOperation::ref, WhiteboardDeleteOperation::ref> result;
- result.first = boost::make_shared<WhiteboardInsertOperation>(*serverOp.get());
+ result.first = boost::make_shared<WhiteboardInsertOperation>(*serverOp);
result.first->setParentID(clientOp->getID());
- result.second = boost::make_shared<WhiteboardDeleteOperation>(*clientOp.get());
+ result.second = boost::make_shared<WhiteboardDeleteOperation>(*clientOp);
result.second->setParentID(serverOp->getID());
if (serverOp->getPos() <= clientOp->getPos()) {
result.second->setPos(result.second->getPos()+1);
@@ -133,9 +133,9 @@ namespace Swift {
std::pair<WhiteboardOperation::ref, WhiteboardOperation::ref> WhiteboardTransformer::transform(WhiteboardUpdateOperation::ref clientOp, WhiteboardDeleteOperation::ref serverOp) {
std::pair<WhiteboardDeleteOperation::ref, WhiteboardUpdateOperation::ref> result;
- result.first = boost::make_shared<WhiteboardDeleteOperation>(*serverOp.get());
+ result.first = boost::make_shared<WhiteboardDeleteOperation>(*serverOp);
result.first->setParentID(clientOp->getID());
- result.second = boost::make_shared<WhiteboardUpdateOperation>(*clientOp.get());
+ result.second = boost::make_shared<WhiteboardUpdateOperation>(*clientOp);
result.second->setParentID(serverOp->getID());
if (clientOp->getPos() > serverOp->getPos()) {
result.second->setPos(result.second->getPos()-1);
@@ -146,9 +146,9 @@ namespace Swift {
std::pair<WhiteboardOperation::ref, WhiteboardOperation::ref> WhiteboardTransformer::transform(WhiteboardDeleteOperation::ref clientOp, WhiteboardUpdateOperation::ref serverOp) {
std::pair<WhiteboardUpdateOperation::ref, WhiteboardDeleteOperation::ref> result;
- result.first = boost::make_shared<WhiteboardUpdateOperation>(*serverOp.get());
+ result.first = boost::make_shared<WhiteboardUpdateOperation>(*serverOp);
result.first->setParentID(clientOp->getID());
- result.second = boost::make_shared<WhiteboardDeleteOperation>(*clientOp.get());
+ result.second = boost::make_shared<WhiteboardDeleteOperation>(*clientOp);
result.second->setParentID(serverOp->getID());
if (clientOp->getPos() < serverOp->getPos()) {
result.first->setPos(result.first->getPos()-1);