• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ showSettings函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中showSettings函数的典型用法代码示例。如果您正苦于以下问题:C++ showSettings函数的具体用法?C++ showSettings怎么用?C++ showSettings使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了showSettings函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: setStyleSheet

void NBMenuButton::showMenu() {

	setStyleSheet( "QToolButton#menuBtn{ background-color: darkgray; border: none; border-radius: 3px; }" );

	NBSystemMenu *menu = new NBSystemMenu( this );
	QPoint point = mapToGlobal( rect().bottomRight() - QPoint( menu->width(), 0 ) );

	connect( menu, SIGNAL( newWindow() ), this, SIGNAL( newWindow() ) );
	connect( menu, SIGNAL( zoomIn() ), this, SIGNAL( zoomIn() ) );
	connect( menu, SIGNAL( zoomOut() ), this, SIGNAL( zoomOut() ) );
	connect( menu, SIGNAL( cut() ), this, SIGNAL( cut() ) );
	connect( menu, SIGNAL( copy() ), this, SIGNAL( copy() ) );
	connect( menu, SIGNAL( paste() ), this, SIGNAL( paste() ) );
	connect( menu, SIGNAL( openVTE() ), this, SIGNAL( openVTE() ) );
	connect( menu, SIGNAL( changeViewMode( int ) ), this, SIGNAL( changeViewMode( int ) ) );
	connect( menu, SIGNAL( sortByName() ), this, SIGNAL( sortByName() ) );
	connect( menu, SIGNAL( sortByType() ), this, SIGNAL( sortByType() ) );
	connect( menu, SIGNAL( sortBySize() ), this, SIGNAL( sortBySize() ) );
	connect( menu, SIGNAL( sortByDate() ), this, SIGNAL( sortByDate() ) );
	connect( menu, SIGNAL( toggleHidden() ), this, SIGNAL( toggleHidden() ) );
	connect( menu, SIGNAL( toggleGrouping() ), this, SIGNAL( toggleGrouping() ) );
	connect( menu, SIGNAL( showSettings() ), this, SIGNAL( showSettings() ) );
	connect( menu, SIGNAL( closeWindow() ), this, SIGNAL( closeWindow() ) );
	connect( menu, SIGNAL( quit() ), this, SIGNAL( quit() ) );

	menu->exec( point );

	setStyleSheet( "QToolButton#menuBtn{ border: none; } QToolButton#menuBtn:hover { border: none; background-color: #A1DFFF; border-radius: 3px; }" );
};
开发者ID:marcusbritanicus,项目名称:NewBreeze,代码行数:29,代码来源:NBMenuButton.cpp


示例2: main

int main(void)
{
   /* create Views object, initialize struct box view */
   union views box = {{YES, YELLOW, YES, GREEN, DASHED}};
   char binStr[8 * sizeof(unsigned int) + 1];

   printf("Original box settings:\n");
   showSettings(&box.st_view);
   printf("\nBox settings using unsigned int view:\n");
   showSettings1(box.ui_view);

   printf("bits are %s\n",
          intToBits(box.ui_view, binStr));
   box.ui_view &= ~FILL_MASK; /* clear fill bits */
   box.ui_view |= FILL_BLUE | FILL_GREEN; /* reset fill */
   box.ui_view ^= OPAQUE; /* toggle opacity */
   box.ui_view |= BORDER_RED; /* wrong approach */
   box.ui_view &= ~STYLE_MASK; /* clear style bits */
   box.ui_view |= B_DOTTED; /* set style to dotted*/
   printf("\nModified box settings:\n");
   showSettings(&box.st_view);
   printf("\nBox settings using unsigned int view:\n");
   showSettings1(box.ui_view);
   printf("bits are %s\n",
          intToBits(box.ui_view, binStr));

   return 0;
}
开发者ID:dwinner,项目名称:CppAppdev,代码行数:28,代码来源:dualview.c


示例3: connect

void PolkaView::connectGroupView( GroupView *groupView )
{
  connect( groupView, SIGNAL( goBack() ), SLOT( goBack() ) );
  connect( groupView, SIGNAL( newPerson() ), SLOT( newPerson() ) );
  connect( groupView, SIGNAL( showIdentity( const Polka::Identity & ) ),
    SLOT( showIdentity( const Polka::Identity & ) ) );
  connect( groupView, SIGNAL( showSettings() ),
    SLOT( showSettings() ) );
}
开发者ID:wyuka,项目名称:polka,代码行数:9,代码来源:polkaview.cpp


示例4: QAction

