• 3744阅读
  • 1回复

parse error before '{' token   编译错误  郁闷两天了 [复制链接]

上一主题 下一主题
离线znbutterfly
 
只看楼主 倒序阅读 楼主  发表于: 2010-04-23
/****************************************************************************
** Form interface generated from reading ui file 'mycom.ui'
**
** Created: Mon Apr 19 22:21:48 2010
**      by:  The User Interface Compiler (uic)
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/
#ifndef MYCOM_H
#define MYCOM_H

#include <qvariant.h>
#include <qwidget.h>
#include <qthread.h>

class QVBoxLayout;
class QHBoxLayout;
class QGridLayout;
class QComboBox;
class QLabel;
class QLineEdit;
class QPushButton;
class QTextView;
//class QTimer;

class MyThread : public QThread
{                                                                //错误显示在这
    public:
    
         void run();
        
    
        
};


class mycom :public QWidget
{
    Q_OBJECT

public:
    mycom( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
    ~mycom() ;

    QLabel* TextLabel1;
    QLabel* TextLabel1_2;
    QLabel* TextLabel1_2_2;
    QLabel* TextLabel1_3;
    QLabel* TextLabel1_4;
    QComboBox* ComboBox1;
    QComboBox* ComboBox1_2;
    QComboBox* ComboBox1_3;
    QComboBox* ComboBox1_4;
    QComboBox* ComboBox1_5;
    QPushButton* PushButton1;
    QPushButton* PushButton1_2;
    QPushButton* PushButton1_2_2;
    QPushButton* PushButton1_2_2_2;
    QPushButton* PushButton1_2_2_2_2;
    QLineEdit* sentdata;
    QTextView* recivedatas;
//    QTimer* t1;
//    comthread* a;

public slots:
    virtual void cleatdatas();
    virtual void closemycom();
    virtual void openmycom();
    virtual void sentdatas();
    virtual  int OpenDev(char*);
    virtual void choose_speed(int);
    virtual void choose_databits(int);
    virtual void choose_parity(int);
    virtual void choose_stopbits(int);
    virtual void choose_com(int);
    virtual void set_speed(int,int);
    virtual int set_Parity(int);
    virtual void commread( );

};

#endif // MYCOM_H

是在编一个串口调试程序
高手帮忙看看错误出现在哪?什么原因
不包含QThread类的话是能编译成功的

整了两天了,不知道问题出在哪
谢谢了!
离线znbutterfly
只看该作者 1楼 发表于: 2010-04-26
应该是缺少这个库libqte-mt.so
但不知道怎么添加
快速回复
限100 字节
 
上一个 下一个