本文整理汇总了C++中writeSettings函数的典型用法代码示例。如果您正苦于以下问题:C++ writeSettings函数的具体用法?C++ writeSettings怎么用?C++ writeSettings使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了writeSettings函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: menu
/*
void NCPreview::contextMenuEvent(QContextMenuEvent *event)
{
QMenu menu(this);
menu.addAction(cutAct);
menu.addAction(copyAct);
menu.addAction(pasteAct);
menu.exec(event->globalPos());
}
*/
void NCPreview::closeEvent( QCloseEvent *ev )
{
writeSettings();
//qDebug( "Closing and writing settings" );
ev->accept();
}
示例2: writeSettings
MainWindow::~MainWindow()
{
writeSettings();
}
示例3: writeSettings
void QFEvaluationPropertyEditor::closeEvent ( QCloseEvent * event ) {
//std::cout<<"QFEvaluationPropertyEditor::closeEvent\n";
writeSettings();
event->accept();
//std::cout<<"QFEvaluationPropertyEditor::closeEvent ... OK\n";
}
示例4: writeSettings
MultiClientWindow::~MultiClientWindow()
{
writeSettings();
this->on_pushButton_DisconnectALL_clicked();
delete ui;
}
示例5: writeSettings
void ConfigDialog::accept()
{
writeSettings();
QDialog::accept();
}
示例6: handleConsoleInput
void handleConsoleInput() {
uint8_t retval;
uint8_t index=0;
uint8_t ch='0';
SdFile finger;
switch (console.keyValue()) {
case _DIR_:
console.printf("SOD:\r\n");
root.ls(LS_DATE | LS_SIZE);
console.printf("EOD:\r\n");
break;
case _LSV_:
console.printf("LSV:" BOM_VERSION "\r\n");
break;
case _TYP_:
typeFile(console.arguments());
break;
case _NSC_:
console.printf("SOD:\r\n");
retval=networkScan();
console.printf("EOD:\r\n");
console.printf("\nDBG: found=%d\r\n",retval);
break;
case _NJN_:
//console.printf("SOD:\r\n");
retval=networkJoin(console.arguments());
//console.printf("EOD:\r\n");
console.printf("\nDBG: joined=%s\r\n",retval?"TRUE":"FALSE");
break;
case _NPW_:
//console.printf("SOD:\r\n");
retval=networkSetPassword(console.arguments());
//console.printf("EOD:\r\n");
console.printf("\nDBG: pwd set=%s\r\n",retval?"TRUE":"FALSE");
break;
case _NST_:
retval=networkStatus();
console.printf("NST: %s\r\n",retval?"CONNECTED":"NOT CONNECTED");
break;
case _FMT_: // there really should be some REALLY do you mean this here but.....
root.openRoot(&volume);
if (finger.open(&root, ".", O_WRITE|O_READ)) {
console.printf("\nDBG: Opened / \r\n");
finger.rmRfStar();
} else {
console.printf("\nDBG: FAIL \r\n");
}
break;
case _TPT_:
toPachube(1, console.arguments());
break;
case _TX2_:
radio.printf("%s",console.arguments());
index=0;
// delay(1000);
while (radio.available()) {
inBuffer[index++]=ch=radio.read();
if( index>= 99 || ((ch== '\n') || ch !='\r')) {
inBuffer[index]='\0';
console.puts(inBuffer);
index=0;
delay(100);
}
}
inBuffer[index]='\0';
console.puts(inBuffer);
console.puts((char *) "\r\n");
break;
// set to one to test output for.
#if 1
case _TS1_: toPachube(0, console.arguments()); break;
case _TS2_: toPachube(1, console.arguments()); break;
case _TS3_: toPachube(2, console.arguments()); break;
case _TS4_: toPachube(3, console.arguments()); break;
case _TS5_: toPachube(4, console.arguments()); break;
case _FAN_: toPachube(5, console.arguments()); break;
case _CHL_: toPachube(6, console.arguments()); break;
case _STC_: toPachube(7, console.arguments()); break;
#endif
case _PKY_:
strncpy(pachubeKey, console.arguments(), MAX_PATCHUBE_KEY_LENGHT-1);
stripcrlf(pachubeKey);
break;
case _PFD_:
strncpy(pachubeFeed, console.arguments(), MAX_PATCHUBE_FEED_LENGHT-1);
stripcrlf(pachubeFeed);
break;
case _SGT_ :
readSettings();
break;
case _SSV_ :
writeSettings();
break;
default:
console.printf("DBG: forwarding (%s) to device\r\n",console.key());
device.puts(console.line());
//.........这里部分代码省略.........
示例7: writeSettings
void MainWindow::closeEvent(QCloseEvent *event)
{
writeSettings();
event->accept();
}
示例8: writeSettings
ConfigDialog::~ConfigDialog()
{
writeSettings();
}
示例9: writeSettings
BracketedWindow::~BracketedWindow()
{
writeSettings();
}
示例10: writeSettings
void mailclient::closeEvent(QCloseEvent *event)
{
writeSettings();
event->accept();
}
示例11: writeSettings
void NoteWindow::closeEvent(QCloseEvent *event)
{
writeSettings();
}
示例12: writeSettings
void QNetsoul::saveStateBeforeQuiting(void)
{
this->tree->saveContacts();
writeSettings();
qApp->quit();
}
示例13: getFullscreenResolutions
//.........这里部分代码省略.........
else if (ui->jpegRadioButton->isChecked())
config.texture.screenShotFormat = 1;
const int lanuageIndex = ui->translationsComboBox->currentIndex();
if (lanuageIndex == 0) // English
config.translationFile.clear();
else {
QStringList translationFiles;
_getTranslations(translationFiles);
config.translationFile = translationFiles[lanuageIndex-1].toLocal8Bit().constData();
}
// Emulation settings
config.generalEmulation.enableLOD = ui->emulateLodCheckBox->isChecked() ? 1 : 0;
config.generalEmulation.enableNoise = ui->emulateNoiseCheckBox->isChecked() ? 1 : 0;
config.generalEmulation.enableFog = ui->emulateFogCheckBox->isChecked() ? 1 : 0;
config.generalEmulation.enableHWLighting = ui->enableHWLightingCheckBox->isChecked() ? 1 : 0;
config.generalEmulation.enableShadersStorage = ui->enableShadersStorageCheckBox->isChecked() ? 1 : 0;
config.generalEmulation.enableCustomSettings = ui->customSettingsCheckBox->isChecked() ? 1 : 0;
config.frameBufferEmulation.bufferSwapMode = ui->bufferSwapComboBox->currentIndex();
config.frameBufferEmulation.enable = ui->frameBufferGroupBox->isChecked() ? 1 : 0;
if (ui->copyBufferDisableRadioButton->isChecked())
config.frameBufferEmulation.copyToRDRAM = Config::ctDisable;
else if (ui->copyBufferSyncRadioButton->isChecked())
config.frameBufferEmulation.copyToRDRAM = Config::ctSync;
else if (ui->copyBufferAsyncRadioButton->isChecked())
config.frameBufferEmulation.copyToRDRAM = Config::ctAsync;
config.frameBufferEmulation.copyFromRDRAM = ui->RenderFBCheckBox->isChecked() ? 1 : 0;
config.frameBufferEmulation.copyDepthToRDRAM = ui->CopyDepthCheckBox->isChecked() ? 1 : 0;
config.frameBufferEmulation.N64DepthCompare = ui->n64DepthCompareCheckBox->isChecked() ? 1 : 0;
if (ui->aspectStretchRadioButton->isChecked())
config.frameBufferEmulation.aspect = Config::aStretch;
else if (ui->aspect43RadioButton->isChecked())
config.frameBufferEmulation.aspect = Config::a43;
else if (ui->aspect169RadioButton->isChecked())
config.frameBufferEmulation.aspect = Config::a169;
else if (ui->aspectAdjustRadioButton->isChecked())
config.frameBufferEmulation.aspect = Config::aAdjust;
config.frameBufferEmulation.nativeResFactor = ui->resolutionFactorSlider->value();
config.frameBufferEmulation.copyAuxToRDRAM = ui->copyAuxBuffersCheckBox->isChecked() ? 1 : 0;
config.frameBufferEmulation.fbInfoDisabled = ui->fbInfoDisableCheckBox->isChecked() ? 1: 0;
config.frameBufferEmulation.fbInfoReadColorChunk = ui->readColorChunkCheckBox->isChecked() ? 1 : 0;
config.frameBufferEmulation.fbInfoReadDepthChunk = ui->readDepthChunkCheckBox->isChecked() ? 1 : 0;
// Texture filter settings
config.textureFilter.txFilterMode = ui->filterComboBox->currentIndex();
config.textureFilter.txEnhancementMode = ui->enhancementComboBox->currentIndex();
config.textureFilter.txCacheSize = ui->textureFilterCacheSpinBox->value() * gc_uMegabyte;
config.textureFilter.txFilterIgnoreBG = ui->ignoreBackgroundsCheckBox->isChecked() ? 1 : 0;
config.textureFilter.txHiresEnable = ui->texturePackGroupBox->isChecked() ? 1 : 0;
config.textureFilter.txHiresFullAlphaChannel = ui->alphaChannelCheckBox->isChecked() ? 1 : 0;
config.textureFilter.txHresAltCRC = ui->alternativeCRCCheckBox->isChecked() ? 1 : 0;
config.textureFilter.txDump = ui->textureDumpCheckBox->isChecked() ? 1 : 0;
config.textureFilter.txCacheCompression = ui->compressCacheCheckBox->isChecked() ? 1 : 0;
config.textureFilter.txForce16bpp = ui->force16bppCheckBox->isChecked() ? 1 : 0;
config.textureFilter.txSaveCache = ui->saveTextureCacheCheckBox->isChecked() ? 1 : 0;
QString txPath = ui->txPathLabel->text();
if (!txPath.isEmpty())
config.textureFilter.txPath[txPath.toWCharArray(config.textureFilter.txPath)] = L'\0';
config.font.size = m_font.pointSize();
QString fontName = m_font.family() + ".ttf";
#ifdef OS_WINDOWS
config.font.name = fontName.toLocal8Bit().constData();
#else
config.font.name = fontName.toStdString();
#endif
config.font.color[0] = m_color.red();
config.font.color[1] = m_color.green();
config.font.color[2] = m_color.blue();
config.font.color[3] = m_color.alpha();
config.font.colorf[0] = m_color.redF();
config.font.colorf[1] = m_color.greenF();
config.font.colorf[2] = m_color.blueF();
config.font.colorf[3] = m_color.alphaF();
// Post filter settings
config.bloomFilter.enable = ui->bloomGroupBox->isChecked() ? 1 : 0;
if (ui->bloomStrongRadioButton->isChecked())
config.bloomFilter.blendMode = 0;
else if (ui->bloomMildRadioButton->isChecked())
config.bloomFilter.blendMode = 1;
else if (ui->bloomLightRadioButton->isChecked())
config.bloomFilter.blendMode = 2;
config.bloomFilter.thresholdLevel = ui->bloomThresholdSlider->value();
config.bloomFilter.blurAmount = ui->blurAmountSlider->value();
config.bloomFilter.blurStrength = ui->blurStrengthSlider->value();
config.gammaCorrection.force = ui->forceGammaCorrectionCheckBox->isChecked() ? 1 : 0;
config.gammaCorrection.level = ui->gammaLevelSpinBox->value();
writeSettings(m_strIniPath);
QDialog::accept();
}
示例14: writeSettings
void
Settings::closeEvent(QCloseEvent *e)
{
writeSettings();
}
示例15: writeSettings
Settings_Lawicel::~Settings_Lawicel()
{
writeSettings();
}