Commit Graph

11347 Commits

Author SHA1 Message Date
Gioacchino Mazzurco
17edf3c8de Fix compilation and some warnings 2017-04-19 23:46:30 +02:00
Konrad
4a0b51ce2d Added: to response information whether the identity is a contact 2017-04-19 22:03:24 +02:00
csoler
ccfd12b506 Merge pull request #778 from csoler/v0.6-ImprovedGUI
V0.6 improved gui
2017-04-19 18:53:49 +02:00
csoler
f406b81238 removed all FFT code and cleaned up deleted code in graphwidget.cpp 2017-04-19 18:46:58 +02:00
csoler
1da89dd70d changed FFT code in graph widget into a more efficient one, with free licence 2017-04-19 17:16:30 +02:00
Gioacchino Mazzurco
30bb84c4a9 Save persistently that default identity is created
In 943a4213fb default identity creation
  burst has been solved but some times the duplication happens in
  sequent instances of the app, now te app store permanently if default
  identity has been created so this other kind of duplication is avoided
  too (hopefully)
2017-04-19 14:23:29 +02:00
Gioacchino Mazzurco
e83fec8d84 Avoid linking libretroshare in qml app and notify
Use QDir::homePath() instead of RsAccounts::ConfigDirectory() to
  determine libresapi socket path, this way statically linking to
  libretroshare is not needed and the android package size is reduced
  dramatically 20+MB -> 13MB

At same time this solves the socket path mismatch between retroshare
  android  service and the other android applications due to merge
2017-04-18 23:14:44 +02:00
Konrad
b43bedf669 Added: Handling requests to set opinion about identity 2017-04-18 23:00:59 +02:00
Konrad
120ca9d078 Added: Handling requests to set opinion about identity 2017-04-18 22:58:15 +02:00
Konrad
3f54568d7f Added: Handling requests to get details about identity 2017-04-18 22:56:35 +02:00
Gioacchino Mazzurco
4455bfa92d Merge branch 'master' into merge_alpha_master 2017-04-18 21:30:25 +02:00
csoler
e2d9152b22 moved converted serialisation files into new directory rsitems/, leaving serialiser/ for the serialisation classes 2017-04-18 21:11:37 +02:00
csoler
e95ddb91af Merge pull request #767 from PhenomRetroShare/Fix_CommentWithLineReturn
Fix comment view when they have line return.
2017-04-18 20:28:36 +02:00
csoler
5f969e7306 Merge pull request #776 from PhenomRetroShare/Fix_ClangWarnings
Fix clang warnings
2017-04-18 20:27:20 +02:00
csoler
3ab39c6b5f Merge pull request #777 from PhenomRetroShare/Fix_EncodeRadixInRSLinks
Encode Radix in RSLinks.
2017-04-18 20:26:14 +02:00
Phenom
3c5e61a297 Encode Radix in RSLinks.
Because it can contains special characters like '+', '/'.
But this is not backward compatible.
2017-04-18 17:36:43 +02:00
Konrad
76dd7fe47f Added: Handling requests to add and remove contact 2017-04-18 14:02:14 +02:00
Konrad
4a99000f16 Added: Handling requests to get and set node options 2017-04-18 14:00:30 +02:00
Gioacchino Mazzurco
f04697d61d Qml app is not supposed to stop core on android 2017-04-18 13:30:28 +02:00
Gioacchino Mazzurco
871ea333fc Qml app allow registrer same callback
As I haven't investigated this enough yet, allow it happening but warn
  if it happens while debugging
2017-04-18 13:06:57 +02:00
Gioacchino Mazzurco
943a4213fb Qml app avoid multiple default identity creation burst 2017-04-18 13:05:07 +02:00
Gioacchino Mazzurco
2c4cbd529a Update to QtQuick 2.7
Since we already depends on Qt 5.7 for QtQuick Controls 2 there is no
  point in using older QtQuick version
2017-04-18 11:53:14 +02:00
Gioacchino Mazzurco
9accb2b3d5 Attempt to fix retroshare android service quit 2017-04-18 11:53:14 +02:00
Gioacchino Mazzurco
a1311c16c8 Use unique name for main
Qt Creator get confused if files with same name are present in the same
  project and when clickng on debug info open the same file, renaming
  main to avoid this
2017-04-18 11:53:14 +02:00
Gioacchino Mazzurco
987b5a1cdc QML app fix: crash closing, notification deadlock
The crash was introduced at 533dbef0c7

This has been particurarly tricky as lot of different parts contributed
  in causing unexpected behaviours

