examples/tutorials/modelview/3_changingmodel/main.cpp
changeset 37 758a864f9613
parent 33 3e2da88830cd
equal deleted inserted replaced
36:ef0373b55136 37:758a864f9613
    37 ** $QT_END_LICENSE$
    37 ** $QT_END_LICENSE$
    38 **
    38 **
    39 ****************************************************************************/
    39 ****************************************************************************/
    40 
    40 
    41 #include <QtGui/QApplication>
    41 #include <QtGui/QApplication>
    42 #include "modelview.h"
    42 #include <QtGui/QTableView>
       
    43 #include "mymodel.h"
    43 
    44 
    44 int main(int argc, char *argv[])
    45 int main(int argc, char *argv[])
    45 {
    46 {
    46     QApplication a(argc, argv);
    47     QApplication a(argc, argv);
    47     ModelView w;
    48     QTableView tableView;
    48     w.show();
    49     MyModel myModel(0);
       
    50     tableView.setModel( &myModel );
       
    51     tableView.show();
    49     return a.exec();
    52     return a.exec();
    50 }
    53 }