void Curl::reset() { buffer = ""; http_response_code = 0; response_headers.clear(); http_response_message.clear(); setCallback(); setUserPass(); setDefaultOptions(); }
void EditServer::setConnections(){ QObject::connect(uiServerNameLine, SIGNAL(textChanged(QString)), _server, SLOT(setServerName(QString))); QObject::connect(uiServerNameLine, SIGNAL(textChanged(QString)), this, SLOT(updateUI())); QObject::connect(uiServerAddressLine, SIGNAL(editingFinished()), this, SLOT(setServerAddress())); QObject::connect(uiServerAddressLine, SIGNAL(editingFinished()), this, SLOT(updateUI())); QObject::connect(uiUserNameLine, SIGNAL(textChanged(QString)), _server, SLOT(setUserName(QString))); QObject::connect(uiUserNameLine, SIGNAL(textChanged(QString)), this, SLOT(updateUI())); QObject::connect(uiUserPassLine, SIGNAL(textChanged(QString)), _server, SLOT(setUserPass(QString))); QObject::connect(uiUserPassLine, SIGNAL(textChanged(QString)), this, SLOT(updateUI())); QObject::connect(uiAddCalendar, SIGNAL(clicked()), this, SLOT(addCalendar())); QObject::connect(uiDeleteCalendar, SIGNAL(clicked()), this, SLOT(deleteCalendar())); }
Widget::Widget(QWidget *parent) : QWidget(parent), ui(new Ui::Widget){ qDebug()<<"Creando ventana..."; ui->setupUi(this); trayMenu = new QMenu("Intuta", this); trayIcon = new QSystemTrayIcon(this); manager = new QNetworkAccessManager(this); alarma = new QTimer(this); opciones = new QSettings(QSettings::IniFormat, QSettings::UserScope, "INTUTA"); ventanaRegistro = new RegistroWidget; crypto = new SimpleCrypt(this->CLAVE_CIFRADO); QObject::connect(this, SIGNAL(userPassReady()), SLOT(iniciarSesion())); QObject::connect(this, SIGNAL(inicioSesionExitoso()), SLOT(revisar())); QObject::connect(alarma, SIGNAL(timeout()), SLOT(setUserPass())); QObject::connect(this, SIGNAL(datosObtenidos(int)), SLOT(comparar1())); // QObject::connect(this, SIGNAL(nuevoMensaje(int,QStringList)), SLOT(informarNuevosMensajes(int,QStringList))); // QObject::connect(this, SIGNAL(nuevoRecurso(int,QStringList)), SLOT(informarNuevosRecursos(int,QStringList))); QObject::connect(this, SIGNAL(userPassReady()), SLOT(cambiarToolTip())); QObject::connect(this, SIGNAL(algoNuevo(QString)), ventanaRegistro, SLOT(registrarMensaje(QString))); alarma->setInterval(DEFAULT_INTERVAL); opciones->beginGroup("login"); ui->saveUserPass->blockSignals(true); ui->saveUserPass->setChecked(opciones->value("saveUserPass", false).toBool()); ui->saveUserPass->blockSignals(false); opciones->endGroup(); acRegistro = trayMenu->addAction("Ver registro", ventanaRegistro, SLOT(show())); trayMenu->addSeparator(); acRevisar = trayMenu->addAction("Revisar", this, SLOT(revisar())); acSetUserPass = trayMenu->addAction("Fijar usuario y contraseña", this, SLOT(show())); trayMenu->addSeparator(); acSalir = trayMenu->addAction("Salir", qApp, SLOT(quit())); trayIcon->setIcon(QIcon(":/img/intuta.svg")); trayIcon->setContextMenu(trayMenu); trayIcon->setToolTip("INTUTA\nSin configurar"); trayIcon->show(); }