commit
e547056664
|
@ -73,7 +73,6 @@ QString DisplayManager::getDisplayType()
|
||||||
|
|
||||||
void DisplayManager::switchToGreeter()
|
void DisplayManager::switchToGreeter()
|
||||||
{
|
{
|
||||||
qDebug()<<"111111111111111111111111111111111111111111111111111111";
|
|
||||||
if(_displayType == "lightdm"){
|
if(_displayType == "lightdm"){
|
||||||
QDBusMessage ret = dmSeatService->call("SwitchToGreeter");
|
QDBusMessage ret = dmSeatService->call("SwitchToGreeter");
|
||||||
handleDBusError(ret);
|
handleDBusError(ret);
|
||||||
|
|
|
@ -849,7 +849,6 @@ void FullBackgroundWidget::showScreensaver(bool isPreview/* = false*/)
|
||||||
} else {
|
} else {
|
||||||
saverWidget->setGeometry(screen->geometry());
|
saverWidget->setGeometry(screen->geometry());
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
setCursor(Qt::BlankCursor);
|
setCursor(Qt::BlankCursor);
|
||||||
|
|
||||||
|
@ -1206,6 +1205,8 @@ void FullBackgroundWidget::onDesktopResized()
|
||||||
//repaint();
|
//repaint();
|
||||||
update();
|
update();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
PlasmaShellManager::getInstance()->setPos(this->windowHandle(),QPoint(0,0));
|
||||||
}
|
}
|
||||||
|
|
||||||
void FullBackgroundWidget::laterInhibit(bool val)
|
void FullBackgroundWidget::laterInhibit(bool val)
|
||||||
|
@ -1345,6 +1346,10 @@ QList<quint64> FullBackgroundWidget::GetSubWndIds()
|
||||||
void FullBackgroundWidget::raiseOtherWnd()
|
void FullBackgroundWidget::raiseOtherWnd()
|
||||||
{
|
{
|
||||||
//qDebug()<<"raiseOtherWnd----:"<<m_listWndIds.size();
|
//qDebug()<<"raiseOtherWnd----:"<<m_listWndIds.size();
|
||||||
|
|
||||||
|
if(!QX11Info::isPlatformX11())
|
||||||
|
return ;
|
||||||
|
|
||||||
for (auto wndId : m_listWndIds) {
|
for (auto wndId : m_listWndIds) {
|
||||||
XRaiseWindow(QX11Info::display(), wndId);
|
XRaiseWindow(QX11Info::display(), wndId);
|
||||||
XFlush(QX11Info::display());
|
XFlush(QX11Info::display());
|
||||||
|
|
|
@ -93,6 +93,7 @@ bool PlasmaShellManager::setPos(QWindow *window, const QPoint &pos)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
plasmaShellSurface->setPosition(pos);
|
plasmaShellSurface->setPosition(pos);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -216,7 +216,6 @@ void PowerManager::powerClicked(QListWidgetItem *item)
|
||||||
lasttime = QTime::currentTime();
|
lasttime = QTime::currentTime();
|
||||||
|
|
||||||
QString name = itemWidget(item)->objectName();
|
QString name = itemWidget(item)->objectName();
|
||||||
printf("111111111111111111111111111 name = %s\n",name.toLatin1().data());
|
|
||||||
// if(name == lockWidget->objectName())
|
// if(name == lockWidget->objectName())
|
||||||
// lockWidgetClicked();
|
// lockWidgetClicked();
|
||||||
if(switchWidget && name == switchWidget->objectName())
|
if(switchWidget && name == switchWidget->objectName())
|
||||||
|
|
|
@ -106,7 +106,7 @@ void ScreenSaverWidget::paintEvent(QPaintEvent *event)
|
||||||
if(!screensaver->exists())
|
if(!screensaver->exists())
|
||||||
{
|
{
|
||||||
QPainter painter(this);
|
QPainter painter(this);
|
||||||
painter.fillRect(geometry(), Qt::black);
|
painter.fillRect(0,0,this->width(),this->height(), Qt::black);
|
||||||
}
|
}
|
||||||
if(screensaver->mode == SAVER_IMAGE) {
|
if(screensaver->mode == SAVER_IMAGE) {
|
||||||
switch(screensaver->effect) {
|
switch(screensaver->effect) {
|
||||||
|
@ -115,7 +115,7 @@ void ScreenSaverWidget::paintEvent(QPaintEvent *event)
|
||||||
QPixmap pixmap(screensaver->path);
|
QPixmap pixmap(screensaver->path);
|
||||||
pixmap.scaled(size(), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
|
pixmap.scaled(size(), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
|
||||||
QPainter painter(this);
|
QPainter painter(this);
|
||||||
painter.drawPixmap(geometry(), pixmap);
|
painter.drawPixmap(0,0,this->width(),this->height(), pixmap);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case TRANSITION_FADE_IN_OUT:
|
case TRANSITION_FADE_IN_OUT:
|
||||||
|
@ -124,17 +124,15 @@ void ScreenSaverWidget::paintEvent(QPaintEvent *event)
|
||||||
QPixmap pixmap1(screensaver->lastPath);
|
QPixmap pixmap1(screensaver->lastPath);
|
||||||
pixmap1.scaled(size(), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
|
pixmap1.scaled(size(), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
|
||||||
painter.setOpacity(opacity);
|
painter.setOpacity(opacity);
|
||||||
painter.drawPixmap(geometry(), pixmap1);
|
painter.drawPixmap(0,0,this->width(),this->height(), pixmap1);
|
||||||
|
|
||||||
QPixmap pixmap(screensaver->path);
|
QPixmap pixmap(screensaver->path);
|
||||||
pixmap.scaled(size(), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
|
pixmap.scaled(size(), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
|
||||||
painter.setOpacity(1 - opacity);
|
painter.setOpacity(1 - opacity);
|
||||||
painter.drawPixmap(geometry(), pixmap);
|
painter.drawPixmap(0,0,this->width(),this->height(), pixmap);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
return QWidget::paintEvent(event);
|
return QWidget::paintEvent(event);
|
||||||
}
|
}
|
||||||
|
@ -174,7 +172,7 @@ void ScreenSaverWidget::embedXScreensaver(const QString &path)
|
||||||
void ScreenSaverWidget::resizeEvent(QResizeEvent *event)
|
void ScreenSaverWidget::resizeEvent(QResizeEvent *event)
|
||||||
{
|
{
|
||||||
if(m_screensaver){
|
if(m_screensaver){
|
||||||
m_screensaver->setGeometry(this->geometry());
|
m_screensaver->setGeometry(0,0,this->width(),this->height());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -227,7 +227,7 @@ int main(int argc, char *argv[])
|
||||||
|
|
||||||
#ifndef USE_INTEL
|
#ifndef USE_INTEL
|
||||||
if (QString(qgetenv("XDG_SESSION_TYPE")) == "wayland")
|
if (QString(qgetenv("XDG_SESSION_TYPE")) == "wayland")
|
||||||
window->showFullScreen();
|
window->show();
|
||||||
else
|
else
|
||||||
window->show();
|
window->show();
|
||||||
window->activateWindow();
|
window->activateWindow();
|
||||||
|
|
Loading…
Reference in New Issue