本文整理汇总了C++中showNormal函数的典型用法代码示例。如果您正苦于以下问题:C++ showNormal函数的具体用法?C++ showNormal怎么用?C++ showNormal使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了showNormal函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: showNormal
void MyVis::toggleFullScreen()
{
static bool showMainWindow = false;
static bool showMiniQMPlay = false;
if ( isFullScreen() )
{
if ( !QLib->getParent( QMP_MAIN )->isVisible() && showMainWindow )
QLib->control( 0xE, 0 );
showMainWindow = false;
if ( QLib->getParent( QMP_MINI )->isVisible() )
QLib->control( 0xD, 0 ); //chowanie miniqmp
if ( showMiniQMPlay )
{
QLib->control( 0xD, 0 ); //pokazywanie miniqmp
showMiniQMPlay = false;
}
if ( QLib->inDock() == NULL && wasInDock )
QLib->dock(this,true,unDock);
else
{
showNormal();
hide();
show();
}
}
else
{
if ( QLib->inDock() == this )
{
QLib->dock(NULL,false,NULL);
wasInDock = true;
}
else
wasInDock = false;
if ( QLib->getParent( QMP_MAIN )->isVisible() )
{
QLib->control( 0xE, 0 ); //chowanie okna głównego
showMainWindow = true;
}
if ( QLib->getParent( QMP_MINI )->isVisible() )
{
QLib->control( 0xD, 0 ); //chowanie miniqmp
showMiniQMPlay = true;
}
showFullScreen();
cursorTim.start( 1500 );
}
}
示例2: if
void OpenGLWidget::keyPressEvent(QKeyEvent* event)
{
if (event->key() < 1024)
keys[event->key()] = true;
if (event->key() == Qt::Key::Key_Q)
{
zoom *= 2.0f;
fractal.computeVariables.at(fractal.computeVariables.size() - 1)->setValue();
rendermodeLR = ALL;
}
else if (event->key() == Qt::Key::Key_E)
{
zoom /= 2.0f;
fractal.computeVariables.at(fractal.computeVariables.size() - 1)->setValue();
rendermodeLR = ALL;
}
else if (event->key() == Qt::Key::Key_P)
{
QString file = QFileDialog::getSaveFileName(this, "Save as...", "screenshot", "PNG (*.png);; BMP (*.bmp);;TIFF (*.tiff *.tif);; JPEG (*.jpg *.jpeg)");
this->grabFramebuffer().save(file);
}
else if (event->key() == Qt::Key::Key_F11)
{
if (this->windowState() == Qt::WindowState::WindowFullScreen)
showNormal();
else
showFullScreen();
}
else if (event->key() == Qt::Key::Key_0)
go = !go;
else if (event->key() == Qt::Key::Key_9)
{
go = false;
anim.reset();
}
else if (event->key() == Qt::Key::Key_I)
autoIterations = !autoIterations;
else if (event->key() == Qt::Key::Key_F8)
{
if (consoleHidden)
ShowWindow(GetConsoleWindow(), SW_SHOW);
else
ShowWindow(GetConsoleWindow(), SW_HIDE);
consoleHidden = !consoleHidden;
}
}
示例3: QWidget
void MusicLrcContainerForDesktop::creatToolBarWidget()
{
m_toolBarWidget = new QWidget(this);
m_toolBarWidget->setStyleSheet(MusicUIObject::MCustomStyle09);
m_toolBarWidget->setGeometry((m_geometry.x() - TOOLBAR_WIDTH)/2, 0, TOOLBAR_WIDTH, TOOLBAR_HEIGHT);
m_showMainWindow = new QPushButton(m_toolBarWidget);
m_toolCloseButton = new QToolButton(m_toolBarWidget);
m_toolCloseButton->setGeometry(290, 0, 30, TOOLBAR_HEIGHT);
connect(m_toolCloseButton, SIGNAL(clicked()), SLOT(close()));
m_toolWindowLockedButton = new QToolButton(m_toolBarWidget);
m_toolWindowLockedButton->setGeometry(260, 0, 30, TOOLBAR_HEIGHT);
connect(m_toolWindowLockedButton, SIGNAL(clicked()), SLOT(setWindowLockedChanged()));
m_toolLrcBigerButton = new QToolButton(m_toolBarWidget);
m_toolLrcBigerButton->setGeometry(200, 0, 30, TOOLBAR_HEIGHT);
connect(m_toolLrcBigerButton, SIGNAL(clicked()), SLOT(setLrcBigerChanged()));
m_toolLrcSmallerButton = new QToolButton(m_toolBarWidget);
m_toolLrcSmallerButton->setGeometry(230, 0, 30, TOOLBAR_HEIGHT);
connect(m_toolLrcSmallerButton, SIGNAL(clicked()), SLOT(setLrcSmallerChanged()));
m_toolUpdateLrcButton = new QToolButton(m_toolBarWidget);
m_toolUpdateLrcButton->setGeometry(170, 0, 30, TOOLBAR_HEIGHT);
connect(m_toolUpdateLrcButton, SIGNAL(clicked()), SIGNAL(theCurrentLrcUpdated()));
m_toolSettingButton = new QToolButton(m_toolBarWidget);
m_toolSettingButton->setGeometry(140, 0, 30, TOOLBAR_HEIGHT);
connect(m_toolSettingButton, SIGNAL(clicked()), SLOT(currentLrcCustom()));
m_toolPreSongButton = new QToolButton(m_toolBarWidget);
m_toolPreSongButton->setGeometry(50, 0, 30, TOOLBAR_HEIGHT);
m_toolNextSongButton = new QToolButton(m_toolBarWidget);
m_toolNextSongButton->setGeometry(110, 0, 30, TOOLBAR_HEIGHT);
m_toolPlayButton = new QToolButton(m_toolBarWidget);
m_toolPlayButton->setGeometry(80, 0, 30, TOOLBAR_HEIGHT);
connect(m_toolPreSongButton, SIGNAL(clicked()), m_supperClass, SLOT(musicPlayPrivious()));
connect(m_toolNextSongButton, SIGNAL(clicked()), m_supperClass, SLOT(musicPlayNext()));
connect(m_toolPlayButton, SIGNAL(clicked()), m_supperClass, SLOT(musicKey()));
connect(m_showMainWindow, SIGNAL(clicked()), m_supperClass, SLOT(showNormal()));
setButtonIcon();
setButtonCursor();
setButtonTips();
m_toolBarWidget->hide();
}
示例4: resize
void CShareBox::Init()
{
/* Set the window's size and opacity. */
resize(DefaultWidth, DefaultHeight);
setWindowOpacity(DefaultOpacity);
/* Set the colors and fonts. */
m_text_font.setPixelSize(28);
m_text_normal.setRgb(215, 215, 215);
m_text_highlight.setRgb(127, 127, 255);
m_border_highlight.setRgb(127, 127, 215);
/* Create the context menu and show the box. */
CreateContextMenu();
showNormal();
}
示例5: switch
void nehewidget::keyPressEvent(QKeyEvent *e)
{
switch(e->key()) {
case Qt::Key_F2:
fullscreen=!fullscreen;
if(fullscreen) showFullScreen();
else {
showNormal();
setGeometry(0,0,640,480);
}
updateGL();
break;
case Qt::Key_Escape:
close();
}
}
示例6: showNormal
void MainWindow::setFullScreenMode(std::size_t screenNo, std::size_t resIndex, std::size_t rateIndex) {
if (screenNo < w_->screens()
&& (w_->currentResIndex(screenNo) != resIndex || w_->currentRateIndex(screenNo) != rateIndex)) {
if (w_->isFullMode() && screenNo == w_->currentScreen()) {
w_->parentExclusiveEvent(false);
w_->setMode(screenNo, resIndex, rateIndex);
#ifdef Q_WS_WIN
showNormal();
showFullScreen();
#endif
correctFullScreenGeometry();
w_->parentExclusiveEvent(isFullScreen() & hasFocus());
} else
w_->setMode(screenNo, resIndex, rateIndex);
}
}
示例7: switch
void MainWindow::trayIconActivated(QSystemTrayIcon::ActivationReason reason)
{
switch(reason){
case QSystemTrayIcon::Trigger:
case QSystemTrayIcon::DoubleClick:
if (isHidden() || isMinimized()) {
showNormal();
activateWindow();
}
else
showMinimized();
break;
default:
;
}
}
示例8: QAction
void Buddies::createActions()
{
minimizeAction = new QAction(tr("Mi&nimize"), this);
connect(minimizeAction, SIGNAL(triggered()), this, SLOT(hide()));
maximizeAction = new QAction(tr("Ma&ximize"), this);
connect(maximizeAction, SIGNAL(triggered()), this, SLOT(showMaximized()));
restoreAction = new QAction(tr("&Restore"), this);
connect(restoreAction, SIGNAL(triggered()), this, SLOT(showNormal()));
quitAction = new QAction(tr("&Quit"), this);
connect(quitAction, SIGNAL(triggered()), qApp, SLOT(quit()));
qDebug("=> Tray actions");
}
示例9: menuBar
/*---------------------------------------------------------------------------*/
void MainWindow::ToggleFullScreen( void )
{
static bool fullScreen = true;
if ( fullScreen )
{
menuBar( )->hide( );
showFullScreen( );
}
else
{
menuBar( )->show( );
showNormal( );
}
fullScreen = !fullScreen;
}
示例10: showNormal
void MainWindow::setMainWindowVisibility(bool state)
{
if(state){
showNormal();
setWindowState(Qt::WindowNoState);
qApp->processEvents();
setWindowState(Qt::WindowActive);
qApp->processEvents();
qApp->setActiveWindow(this);
qApp->processEvents();
m_restoreAction->setText(tr("Hide WifiAssist"));
}else{
m_restoreAction->setText(tr("Show WifiAssist"));
hide();
}
}
示例11: showNormal
void MainWindow::show()
{
if (!isVisible() && !_trayed)
showNormal();
if (_conf->getShowTrayIcon())
{
_trayIcon->blockSignals(false);
_trayIcon->setContextMenu(_trayMenu); // enable context menu
}
if (_trayIcon)
_trayIcon->setVisible(true);
QMainWindow::show();
}
示例12: switch
void MainWindow::iconActivated(QSystemTrayIcon::ActivationReason reason)
{
switch (reason) {
case QSystemTrayIcon::Trigger:
case QSystemTrayIcon::DoubleClick:
if (isVisible())
hide();
else
showNormal();
break;
case QSystemTrayIcon::MiddleClick:
break;
default:
;
}
}
示例13: showNormal
void MainWindow::on_action_OptionsFullScreen_triggered()
{
if(isFullScreen()) {
g_Config.bFullScreen = false;
showNormal();
ui->menubar->setVisible(true);
ui->statusbar->setVisible(true);
SetZoom(g_Config.iInternalResolution);
InitPadLayout();
if (globalUIState == UISTATE_INGAME && QApplication::overrideCursor())
QApplication::restoreOverrideCursor();
}
else {
g_Config.bFullScreen = true;
ui->menubar->setVisible(false);
ui->statusbar->setVisible(false);
// Remove constraint
emugl->setMinimumSize(0, 0);
emugl->setMaximumSize(QWIDGETSIZE_MAX, QWIDGETSIZE_MAX);
ui->centralwidget->setFixedSize(QWIDGETSIZE_MAX, QWIDGETSIZE_MAX);
setFixedSize(QWIDGETSIZE_MAX, QWIDGETSIZE_MAX);
showFullScreen();
int width = (int) QApplication::desktop()->screenGeometry().width();
int height = (int) QApplication::desktop()->screenGeometry().height();
PSP_CoreParameter().pixelWidth = width;
PSP_CoreParameter().pixelHeight = height;
PSP_CoreParameter().outputWidth = width;
PSP_CoreParameter().outputHeight = height;
PSP_CoreParameter().renderWidth = width;
PSP_CoreParameter().renderHeight = height;
pixel_xres = width;
pixel_yres = height;
dp_xres = pixel_xres;
dp_yres = pixel_yres;
if (gpu)
gpu->Resized();
InitPadLayout();
if (globalUIState == UISTATE_INGAME && !g_Config.bShowTouchControls)
QApplication::setOverrideCursor(QCursor(Qt::BlankCursor));
}
}
示例14: Q_ASSERT
bool FixtureConsole::loadXML(QDomDocument* doc, QDomElement* root)
{
bool visible = false;
int x = 0;
int y = 0;
int w = 0;
int h = 0;
QDomNode node;
QDomElement tag;
Q_ASSERT(doc != NULL);
Q_ASSERT(root != NULL);
if (root->tagName() != KXMLQLCFixtureConsole)
{
qWarning("Fixture console node not found!");
return false;
}
node = root->firstChild();
while (node.isNull() == false)
{
tag = node.toElement();
if (tag.tagName() == KXMLQLCWindowState)
{
FileHandler::loadXMLWindowState(&tag, &x, &y, &w, &h,
&visible);
}
else
{
qDebug("Unknown fixture console tag: %s",
(const char*) tag.tagName());
}
node = node.nextSibling();
}
hide();
setGeometry(x, y, w, h);
if (visible == false)
showMinimized();
else
showNormal();
return true;
}
示例15: setUnifiedTitleAndToolBarOnMac
void UIYabause::fullscreenRequested( bool f )
{
if ( isFullScreen() && !f )
{
#ifdef USE_UNIFIED_TITLE_TOOLBAR
setUnifiedTitleAndToolBarOnMac( true );
#endif
toggleFullscreen(0, 0, false, -1 );
showNormal();
VolatileSettings* vs = QtYabause::volatileSettings();
int menubarHide = vs->value( "View/Menubar" ).toInt();
if ( menubarHide == BD_HIDEFS ||
menubarHide == BD_SHOWONFSHOVER)
menubar->show();
if ( vs->value( "View/Toolbar" ).toInt() == BD_HIDEFS )
toolBar->show();
setCursor(Qt::ArrowCursor);
hideMouseTimer->stop();
}
else if ( !isFullScreen() && f )
{
#ifdef USE_UNIFIED_TITLE_TOOLBAR
setUnifiedTitleAndToolBarOnMac( false );
#endif
VolatileSettings* vs = QtYabause::volatileSettings();
setMaximumSize( QWIDGETSIZE_MAX, QWIDGETSIZE_MAX );
setMinimumSize( 0,0 );
toggleFullscreen(vs->value("Video/FullscreenWidth").toInt(), vs->value("Video/FullscreenHeight").toInt(),
f, vs->value("Video/VideoFormat").toInt());
showFullScreen();
if ( vs->value( "View/Menubar" ).toInt() == BD_HIDEFS )
menubar->hide();
if ( vs->value( "View/Toolbar" ).toInt() == BD_HIDEFS )
toolBar->hide();
hideMouseTimer->start(3 * 1000);
}
if ( aViewFullscreen->isChecked() != f )
aViewFullscreen->setChecked( f );
aViewFullscreen->setIcon( QIcon( f ? ":/actions/no_fullscreen.png" : ":/actions/fullscreen.png" ) );
}