Merge branch 'KDE/4.11'
Conflicts: kcontrol/workspaceoptions/workspaceoptions.desktop kwin/sm.cpp
This commit is contained in:
commit
ffaa9d336e
7 changed files with 25 additions and 26 deletions
|
@ -144,6 +144,7 @@ void LogoutEffect::prePaintScreen(ScreenPrePaintData& data, int time)
|
|||
data.mask |= PAINT_SCREEN_WITH_TRANSFORMED_WINDOWS;
|
||||
}
|
||||
|
||||
data.paint |= effects->clientArea(FullArea, 0, 0);
|
||||
effects->prePaintScreen(data, time);
|
||||
}
|
||||
|
||||
|
|
|
@ -285,15 +285,8 @@ void EglOnXBackend::present()
|
|||
if (lastDamage().isEmpty())
|
||||
return;
|
||||
|
||||
if (supportsBufferAge()) {
|
||||
eglSwapBuffers(dpy, surface);
|
||||
eglQuerySurface(dpy, surface, EGL_BUFFER_AGE_EXT, &m_bufferAge);
|
||||
setLastDamage(QRegion());
|
||||
return;
|
||||
}
|
||||
|
||||
const QRegion displayRegion(0, 0, displayWidth(), displayHeight());
|
||||
const bool fullRepaint = (lastDamage() == displayRegion);
|
||||
const bool fullRepaint = supportsBufferAge() || (lastDamage() == displayRegion);
|
||||
|
||||
if (fullRepaint || !surfaceHasSubPost) {
|
||||
if (gs_tripleBufferNeedsDetection) {
|
||||
|
@ -321,6 +314,9 @@ void EglOnXBackend::present()
|
|||
setBlocksForRetrace(result == 'd');
|
||||
}
|
||||
}
|
||||
if (supportsBufferAge()) {
|
||||
eglQuerySurface(dpy, surface, EGL_BUFFER_AGE_EXT, &m_bufferAge);
|
||||
}
|
||||
} else {
|
||||
// a part of the screen changed, and we can use eglPostSubBufferNV to copy the updated area
|
||||
foreach (const QRect & r, lastDamage().rects()) {
|
||||
|
@ -329,8 +325,10 @@ void EglOnXBackend::present()
|
|||
}
|
||||
|
||||
setLastDamage(QRegion());
|
||||
eglWaitGL();
|
||||
xcb_flush(connection());
|
||||
if (!supportsBufferAge()) {
|
||||
eglWaitGL();
|
||||
xcb_flush(connection());
|
||||
}
|
||||
}
|
||||
|
||||
void EglOnXBackend::screenGeometryChanged(const QSize &size)
|
||||
|
|
|
@ -3120,6 +3120,8 @@ void Client::setQuickTileMode(QuickTileMode mode, bool keyboard)
|
|||
if (!isResizable() && maximizeMode() != MaximizeFull)
|
||||
return;
|
||||
|
||||
GeometryUpdatesBlocker blocker(this);
|
||||
|
||||
if (mode == QuickTileMaximize) {
|
||||
TabSynchronizer syncer(this, TabGroup::QuickTile|TabGroup::Geometry|TabGroup::Maximized);
|
||||
quick_tile_mode = QuickTileNone;
|
||||
|
|
|
@ -443,15 +443,8 @@ void GlxBackend::present()
|
|||
if (lastDamage().isEmpty())
|
||||
return;
|
||||
|
||||
if (supportsBufferAge()) {
|
||||
glXSwapBuffers(display(), glxWindow);
|
||||
glXQueryDrawable(display(), glxWindow, GLX_BACK_BUFFER_AGE_EXT, (GLuint *) &m_bufferAge);
|
||||
setLastDamage(QRegion());
|
||||
return;
|
||||
}
|
||||
|
||||
const QRegion displayRegion(0, 0, displayWidth(), displayHeight());
|
||||
const bool fullRepaint = (lastDamage() == displayRegion);
|
||||
const bool fullRepaint = supportsBufferAge() || (lastDamage() == displayRegion);
|
||||
|
||||
if (fullRepaint) {
|
||||
if (haveSwapInterval) {
|
||||
|
@ -483,6 +476,9 @@ void GlxBackend::present()
|
|||
waitSync();
|
||||
glXSwapBuffers(display(), glxWindow);
|
||||
}
|
||||
if (supportsBufferAge()) {
|
||||
glXQueryDrawable(display(), glxWindow, GLX_BACK_BUFFER_AGE_EXT, (GLuint *) &m_bufferAge);
|
||||
}
|
||||
} else if (glXCopySubBuffer) {
|
||||
foreach (const QRect & r, lastDamage().rects()) {
|
||||
// convert to OpenGL coordinates
|
||||
|
@ -495,9 +491,11 @@ void GlxBackend::present()
|
|||
glDrawBuffer(GL_BACK);
|
||||
}
|
||||
|
||||
glXWaitGL();
|
||||
setLastDamage(QRegion());
|
||||
XFlush(display());
|
||||
if (!supportsBufferAge()) {
|
||||
glXWaitGL();
|
||||
XFlush(display());
|
||||
}
|
||||
}
|
||||
|
||||
void GlxBackend::screenGeometryChanged(const QSize &size)
|
||||
|
|
|
@ -29,6 +29,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
#include "activities.h"
|
||||
#endif
|
||||
#include "cursor.h"
|
||||
#include "decorations.h"
|
||||
#include <QX11Info>
|
||||
#include "rules.h"
|
||||
#include "group.h"
|
||||
|
@ -319,7 +320,7 @@ bool Client::manage(xcb_window_t w, bool isMapped)
|
|||
// Create client group if the window will have a decoration
|
||||
bool dontKeepInArea = false;
|
||||
setTabGroup(NULL);
|
||||
if (!noBorder()) {
|
||||
if (!noBorder() && DecorationPlugin::self()->supportsTabbing()) {
|
||||
const bool autogrouping = rules()->checkAutogrouping(options->isAutogroupSimilarWindows());
|
||||
const bool autogroupInFg = rules()->checkAutogroupInForeground(options->isAutogroupInForeground());
|
||||
// Automatically add to previous groups on session restore
|
||||
|
|
4
sm.cpp
4
sm.cpp
|
@ -129,7 +129,6 @@ void Workspace::storeClient(KConfigGroup &cg, int num, Client *c)
|
|||
cg.writeEntry(QStringLiteral("sessionId") + n, c->sessionId().constData());
|
||||
cg.writeEntry(QStringLiteral("windowRole") + n, c->windowRole().constData());
|
||||
cg.writeEntry(QStringLiteral("wmCommand") + n, c->wmCommand().constData());
|
||||
cg.writeEntry(QStringLiteral("wmClientMachine") + n, c->wmClientMachine(true).constData());
|
||||
cg.writeEntry(QStringLiteral("resourceName") + n, c->resourceName().constData());
|
||||
cg.writeEntry(QStringLiteral("resourceClass") + n, c->resourceClass().constData());
|
||||
cg.writeEntry(QStringLiteral("geometry") + n, QRect(c->calculateGravitation(true), c->clientSize())); // FRAME
|
||||
|
@ -216,7 +215,6 @@ void Workspace::addSessionInfo(KConfigGroup &cg)
|
|||
info->sessionId = cg.readEntry(QStringLiteral("sessionId") + n, QString()).toLatin1();
|
||||
info->windowRole = cg.readEntry(QStringLiteral("windowRole") + n, QString()).toLatin1();
|
||||
info->wmCommand = cg.readEntry(QStringLiteral("wmCommand") + n, QString()).toLatin1();
|
||||
info->wmClientMachine = cg.readEntry(QStringLiteral("wmClientMachine") + n, QString()).toLatin1();
|
||||
info->resourceName = cg.readEntry(QStringLiteral("resourceName") + n, QString()).toLatin1();
|
||||
info->resourceClass = cg.readEntry(QStringLiteral("resourceClass") + n, QString()).toLower().toLatin1();
|
||||
info->geometry = cg.readEntry(QStringLiteral("geometry") + n, QRect());
|
||||
|
@ -266,7 +264,6 @@ SessionInfo* Workspace::takeSessionInfo(Client* c)
|
|||
QByteArray sessionId = c->sessionId();
|
||||
QByteArray windowRole = c->windowRole();
|
||||
QByteArray wmCommand = c->wmCommand();
|
||||
QByteArray wmClientMachine = c->wmClientMachine(true);
|
||||
QByteArray resourceName = c->resourceName();
|
||||
QByteArray resourceClass = c->resourceClass();
|
||||
|
||||
|
@ -299,7 +296,6 @@ SessionInfo* Workspace::takeSessionInfo(Client* c)
|
|||
break;
|
||||
if (info->resourceName == resourceName
|
||||
&& info->resourceClass == resourceClass
|
||||
&& info->wmClientMachine == wmClientMachine
|
||||
&& sessionInfoWindowTypeMatch(c, info)) {
|
||||
if (wmCommand.isEmpty() || info->wmCommand == wmCommand) {
|
||||
realInfo = info;
|
||||
|
|
|
@ -127,14 +127,17 @@ QByteArray getStringProperty(xcb_window_t w, xcb_atom_t prop, char separator)
|
|||
return QByteArray();
|
||||
}
|
||||
char *data = static_cast<char*>(xcb_get_property_value(property.data()));
|
||||
int length = property->value_len;
|
||||
if (data && separator) {
|
||||
for (uint32_t i = 0; i < property->value_len; ++i) {
|
||||
if (!data[i] && i + 1 < property->value_len) {
|
||||
data[i] = separator;
|
||||
} else {
|
||||
length = i;
|
||||
}
|
||||
}
|
||||
}
|
||||
return QByteArray(data, property->value_len);
|
||||
return QByteArray(data, length);
|
||||
}
|
||||
|
||||
#ifndef KCMRULES
|
||||
|
|
Loading…
Reference in a new issue