Reply
Thread Tools
Posts: 10 | Thanked: 0 times | Joined on May 2010 @ Birmingham, United Kingdom
#11
Argh sorry, it was just me being stupid.

I found in the SDK, there is a section with the list of build steps (qmake, make and make clean) which are basically automatically what you would type in terminal, along with a list of environment variables where I added to the LD_LIBRARY_PATH:
Code:
LD_LIBRARY_PATH=libqfacebook-build/debug sample
But I just deleted " sample" from the end and now it all works!

Thanks for all your help! This has been bugging me for a couple of days now, always ends up being something simple :P
 
Posts: 726 | Thanked: 345 times | Joined on Apr 2010 @ Sweden
#12
Do you understand what you just did?

And you're welcome.
 
Posts: 10 | Thanked: 0 times | Joined on May 2010 @ Birmingham, United Kingdom
#13
Yea I do I think...haha
I didn't actually put exactly what you said, I did the full /home/blah/blah and there was already something else in it as well.
 
Posts: 726 | Thanked: 345 times | Joined on Apr 2010 @ Sweden
#14
My suggestion in message #11 was to actually type what I wrote in an XTerminal. That's why I had "simple" at the end.

You did something completely different and placed the variable definition inside some part of the build framework to be used when the binary is run.

In effect, it does the same thing but now the value is set and you can't play around with it as easily as if you had written it at a prompt.

(If you really want to understand the implication of defining variables on the command line like that, I'd suggest that you read the man page for /bin/sh.)
 
Posts: 10 | Thanked: 0 times | Joined on May 2010 @ Birmingham, United Kingdom
#15
I seem to have got myself another problem now

I don't know whether you know about qfacebookconnect itself?
But I have got the sample application working fine now, so instead of just modifying that for what I wanted to do, I made my own project and basically added what I needed from the sample application.

At first I just changed the facebook api key and secret in the sample, to connect to my own facebook app, and that worked.
But in my own one when I try and tell the application to login to facebook it just terminates unexpectedly before loading the facebook login page. When I debug it I get a segmentation fault error on clicking the button :\

I have been through both the sample application and my own one to compare the login methods and the various facebook api methods and as it stands they are all the same.
 
Posts: 726 | Thanked: 345 times | Joined on Apr 2010 @ Sweden
#16
How do you connect signals to slots? How do you handle the data that is sent with the signal to your handler?

To just look at code and say "It looks the same!" is tricky, especially with C++...
 
Posts: 10 | Thanked: 0 times | Joined on May 2010 @ Birmingham, United Kingdom
#17
Ahh this is where I was a bit confused as I'm pretty new to C++.

I don't entirely understand about signals and slots, but qt designer seemed to sort it out for me (which is where learning it before just using the sdk probably comes in I may start reading up a lot more on c++...).

but in the header file (mainwindow.h) there is:
Code:
private slots:

    void on_btLogout_clicked();
    void on_btLogin_clicked();
And then in the source (mainwindow.cpp):
Code:
void MainWindow::on_btLogin_clicked()
{
    if (iFBSession->resume() == false)
    {
        iLoginDialog = new FBLoginDialog();
        iLoginDialog->show();
    }
}

void MainWindow::on_btLogout_clicked()
{
        iFBSession->logout();
}
I don't know if I'm being stupid, but I cant see how these link to the actual action of the button being clicked? Which is the problem I guess..

Sorry if I'm being a headache
 
Posts: 10 | Thanked: 0 times | Joined on May 2010 @ Birmingham, United Kingdom
#18
Ohh, a bit of playing around with dialogues in QtDesigner and I think I have fixed it.
 
Reply


 
Forum Jump


All times are GMT. The time now is 16:53.