I had an strange problem, help!
Added by ruliang ge over 14 years ago
The following problem make me so confused.
Firstly please look at the file "TestControl.cpp",it would be correctly run.
TestControl::TestControl(TestSuitTree *arg_p_tree)
: app_(WApplication::instance())
{
this->setStyleClass("testcontrol");
treeName_ = new WText("No test suit will be started",this);
new WBreak(this);
startButton_ = new WPushButton("start",this);
//stopButton_ = new WPushButton("stop",this);testSuitTree_ = arg_p_tree; treeEventConnection_ = testSuitTree_->treeEvent().connect(SLOT(this, TestControl::showTreeName)); app_->enableUpdates(); }
Secondly make the following code out, it got a fault
stopButton_ = new WPushButton("stop",this);Thirdly I tried some other method instead of this code , it could be run normally.
new WPushButton("stop",this);
And now I am confused, and don't know the reason about it!
I don't think there is something wrong in this code.
Is there other wrong?
I have uploaded the whole project.
Someone could help me?
Thank you!
TestWebUI.zip (301 KB) TestWebUI.zip |
Replies (1)
RE: I had an strange problem, help! - Added by Wim Dumon over 14 years ago
I quickly looked at this, compiled it, ran it, and didn't see any problem (MSVC on Windows). Possibly this is a build problem. I didn't see a Makefile/CMake file, so I don't know how you built your program. I suggest to do a 'make clean' (erase all your .o files) and rebuild the application from scratch, and see if it works then.
BR,
Wim.