Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Update: Forum Guidelines & Code of Conduct


    Qt World Summit: Early-Bird Tickets

    Unsolved QList<const QBluetoothDeviceInfo* declaration / definiton problem

    C++ Gurus
    6
    47
    1042
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • A
      AnneRanch @J.Hilk last edited by

      @J-Hilk Would it be too offensive to ask you to discuss this ?
      PS I do not get notified about new posts so it may take a few days before I ;ll read your reply.

      Pl45m4 J.Hilk 2 Replies Last reply Reply Quote 0
      • Pl45m4
        Pl45m4 @AnneRanch last edited by Pl45m4

        @AnneRanch said in QList<const QBluetoothDeviceInfo* declaration / definiton problem:

        Would it be too offensive to ask you to discuss this ?

        What do you want to discuss? Whether the documentation is lying?
        You should not copy QObject.

        Everything else, you can copy/use copy c'tors, as it's just standard C++ language and not "Qt".


        If debugging is the process of removing software bugs, then programming must be the process of putting them in.

        ~E. W. Dijkstra

        A 1 Reply Last reply Reply Quote 0
        • A
          AnneRanch @Pl45m4 last edited by

          @Pl45m4 I was looking for alternative way to make a copy of "info" and I got it solved. CLOSED

          1 Reply Last reply Reply Quote 0
          • J.Hilk
            J.Hilk Moderators @AnneRanch last edited by

            @AnneRanch said in QList<const QBluetoothDeviceInfo* declaration / definiton problem:

            @J-Hilk Would it be too offensive to ask you to discuss this ?

            No, of course not, open discourse is one of the fundamentals of society.

            @AnneRanch said in QList<const QBluetoothDeviceInfo* declaration / definiton problem:

            @Pl45m4 I was looking for alternative way to make a copy of "info" and I got it solved. CLOSED

            I'm curious on what you now ended up using! But for your information I wanted to point out, that you can click on the cog symbol on your opening post and actually select "Mark topic as solved". Alternatively, if you think that one answer in particular solved your issue, you can mark that answer as the correct one.

            Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct

            Qt Needs YOUR vote: https://bugreports.qt.io/browse/QTQAINFRA-4121


            Q: What's that?
            A: It's blue light.
            Q: What does it do?
            A: It turns blue.

            A 1 Reply Last reply Reply Quote 1
            • A
              AnneRanch @J.Hilk last edited by

              @J-Hilk

              Currently I just add "info" to struct - class variable and pass "info" to another function for( partial) processing.
              I am still not sure if I can process multiple SIGNAL.

              Here is a code snippet. PLEASE keep in mind it is a code under construction and I like to keep old code so I do not duplicate and of course I use QDebug extensively.
              I am posting the cope "as is " PLEASE do not tell me it does not compile.

                     void SettingsDialog::addDevice(const QBluetoothDeviceInfo &info)
                     {
                         // //*BT_Database_Array[16];
                         //HERE
                         BT_Database_Array[Array_Index].BT_INFO_Address = info.address();
                         BT_Database_Array[Array_Index].INFO_Name = info.name();
              
                         //Array_Index++;
                         //#endif
                         //temporary copy to QString
                         INFO_Name = info.name();
                         BT_Database.INFO_Name = info.name();
                         BT_Database.INFO_Address = info.address().toString();
                         // verify name
                         text = " TASK  verify name";
                         text += BT_Database_Array[Array_Index].INFO_Name;
              #ifdef DEBUG_TASK_SCAN
                         qDebug()<< text;
              #endif
                         text= "Read info ";
                         text += " name ";
                         text += info.name();
                         text += " address ";
                         text += info.address().toString();
              
              #ifdef DEBUG_TASK_SCAN
                         qDebug()<< text;
              #endif
              
                         // verify address
                         text = " TASK  verify address";
                         text += BT_Database_Array[Array_Index].BT_INFO_Address.toString();
              #ifdef DEBUG_TASK_PAIRING
                         qDebug()<< text;
              #endif
              
                         //Pairing_verify(0);
                         Pairing_verify(0, info);
              
              
              1 Reply Last reply Reply Quote 0
              • A
                AnneRanch @Axel Spoerl last edited by

                @Axel-Spoerl Hello sir, I wonder if I could ask you a favor which
                would be immensely helpful in using QT.
                I am looking forward to your reply.
                Thanks
                Cheers

                Axel Spoerl 1 Reply Last reply Reply Quote 0
                • Axel Spoerl
                  Axel Spoerl @AnneRanch last edited by

                  @AnneRanch
                  Feeling honored to be addressed aristocraticly :-)
                  Just ask!

                  Software Engineer
                  The Qt Company, Oslo

                  A 1 Reply Last reply Reply Quote 1
                  • A
                    AnneRanch @Axel Spoerl last edited by

                    @Axel-Spoerl OK - here it comes

                    is there a written document (QT ) describing how to setup QT to
                    compile ONCE ?

                    There are options but I must have them set incorrectly - "typical" user error...

                    I have a growing "subdirs" project and when I do "rebuild" and then "run" or "debug" it will compile again - without me doing any editing.

                    Same when I do edit , then "run " and "run" again, it compiles again , without me doing any more editing.

                    This redundant recompile is beginning to take more and more of my precious time ... I could spent with my grand kids instead ...

                    I had posted a bug report but got no solution.

                    Axel Spoerl 1 Reply Last reply Reply Quote 0
                    • Axel Spoerl
                      Axel Spoerl @AnneRanch last edited by

                      @AnneRanch
                      I guess this is worth a thread of its own.
                      Generally, it is not the intention for Qt Creator to always recompile.
                      If the project is configured correctly, what you describe should not happen.
                      Troubleshooting depends on whether you use qmake or cmake.
                      Both build systems check time stamps to determine if a build tree is dirty and needs compilation.

                      Typical constellations that trigger rebuilding are

                      • git pull or git rebase in the source tree
                      • a build step in Qt Creator that triggers a cleanup before building
                      • broken subdir configuration

                      Suggest you post your subdir structure and cmake / .pro files in a separate thread.

                      Software Engineer
                      The Qt Company, Oslo

                      A 1 Reply Last reply Reply Quote 0
                      • A
                        AnneRanch @Axel Spoerl last edited by

                        @Axel-Spoerl Thanks , I did post "sarcastic" ...." it compiles" in "the lounge".

                        Maybe I could ask for it to be moved .....

                        and do as you suggested after

                        1 Reply Last reply Reply Quote 0
                        • First post
                          Last post