When the activity is created onNewIntent is not called and we have to
  get the intent data from C++ bu other means, but C++ code is running
  in a different thread so there is no guarantee that the intent data is
  reacheable yet on starting, so the C++ code has to wait for the intent
  data being ready, but paying attention to not cause a deadlock beetween
  the two thread (the android ui thread may be waiting for some
  operation performed by Qt)

Because of notification intent flags not properly set the activity was
  recreated also if it was already on top, this caused a nasty
  interaction between android ui thread and qt thread that derived in a
  deadlock, to avoid this lot of try/error has been made until the
  proper soup of manifest and intent flags has been found

At this point link handling, notification handling, and Activity closing
  should work as expected without any deadlock or crash
2017-04-18 11:53:14 +02:00
Phenom
37331372c1 Fix Clang warnings: implicit conversion
warning: implicit conversion from 'int' to 'char' changes value from 255
to -1 [-Wconstant-conversion]
                                asctobin()[i] = 255;    /* used to
detect invalid characters */
2017-04-18 11:25:41 +02:00
Phenom
7d9a80326d Fix Clang warnings: bdnet_inet_ntoa C-linkage
/libbitdht/src/util/bdnet.h:107: warning: 'bdnet_inet_ntoa' has C-
linkage specified, but returns user-defined type 'std::string' (aka
'basic_string<char>') which is incompatible with C [-Wreturn-type-c-
linkage]
std::string bdnet_inet_ntoa(struct in_addr in);
            ^
2017-04-18 11:18:10 +02:00
csoler
4faaaf7093 Merge pull request #775 from csoler/v0.6-PRTest
V0.6 pr test
2017-04-17 22:03:48 +02:00
Phenom
87dd614088 Fix Clang Warnings: private field 'encoding_debug_file' is not used
warning: private field 'encoding_debug_file' is not used [-Wunused-
private-field]
    FILE *encoding_debug_file ;
