InputDataDialog::InputDataDialog(QWidget * parent) : QDialog(parent) { initInterface(); initConnections(); setWindowTitle(conv("Начальные данные")); }
TcpSrvGui::TcpSrvGui(QWidget *parent) : QMainWindow(parent), sMSG("Message: "), sFILE("File: "), sSRV("srv: "), sCLI("cli: "), sBTS("Total bytes: "), pbListen(new QPushButton("Listen")), pbClose(new QPushButton("Close")), lbStatus(new QLabel("<status>")), lbMessage(new QLabel(sMSG)), lbFile(new QLabel(sFILE)), lbSrv(new QLabel(sSRV + "<addr>:<port>")), lbCli(new QLabel(sCLI + "<addr>:<port>")), lbBytes(new QLabel(sBTS + "0")), switcher(false), path("") { initMembers(); initForm(); initConnections(); }
int main(int argc, char* argv[]) { if (argc !=4) usage(); string hostsFile=argv[1]; ifstream diff(argv[2]); port = (unsigned short)atoi(argv[3]); if (diff.fail()) { cerr << "error: open diff file" << endl; usage(); } if (verbose) cout << "Reading diff..." << endl; assert(readChanges(diff)); if (verbose) cout << "Reading core info..." << endl; assert(getCores(hostsFile)); diff.close(); if (verbose) cout << "Getting addresses..."<<endl; errcheck(getAddrs()); if (verbose) cout << "Constructing stage data..."<<endl; errcheck(makeStages()); if (verbose) cout << "Opening connections..." << endl; errcheck(initConnections()); if (verbose) cout << "Transferring stage data..." << endl; errcheck(sendStages()); int i; for (i=0;i<3;i++) { if (verbose) cout << "Doing stage " << i << "..."<<endl; errcheck(doStage(i)); } if (verbose) cout << "Closing connections..." <<endl; errcheck(finishConnections()); if (verbose) cout<<"Reassign complete."<<endl; }
MainForm::MainForm(QWidget* parent, Qt::WFlags flags) : QMainWindow(parent, flags) { vrLut = 0; mprExaminer0 = 0; mprExaminer1 = 0; mprExaminer2 = 0; vrExaminer = 0; mprWindowLevelManip = 0; vrTexture = 0; vrSlicer = 0; isUpdatingGui_ = false; isDraggingWindow_ = false; setupUi(this); ViewerCore::get()->createPresetMixerForm(this); ViewerCore::get()->createDicomForm(this, ViewerCore::get()->getDicomElementList()); setWindowFlags(Qt::CustomizeWindowHint); initFields(); initControlValues(); initConnections(); initCallbacks(); initPresets(); }
ParamCompareDialog::ParamCompareDialog(QMap<QString, UASParameter* >& paramaterList, const QString& filename, QWidget *parent) : QDialog(parent), ui(new Ui::ParamCompareDialog), m_currentList(¶materList), m_newList(new QMap<QString, UASParameter*>()), m_fileToCompare(filename) { ui->setupUi(this); QStringList headerList; headerList << tr("Parameter") << tr("Value") << tr("New Value") << tr("Use"); QTableWidget* table = ui->compareTableWidget; table->setColumnCount(headerList.count()); table->setHorizontalHeaderLabels(headerList); table->setSelectionBehavior(QAbstractItemView::SelectRows); table->setAlternatingRowColors(true); table->setColumnWidth(PCD_COLUMN_CHECKBOX, 40); initConnections(); if(filename.count()>0){ QTimer::singleShot(200, this, SLOT(loadParameterWithFile())); } }
MainWindow::MainWindow(QWidget *parent) : QWidget(parent), m_updatePanelVisible(true), m_mainPanel(new MainPanel(this)), m_positionUpdateTimer(new QTimer(this)), m_expandDelayTimer(new QTimer(this)), m_sizeChangeAni(new QPropertyAnimation(this, "size")), m_posChangeAni(new QPropertyAnimation(this, "pos")), m_panelShowAni(new QPropertyAnimation(m_mainPanel, "pos")), m_panelHideAni(new QPropertyAnimation(m_mainPanel, "pos")), m_xcbMisc(XcbMisc::instance()) { setAccessibleName("dock-mainwindow"); setWindowFlags(Qt::FramelessWindowHint | Qt::WindowDoesNotAcceptFocus); setAttribute(Qt::WA_TranslucentBackground); m_settings = new DockSettings(this); m_xcbMisc->set_window_type(winId(), XcbMisc::Dock); initComponents(); initConnections(); m_mainPanel->setFixedSize(m_settings->windowSize()); updatePanelVisible(); // setStyleSheet("background-color:red;"); connect(m_mainPanel, &MainPanel::geometryChanged, this, &MainWindow::panelGeometryChanged); }
GaduAccount::GaduAccount( Kopete::Protocol* parent, const QString& accountID,const char* name ) : Kopete::PasswordedAccount( parent, accountID, 0, name ) { QHostAddress ip; p = new GaduAccountPrivate; p->pingTimer_ = NULL; p->saveListDialog = NULL; p->loadListDialog = NULL; p->forFriends = false; p->textcodec_ = QTextCodec::codecForName( "CP1250" ); p->session_ = new GaduSession( this, "GaduSession" ); KGlobal::config()->setGroup( "Gadu" ); setMyself( new GaduContact( accountId().toInt(), accountId(), this, Kopete::ContactList::self()->myself() ) ); p->status = GaduProtocol::protocol()->convertStatus( GG_STATUS_NOT_AVAIL ); p->lastDescription = QString::null; for ( unsigned int i = 0; i < NUM_SERVERS ; i++ ) { ip.setAddress( QString( servers_ip[i] ) ); p->servers.append( htonl( ip.toIPv4Address() ) ); kdDebug( 14100 ) << "adding IP: " << p->servers[ i ] << " to cache" << endl; } p->currentServer = -1; p->serverIP = 0; // initialize KGaduLogin structure to default values p->loginInfo.uin = accountId().toInt(); p->loginInfo.useTls = false; p->loginInfo.status = GG_STATUS_AVAIL; p->loginInfo.server = 0; p->loginInfo.client_port = 0; p->loginInfo.client_addr = 0; p->pingTimer_ = new QTimer( this ); p->exportTimer_ = new QTimer( this ); p->exportUserlist = false; p->gaduDcc_ = NULL; p->config = configGroup(); p->ignoreAnons = ignoreAnons(); p->forFriends = loadFriendsMode(); initConnections(); initActions(); QString nick = p->config->readEntry( QString::fromAscii( "nickName" ) ); if ( !nick.isNull() ) { myself()->setProperty( Kopete::Global::Properties::self()->nickName(), nick ); } else { myself()->setProperty( Kopete::Global::Properties::self()->nickName(), accountId() ); p->config->writeEntry( QString::fromAscii( "nickName" ), accountId() ); } }
fsirc::fsirc(QWidget *parent) : QDialog(parent) { setupUi(this); actionNewTab = new QAction (QIcon (":/fsirc/data/new.svg"), tr ("New tab"), this); actionNewTab->setToolTip (tr ("Create new tab")); ircTabHolder->addAction(actionNewTab); actionCloseTab = new QAction (QIcon (":/fsirc/data/close.svg"), tr ("Close tab"), this); actionCloseTab->setToolTip (tr ("Close current tab")); actionCloseTab->setDisabled (true); ircTabHolder->addAction(actionCloseTab); cornerButtons = new QToolBar(ircTabHolder); cornerButtons->addAction(actionNewTab); cornerButtons->addAction(actionCloseTab); QVBoxLayout *mainLayout = qobject_cast<QVBoxLayout*> (layout ()); mainLayout->insertWidget (0, cornerButtons); setWindowIcon(QIcon(":/fsirc/data/icon.svg")); ticker = new QTimer; ticker->setInterval(700); ticker->start(); initConnections(); connect(ticker, SIGNAL(timeout()), this, SLOT(checkIfTop())); trayIcon = 0; }
MainWindow::MainWindow(QWidget* parent) : QMainWindow(parent), MainWindowBase(), m_Settings(), m_AppConfig(&m_Settings), m_pSynergy(NULL), m_SynergyState(synergyDisconnected), m_ServerConfig(&m_Settings, 5, 3), m_pTempConfigFile(NULL), m_pLogDialog(new LogDialog(this, synergyProcess())), m_pTrayIcon(NULL), m_pTrayIconMenu(NULL) { setupUi(this); createTrayIcon(); createMenuBar(); loadSettings(); initConnections(); // HACK - surely window should be visible by default? setVisible(true); if (appConfig().autoConnect()) startSynergy(); }
OfferView::OfferView(OfferController *controller, QWidget *parent) : PriceDocumentView(parent) { this->controller = controller; setMainWidgets(); initConnections(); setGUISettings(); }
ParamGeneratorGUI::ParamGeneratorGUI( const QString& name,QTreeWidgetItem* pitem,QWidget* parent /*= NULL*/ ) :QFrame(parent),parentitem(pitem),currentname(name) { initUI(); initConnections(); setParamName(name); }
Solver::Solver(const PrintableMap& map){ hashing = new ZobristHashing<HASHLENGTH>(map.dims,2); initialState = MapUtils::buildGameState(map,*hashing); initialState->children++; initConnections(); }
BtInstallPage::BtInstallPage() : BtConfigPage() { qDebug("BtInstallPage::BtInstallPage() start"); initView(); initConnections(); }
CModuleChooserDialog::CModuleChooserDialog( QWidget* parentDialog, ListCSwordModuleInfo modules ) : KDialogBase(Plain, i18n("Choose work(s)"), Ok, Ok, parentDialog, "CModuleChooser", false, true) { initView(); initConnections(); m_moduleChooser->setModules(modules); };
fsirc::fsirc(QWidget *parent) : QDialog(parent) { setupUi(this); closeTabButton = new QPushButton(QIcon(":/fsirc/data/close.svg"),QString(),this); newTabButton = new QPushButton(QIcon(":/fsirc/data/new.svg"),QString(),this); clearTabButton = new QPushButton(QIcon(":/fsirc/data/clear.svg"), QString(), this); closeTabButton->setFocusPolicy(Qt::NoFocus); newTabButton->setFocusPolicy(Qt::NoFocus); clearTabButton->setFocusPolicy(Qt::NoFocus); cornerButtons = new QToolBar(ircTabHolder); cornerButtons->addWidget(closeTabButton); cornerButtons->addWidget(newTabButton); cornerButtons->addWidget(clearTabButton); closeTabButton->setDisabled(true); ircTabHolder->setCornerWidget(cornerButtons); newTab(); setWindowIcon(QIcon(":/fsirc/data/icon.svg")); ticker = new QTimer; ticker->setInterval(700); ticker->start(); initConnections(); #ifndef FSIRC_NO_TRAY_ICON addTrayIcon(); connect(ticker, SIGNAL(timeout()), this, SLOT(checkIfTop())); #endif }
void DialogObjects::initModels(std::string unique, const QStringList &columnList) { objectModel = new ObjectListModel(this, unique, columnList); objectDetailsModel = new ObjectDetailsModel(this); initConnections(); }
GoodsRemoveConfirmativeDialog::GoodsRemoveConfirmativeDialog(int id, QWidget *parent) : QDialog(parent) { service = new GoodsService(); idGood = id; initView(); initConnections(); }
void DialogObjects::initModels(std::string unique) { objectModel = new ObjectListModel(this, unique); objectDetailsModel = new ObjectDetailsModel(this); initConnections(); }
// constructor Client::Client(QSharedPointer<SimpleSwitchReplica> ptr) : QObject(Q_NULLPTR), reptr(ptr) { //connect signal for replica initialized with initialization slot initConnections(); // We can connect to SimpleSwitchReplica signals/slots //directly because our Replica was generated by repc }
DBConfigDialog::DBConfigDialog() : Dialog() { initInterface(); initConnections(); setWindowTitle(conv("Настройка подключения к базе данных")); resize(400, 250); }
QtDcm::QtDcm ( QWidget *parent ) : QWidget ( parent ), d ( new QtDcmPrivate ) { QTextCodec::setCodecForLocale( QTextCodec::codecForName ( "iso" ) ); setupUi ( this ); d->mode = QtDcm::CD_MODE; //Initialize QTreeWidgetPatients treeWidgetPatients->setColumnWidth ( 0, 400 ); treeWidgetPatients->setColumnWidth ( 1, 100 ); treeWidgetPatients->setColumnWidth ( 2, 100 ); const QStringList labelsPatients = QStringList() << "Patients name" << "ID" << "Birthdate" << "Sex"; treeWidgetPatients->setHeaderLabels ( labelsPatients ); treeWidgetPatients->setContextMenuPolicy ( Qt::CustomContextMenu ); //Initialize QTreeWidgetSeries treeWidgetStudies->setColumnWidth ( 0, 200 ); treeWidgetStudies->setColumnWidth ( 1, 100 ); const QStringList labelsStudies = QStringList() << "Studies description" << "Date" << "ID"; treeWidgetStudies->setHeaderLabels ( labelsStudies ); treeWidgetStudies->setContextMenuPolicy ( Qt::CustomContextMenu ); //Initialize QTreeWidgetSeries treeWidgetSeries->setColumnWidth ( 0, 230 ); treeWidgetSeries->setColumnWidth ( 1, 100 ); treeWidgetSeries->setColumnWidth ( 2, 100 ); const QStringList labelsSeries = QStringList() << "Series description" << "Modality" << "Date" << "ID"; treeWidgetSeries->setHeaderLabels ( labelsSeries ); treeWidgetSeries->setContextMenuPolicy ( Qt::CustomContextMenu ); //Initialize widgets QDate currentDate = QDate::currentDate(); startDateEdit->setDate ( currentDate.addYears(-100) ); endDateEdit->setDate ( currentDate ); QtDcmManager::instance()->setPatientsTreeWidget ( treeWidgetPatients ); QtDcmManager::instance()->setStudiesTreeWidget ( treeWidgetStudies ); QtDcmManager::instance()->setSeriesTreeWidget ( treeWidgetSeries ); QtDcmManager::instance()->setStartDate ( startDateEdit->date() ); QtDcmManager::instance()->setEndDate ( endDateEdit->date() ); initConnections(); }
void initTreeMolecule(TreeMolecule* treeMolecule, GeomDef* geom, gint NAtoms, gint ringSize) { treeMolecule->done = FALSE; treeMolecule->bonds = 0; treeMolecule->ringSize = ringSize; treeMolecule->nAtoms = NAtoms; if(NAtoms<1) return; initStack(treeMolecule); initConnections(treeMolecule, geom); }
JBlockerMainWindow::JBlockerMainWindow(QWidget *parent, Qt::WindowFlags flags) : QMainWindow(parent, flags), p_tabW(0), p_inboxW(0), p_junkListW(0), p_messageCore(0), p_messageBox(0), p_progressBar(0), p_refresh(0), p_addToBlackList(0), p_switchAccount(0) { qDebug() << "+ " << __PRETTY_FUNCTION__; /* Initialization */ initUI(); initCore(); initConnections(); QTimer::singleShot(1000, this, SLOT(slt_loadingStart())); }
SelectionDialog:: SelectionDialog( DataAccess * da, QWidget * parent, const char * name, bool modal, Qt::WFlags fl ) : SelectionDialogBase( parent, name, modal, fl ), dataSource( da ) { initConnections(); initSelectors(); //QStringList labels = dataSource -> getResultLabels(); QStringList labels = dataSource -> getAllLabelNames(); labelListBox->clear(); labelListBox->insertStringList(labels); }
CBookmarkIndex::CBookmarkIndex(QWidget *parent) : QTreeWidget(parent), m_magTimer(this), m_previousEventItem(0) { setMouseTracking(true); m_magTimer.setSingleShot(true); m_magTimer.setInterval(CBTConfig::get(CBTConfig::magDelay)); setContextMenuPolicy(Qt::CustomContextMenu); initView(); initConnections(); initTree(); }
SelectVisibleColumns::SelectVisibleColumns(QTableView *table, QWidget *parent) : QDialog(parent) { this->table = table; this->setLayout(layout = new QGridLayout()); layout->setAlignment(Qt::AlignLeft | Qt::AlignTop); this->setMinimumSize(400, 100); this->setWindowTitle("Wybierz, które kolumny mają być widoczne"); initView(); initConnections(); }
MainWindow::MainWindow() : QMainWindow(), m_api(trace::API_GL), m_initalCallNum(-1), m_selectedEvent(0), m_stateEvent(0), m_nonDefaultsLookupEvent(0) { m_ui.setupUi(this); initObjects(); initConnections(); }
void Plasticity::initData() { // params for plast // cout << std::string(100, '*')<< endl; // cout << "Init plasticity "<< endl; FACT = 400.0; tau_lowsp = 8.0; tau_q = 1.3; A_gapD = 2.45e-5 * FACT; th_lowsp = 1.5; th_q = 1.5; // th_lowsp = 2.0; // th_q = 2.0; // threshold to differentiate between bursts and spikes // A_gapP = A_gapD * 0.6; // A_gapP = A_gapD * 0.05; A_gapP = A_gapD * 0.5; initConnections(); sim.nbOfGapJunctions = 0; for (int m = 0; m < sim.NI; ++m) { for (int n = 0; n < sim.NI; ++n) { sim.nbOfGapJunctions += int(allowedConnections[m][n]); } } VgapIN = 7.0 / sqrt(sim.nbOfGapJunctions); Vgap = sim.gamma_c / sqrt(sim.nbOfGapJunctions); VgapLocal = new double *[sim.NI]; WIILocal = new double *[sim.NI]; // Synaptic weights // WII = sim.GammaII / sim.NI / sim.dt; WIE = sim.GammaIE / sim.NI / sim.dt; if(sim.NE>0) { WEE = sim.GammaEE / sim.NE / sim.dt; WEI = sim.GammaEI / sim.NE / sim.dt; } else { WEE = 0; WEI = 0; } // cout << "Plasticity initialized: WII: "<< WII << "\t NI:" << sim.NI << endl; // cout << std::string(100, '*')<< endl; }
CSearchDialog::CSearchDialog(QWidget *parent) : QDialog(parent), /*m_searchButton(0),*/ m_closeButton(0), m_searchResultArea(0), m_searchOptionsArea(0) { namespace DU = util::directory; setWindowIcon(DU::getIcon(CResMgr::searchdialog::icon)); setWindowTitle(tr("Search")); setAttribute(Qt::WA_DeleteOnClose); m_searcher.connectFinished( this, SLOT(searchFinished())); initView(); initConnections(); }
/** * @brief 생성자 * @param parent 부모 위젯 */ Puzzle::Puzzle(QWidget *parent) : QMainWindow(parent) , _emptyPiece(0) , _shuffle(false) , _tryCount(0) { initMenus(); // 메뉴 초기화 initWidgets(); // 위젯 초기화 initConnections(); // 시그널과 슬롯 연결 newPuzzle(); // 새 퍼즐 }