本文整理汇总了C++中StHandle::isFullScreen方法的典型用法代码示例。如果您正苦于以下问题:C++ StHandle::isFullScreen方法的具体用法?C++ StHandle::isFullScreen怎么用?C++ StHandle::isFullScreen使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类StHandle
的用法示例。
在下文中一共展示了StHandle::isFullScreen方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: stWindowLoop
void StActiveXCtrl::stWindowLoop() {
// do not load plugin until it is placed on screen
StWindow aParentWin(myResMgr, myParentWin);
for(;;) {
if(aParentWin.isParentOnScreen()) {
break;
}
StThread::sleep(10);
if(myToQuit) {
return;
}
}
myStApp = new StImageViewer(myResMgr, myParentWin, new StOpenInfo());
if(!myStApp->open()) {
myStApp.nullify();
return;
}
bool isFullscreen = false;
myIsActive = true;
for(;;) {
if(myStApp->closingDown()) {
myStApp.nullify();
myIsActive = false;
return;
}
myIsActive = myStApp->isActive();
if(myToQuit) {
myStApp->exit(0);
} else if(myOpenEvent.check()
&& myStApp->isActive()) {
// load the image
myStApp->open(myOpenInfo);
myOpenEvent.reset();
}
StHandle<StWindow> aWin = myStApp->getMainWindow();
if(myIsActive) {
aWin->show();
} else {
aWin->hide();
}
myStApp->processEvents();
if(aWin->isFullScreen()) {
if(!isFullscreen) {
PostMessage(WM_TIMER, 1);
isFullscreen = true;
}
} else if(isFullscreen) {
PostMessage(WM_TIMER, 0);
isFullscreen = false;
}
}
}
示例2: stWindowLoop
void StBrowserPlugin::stWindowLoop() {
// do not load plugin until it is placed on screen
StWindow aParentWin(myResMgr, myParentWin);
for(;;) {
#ifndef _WIN32
const int32_t anActiveNb =
#endif
ST_PLUGIN_QUEUE.increment();
if(aParentWin.isParentOnScreen()
#ifndef _WIN32
|| anActiveNb <= 1
#endif
) {
break;
}
ST_PLUGIN_QUEUE.decrement();
StThread::sleep(10);
if(myToQuit) {
return;
}
}
// Load image viewer
myStApp = new StImageViewer(myResMgr, myParentWin, new StOpenInfo());
if(!myStApp->open()) {
ST_PLUGIN_QUEUE.decrement();
myStApp.nullify();
return;
}
ST_PLUGIN_QUEUE.decrement();
bool isFileOpened = false;
bool isFullscreen = false;
bool isFullLoaded = false;
myIsActive = true;
for(;;) {
if(myStApp->closingDown()) {
myStApp.nullify();
myIsActive = false;
return;
}
myIsActive = myStApp->isActive();
if(myToQuit) {
myStApp->exit(0);
} else if(!isFileOpened
&& myIsActive) {
// load the image
StMutexAuto aLock(myMutex);
if(myPreviewUrl.isEmpty()) {
if(!myFullPath.isEmpty()) {
myOpenInfo.setPath(myFullPath);
aLock.unlock();
myStApp->open(myOpenInfo);
isFileOpened = true;
}
} else if(!myPreviewPath.isEmpty()) {
myOpenInfo.setPath(myPreviewPath);
aLock.unlock();
myStApp->open(myOpenInfo);
isFileOpened = true;
}
}
StHandle<StWindow> aWin = myStApp->getMainWindow();
if(myIsActive) {
aWin->show();
} else {
aWin->hide();
}
myStApp->processEvents();
if(aWin->isFullScreen()) {
StMutexAuto aLock(myMutex);
if(!isFullscreen && !myFullPath.isEmpty()) {
myOpenInfo.setPath(myFullPath);
aLock.unlock();
myStApp->open(myOpenInfo);
isFullscreen = true;
} else if(!isFullLoaded && NPNFuncs.pluginthreadasynccall != NULL) {
aLock.unlock();
NPNFuncs.pluginthreadasynccall(nppInstance, StBrowserPlugin::doLoadFullSize, this);
isFullLoaded = true;
}
} else if(isFullscreen) {
StMutexAuto aLock(myMutex);
if(!myPreviewPath.isEmpty()) {
myOpenInfo.setPath(myPreviewPath);
aLock.unlock();
myStApp->open(myOpenInfo);
isFullscreen = false;
}
}
}
}