void BaseOrdinalPropertyWidgetQt::generatesSettingsWidget() {

    settingsAction_ = new QAction(tr("&Property settings..."), this);
    settingsAction_->setToolTip(tr("&Open the property settings dialog to adjust min, max, and increment values"));
    minAction_ = new QAction(tr("&Set as Min"), this);
    minAction_->setToolTip(tr("&Use the current value as the min value for the property"));
    maxAction_ = new QAction(tr("&Set as Max"), this);
    maxAction_->setToolTip(tr("&Use the current value as the max value for the property"));

    connect(settingsAction_,
            SIGNAL(triggered()),
            this,
            SLOT(showSettings()));

    connect(minAction_,
            SIGNAL(triggered()),
            this,
            SLOT(setAsMin()));
    
    connect(maxAction_,
            SIGNAL(triggered()),
            this,
            SLOT(setAsMax()));
               
    contextMenu_ = new QMenu(this);
    contextMenu_->addActions(PropertyWidgetQt::getContextMenu()->actions());
    contextMenu_->addAction(settingsAction_);
    contextMenu_->addAction(minAction_);
    contextMenu_->addAction(maxAction_);
    minAction_->setVisible(false);
    maxAction_->setVisible(false);
}
开发者ID:sarbi127,项目名称:inviwo,代码行数:32,代码来源:ordinalpropertywidgetqt.cpp


示例5: switch

int databasTab::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
    _id = QWidget::qt_metacall(_c, _id, _a);
    if (_id < 0)
        return _id;
    if (_c == QMetaObject::InvokeMetaMember) {
        switch (_id) {
        case 0:
            init();
            break;
        case 1:
            showSettings();
            break;
        case 2:
            testConn();
            break;
        case 3:
            saveConn();
            break;
        case 4:
            exit();
            break;
        }
        _id -= 5;
    }
    return _id;
}
开发者ID:BackupTheBerlios,项目名称:tribok,代码行数:27,代码来源:moc_mainwindow.cpp


示例6: setRect

MagicMenuItem::MagicMenuItem()
{
  int itemSize = 55;

  setRect( -itemSize/2, -itemSize/2, itemSize, itemSize );
  setBrush( QColor( 230,229,229 ) );

  QPen pen;
  pen.setBrush( Qt::NoBrush );
  setPen( pen );

  QGraphicsTextItem *textItem = new QGraphicsTextItem( i18n("Magic"), this );

  int textWidth = textItem->boundingRect().width();
  int textHeight = textItem->boundingRect().height();

  textItem->setPos( - textWidth / 2, - textHeight / 2 );

  m_fanMenu = new FanMenu( this );
  m_fanMenu->setZValue( 50 );
  m_fanMenu->hide();
  m_fanMenu->setStartAngle( 80 );
  m_fanMenu->setEndAngle( 280 );

  FanMenuItem *menuItem = m_fanMenu->addItem( i18n("Reset\nlayout") );
  connect( menuItem, SIGNAL( clicked() ), SIGNAL( resetLayout() ) );
  menuItem = m_fanMenu->addItem( i18n("Settings") );
  connect( menuItem, SIGNAL( clicked() ), SIGNAL( showSettings() ) );

  m_fanMenu->setupItems( 80 );

  setAcceptHoverEvents( true );
}
开发者ID:cornelius,项目名称:polka,代码行数:33,代码来源:magicmenuitem.cpp


示例7: QSystemTrayIcon

// Tray functions
void MainWindow::setupTray()
{
	trayIcon = new QSystemTrayIcon(this);
	trayIcon->setIcon(StatusIcon::getStatusIcon(UserStatus::Offline));

	trayIcon->show();
	connect(trayIcon, SIGNAL(activated(QSystemTrayIcon::ActivationReason)), this, SLOT(onTrayIconActivated(QSystemTrayIcon::ActivationReason)));

	trayMenu = new QMenu(this);

	openTvAction = trayMenu->addAction(tr(OPEN_TV_MENU_ITEM));
	connect(openTvAction, SIGNAL(triggered()), this, SLOT(showWindow()));

	trayMenu->addSeparator();

	onlineAction = trayMenu->addAction(StatusIcon::getStatusIcon(UserStatus::Online), tr(ONLINE_MENU_ITEM));	
	connect(onlineAction, SIGNAL(triggered()), this, SLOT(relogon()));

	offlineAction = trayMenu->addAction(StatusIcon::getStatusIcon(UserStatus::Offline), tr(OFFLINE_MENU_ITEM));
	connect(offlineAction, SIGNAL(triggered()), this, SLOT(offline()));

	networkSettingsAction = trayMenu->addAction(tr(NETWORK_SETTINGS_MENU_ITEM));
	connect(networkSettingsAction, SIGNAL(triggered()), this, SLOT(showSettings()));

	trayMenu->addSeparator();

	signOutAction = trayMenu->addAction(tr(SIGNOUT_MENU_ITEM));
	connect(signOutAction, SIGNAL(triggered()), this, SLOT(logout()));

	exitAction = trayMenu->addAction(tr(EXIT_MENU_ITEM));
	connect(exitAction, SIGNAL(triggered()), this, SLOT(shutDown()));
}
开发者ID:ildus,项目名称:moodbox_aka_risovaska,代码行数:33,代码来源:mainwindow.cpp