2017-04-17 22:01:48 +02:00
Phenom
4f939b2b76 Fix Clang warnings: unused function 'set_item_background'
warning: unused function 'set_item_background' [-Wunused-function]
static void set_item_background(QTreeWidgetItem *item, uint32_t type)
2017-04-17 22:01:28 +02:00
Phenom
76f7573659 Fix Clang warnings: comparison of array != a null pointer is always true
warning: comparison of array 'known_zones[i].tzName' not equal to a null
pointer is always true [-Wtautological-pointer-compare]
                        for (int i=0; known_zones[i].tzName != 0; i++) {
2017-04-17 21:58:19 +02:00
Phenom
0bbd1499d4 Fix Clang warnings: comparison of integers of different signs
warning: comparison of integers of different signs: 'uint32_t' (aka
'unsigned int') and 'int' [-Wsign-compare]
        for(uint32_t i=0;i<(*it).size();++i)
                         ~^~~~~~~~~~~~~
2017-04-17 21:54:49 +02:00
Phenom
a476a8138c Fix Clang warnings: function 'update_children_background' is not needed
warning: function 'update_children_background' is not needed and will
not be emitted [-Wunneeded-internal-declaration]
static void update_children_background(QTreeWidgetItem *item, uint32_t
type)
            ^
2017-04-17 21:53:57 +02:00
Phenom
d8a73132c1 Fix Clang warnings: implicit conversion from 'double' to 'int'
warning: implicit conversion from 'double' to 'int' changes value from
0.5 to 0 [-Wliteral-conversion]
    painter.setPen(QColor::fromRgb(0.5,0.5,0.5));
2017-04-17 21:51:08 +02:00
Phenom
19196e2cb0 Fix Clang warnings: ariable 'status' is used uninitialized
warning: variable 'status' is used uninitialized whenever 'if' condition
is false [-Wsometimes-uninitialized]
        else if(state_string == "away")
                ^~~~~~~~~~~~~~~~~~~~~~
2017-04-17 21:50:18 +02:00
Phenom
a3a53b970d Fix Clang warnings: unused parameter 'req'
warning: unused parameter 'req' [-Wunused-parameter]
void PeersHandler::handleGetStateString(Request& req, Response& resp)
2017-04-17 21:49:54 +02:00
Phenom
94ac8216f7 Fix Clang warnings: Unused variable Pi
warning: unused variable 'Pi' [-Wunused-const-variable]
static const double Pi = 3.14159265358979323846264338327950288419717;
2017-04-17 21:47:38 +02:00
Phenom
fd92bca688 Fix Clang warnings: variable 'layout' is used uninitialized
warning: variable 'layout' is used uninitialized whenever 'if' condition
is false [-Wsometimes-uninitialized]
                if (wid) layout =
2017-04-17 21:46:42 +02:00
Phenom
8d85cf558b Fix Clang warnings: 'xxxWidget::sizeHint' hides overloaded vf
warning: 'IdentityWidget::sizeHint' hides overloaded virtual function [-
Woverloaded-virtual]
        QSize sizeHint();
warning: 'CircleWidget::sizeHint' hides overloaded virtual function [-
Woverloaded-virtual]
        QSize sizeHint();
/usr/include/qt4/QtGui/qwidget.h:537: hidden overloaded virtual function
'QWidget::sizeHint' declared here: different qualifiers (const vs none)
    virtual QSize sizeHint() const;
2017-04-17 21:46:11 +02:00
Phenom
6f2d7bbca0 Fix Clang warnings: implicit conversion from 'double' to 'int'
warning: implicit conversion from 'double' to 'int' changes value from
2.5 to 2 [-Wliteral-conversion]
        QSize buttonSize = QSize(iconSize + QSize(FMM,FMM));
2017-04-17 21:42:13 +02:00
Phenom
07b67e9cc9 Fix Clang warnings: 'PopupDistantChatDialog::init' hides overloaded
virtual function

warning: 'PopupDistantChatDialog::init' hides overloaded virtual
function [-Woverloaded-virtual]
                virtual void init(const DistantChatPeerId& peer_id);
/retroshare-gui/src/gui/chat/PopupChatDialog.h:49: hidden overloaded
virtual function 'PopupChatDialog::init' declared here: different number
of parameters (2 vs 1)
        virtual void init(const ChatId &chat_id, const QString &title);
2017-04-17 21:41:38 +02:00
Phenom
eea49d96bf Fix Clang warnings: change ChatDialog::init definition
warning: 'PopupChatDialog::init' hides overloaded virtual function [-
Woverloaded-virtual]
    virtual void init(const ChatId &chat_id, const QString &title);
                 ^
/retroshare-gui/src/gui/chat/ChatDialog.h:87: hidden overloaded virtual
function 'ChatDialog::init' declared here: type mismatch at 1st
parameter ('ChatId' vs 'const ChatId &')
    virtual void init(ChatId id, const QString &title);
                 ^
2017-04-17 21:40:25 +02:00
Phenom
9319caffc7 Fix Clang warnings: 'Node::advance' hides overloaded virtual function
warning: 'Node::advance' hides overloaded virtual function [-
Woverloaded-virtual]
    bool advance();
         ^
/usr/include/qt4/QtGui/qgraphicsitem.h:323: hidden overloaded virtual
function 'QGraphicsItem::advance' declared here: different number of
parameters (1 vs 0)
    virtual void advance(int phase);
                 ^
2017-04-17 21:39:44 +02:00
Phenom
13c8f7d342 Fix Clang warnings: Infinite recursion
warning: all paths through this function will call itself [-Winfinite-
recursion]
{
^
2017-04-17 21:38:41 +02:00
Phenom
e0225efef3 Fix Clang warnings: 'ChatLobbyDialog::init' hides overloaded virtual
function

warning: 'ChatLobbyDialog::init' hides overloaded virtual function [-
Woverloaded-virtual]
    virtual void init();
                 ^
/retroshare-gui/src/gui/chat/ChatDialog.h:87: hidden overloaded virtual
function 'ChatDialog::init' declared here: different number of
parameters (2 vs 0)
    virtual void init(ChatId id, const QString &title);
                 ^
2017-04-17 21:37:17 +02:00
Phenom
de4f6c06dd Fix Clang warnings: Z-order assignment to spacer
warning: Z-order assignment: 'verticalSpacer_2' is not a valid widget.
2017-04-17 21:36:14 +02:00
Phenom
32eeb957b2 Fix Clang warnings: unused private field
warning: private field 'mAutoBanIdentitiesLimit' is not used [-Wunused-
private-field]
    float mAutoBanIdentitiesLimit ;
warning: private field 'mFiles' is not used [-Wunused-private-field]
    RsFiles* mFiles;
2017-04-17 21:35:29 +02:00
Phenom
4ac3b3f5bf Fix Clang warnings: implicit conversion of NULL to bool
warning: implicit conversion of NULL constant to 'bool' [-Wnull-
conversion]
        return NULL ;
        ~~~~~~ ^~~~
               false
2017-04-17 21:33:39 +02:00
Phenom
e83104ee0f Fix Clang warnings: Add author and date to #warning 2017-04-17 21:32:14 +02:00
Phenom
039908b2c6 Fix Clang warnings: private field not used
warning: private field 'mNetMgr' is not used [-Wunused-private-field]
    p3NetMgr *mNetMgr;
2017-04-17 21:29:16 +02:00