コード例 #1
0
void QuteMessenger::createNewTab(const QBtAddress & address)
{
    QChatWidget* tmpChat;
    tmpChat = new QChatWidgetServer(this);
    tmpChat->SetName(address.toString());

    ((QChatWidgetServer*) tmpChat)->SetDiscoverer(devDisc);

    ((QChatWidgetServer*) tmpChat)->SetServer(rfcommServer);
    connect(tmpChat, SIGNAL(tabNameChanged(QString, QChatWidget*)), this,
            SLOT(tabNameChangedReport(QString, QChatWidget*)));

    ui.tabWidget->addTab(tmpChat, "Chat");
    chatTabs.append(tmpChat);
}
コード例 #2
0
bool QBtLocalDevicePrivate::UnpairDevice(const QBtAddress& address)
{
    BTINT32 result = BTSDK_FALSE;
    //get device handle
    BTDEVHDL devHandle = BTSDK_INVALID_HANDLE;
    BTUINT8 btAddr [6]= {0};
    QByteArray btAddrQt = address.toReversedByteArray();
    memcpy(btAddr, btAddrQt.constData(), btAddrQt.size());
    devHandle = Btsdk_GetRemoteDeviceHandle(btAddr);

    if(devHandle == BTSDK_INVALID_HANDLE)
        return false;

    result = Btsdk_UnPairDevice (devHandle);

    return (result == BTSDK_OK);
}
コード例 #3
0
ファイル: QBtAddress.cpp プロジェクト: lukstei/RF12-Network
bool QBtAddress::operator< (const QBtAddress & other )
{
	return (this->toString() < other.toString());
}
コード例 #4
0
ファイル: QBtAddress.cpp プロジェクト: lukstei/RF12-Network
bool QBtAddress::operator!= (const QBtAddress & other )
{
  int result = _address.compare(other.toString(),Qt::CaseInsensitive);
  
  return ((result == 0) ? false : true);
}