示例#1
0
void OwncloudSetupPage::slotSelectFolder()
{

    QString dir = QFileDialog::getExistingDirectory(0, tr("Local Sync Folder"), QDir::homePath());
    if( !dir.isEmpty() ) {
        _ui.pbSelectLocalFolder->setText(dir);
        slotHandleUserInput();
    }
}
示例#2
0
void OwncloudSetupPage::initializePage()
{
    _connected = false;
    _checking  = false;
    _multipleFoldersExist = false;

    // call to init label
    slotHandleUserInput();

    if( _configExists ) {
        _ui.lePassword->setFocus();
    } else {
        _ui.leUrl->setFocus();
    }
}
示例#3
0
// slot hit from textChanged of the url entry field.
void OwncloudSetupPage::slotUrlChanged(const QString& ocUrl)
{
    slotHandleUserInput();

#if 0
    QString url = ocUrl;
    bool visible = false;

    if (url.startsWith(QLatin1String("https://"))) {
        _ui.urlLabel->setPixmap( QPixmap(":/mirall/resources/security-high.png"));
        _ui.urlLabel->setToolTip(tr("This url is secure. You can use it."));
        visible = true;
    }
    if (url.startsWith(QLatin1String("http://"))) {
        _ui.urlLabel->setPixmap( QPixmap(":/mirall/resources/security-low.png"));
        _ui.urlLabel->setToolTip(tr("This url is NOT secure. You should not use it."));
        visible = true;
    }
#endif
}
示例#4
0
void OwncloudSetupPage::slotUserChanged(const QString& user )
{
    slotHandleUserInput();
}