void CSVRender::WorldspaceWidget::selectNavigationMode (const std::string& mode) { if (mode=="1st") setNavigation (&m1st); else if (mode=="free") setNavigation (&mFree); else if (mode=="orbit") setNavigation (&mOrbit); }
void JabberBrowser::go(const QString &url, const QString &node) { setNavigation(); Command cmd; setTitle(); m_list->clear(); cmd->id = CmdBrowseInfo; cmd->flags = COMMAND_DISABLED; cmd->param = this; Event eNext(EventCommandDisabled, cmd); eNext.process(); cmd->id = CmdBrowseSearch; cmd->flags = COMMAND_DISABLED; cmd->param = this; eNext.process(); cmd->id = CmdRegister; cmd->flags = COMMAND_DISABLED; cmd->param = this; eNext.process(); cmd->id = CmdBrowseConfigure; cmd->flags = COMMAND_DISABLED; cmd->param = this; eNext.process(); m_bInProcess = true; QListViewItem *item = new QListViewItem(m_list); item->setText(COL_JID, url); item->setText(COL_NAME, url); item->setText(COL_NODE, node); m_bError = false; unsigned mode = 0; if (m_client->getBrowseType() & BROWSE_DISCO){ item->setText(COL_ID_DISCO_ITEMS, m_client->discoItems(url.utf8(), node.utf8()).c_str()); item->setText(COL_ID_DISCO_INFO, m_client->discoInfo(url.utf8(), node.utf8()).c_str()); mode = BROWSE_DISCO | BROWSE_INFO; } if (m_client->getBrowseType() & BROWSE_BROWSE){ if (node.isEmpty()){ item->setText(COL_ID_BROWSE, m_client->browse(url.utf8()).c_str()); mode |= BROWSE_BROWSE; } } item->setText(COL_MODE, QString::number(mode)); item->setPixmap(COL_NAME, Pict("empty")); cmd->id = CmdUrl; cmd->param = this; Event eWidget(EventCommandWidget, cmd); CToolCombo *cmbUrl = (CToolCombo*)(eWidget.process()); if (cmbUrl) cmbUrl->setText(url); cmd->id = CmdNode; CToolCombo *cmbNode = (CToolCombo*)(eWidget.process()); if (cmbNode) cmbNode->setText(node); startProcess(); if (item->text(COL_ID_DISCO_INFO).isEmpty()) stop(i18n("Client offline")); }
void JabberBrowser::go(const QString &url, const QString &node) { setNavigation(); Command cmd; setTitle(); m_list->clear(); m_category = ""; m_type = ""; m_name = ""; m_features = ""; cmd->id = static_cast<JabberPlugin*>(m_client->protocol()->plugin())->CmdInfo; cmd->flags = COMMAND_DISABLED; cmd->param = this; Event eNext(EventCommandDisabled, cmd); eNext.process(); cmd->id = static_cast<JabberPlugin*>(m_client->protocol()->plugin())->CmdSearch; cmd->flags = COMMAND_DISABLED; cmd->param = this; eNext.process(); cmd->id = static_cast<JabberPlugin*>(m_client->protocol()->plugin())->CmdRegister; cmd->flags = COMMAND_DISABLED; cmd->param = this; eNext.process(); cmd->id = static_cast<JabberPlugin*>(m_client->protocol()->plugin())->CmdConfigure; cmd->flags = COMMAND_DISABLED; cmd->param = this; eNext.process(); m_id1 = m_client->discoItems(url.utf8(), node.utf8()); m_id2 = m_client->discoInfo(url.utf8(), node.utf8()); cmd->id = static_cast<JabberPlugin*>(m_client->protocol()->plugin())->CmdUrl; cmd->text = I18N_NOOP("Stop"); cmd->icon = "cancel"; cmd->bar_grp = 0x2000; cmd->flags = BTN_COMBO_CHECK; cmd->param = this; Event e(EventCommandChange, cmd); e.process(); cmd->id = static_cast<JabberPlugin*>(m_client->protocol()->plugin())->CmdUrl; cmd->param = this; Event eWidget(EventCommandWidget, cmd); CToolCombo *cmbUrl = (CToolCombo*)(eWidget.process()); if (cmbUrl) cmbUrl->setText(url); cmd->id = static_cast<JabberPlugin*>(m_client->protocol()->plugin())->CmdNode; CToolCombo *cmbNode = (CToolCombo*)(eWidget.process()); if (cmbNode) cmbNode->setText(node); m_status->message(i18n("Process")); if (m_id1.empty()) stop(i18n("Client offline")); }
void CSVRender::PreviewWidget::setup() { setNavigation (&mOrbit); mNode = getSceneManager()->getRootSceneNode()->createChildSceneNode(); mNode->setPosition (Ogre::Vector3 (0, 0, 0)); setModel(); QAbstractItemModel *referenceables = mData.getTableModel (CSMWorld::UniversalId::Type_Referenceables); connect (referenceables, SIGNAL (dataChanged (const QModelIndex&, const QModelIndex&)), this, SLOT (ReferenceableDataChanged (const QModelIndex&, const QModelIndex&))); connect (referenceables, SIGNAL (rowsAboutToBeRemoved (const QModelIndex&, int, int)), this, SLOT (ReferenceableAboutToBeRemoved (const QModelIndex&, int, int))); }
void CSVRender::WorldspaceWidget::selectDefaultNavigationMode() { setNavigation (&m1st); }
void Viewer::on_fpsManipulatorAction_triggered() { setNavigation(new FpsNavigation(m_camera)); uncheckManipulatorActions(); m_ui->fpsManipulatorAction->setChecked(true); qDebug("FPS Navigation, use mouse and WASD"); }
void Viewer::on_trackballManipulatorAction_triggered() { setNavigation(new ArcballNavigation(m_camera)); uncheckManipulatorActions(); m_ui->trackballManipulatorAction->setChecked(true); qDebug("Arcball navigation, use left and right mouse buttons"); }
void Viewer::on_flightManipulatorAction_triggered() { setNavigation(new FlightNavigation(m_camera)); uncheckManipulatorActions(); m_ui->flightManipulatorAction->setChecked(true); qDebug("Flight navigation, use WASD and arrow keys"); }