示例8: QMenu

void VisWidget::contextMenu( const QPoint &point )
{
	QMenu *menu = new QMenu( this );
	connect( menu, SIGNAL( aboutToHide() ), menu, SLOT( deleteLater() ) );
	connect( menu->addAction( tr( "Ustawienia" ) ), SIGNAL( triggered() ), this, SLOT( showSettings() ) );
	menu->popup( mapToGlobal( point ) );
}
开发者ID:JERUKA9,项目名称:QMPlay2,代码行数:7,代码来源:VisWidget.cpp


示例9: showMenu

void showMenu()
{
    ClearLcd();
    LcdArrayLineOne("Main menu", 9);
    switch (isSettings)
    {
        case 0:
        {
            tm time;
            X12RtcGetClock(&time);
            char str1[16];
            sprintf(str1, "<   %02d:%02d:%02d   >", time.tm_hour, time.tm_min, time.tm_sec);
            LcdArrayLineTwo(str1, 16);
            break;
        }
        case 1:
        {
            showSettings();
            break;
        }
        case 2:
        {
            showPlay();
            break;
        }
    }
}
开发者ID:aareschluchtje,项目名称:C-programming,代码行数:27,代码来源:mainMenu.c


示例10: psUpdateMargins

void PsMainWindow::psFirstShow() {
	finished = false;

    psUpdateMargins();

	bool showShadows = true;

	show();
    _private.enableShadow(winId());
	if (cWindowPos().maximized) {
		setWindowState(Qt::WindowMaximized);
	}

	if ((cFromAutoStart() && cStartMinimized()) || cStartInTray()) {
		setWindowState(Qt::WindowMinimized);
		if (cWorkMode() == dbiwmTrayOnly || cWorkMode() == dbiwmWindowAndTray) {
			hide();
		} else {
			show();
		}
		showShadows = false;
	} else {
		show();
	}

	posInited = true;

	// init global menu
	QMenu *main = psMainMenu.addMenu(qsl("Telegram"));
	main->addAction(lng_mac_menu_about_telegram(lt_telegram, qsl("Telegram")), App::wnd()->getTitle(), SLOT(onAbout()))->setMenuRole(QAction::AboutQtRole);
	main->addSeparator();
	QAction *prefs = main->addAction(lang(lng_mac_menu_preferences), App::wnd(), SLOT(showSettings()), QKeySequence(Qt::ControlModifier | Qt::Key_Comma));
	prefs->setMenuRole(QAction::PreferencesRole);

	QMenu *file = psMainMenu.addMenu(lang(lng_mac_menu_file));
	psLogout = file->addAction(lang(lng_mac_menu_logout), App::wnd(), SLOT(onLogout()));

	QMenu *edit = psMainMenu.addMenu(lang(lng_mac_menu_edit));
	psUndo = edit->addAction(lang(lng_mac_menu_undo), this, SLOT(psMacUndo()), QKeySequence::Undo);
	psRedo = edit->addAction(lang(lng_mac_menu_redo), this, SLOT(psMacRedo()), QKeySequence::Redo);
	edit->addSeparator();
	psCut = edit->addAction(lang(lng_mac_menu_cut), this, SLOT(psMacCut()), QKeySequence::Cut);
	psCopy = edit->addAction(lang(lng_mac_menu_copy), this, SLOT(psMacCopy()), QKeySequence::Copy);
	psPaste = edit->addAction(lang(lng_mac_menu_paste), this, SLOT(psMacPaste()), QKeySequence::Paste);
	psDelete = edit->addAction(lang(lng_mac_menu_delete), this, SLOT(psMacDelete()), QKeySequence(Qt::ControlModifier | Qt::Key_Backspace));
	edit->addSeparator();
	psSelectAll = edit->addAction(lang(lng_mac_menu_select_all), this, SLOT(psMacSelectAll()), QKeySequence::SelectAll);

	QMenu *window = psMainMenu.addMenu(lang(lng_mac_menu_window));
	psContacts = window->addAction(lang(lng_mac_menu_contacts), App::wnd()->getTitle(), SLOT(onContacts()));
	psAddContact = window->addAction(lang(lng_mac_menu_add_contact), App::wnd(), SLOT(onShowAddContact()));
	window->addSeparator();
	psNewGroup = window->addAction(lang(lng_mac_menu_new_group), App::wnd(), SLOT(onShowNewGroup()));
	psNewChannel = window->addAction(lang(lng_mac_menu_new_channel), App::wnd(), SLOT(onShowNewChannel()));
	window->addSeparator();
	psShowTelegram = window->addAction(lang(lng_mac_menu_show), App::wnd(), SLOT(showFromTray()));

	psMacUpdateMenu();
}
开发者ID:0ps,项目名称:telegram,代码行数:59,代码来源:pspecific_mac.cpp


示例11: QWidget

