TouchpadConfig::TouchpadConfig(LXQt::Settings* _settings, QWidget* parent): QWidget(parent), settings(_settings) { ui.setupUi(this); devices = TouchpadDevice::enumerate_from_udev(); for (const TouchpadDevice& device : devices) { ui.devicesComboBox->addItem(device.name()); } initControls(); connect(ui.devicesComboBox, QOverload<int>::of(&QComboBox::currentIndexChanged), this, [this] (int/* index*/) { initControls(); }); // update GUI on device change connect(ui.tappingEnabledCheckBox, &QAbstractButton::clicked, this, &TouchpadConfig::settingsChanged); connect(ui.naturalScrollingEnabledCheckBox, &QAbstractButton::clicked, this, &TouchpadConfig::settingsChanged); connect(ui.tapToDragEnabledCheckBox, &QAbstractButton::clicked, this, &TouchpadConfig::settingsChanged); connect(ui.accelSpeedDoubleSpinBox, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &TouchpadConfig::settingsChanged); connect(ui.noScrollingRadioButton, &QAbstractButton::clicked, this, &TouchpadConfig::settingsChanged); connect(ui.twoFingerScrollingRadioButton, &QAbstractButton::clicked, this, &TouchpadConfig::settingsChanged); connect(ui.edgeScrollingRadioButton, &QAbstractButton::clicked, this, &TouchpadConfig::settingsChanged); connect(ui.buttonScrollingRadioButton, &QAbstractButton::clicked, this, &TouchpadConfig::settingsChanged); }
void Blender::handleAsyncUpdate() { if (m_initialized) { if (m_update & updt_unmount) { sendRemoveMixers(); m_update &= ~updt_unmount; } if (m_update & updt_mount) { if (m_device && m_device->isEapSupported()) { m_created = false; loadSettings(); router_cfg(); stream_cfg(); createControls(); initControls(); for (int i=0; i<m_bl_desc.num_mixers; i++) { mixer_cfg(i); } } m_update &= ~updt_mount; } if (m_update & updt_clock) { m_update &= ~updt_clock; } } }
BOOL VideoRegionsConfigDialog::onInitDialog() { m_config = Configurator::getInstance()->getServerConfig(); initControls(); updateUI(); return TRUE; }
/*! \param parent the parent window. */ NanocompAboutDialog::NanocompAboutDialog(wxWindow *parent) : wxDialog(parent, wxID_ANY, _("About NanoComp"), wxDefaultPosition, wxDefaultSize) { initControls(); initSizers(); }
jint EXPORT_ME JAVA_FUNC(init) ( JNIEnv* env, jobject thiz,jstring graphics_dir,jint mem_mb,jobjectArray argsArray,jint lowRes,jstring game_path_ ) { #ifdef ANTI_HACK getGlobalClasses(env); #endif env_ = env; /* if (lowRes) Android_SetGameResolution(320,240); else Android_SetGameResolution(640,400); */ //Android_SetGameResolution(320,200); Android_SetGameResolution(320,240); //Android_SetGameResolution(640,480); argv[0] = "quake"; int argCount = (env)->GetArrayLength( argsArray); LOGI("argCount = %d",argCount); for (int i=0; i<argCount; i++) { jstring string = (jstring) (env)->GetObjectArrayElement( argsArray, i); argv[argc] = (char *)(env)->GetStringUTFChars( string, 0); LOGI("arg = %s",argv[argc]); argc++; } game_path = (char *)(env)->GetStringUTFChars( game_path_, 0); LOGI("game_path = %s",getGamePath()); //Needed for ecwolf to run //home_env = "HOME=/" + game_path; //putenv(home_env.c_str()); setenv("HOME", getGamePath(),1); putenv("TIMIDITY_CFG=../timidity.cfg"); chdir(getGamePath()); const char * p = env->GetStringUTFChars(graphics_dir,NULL); graphicpath = std::string(p); initControls(android_screen_width,-android_screen_height,graphicpath.c_str()); SDL_SetSwapBufferCallBack(frameControls); //Now done in java to keep context etc SDL_SwapBufferPerformsSwap(false); PortableInit(argc,argv); //Never returns!! return 0; }
SongDialog::SongDialog(Song* song) { initControls(); qDebug() << song->id; qDebug() << song->lyrics; id=song->id; textEdit->setText(song->lyrics); }
BOOL AdministrationConfigDialog::onInitDialog() { m_config = Configurator::getInstance()->getServerConfig(); initControls(); updateUI(); return TRUE; }
BOOL VncViewerConfigDialog::onInitDialog() { initControls(); updateControlValues(); m_historyWasCleared = false; return TRUE; }
MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow) { ui->setupUi(this); setWindowTitle("SmartDeblur v. " + appVersion); resize(1000, 700); helpDialog = new HelpDialog(this); imageLabel = new QLabel; imageLabel->setBackgroundRole(QPalette::Base); imageLabel->setSizePolicy(QSizePolicy::Ignored, QSizePolicy::Ignored); imageLabel->setScaledContents(true); ui->scrollArea->setBackgroundRole(QPalette::Dark); ui->scrollArea->setWidget(imageLabel); radius = 9; quality = 30; workerThread = new WorkerThread(); inputImage = NULL; outputImage = NULL; createActions(); initControls(); updateZoomControls(); progressBar = new QProgressBar(); progressBar->setStyleSheet("QProgressBar { border: 2px solid grey; border-radius: 5px; text-align: center; }"); progressBar->setValue(0); progressBar->setVisible(false); lblDeconvolutionTime = new QLabel(); lblThreadsCount = new QLabel(); lblImageSize = new QLabel(); ui->statusBar->addWidget(lblThreadsCount); ui->statusBar->addWidget(lblImageSize); ui->statusBar->addWidget(lblDeconvolutionTime); ui->statusBar->addWidget(progressBar); workerThread->start(); if (helpDialog->isShowOnStartup()) { // Delay start because we need to wait while main window will be initialized startupTimer = new QTimer(); startupTimer->setSingleShot(true); connect(startupTimer, SIGNAL(timeout()), SLOT(help())); startupTimer->start(500); } checkUpdatesThread = new CheckUpdatesThread(); //checkUpdatesThread->start(); }
// Main function int main(int argc, char* argv[]) { int i; char *chemin; // Glut initializations glutInit(&argc, argv); glutInitDisplayMode(GLUT_RGBA | GLUT_DOUBLE | GLUT_DEPTH); glutInitWindowSize(400, 400); glutInitWindowPosition(100, 100); glutCreateWindow("Projet OpenGl - Bender"); glShadeModel(GL_SMOOTH); glEnable(GL_DEPTH_TEST); glClearColor(0.5,0.5,0.5, 1); // Glut callback functions glutReshapeFunc(&window_reshape); glutDisplayFunc(&window_display); glutKeyboardFunc(&window_key); glutKeyboardUpFunc(&window_key_up); glutMouseFunc(&window_mouseFunc); glutMotionFunc(&window_motionFunc); glutSpecialFunc(&window_specialDownFunc); glutSpecialUpFunc(&window_specialUpFunc); glutTimerFunc(40, &window_timer, 0); // Program variables initialization initControls(); initCamera(); initBuildings(); // Fetching the path for the texture directory. chemin = (char*)malloc(100); chemin[0]='\0'; strcat(chemin, argv[0]); for(i=99;i>=0;i--) { if(chemin[i]=='/' || chemin[i]=='\\') { chemin[i+1]='\0'; i=-1; } } // Buildings and robots list initialization makeBender(chemin); createCity(chemin); free(chemin); glutMainLoop(); return EXIT_FAILURE; }
bool GameScene::init() { if (!Layer::init()) { return false; } initGame(); initValues(); initControls(); return initTouch(); }
void TouchpadConfig::reset() { for (TouchpadDevice& device : devices) { device.setTappingEnabled(device.oldTappingEnabled()); device.setNaturalScrollingEnabled(device.oldNaturalScrollingEnabled()); device.setTapToDragEnabled(device.oldTapToDragEnabled()); device.setAccelSpeed(device.oldAccelSpeed()); device.setScrollingMethodEnabled(device.oldScrollingMethodEnabled()); } initControls(); accept(); }
BOOL ConfigDialog::onInitDialog() { m_config = Configurator::getInstance(); m_config->setServiceFlag(m_isConfiguringService); initControls(); m_tabControl.addTab(NULL, _T("Temp")); m_serverConfigDialog.setParent(&m_ctrlThis); m_serverConfigDialog.setParentDialog(this); m_serverConfigDialog.create(); moveDialogToTabControl(&m_serverConfigDialog); m_portMappingDialog.setParent(&m_ctrlThis); m_portMappingDialog.setParentDialog(this); m_portMappingDialog.create(); moveDialogToTabControl(&m_portMappingDialog); m_portMappingDialog.hide(); m_administrationConfigDialog.setParent(&m_ctrlThis); m_administrationConfigDialog.setParentDialog(this); m_administrationConfigDialog.create(); moveDialogToTabControl(&m_administrationConfigDialog); m_ipAccessControlDialog.setParent(&m_ctrlThis); m_ipAccessControlDialog.setParentDialog(this); m_ipAccessControlDialog.create(); moveDialogToTabControl(&m_ipAccessControlDialog); m_videoRegionsConfigDialog.setParent(&m_ctrlThis); m_videoRegionsConfigDialog.setParentDialog(this); m_videoRegionsConfigDialog.create(); moveDialogToTabControl(&m_videoRegionsConfigDialog); m_tabControl.addTab(&m_serverConfigDialog, StringTable::getString(IDS_SERVER_TAB_CAPTION)); m_tabControl.addTab(&m_portMappingDialog, StringTable::getString(IDS_EXTRA_PORTS_TAB_CAPTION)); m_tabControl.addTab(&m_ipAccessControlDialog, StringTable::getString(IDS_ACCESS_CONTROL_TAB_CAPTION)); m_tabControl.addTab(&m_videoRegionsConfigDialog, StringTable::getString(IDS_VIDEO_WINDOWS_TAB_CAPTION)); m_tabControl.addTab(&m_administrationConfigDialog, StringTable::getString(IDS_ADMINISTRATION_TAB_CAPTION)); m_tabControl.removeTab(0); m_tabControl.showTab(m_lastSelectedTabIndex); m_tabControl.setFocus(); m_ctrlApplyButton.setEnabled(false); m_ctrlThis.setForeground(); return FALSE; }
jint EXPORT_ME Java_com_beloko_opengames_prboom_NativeLib_init( JNIEnv* env, jobject thiz,jstring graphics_dir,jint mem_mb,jobjectArray argsArray,jint renderer,jstring doom_path_,jint snd_buffer_size ) { env_ = env; curRenderer = renderer; argv[0] = "quake"; int argCount = (env)->GetArrayLength( argsArray); LOGI("argCount = %d",argCount); for (int i=0; i<argCount; i++) { jstring string = (jstring) (env)->GetObjectArrayElement( argsArray, i); argv[argc] = (char *)(env)->GetStringUTFChars( string, 0); LOGI("arg = %s",argv[argc]); argc++; } Android_SetGameResolution(320,240); ANDROID_SAMPLECOUNT = snd_buffer_size; doom_path = (char *)(env)->GetStringUTFChars( doom_path_, 0); LOGI("doom_path = %s",getDoomPath()); chdir(getDoomPath()); putenv("TIMIDITY_CFG=../timidity.cfg"); PortableInit(argc,argv); const char * p = env->GetStringUTFChars(graphics_dir,NULL); graphicpath = std::string(p); initControls(android_screen_width,-android_screen_height,graphicpath.c_str(),(graphicpath + "/prdoom.xml").c_str()); #ifdef ANTI_HACK getGlobalClasses(env_); #endif if (renderer != REND_SOFT) SDL_SetSwapBufferCallBack(frameControls); if (renderer == REND_SOFT)// In soft mode SDL calls swap buffer, disable so it does not flicker SDL_SwapBufferPerformsSwap(false); return 0; }
static void configDialog(HINSTANCE hInstance) { initControls(); Ime::WindowsVersion winVer; Config config(winVer); config.load(); Ime::PropertyDialog dlg; TypingPropertyPage* typingPage = new TypingPropertyPage(&config); UiPropertyPage* uiPage = new UiPropertyPage(&config); KeyboardPropertyPage* keyboardPage = new KeyboardPropertyPage(&config); SymbolsPropertyPage* symbolsPage = new SymbolsPropertyPage(&config); dlg.addPage(typingPage); dlg.addPage(uiPage); dlg.addPage(keyboardPage); dlg.addPage(symbolsPage); INT_PTR ret = dlg.showModal(hInstance, (LPCTSTR)IDS_CONFIG_TITLE, 0, HWND_DESKTOP); if(ret) { // the user clicks OK button // get current time stamp and set the value to global compartment to notify all // text service instances to reload their config. // TextService::onCompartmentChanged() of all other instances will be triggered. config.save(); DWORD stamp = ::GetTickCount(); if(stamp == Config::INVALID_TIMESTAMP) // this is almost impossible stamp = 0; // set global compartment value to notify existing ChewingTextService instances ::CoInitialize(NULL); // initialize COM Ime::ComPtr<ITfThreadMgr> threadMgr; if(CoCreateInstance(CLSID_TF_ThreadMgr, NULL, CLSCTX_INPROC_SERVER, IID_ITfThreadMgr, (void**)&threadMgr) == S_OK) { TfClientId clientId = 0; if(threadMgr->Activate(&clientId) == S_OK) { Ime::ComPtr<ITfCompartmentMgr> compartmentMgr; if(threadMgr->GetGlobalCompartment(&compartmentMgr) == S_OK) { Ime::ComPtr<ITfCompartment> compartment; if(compartmentMgr->GetCompartment(g_configChangedGuid, &compartment) == S_OK) { VARIANT var; VariantInit(&var); var.vt = VT_I4; var.lVal = ::GetTickCount(); // set current timestamp compartment->SetValue(clientId, &var); } } threadMgr->Deactivate(); } } ::CoUninitialize(); } }
MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow) { ui->setupUi(this); initControls(); layoutControls(); connect( ui->txtEdt, SIGNAL(currentCharFormatChanged( QTextCharFormat)), this, SLOT(onTextCharFormatChanged(QTextCharFormat)) ); QFont fnt = currentFont(); m_pCmbFont->setCurrentText( fnt.family() ); m_pCmbFontPointSize->setCurrentText( QString::number( fnt.pointSize() ) ); }
int main (int argc, char **argv) { LXQt::SingleApplication app(argc, argv); LXQt::Settings* settings = new LXQt::Settings("lxqt"); LXQt::Settings* sessionSettings = new LXQt::Settings("session"); LXQt::ConfigDialog* dialog = new LXQt::ConfigDialog(QObject::tr("LXQt Appearance Configuration"), settings); app.setActivationWindow(dialog); QSettings& qtSettings = *settings; // use lxqt config file for Qt settings in Qt5. StyleConfig* stylePage = new StyleConfig(settings, &qtSettings, dialog); dialog->addPage(stylePage, QObject::tr("Widget Style"), QStringList() << "preferences-desktop-theme" << "preferences-desktop"); QObject::connect(dialog, SIGNAL(reset()), stylePage, SLOT(initControls())); IconThemeConfig* iconPage = new IconThemeConfig(settings, dialog); dialog->addPage(iconPage, QObject::tr("Icons Theme"), QStringList() << "preferences-desktop-icons" << "preferences-desktop"); QObject::connect(dialog, SIGNAL(reset()), iconPage, SLOT(initControls())); LXQtThemeConfig* themePage = new LXQtThemeConfig(settings, dialog); dialog->addPage(themePage, QObject::tr("LXQt Theme"), QStringList() << "preferences-desktop-color" << "preferences-desktop"); QObject::connect(dialog, SIGNAL(reset()), themePage, SLOT(initControls())); FontsConfig* fontsPage = new FontsConfig(settings, &qtSettings, dialog); dialog->addPage(fontsPage, QObject::tr("Font"), QStringList() << "preferences-desktop-font" << "preferences-desktop"); QObject::connect(dialog, SIGNAL(reset()), fontsPage, SLOT(initControls())); SelectWnd* cursorPage = new SelectWnd(sessionSettings, dialog); cursorPage->setCurrent(); dialog->addPage(cursorPage, QObject::tr("Cursor"), QStringList() << "input-mouse" << "preferences-desktop"); dialog->setAttribute(Qt::WA_DeleteOnClose); dialog->setWindowIcon(QIcon::fromTheme("preferences-desktop-theme")); dialog->show(); return app.exec(); }
KeyboardLayoutConfig::KeyboardLayoutConfig(LXQt::Settings* _settings, QWidget* parent): QWidget(parent), settings(_settings) { ui.setupUi(this); loadLists(); loadSettings(); initControls(); connect(ui.addLayout, SIGNAL(clicked(bool)), SLOT(onAddLayout())); connect(ui.removeLayout, SIGNAL(clicked(bool)), SLOT(onRemoveLayout())); connect(ui.moveUp, SIGNAL(clicked(bool)), SLOT(onMoveUp())); connect(ui.moveDown, SIGNAL(clicked(bool)), SLOT(onMoveDown())); connect(ui.keyboardModel, SIGNAL(currentIndexChanged(int)), SLOT(accept())); connect(ui.switchKey, SIGNAL(currentIndexChanged(int)), SLOT(accept())); }
int main (int argc, char **argv) { QApplication app(argc, argv); XdgIcon::setThemeName(RazorSettings::globalSettings()->value("icon_theme").toString()); app.setWindowIcon(QIcon(QString(SHARE_DIR) + "/graphics/razor_logo.png")); TRANSLATE_APP; RazorSettings* settings = new RazorSettings("razor"); RazorConfigDialog* dialog = new RazorConfigDialog(QObject::tr("Razor Appearance Configuration"), settings); IconThemeConfig* iconPage = new IconThemeConfig(settings); dialog->addPage(iconPage, QObject::tr("Icons Theme"), QStringList() << "preferences-desktop-icons" << "preferences-desktop"); QObject::connect(dialog, SIGNAL(reset()), iconPage, SLOT(initControls())); dialog->show(); return app.exec(); }
BOOL OutgoingConnectionDialog::onInitDialog() { initControls(); m_viewOnlyCB.check(false); m_connHistory.load(); for (size_t i = 0; i < m_connHistory.getHostCount(); i++) { m_connectStringCB.addItem(m_connHistory.getHost(i)); } m_connectStringCB.setSelectedItem(0); m_connectStringCB.setFocus(); return FALSE; }
HistoryItem::HistoryItem(HisEintrag *item, QWidget *parent): QWidget(parent), ui(new Ui::historyItemUi) { ui->setupUi(this); //this->setFixedSize(this->size().width(),33); //this->setSizePolicy(QLayout::SetFixedSize); //this->sesetSizeConstraint( QLayout::SetFixedSize ); this->hisEintrag = item; if(item->getSpieler()->getFarbe() == ROT){ //load redImage... this->image = new QPixmap(":/image/red_point.png"); } else{ this->image = new QPixmap(":/image/yellow_point.png"); } initControls(); }
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow) { HWND hWnd = initMainWindow(hInstance, hPrevInstance, lpCmdLine); initControls(hWnd); ShowWindow(hWnd, nCmdShow); UpdateWindow(hWnd); MSG msg; while (GetMessage(&msg, nullptr, 0, 0)) { TranslateMessage(&msg); DispatchMessage(&msg); } return static_cast<int>(msg.wParam); }
void FeatureDemo::initLightingPass() { mLightingPass.pProgram = GraphicsProgram::createFromFile("FeatureDemo.vs.slang", "FeatureDemo.ps.slang"); mLightingPass.pProgram->addDefine("_LIGHT_COUNT", std::to_string(mpSceneRenderer->getScene()->getLightCount())); initControls(); mLightingPass.pVars = GraphicsVars::create(mLightingPass.pProgram->getActiveVersion()->getReflector()); DepthStencilState::Desc dsDesc; dsDesc.setDepthTest(true).setStencilTest(false).setDepthWriteMask(false).setDepthFunc(DepthStencilState::Func::LessEqual); mLightingPass.pDsState = DepthStencilState::create(dsDesc); RasterizerState::Desc rsDesc; rsDesc.setCullMode(RasterizerState::CullMode::None); mLightingPass.pNoCullRS = RasterizerState::create(rsDesc); BlendState::Desc bsDesc; bsDesc.setRtBlend(0, true).setRtParams(0, BlendState::BlendOp::Add, BlendState::BlendOp::Add, BlendState::BlendFunc::SrcAlpha, BlendState::BlendFunc::OneMinusSrcAlpha, BlendState::BlendFunc::One, BlendState::BlendFunc::Zero); mLightingPass.pAlphaBlendBS = BlendState::create(bsDesc); }
BOOL PortMappingDialog::onInitDialog() { initControls(); m_extraPorts = Configurator::getInstance()->getServerConfig()->getPortMappingContainer(); // // Fill listbox. // StringStorage mappingString; for (size_t i = 0; i < m_extraPorts->count(); i++) { m_extraPorts->at(i)->toString(&mappingString); _ASSERT((int)i == i); m_exPortsListBox.insertString((int)i, mappingString.getString()); } return TRUE; }
NoteItem::NoteItem(QWidget *parent, int row, bool readOnly, bool rich) : QFrame(parent) { m_noteId = row; m_gid = 0; m_status = 2; m_readOnly = readOnly; m_rich = rich; m_sized = false; m_q = g_mainWindow->getSqlQuery(); installEventFilter(this); m_verticalLayout = new QVBoxLayout(this); m_verticalLayout->setSpacing(0); m_verticalLayout->setContentsMargins(0, 0, 0, 0); setStyleSheet(".NoteItem { background-color : white; padding: 6px; }"); initControls(); resize(parentWidget()->width() - 32, 240); }
BOOL EditPortMappingDialog::onInitDialog() { initControls(); if (m_dialogType == Add) { m_portTextBox.setText(_T("5901")); m_geometryTextBox.setText(_T("640x480+0+0")); } else if (m_dialogType == Edit) { StringStorage portString; StringStorage rectString; portString.format(_T("%d"), m_mapping->getPort()); m_mapping->getRect().toString(&rectString); m_portTextBox.setText(portString.getString()); m_geometryTextBox.setText(rectString.getString()); } return TRUE; }
BOOL QueryConnectionDialog::onInitDialog() { initControls(); m_peerAddressLabel.setText(m_peerAddress.getString()); if (m_acceptByDefault) { m_acceptButton.setFocus(); } else { m_rejectButton.setFocus(); } setDefaultPushButton(m_acceptByDefault ? IDC_ACCEPT_BUTTON : IDC_REJECT_BUTTON); updateTimeoutLabel(); SetTimer(m_ctrlThis.getWindow(), 0, 1000, 0); return FALSE; }
BOOL EditIpAccessRuleDialog::onInitDialog() { initControls(); for (int i = 0; i < 3; i++) { m_access[i].check(false); } if (m_data == NULL) { return TRUE; } switch (m_data->getAction()) { case IpAccessRule::ACTION_TYPE_ALLOW: m_access[0].check(true); break; case IpAccessRule::ACTION_TYPE_DENY: m_access[1].check(true); break; case IpAccessRule::ACTION_TYPE_QUERY: m_access[2].check(true); break; } if (m_isOpenedForEdit) { StringStorage firstIp; StringStorage lastIp; m_data->getFirstIp(&firstIp); m_data->getLastIp(&lastIp); m_firstIp.setText(firstIp.getString()); m_lastIp.setText(lastIp.getString()); m_ctrlThis.setText(StringTable::getString(IDS_EDIT_IP_ACCESS_RULE_DIALOG_CAPTION)); } else { m_ctrlThis.setText(StringTable::getString(IDS_NEW_IP_ACCESS_RULE_DIALOG_CAPTION)); } return FALSE; }
FontsConfig::FontsConfig(LXQt::Settings* settings, QSettings* qtSettings, QWidget* parent) : QWidget(parent), ui(new Ui::FontsConfig), mQtSettings(qtSettings), mSettings(settings), mFontConfigFile() { ui->setupUi(this); initControls(); connect(ui->fontName, SIGNAL(currentFontChanged(QFont)), SLOT(updateQtFont())); connect(ui->fontStyle, SIGNAL(currentIndexChanged(int)), SLOT(updateQtFont())); connect(ui->fontSize, SIGNAL(valueChanged(int)), SLOT(updateQtFont())); connect(ui->antialias, SIGNAL(toggled(bool)), SLOT(antialiasToggled(bool))); connect(ui->subpixel, SIGNAL(currentIndexChanged(int)), SLOT(subpixelChanged(int))); connect(ui->hinting, SIGNAL(toggled(bool)), SLOT(hintingToggled(bool))); connect(ui->hintStyle, SIGNAL(currentIndexChanged(int)), SLOT(hintStyleChanged(int))); connect(ui->dpi, SIGNAL(valueChanged(int)), SLOT(dpiChanged(int))); connect(ui->autohint, SIGNAL(toggled(bool)), SLOT(autohintToggled(bool))); }
LRESULT FulHighlightDialog::onInitDialog(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM /*lParam*/, BOOL& /*bHandled*/) { if (texts != NULL) { for(int i = 0; texts[i].itemID != 0; i++) { ::SetDlgItemText(m_hWnd, texts[i].itemID, CTSTRING_I(texts[i].translatedString)); } } //initalize colors bgColor = WinUtil::bgColor; fgColor = WinUtil::textColor; //initalize ComboBox ctrlMatchType.Attach(GetDlgItem(IDC_MATCHTYPE)); ctrlContext.Attach(GetDlgItem(IDC_HCONTEXT)); ctrlText.Attach(GetDlgItem(IDC_HLTEXT)); ctrlMatchCol.Attach(GetDlgItem(IDC_MATCH_COLUMN)); //add alternatives StringTokenizer<tstring> s(Text::toT(STRING(HIGHLIGHT_MATCH_TYPES)), _T(',')); TStringList l = s.getTokens(); for(TStringIter i = l.begin(); i != l.end(); ++i) ctrlMatchType.AddString((*i).c_str()); ctrlMatchType.SetCurSel(1); ctrlContext.AddString(CTSTRING(CONTEXT_CHAT)); ctrlContext.AddString(CTSTRING(CONTEXT_NICKLIST)); ctrlContext.AddString(CTSTRING(CONTEXT_FILELIST)); ctrlContext.AddString(CTSTRING(CONTEXT_SEARCH)); CenterWindow(WinUtil::mainWnd); SetWindowText(CTSTRING(HIGHLIGHT_DIALOG_TITLE)); initControls(); fix(); return TRUE; }