void KexiDBConnectionDialog::init(const KGuiItem& acceptButtonGuiItem)
{
    setObjectName("KexiDBConnectionDialog");
    setButtons(KDialog::User1 | KDialog::Cancel | KDialog::Help);
    setButtonGuiItem(KDialog::User1,
                     acceptButtonGuiItem.text().isEmpty()
                     ? KGuiItem(i18n("&Open"), "document-open", i18n("Open Database Connection"))
                     : acceptButtonGuiItem
                    );
    setModal(true);

    setMainWidget(m_tabWidget);
    connect(this, SIGNAL(user1Clicked()), this, SLOT(accept()));
    connect(m_tabWidget->mainWidget, SIGNAL(saveChanges()), this, SIGNAL(saveChanges()));
    connect(m_tabWidget, SIGNAL(testConnection()), this, SIGNAL(testConnection()));

    adjustSize();
    resize(width(), m_tabWidget->height());
    if (m_tabWidget->mainWidget->connectionOnly())
        m_tabWidget->mainWidget->driversCombo()->setFocus();
    else if (m_tabWidget->mainWidget->nameCombo->currentText().isEmpty())
        m_tabWidget->mainWidget->nameCombo->setFocus();
    else if (m_tabWidget->mainWidget->userEdit->text().isEmpty())
        m_tabWidget->mainWidget->userEdit->setFocus();
    else if (m_tabWidget->mainWidget->passwordEdit->text().isEmpty())
        m_tabWidget->mainWidget->passwordEdit->setFocus();
    else //back
        m_tabWidget->mainWidget->nameCombo->setFocus();
}
Exemplo n.º 2
0
 CError CProfileDatabase::removeProfileImplementation(UID profileUid, std::string platform)
 {
    LOG4CPLUS_TRACE_METHOD(msLogger, __PRETTY_FUNCTION__ );
    mpRequestMutex->lock();
    std::map<UID,CProfileInfo>::iterator mit = mProfiles.find(profileUid);
    if (mProfiles.end() == mit)
    {
       mpRequestMutex->unlock();
       return CProfileRepoError(CProfileRepoError::ERROR_UNKNOWN_UID);
    }
    bool res = mit->second.removeLib(platform);
    if (!res)
    {
       mpRequestMutex->unlock();
       return CProfileRepoError(CProfileRepoError::ERROR_NO_DLL);
    }
    if (saveChanges())
    {
       mpRequestMutex->unlock();
       return CProfileRepoError::NoProfileRepoError();
    }
    else
    {
       mpRequestMutex->unlock();
       return CProfileRepoError(CProfileRepoError::ERROR_DATABASE_WRITE);
    }
 }
Exemplo n.º 3
0
 CError CProfileDatabase::removeProfile(UID profileUid)
 {
    LOG4CPLUS_TRACE_METHOD(msLogger, __PRETTY_FUNCTION__ );
    mpRequestMutex->lock();
    std::map<UID,CProfileInfo>::iterator mit = mProfiles.find(profileUid);
    if (mProfiles.end() == mit)
    {
       mpRequestMutex->unlock();
       return CProfileRepoError(CProfileRepoError::ERROR_UNKNOWN_UID);
    }
    else
    {
       for (std::map<std::string,std::string>::const_iterator it = mit->second.libs().begin(); it != mit->second.libs().end(); ++it)
       {
          mit->second.removeLib(it->first);
       }
       mProfiles.erase(mit);
    }
    if (saveChanges())
    {
       mpRequestMutex->unlock();
       return CProfileRepoError::NoProfileRepoError();
    }
    else
    {
       mpRequestMutex->unlock();
       return CProfileRepoError(CProfileRepoError::ERROR_DATABASE_WRITE);
    }
 }
/**
 * 桥梁限界输入界面类定义
 *
 * @author 熊雪
 * @author 范翔
 * @version 1.0.0
 * @date 20140615
 */