Settings::Settings(Window *parent) : QWidget(parent),
	_scroll(this, st::setScroll), _inner(this), _close(this, st::setClose) {
	_scroll.setWidget(&_inner);

	connect(App::wnd(), SIGNAL(resized(const QSize &)), this, SLOT(onParentResize(const QSize &)));
	connect(&_close, SIGNAL(clicked()), App::wnd(), SLOT(showSettings()));

	setGeometry(QRect(0, st::titleHeight, Application::wnd()->width(), Application::wnd()->height() - st::titleHeight));

	showAll();
}
开发者ID:Brandhor,项目名称:tdesktop,代码行数:11,代码来源:settingswidget.cpp


示例12: connect

void TagEditor::createActions(){

    connect(LoadScriptButton,SIGNAL(clicked()),this,SLOT(loadScript()));
    connect(SaveScriptButton,SIGNAL(clicked()),this,SLOT(saveScript()));
    connect(RunScriptButton,SIGNAL(clicked()),this, SLOT(runScript()));

    QAction* searchOnlineAction = new QAction(tr("Search for selected file/album in online musicdatabases..."), this);
    searchOnlineAction->setShortcut(tr("Ctrl+S"));
    connect(searchOnlineAction, SIGNAL(triggered()), this, SLOT(searchOnline()));
    QAction* searchForFilesAction = new QAction(tr("Search for files to add to workspace..."), this);
    //searchForFilesAction->setShortcut(tr("Ctrl+S"));
    connect(searchForFilesAction, SIGNAL(triggered()), this, SLOT(searchAndAddFiles()));

    TreeView->setContextMenuPolicy(Qt::ActionsContextMenu);
    TreeView->addAction(searchOnlineAction);
    TreeView->addAction(searchForFilesAction);


    connect( TreeView, SIGNAL( expanded( const QModelIndex & )  ), this, SLOT( resizeColumn() ) );
    connect( TreeView, SIGNAL( collapsed( const QModelIndex & )  ), this, SLOT( resizeColumn() ) );
    //connect( TreeWidget_, SIGNAL( currentRowChanged( int )  ), this, SLOT( showTagInfo(int) ) );
    connect( TreeWidget_, SIGNAL( itemSelectionChanged() ), this, SLOT( showTagInfo() ) );
    connect( AddButton, SIGNAL( clicked()  ), this, SLOT(addFiles() ) );
    connect( RemoveButton, SIGNAL( clicked()  ), this, SLOT(removeFiles() ) );
    connect( ClearButton, SIGNAL( clicked()  ), this, SLOT(removeAllFiles() ) );
    connect( SaveButton, SIGNAL( clicked()  ), this, SLOT(saveTag() ) );
    connect( ChooseDirButton, SIGNAL( clicked()  ), this, SLOT(chooseDir() ) );

    connect( actionSettings, SIGNAL( triggered() ), this, SLOT( showSettings() ) );
    connect( actionRewriteTag, SIGNAL( triggered() ), this, SLOT( rewriteTag() ) );
    connect( actionRenameFiles, SIGNAL( triggered() ), this, SLOT( renameFiles() ) );
    connect( actionReplaceTags, SIGNAL( triggered() ), this, SLOT( replaceTags() ) );
    connect( actionSerialize, SIGNAL( triggered() ), this, SLOT( serialize() ) );
    connect( actionClearTags, SIGNAL( triggered() ), this, SLOT( clearTags() ) );
    //connect( actionRemoveFrames, SIGNAL( triggered() ), this, SLOT( removeFrames() ) );
    //styles

    QSignalMapper *styleMapper = new QSignalMapper(this);
    QStringList styles = QStyleFactory::keys();
    for(int i=0;i<styles.size();i++){
        QAction *a = new QAction(styles[i],menuStyle);
        a->setCheckable(true);
        connect(a, SIGNAL(triggered()), styleMapper, SLOT(map()));
        styleMapper->setMapping(a, styles[i]);
        menuStyle->addAction(a);
    }
    menuStyle->addSeparator();
    QAction *actionCustomStyleSheet = new QAction("Custom...",menuStyle);
    actionCustomStyleSheet->setCheckable(true);
    connect(actionCustomStyleSheet, SIGNAL(triggered()), this, SLOT(openStyleSheet()));
    menuStyle->addAction( actionCustomStyleSheet );
    connect(styleMapper, SIGNAL(mapped(const QString &)), this, SLOT(setGUIStyle(const QString &)));

}
开发者ID:ivareske,项目名称:TagEditor,代码行数:54,代码来源:tagEditor.cpp


示例13: connect

