diff options
Diffstat (limited to 'Swift/QtUI/QtWebKitChatView.cpp')
| -rw-r--r-- | Swift/QtUI/QtWebKitChatView.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/Swift/QtUI/QtWebKitChatView.cpp b/Swift/QtUI/QtWebKitChatView.cpp index bca9e2e..75a23f8 100644 --- a/Swift/QtUI/QtWebKitChatView.cpp +++ b/Swift/QtUI/QtWebKitChatView.cpp | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | * Copyright (c) 2010-2018 Isode Limited. | 2 | * Copyright (c) 2010-2019 Isode Limited. |
| 3 | * All rights reserved. | 3 | * All rights reserved. |
| 4 | * See the COPYING file for more information. | 4 | * See the COPYING file for more information. |
| 5 | */ | 5 | */ |
| @@ -141,7 +141,7 @@ void QtWebKitChatView::addMessageBottom(std::shared_ptr<ChatSnippet> snippet) { | |||
| 141 | 141 | ||
| 142 | void QtWebKitChatView::addMessageTop(std::shared_ptr<ChatSnippet> /* snippet */) { | 142 | void QtWebKitChatView::addMessageTop(std::shared_ptr<ChatSnippet> /* snippet */) { |
| 143 | // TODO: Implement this in a sensible manner later. | 143 | // TODO: Implement this in a sensible manner later. |
| 144 | SWIFT_LOG(error) << "Not yet implemented!" << std::endl; | 144 | SWIFT_LOG(error) << "Not yet implemented!"; |
| 145 | } | 145 | } |
| 146 | 146 | ||
| 147 | void QtWebKitChatView::addToDOM(std::shared_ptr<ChatSnippet> snippet) { | 147 | void QtWebKitChatView::addToDOM(std::shared_ptr<ChatSnippet> snippet) { |
| @@ -384,7 +384,7 @@ void QtWebKitChatView::setFileTransferProgress(QString id, const int percentageD | |||
| 384 | rememberScrolledToBottom(); | 384 | rememberScrolledToBottom(); |
| 385 | QWebElement ftElement = findElementWithID(document_, "div", id); | 385 | QWebElement ftElement = findElementWithID(document_, "div", id); |
| 386 | if (ftElement.isNull()) { | 386 | if (ftElement.isNull()) { |
| 387 | SWIFT_LOG(debug) << "Tried to access FT UI via invalid id!" << std::endl; | 387 | SWIFT_LOG(debug) << "Tried to access FT UI via invalid id!"; |
| 388 | return; | 388 | return; |
| 389 | } | 389 | } |
| 390 | QWebElement progressBar = ftElement.findFirst("div.progressbar"); | 390 | QWebElement progressBar = ftElement.findFirst("div.progressbar"); |
| @@ -398,7 +398,7 @@ void QtWebKitChatView::setFileTransferStatus(QString id, const ChatWindow::FileT | |||
| 398 | rememberScrolledToBottom(); | 398 | rememberScrolledToBottom(); |
| 399 | QWebElement ftElement = findElementWithID(document_, "div", id); | 399 | QWebElement ftElement = findElementWithID(document_, "div", id); |
| 400 | if (ftElement.isNull()) { | 400 | if (ftElement.isNull()) { |
| 401 | SWIFT_LOG(debug) << "Tried to access FT UI via invalid id! id = " << Q2PSTRING(id) << std::endl; | 401 | SWIFT_LOG(debug) << "Tried to access FT UI via invalid id! id = " << Q2PSTRING(id); |
| 402 | return; | 402 | return; |
| 403 | } | 403 | } |
| 404 | 404 | ||
| @@ -483,7 +483,7 @@ int QtWebKitChatView::getSnippetPositionByDate(const QDate& date) { | |||
| 483 | 483 | ||
| 484 | void QtWebKitChatView::resetTopInsertPoint() { | 484 | void QtWebKitChatView::resetTopInsertPoint() { |
| 485 | // TODO: Implement or refactor later. | 485 | // TODO: Implement or refactor later. |
| 486 | SWIFT_LOG(error) << "Not yet implemented!" << std::endl; | 486 | SWIFT_LOG(error) << "Not yet implemented!"; |
| 487 | } | 487 | } |
| 488 | 488 | ||
| 489 | std::string QtWebKitChatView::addMessage( | 489 | std::string QtWebKitChatView::addMessage( |
| @@ -624,7 +624,7 @@ void QtWebKitChatView::resizeEvent(QResizeEvent* event) { | |||
| 624 | } | 624 | } |
| 625 | 625 | ||
| 626 | std::string QtWebKitChatView::addFileTransfer(const std::string& senderName, const std::string& avatarPath, bool senderIsSelf, const std::string& filename, const boost::uintmax_t sizeInBytes, const std::string& description) { | 626 | std::string QtWebKitChatView::addFileTransfer(const std::string& senderName, const std::string& avatarPath, bool senderIsSelf, const std::string& filename, const boost::uintmax_t sizeInBytes, const std::string& description) { |
| 627 | SWIFT_LOG(debug) << "addFileTransfer" << std::endl; | 627 | SWIFT_LOG(debug) << "addFileTransfer"; |
| 628 | QString ft_id = QString("ft%1").arg(P2QSTRING(boost::lexical_cast<std::string>(idCounter_++))); | 628 | QString ft_id = QString("ft%1").arg(P2QSTRING(boost::lexical_cast<std::string>(idCounter_++))); |
| 629 | 629 | ||
| 630 | QString actionText; | 630 | QString actionText; |
| @@ -726,7 +726,7 @@ static bool isFilePathWritable(const QString& path) { | |||
| 726 | void QtWebKitChatView::setFileTransferWarning(QString id, QString warningText) { | 726 | void QtWebKitChatView::setFileTransferWarning(QString id, QString warningText) { |
| 727 | QWebElement ftElement = findElementWithID(document_, "div", id); | 727 | QWebElement ftElement = findElementWithID(document_, "div", id); |
| 728 | if (ftElement.isNull()) { | 728 | if (ftElement.isNull()) { |
| 729 | SWIFT_LOG(debug) << "Tried to access FT UI via invalid id! id = " << Q2PSTRING(id) << std::endl; | 729 | SWIFT_LOG(debug) << "Tried to access FT UI via invalid id! id = " << Q2PSTRING(id); |
| 730 | return; | 730 | return; |
| 731 | } | 731 | } |
| 732 | 732 | ||
| @@ -737,7 +737,7 @@ void QtWebKitChatView::setFileTransferWarning(QString id, QString warningText) { | |||
| 737 | void QtWebKitChatView::removeFileTransferWarning(QString id) { | 737 | void QtWebKitChatView::removeFileTransferWarning(QString id) { |
| 738 | QWebElement ftElement = findElementWithID(document_, "div", id); | 738 | QWebElement ftElement = findElementWithID(document_, "div", id); |
| 739 | if (ftElement.isNull()) { | 739 | if (ftElement.isNull()) { |
| 740 | SWIFT_LOG(debug) << "Tried to access FT UI via invalid id! id = " << Q2PSTRING(id) << std::endl; | 740 | SWIFT_LOG(debug) << "Tried to access FT UI via invalid id! id = " << Q2PSTRING(id); |
| 741 | return; | 741 | return; |
| 742 | } | 742 | } |
| 743 | 743 | ||
| @@ -829,7 +829,7 @@ void QtWebKitChatView::handleHTMLButtonClicked(QString id, QString encodedArgume | |||
| 829 | window_->resendMessage(Q2PSTRING(chatID)); | 829 | window_->resendMessage(Q2PSTRING(chatID)); |
| 830 | } | 830 | } |
| 831 | else { | 831 | else { |
| 832 | SWIFT_LOG(debug) << "Unknown HTML button! ( " << Q2PSTRING(id) << " )" << std::endl; | 832 | SWIFT_LOG(debug) << "Unknown HTML button! ( " << Q2PSTRING(id) << " )"; |
| 833 | } | 833 | } |
| 834 | } | 834 | } |
| 835 | 835 | ||
Swift