InputBridgeWidget::InputBridgeWidget(QWidget *parent) :
    QWidget(parent),
    ui(new Ui::InputBridgeWidget)
{
    ui->setupUi(this);

    //data.initMaps();
    bridgeCollectModel = NULL;

    tunnelid = -1;

    tasktunnelid = -1;

    connect(ui->finishButton, SIGNAL(clicked()), this, SLOT(finishEdit()));

    // 初始没有做任何编辑
    hasedit = false;

    // 加载桥梁限界表表头数据
    loadBridgeClearanceData();

    // 关于编辑限界值、保存限界值的信号槽
    connect(ui->tableWidget, SIGNAL(itemChanged(QTableWidgetItem*)), this, SLOT(saveItemChanged(QTableWidgetItem*)));
    connect(ui->lineEdit_minHeight,SIGNAL(textEdited(QString)),this,SLOT(minheightChanged(QString)));
    connect(ui->modifyButton, SIGNAL(clicked()), this, SLOT(canBeModified()));
    connect(ui->saveButton, SIGNAL(clicked()), this, SLOT(saveChanges()));
    //connect(ui->cancelButton, SIGNAL(clicked()), this, SLOT(cancelModify()));
}
Exemplo n.º 5
0
/**
  * Constructor of Options Dialog
  */
OptionsDialog::OptionsDialog(QWidget *parent) :QDialog(parent) {

    mainWindow = (MainWindow *)parent;

    createAppearancePage();
    createGameplayPage();

    buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel,Qt::Horizontal,this);

    listWidget = new QListWidget(this);
    listWidget->addItem("Appearance");
    listWidget->addItem("Gameplay");

    stackedLayout = new QStackedLayout();
    stackedLayout->addWidget(appearancePage);
    stackedLayout->addWidget(gameplayPage);
    connect(listWidget, SIGNAL(currentRowChanged(int)), stackedLayout, SLOT(setCurrentIndex(int)));

    QGridLayout *mainLayout = new QGridLayout(this);
    mainLayout->setColumnStretch(0,1);
    mainLayout->setColumnStretch(1,3);
    mainLayout->addWidget(listWidget,0,0);
    mainLayout->addLayout(stackedLayout,0,1);
    mainLayout->addWidget(buttonBox,1,0,1,2);
    setLayout(mainLayout);

    connect(buttonBox, SIGNAL(rejected()),this,SLOT(reject()) );
    connect(buttonBox, SIGNAL(accepted()), this, SLOT(saveChanges()));
    setWindowTitle("Othello FPG - Options");
    listWidget->setCurrentRow(0);
}
Exemplo n.º 6
0
 CError CProfileDatabase::addProfile(const std::string xmlManifestPath)
 {
    LOG4CPLUS_TRACE_METHOD(msLogger, __PRETTY_FUNCTION__ );
    CProfileInfo info(xmlManifestPath);
    mpRequestMutex->lock();
    std::map<UID,CProfileInfo>::iterator mit = mProfiles.find(info.uid());
    if (mProfiles.end() != mit)
    {
       mpRequestMutex->unlock();
       LOG4CPLUS_WARN(msLogger, "Error: UID repetition");
       return CProfileRepoError(CProfileRepoError::ERROR_UID_ALREADY_EXISTS);
    }
    else
    {
       mProfiles[info.uid()] = info;
    }
    if (saveChanges())
    {
       mpRequestMutex->unlock();
       return CProfileRepoError::NoProfileRepoError();
    }
    else
    {
       mpRequestMutex->unlock();
       return CProfileRepoError(CProfileRepoError::ERROR_DATABASE_WRITE);
    }
 }