void MainWindow::createConnections()
{
    connect(this, SIGNAL(windowWasShown()), this, SLOT(initUpdates()),
            Qt::ConnectionType(Qt::QueuedConnection | Qt::UniqueConnection));

    connect(ui->tabs, SIGNAL(currentChanged(QWidget *)), this, SLOT(currentWidget(QWidget *)));
    connect(ui->tabs, SIGNAL(currentChanged(QWidget *)), _recorder, SLOT(currentWidget(QWidget *)));
    connect(_playlistTab, SIGNAL(changeTo(QWidget *)), ui->tabs, SLOT(setCurrentWidget(QWidget *)));
    connect(_scheduleTab, SIGNAL(changeTo(QWidget *)), ui->tabs, SLOT(setCurrentWidget(QWidget *)));
    connect(_showInfoTab, SIGNAL(changeTo(QWidget *)), ui->tabs, SLOT(setCurrentWidget(QWidget *)));

    connect(ui->actionSupport, SIGNAL(triggered()), this, SLOT(support()));
    connect(ui->actionAbout, SIGNAL(triggered()), this, SLOT(aboutTano()));
    connect(ui->actionAboutQt, SIGNAL(triggered()), qApp, SLOT(aboutQt()));
    connect(ui->actionLogoutExit, SIGNAL(triggered()), this, SLOT(exitLogout()));
    connect(ui->actionExit, SIGNAL(triggered()), this, SLOT(exit()));

    connect(ui->actionTop, SIGNAL(triggered()), this, SLOT(top()));
    connect(ui->actionLite, SIGNAL(triggered()), this, SLOT(lite()));

    connect(ui->actionOpen, SIGNAL(triggered()), this, SLOT(openPlaylist()));
    connect(ui->actionOpenFile, SIGNAL(triggered()), _mediaPlayer, SLOT(openFile()));
    connect(ui->actionOpenUrl, SIGNAL(triggered()), _mediaPlayer, SLOT(openUrl()));

    connect(ui->actionSchedule, SIGNAL(triggered()), this, SLOT(showSchedule()));
    connect(ui->actionScheduleCurrent, SIGNAL(triggered()), this, SLOT(showScheduleCurrent()));
    connect(ui->actionSettings, SIGNAL(triggered()), this, SLOT(showSettings()));
    connect(ui->actionSettingsShortcuts, SIGNAL(triggered()), this, SLOT(showSettingsShortcuts()));
    connect(ui->actionEditPlaylist, SIGNAL(triggered()), this, SLOT(showPlaylistEditor()));

    connect(ui->actionPlay, SIGNAL(triggered()), _mediaPlayer, SLOT(togglePause()));
    connect(ui->actionStop, SIGNAL(triggered()), this, SLOT(stop()));
    connect(ui->actionPreview, SIGNAL(triggered(bool)), this, SLOT(preview(bool)));

    connect(_playlistTab->playlist(), SIGNAL(itemSelected(Channel *)), this, SLOT(playChannel(Channel *)));
    connect(_previewTimer, SIGNAL(timeout()), ui->actionNext, SLOT(trigger()));

    if (_trayIcon) {
        connect(_trayIcon, SIGNAL(restoreClick()), this, SLOT(tray()));
        connect(ui->actionTray, SIGNAL(triggered()), this, SLOT(tray()));
    }

    connect(ui->actionFullscreen, SIGNAL(triggered(bool)), this, SLOT(toggleFullscreen(bool)));

    connect(ui->actionMute, SIGNAL(toggled(bool)), _mediaPlayer->osd(), SLOT(mute(bool)));
    connect(ui->actionVolumeDown, SIGNAL(triggered()), _mediaPlayer->osd(), SLOT(volumeDown()));
    connect(ui->actionVolumeUp, SIGNAL(triggered()), _mediaPlayer->osd(), SLOT(volumeUp()));

#if defined(Q_OS_LINUX)
    if (_mediaPlayer->teletextEnabled()) {
        connect(ui->actionTeletext, SIGNAL(triggered(bool)), _mediaPlayer->osd(), SLOT(teletext(bool)));
        connect(ui->actionTeletext, SIGNAL(triggered(bool)), _mediaPlayer, SLOT(teletext(bool)));
        connect(_mediaPlayer->osd(), SIGNAL(teletextClicked()), ui->actionTeletext, SLOT(trigger()));
    }
开发者ID:ntadej,项目名称:tano,代码行数:54,代码来源:MainWindow.cpp


示例14: TWidget

TitleWidget::TitleWidget(MainWindow *window) : TWidget(window)
, wnd(window)
, hideLevel(0)
, hider(0)
, _back(this, st::titleBackButton, lang(lng_menu_back))
, _cancel(this, lang(lng_cancel), st::titleTextButton)
, _settings(this, lang(lng_menu_settings), st::titleTextButton)
, _contacts(this, lang(lng_menu_contacts), st::titleTextButton)
, _about(this, lang(lng_menu_about), st::titleTextButton)
, _lock(this, window)
, _update(this, window, lang(lng_menu_update))
, _minimize(this, window)
, _maximize(this, window)
, _restore(this, window)
, _close(this, window)
, _a_update(animation(this, &TitleWidget::step_update))
, lastMaximized(!(window->windowState() & Qt::WindowMaximized))
{
	setGeometry(0, 0, wnd->width(), st::titleHeight);
	setAttribute(Qt::WA_OpaquePaintEvent);
	_lock.hide();
	_update.hide();
    _cancel.hide();
    _back.hide();
	if (
#ifndef TDESKTOP_DISABLE_AUTOUPDATE
		Sandbox::updatingState() == Application::UpdatingReady ||
#endif
		cHasPasscode()
	) {
		showUpdateBtn();
	}
	stateChanged();

	connect(&_back, SIGNAL(clicked()), window, SLOT(hideSettings()));
	connect(&_cancel, SIGNAL(clicked()), this, SIGNAL(hiderClicked()));
	connect(&_settings, SIGNAL(clicked()), window, SLOT(showSettings()));
	connect(&_contacts, SIGNAL(clicked()), this, SLOT(onContacts()));
	connect(&_about, SIGNAL(clicked()), this, SLOT(onAbout()));
	connect(wnd->windowHandle(), SIGNAL(windowStateChanged(Qt::WindowState)), this, SLOT(stateChanged(Qt::WindowState)));

#ifndef TDESKTOP_DISABLE_AUTOUPDATE
	Sandbox::connect(SIGNAL(updateReady()), this, SLOT(showUpdateBtn()));
#endif

    if (cPlatform() != dbipWindows) {
        _minimize.hide();
        _maximize.hide();
        _restore.hide();
        _close.hide();
    }
}
开发者ID:NXij,项目名称:tdesktop-dark,代码行数:52,代码来源:title.cpp


示例15: tr

void DataSourceView::spawnZimaUtilityOnDir(const QString &label)
{
	QString executable = Settings::get()->ExternalPrograms[label];

	if (executable.isEmpty())
	{
		QMessageBox::warning(this, tr("Configure %1").arg(label), tr("Please first configure path to %1 executable.").arg(label));
		emit showSettings(SettingsDialog::ExternalPrograms);
		return;
	}

	if (!QFile::exists(executable))
	{
		QMessageBox::warning(this, tr("Configure %1").arg(label), tr("Path '%1' to %2 executable does not exists!").arg(executable).arg(label));
		emit showSettings(SettingsDialog::ExternalPrograms);
		return;
	}

	QStringList args;
	args << currentFileInfo().absoluteFilePath();
	QProcess::startDetached(executable, args);
}
开发者ID:ZIMA-Engineering,项目名称:ZIMA-CAD-Parts,代码行数:22,代码来源:datasourceview.cpp


示例16: args

void InternalLink::handleInternalLink(DesuraId id, uint8 action, const std::vector<std::string> &argsList)
{
	if (g_pMainApp->isOffline() && action != ACTION_LAUNCH)
		return;

	Args args(argsList);

	bool handled = true;

	switch (action)
	{
	case ACTION_UPLOAD		: uploadMCF( id );						break;
	case ACTION_CREATE		: createMCF( id );						break;
	case ACTION_RESUPLOAD	: resumeUploadMCF( id, args );			break;
#ifdef WIN32
	case ACTION_INSTALLEDW	: installedWizard();					break;
#endif
	case ACTION_SHOWSETTINGS: showSettings(args);					break;
	case ACTION_APPUPDATELOG: showUpdateLogApp( id.getItem() );		break;
	case ACTION_PAUSE		: setPauseItem( id , true );			break;
	case ACTION_UNPAUSE		: setPauseItem( id , false );			break;
	case ACTION_UNINSTALL	: uninstallMCF( id );					break;
	case ACTION_PROMPT		: showPrompt(id, args);					break;
	case ACTION_UPDATELOG	: showUpdateLog(id);					break;
	case ACTION_DISPCDKEY	: showCDKey(id, args);					break;

	default: 
		handled = false;
		break;
	}

	if (handled || checkForm(id))
		return;

	switch (action)
	{
	case ACTION_INSTALL		: installItem(id, args);				break;
	case ACTION_LAUNCH		: launchItem(id, args);					break;
	case ACTION_VERIFY		: verifyItem(id, args);					break;
	case ACTION_UPDATE		: updateItem(id, args);					break;
	case ACTION_TEST		: installTestMCF(id, args);				break;
	case ACTION_INSCHECK	: installCheck(id);						break;
	case ACTION_SHOWUPDATE	: showUpdateForm(id, args);				break;
	case ACTION_SWITCHBRANCH: switchBranch(id, args);				break;
	case ACTION_CLEANCOMPLEXMOD: cleanComplexMod(id);				break;

	default: 
		Warning(gcString("Unknown internal link {0} for item {1}\n.", (uint32)action, id.toInt64()));	
		break;
	}
}
开发者ID:CSRedRat,项目名称:desura-app,代码行数:51,代码来源:InternalLink.cpp


示例17: lmcMessaging

lmcCore::lmcCore(void) {
	pMessaging = new lmcMessaging();
	connect(pMessaging, SIGNAL(messageReceived(MessageType, QString*, XmlMessage*)), 
		this, SLOT(receiveMessage(MessageType, QString*, XmlMessage*)));
	connect(pMessaging, SIGNAL(connectionStateChanged()), this, SLOT(connectionStateChanged()));
	pMainWindow = new lmcMainWindow();
	connect(pMainWindow, SIGNAL(appExiting()), this, SLOT(exitApp()));
	connect(pMainWindow, SIGNAL(chatStarting(QString*)), this, SLOT(startChat(QString*)));
	connect(pMainWindow, SIGNAL(chatRoomStarting(QString*)), this, SLOT(startChatRoom(QString*)));
	connect(pMainWindow, SIGNAL(messageSent(MessageType, QString*, XmlMessage*)), 
		this, SLOT(sendMessage(MessageType, QString*, XmlMessage*)));
	connect(pMainWindow, SIGNAL(showTransfers()), this, SLOT(showTransfers()));
	connect(pMainWindow, SIGNAL(showHistory()), this, SLOT(showHistory()));
	connect(pMainWindow, SIGNAL(showSettings()), this, SLOT(showSettings()));
	connect(pMainWindow, SIGNAL(showHelp(QRect*)), this, SLOT(showHelp(QRect*)));
	connect(pMainWindow, SIGNAL(showUpdate(QRect*)), this, SLOT(showUpdate(QRect*)));
	connect(pMainWindow, SIGNAL(showAbout()), this, SLOT(showAbout()));
	connect(pMainWindow, SIGNAL(showBroadcast()), this, SLOT(showBroadcast()));
	connect(pMainWindow, SIGNAL(showPublicChat()), this, SLOT(showPublicChat()));
	connect(pMainWindow, SIGNAL(groupUpdated(GroupOp, QVariant, QVariant)),
			this, SLOT(updateGroup(GroupOp, QVariant, QVariant)));
	pPublicChatWindow = new lmcChatRoomWindow();
	connect(pPublicChatWindow, SIGNAL(messageSent(MessageType, QString*, XmlMessage*)),
		this, SLOT(sendMessage(MessageType, QString*, XmlMessage*)));
	connect(pPublicChatWindow, SIGNAL(chatStarting(QString*)), this, SLOT(startChat(QString*)));
	chatWindows.clear();
	chatRoomWindows.clear();
	pTransferWindow = NULL;
	pHistoryWindow = NULL;
	pSettingsDialog = NULL;
	pUserInfoWindow = NULL;
	pHelpWindow = NULL;
	pUpdateWindow = NULL;
	pUserSelectDialog = NULL;
	pAboutDialog = NULL;
	pBroadcastWindow = NULL;
	pTimer = NULL;
}
开发者ID:Litew,项目名称:lanmsng,代码行数:38,代码来源:lmc.cpp


示例18: SLOT

void KMahjongg::setupKAction()
{
    KStandardGameAction::gameNew(this, SLOT(startNewGame()), actionCollection());
    KStandardGameAction::load(this, SLOT(loadGame()), actionCollection());
    KStandardGameAction::save(this, SLOT(saveGame()), actionCollection());
    KStandardGameAction::quit(this, SLOT(close()), actionCollection());
    KStandardGameAction::restart(this, SLOT(restartGame()), actionCollection());

    QAction * newNumGame = actionCollection()->addAction(QStringLiteral("game_new_numeric"));
    newNumGame->setText(i18n("New Numbered Game..."));
    connect(newNumGame, &QAction::triggered, this, &KMahjongg::startNewNumeric);

    QAction * action = KStandardGameAction::hint(m_gameView, SLOT(helpMove()), this);
    actionCollection()->addAction(action->objectName(), action);

    QAction * shuffle = actionCollection()->addAction(QStringLiteral("move_shuffle"));
    shuffle->setText(i18n("Shu&ffle"));
    shuffle->setIcon(QIcon::fromTheme(QStringLiteral("view-refresh")));
    connect(shuffle, &QAction::triggered, m_gameView, &GameView::shuffle);

    QAction * angleccw = actionCollection()->addAction(QStringLiteral("view_angleccw"));
    angleccw->setText(i18n("Rotate View Counterclockwise"));
    angleccw->setIcon(QIcon::fromTheme(QStringLiteral("object-rotate-left")));
    actionCollection()->setDefaultShortcut(angleccw, Qt::Key_F);
    connect(angleccw, &QAction::triggered, m_gameView, &GameView::angleSwitchCCW);

    QAction * anglecw = actionCollection()->addAction(QStringLiteral("view_anglecw"));
    anglecw->setText(i18n("Rotate View Clockwise"));
    anglecw->setIcon(QIcon::fromTheme(QStringLiteral("object-rotate-right")));
    actionCollection()->setDefaultShortcut(anglecw, Qt::Key_G);
    connect(anglecw, &QAction::triggered, m_gameView, &GameView::angleSwitchCW);

    m_demoAction = KStandardGameAction::demo(this, SLOT(demoMode()), actionCollection());

    KStandardGameAction::highscores(this, SLOT(showHighscores()), actionCollection());
    m_pauseAction = KStandardGameAction::pause(this, SLOT(pause()), actionCollection());

    // move
    m_undoAction = KStandardGameAction::undo(this, SLOT(undo()), actionCollection());
    m_redoAction = KStandardGameAction::redo(this, SLOT(redo()), actionCollection());

    // edit
    QAction * boardEdit = actionCollection()->addAction(QStringLiteral("game_board_editor"));
    boardEdit->setText(i18n("&Board Editor"));
    connect(boardEdit, &QAction::triggered, this, &KMahjongg::slotBoardEditor);

    // settings
    KStandardAction::preferences(this, SLOT(showSettings()), actionCollection());
    setupGUI(qApp->desktop()->availableGeometry().size() * 0.7);
}
开发者ID:KDE,项目名称:kmahjongg,代码行数:50,代码来源:kmahjongg.cpp


示例19: main

int main(int argc, char *argv[])
{
    QCoreApplication::setOrganizationName("SRFGames");
    QCoreApplication::setOrganizationDomain("sol-online.org"),
    QCoreApplication::setApplicationName("ShareYourClipboard");

#ifdef Q_OS_MAC
    QDir dir(argv[0]);
    dir.cdUp();
    QString currentDir = dir.absolutePath();
    dir.cdUp();
    dir.cd("PlugIns");
    QCoreApplication::setLibraryPaths(QStringList(dir.absolutePath()));
#endif

    QApplication a(argc, argv);
    QApplication::setQuitOnLastWindowClosed(false);

#ifdef Q_OS_MAC
    QDir::setCurrent(currentDir);
#endif

    qDebug() << "init manager\n";
    cClipboardManager manager(a.clipboard());

    qDebug() << "init tray icon\n";
    cTrayIcon trIcon(&manager);
    QObject::connect(&trIcon, SIGNAL(switchState()), &manager, SLOT(switchState()));
    QObject::connect(&trIcon, SIGNAL(pasteFiles()), &manager, SLOT(pasteFiles()));
    QObject::connect(&manager, SIGNAL(onStateChanged(cClipboardManager::eClipboardState)), &trIcon, SLOT(setState(cClipboardManager::eClipboardState)));

    qDebug() << "init settings window\n";
    SettingsWindow settingsWindow(&manager);
    QObject::connect(&trIcon, SIGNAL(showSettings()), &settingsWindow, SLOT(showNormal()));
    QObject::connect(&settingsWindow, SIGNAL(preferencesChange()), &manager, SLOT(onPreferencesChanged()));

    qDebug() << "init copy dialog\n";
    CopyProgressDialog copydialog;
    QObject::connect(&manager, SIGNAL(onStartCopyProcess(QString)), &copydialog, SLOT(start(QString)));
    QObject::connect(&manager, SIGNAL(onStopCopyProcess()), &copydialog, SLOT(stop()));
    QObject::connect(&manager, SIGNAL(showMessage(QString)), &copydialog, SLOT(showMessage(QString)));
    QObject::connect(&manager, SIGNAL(onSetProgressMain(QString,int,int)), &copydialog, SLOT(setProgressMain(QString,int,int)));
    QObject::connect(&manager, SIGNAL(onSetProgressSecond(QString,int,int)), &copydialog, SLOT(setProgressSecond(QString,int,int)));
    QObject::connect(&copydialog, SIGNAL(cancel()), &manager, SLOT(cancelDownloading()));

    qDebug() << "start app loop\n";
    int result = a.exec();
    qDebug() << "application close\n";
    return result;
}
开发者ID:Allexin,项目名称:ShareYourClipboard,代码行数:50,代码来源:main.cpp


示例20: QAction

void BaseOrdinalMinMaxTextPropertyWidgetQt::generatesSettingsWidget() {

    settingsAction_ = new QAction(tr("&Property settings..."), this);
    settingsAction_->setToolTip(tr("&Open the property settings dialog to adjust min bound, start, end, max bound, minSepration and increment values"));

    connect(settingsAction_,
        SIGNAL(triggered()),
        this,
        SLOT(showSettings()));

    contextMenu_ = new QMenu(this);
    contextMenu_->addActions(PropertyWidgetQt::getContextMenu()->actions());
    contextMenu_->addAction(settingsAction_);
}
开发者ID:sarbi127,项目名称:inviwo,代码行数:14,代码来源:ordinalminmaxtextpropertywidgetqt.cpp



注:本文中的showSettings函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ showStatus函数代码示例发布时间:2022-05-30
下一篇:
C++ showRestartWarning_Lang函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap