• 5812阅读
  • 2回复

[提问]为什么加上toolbar触摸屏就没有反应了呢? [复制链接]

上一主题 下一主题
离线tanglek
 

只看楼主 倒序阅读 楼主  发表于: 2011-03-21
/*addToolBar(toolBar=new QToolBar());
    
    dateLabel=new QLabel();
    dateLabel->setText(tr("日期"));
    dateEdit=new QDateEdit();
    dateEdit->setDate(QDate::currentDate());
    toolBar->addWidget(dateLabel);
    toolBar->addWidget(dateEdit);
    */
    tableView=new QTableView();
    tableView->setSelectionBehavior(QAbstractItemView::SelectRows);
    setCentralWidget(tableView);

注释掉toolbar触摸屏才能响应点击,有遇到类似情况的吗?
[ 此帖被tanglek在2011-03-21 22:13重新编辑 ]
离线wxj120bw

只看该作者 1楼 发表于: 2011-03-21
怀疑点击事件没有传道toolbar导致的,楼主可以监控下系统下的点击事件是否发生,然后再做进一步的处理
离线tanglek

只看该作者 2楼 发表于: 2011-03-22
如何监控 ?
快速回复
限100 字节
 
上一个 下一个