GameControllerMappingDialog::GameControllerMappingDialog(InputDevice *device, QWidget *parent) :
    QDialog(parent),
    ui(new Ui::GameControllerMappingDialog)
{
    ui->setupUi(this);
    setAttribute(Qt::WA_DeleteOnClose);

    this->device = device;

    device->getActiveSetJoystick()->setIgnoreEventState(true);
    device->getActiveSetJoystick()->release();

    GameController *controller = qobject_cast<GameController*>(device);
    if (controller)
    {
        populateGameControllerBindings(controller);
        ui->mappingStringPlainTextEdit->document()->setPlainText(generateSDLMappingString());
    }

    QString tempWindowTitle = QString(tr("Game Controller Mapping (%1)")).arg(device->getSDLName());
    setWindowTitle(tempWindowTitle);

    enableDeviceConnections();

    ui->buttonMappingTableWidget->setCurrentCell(0, 0);

    connect(device, SIGNAL(destroyed()), this, SLOT(obliterate()));
    connect(ui->buttonBox, SIGNAL(accepted()), this, SLOT(saveChanges()));
    connect(ui->buttonBox, SIGNAL(clicked(QAbstractButton*)), this, SLOT(discardMapping(QAbstractButton*)));
    connect(this, SIGNAL(finished(int)), this, SLOT(enableButtonEvents(int)));
}
Exemplo n.º 8
0
void MainWindow::openFile()
{
    if(saveChanges())
    {
        QFileDialog openDialog(this);
        openDialog.setWindowTitle("Open File");
        openDialog.setFileMode(QFileDialog::ExistingFile);
        openDialog.setNameFilters(QStringList() << "Rail Files (*.rail)" << "Text Files (*.txt)" << "All Files (*.*)");

        if(openDialog.exec() && !openDialog.selectedFiles().isEmpty())
        {
            QString filePath = openDialog.selectedFiles().first();
            QFile file(filePath);
            if(file.open(QIODevice::ReadOnly | QIODevice::Text))
            {
                setCurrentPath(filePath);
                ui->ui_sourceEditTableWidget->clear();
                ui->ui_inputPlainTextEdit->clear();
                ui->ui_outputPlainTextEdit->clear();
                ui->ui_sourceEditTableWidget->setPlainText(file.readAll());
                setModified(false);
            }
            file.close();
        }
    }
}
Exemplo n.º 9
0
 CError CProfileDatabase::addProfileImplementation(UID profileID, const LibDescriptor& library)
 {
    LOG4CPLUS_TRACE_METHOD(msLogger, __PRETTY_FUNCTION__ );
    mpRequestMutex->lock();
    std::map<UID,CProfileInfo>::iterator mit = mProfiles.find(profileID);
    if (mProfiles.end() == mit)
    {
       mpRequestMutex->unlock();
       return CProfileRepoError(CProfileRepoError::ERROR_UNKNOWN_UID);
    }
    else
    {
       mit->second.addLib(library.platform,library.libPath);
    }
    if (saveChanges())
    {
       mpRequestMutex->unlock();
       return CProfileRepoError::NoProfileRepoError();
    }
    else
    {
       mpRequestMutex->unlock();
       return CProfileRepoError(CProfileRepoError::ERROR_DATABASE_WRITE);
    }
 }
Exemplo n.º 10
0
// -----------------------------------------------------------------------------
// 'Closes' the texture editor, prompting the user to save any unsaved changes.
// Returns false if the close operation should be cancelled, true otherwise
// -----------------------------------------------------------------------------
bool TextureXEditor::close()
{
	// Check if any texture lists are modified
	bool modified = false;
	for (auto& texture_editor : texture_editors_)
	{
		texture_editor->applyChanges();
		if (texture_editor->isModified())
			modified = true;
	}

	// Check if patch table was modified
	if (pnames_modified_)
		modified = true;

	// Ask to save changes
	if (modified)
	{
		wxMessageDialog md(this, "Save changes to texture entries?", "Unsaved Changes", wxYES_NO | wxCANCEL);
		int             result = md.ShowModal();
		if (result == wxID_YES)
			saveChanges(); // User selected to save
		else if (result == wxID_CANCEL)
			return false; // User selected cancel, don't close the archive
	}

	return true;
}
Generic6DofConstraintController::Generic6DofConstraintController(QWidget *parent) :
    QWidget(parent),
    ui(new Ui::Generic6DofConstraintController)
{
    ui->setupUi(this);

    connect(this->ui->pbSaveChanges,SIGNAL(clicked()),this,SLOT(saveChanges()));
}
Exemplo n.º 12
0
void MainWindow::reload()
{
	if (saveChanges())
	{
		loadFile(windowFilePath());
		setWindowModified(false);
	}
}
Exemplo n.º 13
0
void CQAnimationSettingsEditor::saveTo(CQCopasiAnimation* target)
{
  saveChanges();

  if (radGlobal->isChecked())
    target->setScaleMode(CQCopasiAnimation::Global);
  else
    target->setScaleMode(CQCopasiAnimation::Individual);
}
Exemplo n.º 14
0
KexiDBConnectionWidget::KexiDBConnectionWidget(QWidget* parent)
        : QWidget(parent)
        , d(new Private())
{
    setupUi(this);
    setObjectName("KexiConnSelectorWidget");
    iconLabel->setPixmap(DesktopIcon(KEXI_ICON_DATABASE_SERVER));

    QVBoxLayout *driversComboLyr = new QVBoxLayout(frmEngine);
    m_driversCombo = new KexiDBDriverComboBox(frmEngine, Kexi::driverManager().driversInfo(),
            KexiDBDriverComboBox::ShowServerDrivers);
    //lblEngine->setFocusProxy( m_driversCombo );
    driversComboLyr->addWidget(m_driversCombo);
    frmEngine->setFocusProxy(m_driversCombo);
    lblEngine->setBuddy(m_driversCombo);
    QWidget::setTabOrder(lblEngine, m_driversCombo);

#ifdef NO_LOAD_DB_LIST
    btnLoadDBList->hide();
#endif
    btnLoadDBList->setIcon(KIcon("view-refresh"));
    btnLoadDBList->setToolTip(i18n("Load database list from the server"));
    btnLoadDBList->setWhatsThis(
        i18n("Loads database list from the server, so you can select one using the \"Name\" combo box."));

    QHBoxLayout *hbox = new QHBoxLayout(frmBottom);
    hbox->addStretch(2);
    d->btnSaveChanges = new KPushButton(
        KGuiItem(
            i18n("Save Changes"), "document-save",
            i18n("Save all changes made to this connection information"),
            i18n("Save all changes made to this connection information. "
                 "You can later reuse this information.")),
        frmBottom);
    d->btnSaveChanges->setObjectName("savechanges");
    hbox->addWidget(d->btnSaveChanges);
    hbox->addSpacing(KDialog::spacingHint());
    QWidget::setTabOrder(titleEdit, d->btnSaveChanges);
    d->btnSaveChanges->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);

    d->btnTestConnection = new KPushButton(
// @todo add Test Connection icon
        KGuiItem(i18n("&Test Connection"), QString(),
                 i18n("Test database connection"),
                 i18n("Tests database connection. "
                      "You can ensure that valid connection information is provided.")),
        frmBottom);
    d->btnTestConnection->setObjectName("testConnection");
    hbox->addWidget(d->btnTestConnection);
    setTabOrder(d->btnSaveChanges, d->btnTestConnection);
    d->btnTestConnection->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);

    connect(locationBGrp, SIGNAL(clicked(int)), this, SLOT(slotLocationBGrpClicked(int)));
    connect(chkPortDefault, SIGNAL(toggled(bool)), this , SLOT(slotCBToggled(bool)));
    connect(btnLoadDBList, SIGNAL(clicked()), this, SIGNAL(loadDBList()));
    connect(d->btnSaveChanges, SIGNAL(clicked()), this, SIGNAL(saveChanges()));
}
Exemplo n.º 15
0
void MainWindow::newForm()
{
	if (saveChanges())
	{
		form->reset();
		setWindowFilePath(tr("Untitled"));
		setWindowModified(false);
		updateUi();
	}
}
Exemplo n.º 16
0
void Theme::change_theme(std::string whichTheme, bool overwrite){
	debug_out("void change_theme(std::string "+whichTheme+", bool overwrite");
	if(whichTheme.compare("")==0){
		errorOUT("Empty theme sent in!");
		return;
	}
	if(overwrite){theme_copier(whichTheme);}
	else if(!overwrite){modCurrentTheme(whichTheme);}
	saveChanges();
} 
Exemplo n.º 17
0
ThreadProperties::ThreadProperties(QWidget *parent, ForumThread *th, ForumDatabase &fd) :
    QDialog(parent), ui(new Ui::ThreadProperties), fdb(fd), thread(th)
{
    ui->setupUi(this);
    connect(this, SIGNAL(accepted()), this, SLOT(saveChanges()));
    connect(this, SIGNAL(rejected()), this, SLOT(deleteLater()));
    connect(thread, SIGNAL(destroyed()), this, SLOT(deleteLater()));
    connect(thread, SIGNAL(changed(ForumThread*)), this, SLOT(updateValues()));
    updateValues();
}
Exemplo n.º 18
0
ConstantEditor::ConstantEditor(bool forceScalar, bool forceVector):QWidget()
{
    hChanges=false;
    isScalar=false;
    QGridLayout * layout = new QGridLayout();
    scalar_rb = new QRadioButton("Scalar", this);
    vector_rb = new QRadioButton("Vector", this);
    scalar_rb->setDown(true);
    QObject::connect(scalar_rb,SIGNAL(toggled(bool)),this,SLOT(radioButtonSelected(bool)));
    QObject::connect(scalar_rb,SIGNAL(toggled(bool)),this,SLOT(changes()));
    layout->addWidget(scalar_rb,0,0,1,2);
    layout->addWidget(vector_rb,2,0,1,2);
    QDoubleValidator * v=new QDoubleValidator(this);
    s_edit=new QLineEdit(this);
    QObject::connect(s_edit,SIGNAL(textEdited(QString)),this,SLOT(changes()));
    QObject::connect(s_edit,SIGNAL(returnPressed()),this,SIGNAL(saveChanges()));
    s_edit->setValidator(v);
    layout->addWidget(s_edit,1,1,1,3);
    v1_edit=new QLineEdit(this);
    QObject::connect(v1_edit,SIGNAL(textEdited(QString)),this,SLOT(changes()));
    QObject::connect(v1_edit,SIGNAL(returnPressed()),this,SIGNAL(saveChanges()));
    v1_edit->setValidator(v);
    layout->addWidget(v1_edit,3,1,1,1);
    v2_edit=new QLineEdit(this);
    QObject::connect(v2_edit,SIGNAL(textEdited(QString)),this,SLOT(changes()));
    QObject::connect(v2_edit,SIGNAL(returnPressed()),this,SIGNAL(saveChanges()));
    v2_edit->setValidator(v);
    layout->addWidget(v2_edit,3,2,1,1);
    v3_edit=new QLineEdit(this);
    QObject::connect(v3_edit,SIGNAL(textEdited(QString)),this,SLOT(changes()));
    QObject::connect(v3_edit,SIGNAL(returnPressed()),this,SIGNAL(saveChanges()));
    v3_edit->setValidator(v);
    layout->addWidget(v3_edit,3,3,1,1);
    s_edit->setText("0.0");
    v1_edit->setText("0.0");
    v2_edit->setText("0.0");
    v3_edit->setText("0.0");
    vector_rb->setEnabled(!forceScalar);
    scalar_rb->setEnabled(!forceVector);
    this->setLayout(layout);
    hChanges=false;
}
Exemplo n.º 19
0
void MainWindow::newFile()
{
    if(saveChanges())
    {
        ui->ui_sourceEditTableWidget->clear();
        ui->ui_inputPlainTextEdit->clear();
        ui->ui_outputPlainTextEdit->clear();
        setModified(false);
        setCurrentPath(QString());
    }
}
Exemplo n.º 20
0
void MainWindow::openRecentFile()
{
	QAction* action = qobject_cast<QAction*>(sender());
	if (action && saveChanges())
	{
		const QString fileName = QDir::fromNativeSeparators(action->data().toString());
		setWindowFilePath(fileName);
		loadFile(fileName);
		updateRecentFile(fileName);
	}
}
Exemplo n.º 21
0
void MainWindow::closeEvent(QCloseEvent *closeEvent)
{
    if(saveChanges())
    {
        closeEvent->accept();
    }
    else
    {
        closeEvent->ignore();
    }
}
Exemplo n.º 22
0
void MainWindow::closeEvent(QCloseEvent* event)
{
	if (!saveChanges())
	{
		event->ignore();
		return;
	}

	saveSettings();
	QWidget::closeEvent(event);
}
Exemplo n.º 23
0
void KexiDBConnectionDialog::init()
{
	connect( this, SIGNAL(user1Clicked()), this, SLOT(accept()));
	setMainWidget(tabWidget);
	connect(tabWidget->mainWidget, SIGNAL(saveChanges()), this, SIGNAL(saveChanges()));
	connect(tabWidget, SIGNAL(testConnection()), this, SIGNAL(testConnection()));

	adjustSize();
	resize(width(), tabWidget->height());
	if (tabWidget->mainWidget->connectionOnly())
		tabWidget->mainWidget->driversCombo()->setFocus();
	else if (tabWidget->mainWidget->nameCombo->currentText().isEmpty())
		tabWidget->mainWidget->nameCombo->setFocus();
	else if (tabWidget->mainWidget->userEdit->text().isEmpty())
		tabWidget->mainWidget->userEdit->setFocus();
	else if (tabWidget->mainWidget->passwordEdit->text().isEmpty())
		tabWidget->mainWidget->passwordEdit->setFocus();
	else //back
		tabWidget->mainWidget->nameCombo->setFocus();
}
Exemplo n.º 24
0
void QuickStartWizard::on_pushButtonSystemFinish_clicked()
{
  Settings->setStartMinimized(ui.checkBoxStartMinimized->isChecked());
  Settings->setValue("doQuit", ui.checkBoxQuit->isChecked());
#ifdef Q_WS_WIN
  Settings->setRunRetroshareOnBoot(ui.checkBoxRunRetroshareAtSystemStartup->isChecked(), ui.chkRunRetroshareAtSystemStartupMinimized->isChecked());
#endif

  saveChanges();
  
  close();
}
Exemplo n.º 25
0
void MainWindow::closeEvent(QCloseEvent *event)
{
    QMessageBox::StandardButton ret = saveChanges();
    switch(ret)
    {
        case QMessageBox::Save:
            saveComputation(); // deliberate fallthrough
        case QMessageBox::Discard:
            event->accept();
            break;
        default:
        event->ignore();
    }
}
Exemplo n.º 26
0
void OptionsServerPage::addNewServer()
{
    DVRServer *server = m_serverRepository->createServer(tr("New Server"));
    server->configuration().setAutoConnect(true);
    server->configuration().setPort(7001);
    server->configuration().setConnectionType(DVRServerConnectionType::RTSP);

    if (!m_serversView->currentIndex().isValid())
        saveChanges(server);
    setCurrentServer(server);

    m_nameEdit->setFocus();
    m_nameEdit->selectAll();
}
Exemplo n.º 27
0
RSettingsWin::RSettingsWin(QWidget *parent)
    : QDialog(parent, Qt::WindowSystemMenuHint | Qt::WindowTitleHint | Qt::WindowCloseButtonHint)
{
    setupUi(this);
    setAttribute(Qt::WA_DeleteOnClose, true);
    setModal(false);

    initStackedWidget();

    connect(listWidget, SIGNAL(currentRowChanged(int)), this, SLOT(setNewPage(int)));
    connect(buttonBox, SIGNAL(accepted()), this, SLOT(saveChanges()));
    connect(buttonBox, SIGNAL(rejected()), this, SLOT(close()));
    connect(this, SIGNAL(finished(int)), this, SLOT(dialogFinished(int)));
}
Exemplo n.º 28
0
void MainWindow::openForm()
{
	if (saveChanges())
	{
		const QString fileName = QFileDialog::getOpenFileName(this, tr("Open"),
									  recentFolder,
									  tr("Jupiter Forms (*.jform);;All Files (*.*)"));
		if (fileName != "")
		{
			setWindowFilePath(fileName);
			loadFile(fileName);
			recentFolder = QFileInfo(fileName).path();
			updateRecentFile(fileName);
		}
	}
}
Exemplo n.º 29
0
void CQAnimationSettingsEditor::slotSelectionChanged()
{
  saveChanges();

  // fill with new entries
  QList<QListWidgetItem*> selected = listWidget->selectedItems();

  for (int i = 0; i < selected.size(); ++i)
    {
      QListWidgetItem* current = selected[i];
      int index = current->data(Qt::UserRole).toInt();
      widget->initFrom(mEntries[index], selected.size() > 1);
    }

  mLastSelection = selected;
}
Exemplo n.º 30
0
KexiDBConnectionWidget::KexiDBConnectionWidget( QWidget* parent,  const char* name )
 : KexiDBConnectionWidgetBase( parent, name )
 , d(new Private())
{
	iconLabel->setPixmap(DesktopIcon("network"));

	QVBoxLayout *driversComboLyr = new QVBoxLayout(frmEngine);
	m_driversCombo = new KexiDBDriverComboBox(frmEngine, Kexi::driverManager().driversInfo(), 
		KexiDBDriverComboBox::ShowServerDrivers);
	lblEngine->setBuddy( m_driversCombo );
	lblEngine->setFocusProxy( m_driversCombo );
	driversComboLyr->addWidget( m_driversCombo );

#ifdef NO_LOAD_DB_LIST
	btnLoadDBList->hide();
#endif
	btnLoadDBList->setIconSet(SmallIconSet("reload"));
	QToolTip::add(btnLoadDBList, i18n("Load database list from the server"));
	QWhatsThis::add(btnLoadDBList, 
		i18n("Loads database list from the server, so you can select one using the \"Name\" combo box."));

	QHBoxLayout *hbox = new QHBoxLayout(frmBottom);
	hbox->addStretch(2);
	d->btnSaveChanges = new KPushButton(KGuiItem(i18n("Save Changes"), "filesave", 
		i18n("Save all changes made to this connection information"),
		i18n("Save all changes made to this connection information. You can later reuse this information.")), 
		frmBottom, "savechanges");
	hbox->addWidget( d->btnSaveChanges );
	hbox->addSpacing( KDialogBase::spacingHint() );
	QWidget::setTabOrder(titleEdit, d->btnSaveChanges);
	d->btnSaveChanges->setSizePolicy( QSizePolicy::Fixed, QSizePolicy::Fixed );

	d->btnTestConnection = new KPushButton(KGuiItem(i18n("&Test Connection"), "", 
		i18n("Test database connection"), 
		i18n("Tests database connection. You can ensure that valid connection information is provided.")), 
		frmBottom, "testConnection");
	hbox->addWidget( d->btnTestConnection );
	QWidget::setTabOrder(d->btnSaveChanges, d->btnTestConnection);
	d->btnTestConnection->setSizePolicy( QSizePolicy::Fixed, QSizePolicy::Fixed );

	connect( locationBGrp, SIGNAL(clicked(int)), this, SLOT(slotLocationBGrpClicked(int)) );
	connect( chkPortDefault, SIGNAL(toggled(bool)), this , SLOT(slotCBToggled(bool)) );
	connect( btnLoadDBList, SIGNAL(clicked()), this, SIGNAL(loadDBList()) );
	connect( d->btnSaveChanges, SIGNAL(clicked()), this, SIGNAL(saveChanges()) );
}