Merge branch 'Plasma/5.8'

icc-effect-5.14.5
Martin Gräßlin 2016-11-07 11:41:30 +01:00
commit d9612b327c
8 changed files with 16 additions and 8 deletions

View File

@ -30,6 +30,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include <QAbstractEventDispatcher>
#include <QPluginLoader>
#include <QSocketNotifier>
#include <QStyle>
#include <QThread>
#include <QtConcurrentRun>
@ -80,6 +81,9 @@ WaylandTestApplication::~WaylandTestApplication()
}
waylandServer()->destroyXWaylandConnection();
}
if (QStyle *s = style()) {
s->unpolish(this);
}
waylandServer()->terminateClientConnections();
destroyCompositor();
}

View File

@ -629,9 +629,7 @@ void TestShellClient::testCaptionSimplified()
shellSurface->setTitle(origTitle);
auto c = Test::renderAndWaitForShown(surface.data(), QSize(100, 50), Qt::blue);
QVERIFY(c);
QEXPECT_FAIL("", "BUG 323798", Continue);
QVERIFY(c->caption() != origTitle);
QEXPECT_FAIL("", "BUG 323798", Continue);
QCOMPARE(c->caption(), origTitle.simplified());
}

View File

@ -111,9 +111,7 @@ void X11ClientTest::testCaptionSimplified()
Client *client = windowCreatedSpy.first().first().value<Client*>();
QVERIFY(client);
QCOMPARE(client->window(), w);
QEXPECT_FAIL("", "BUG 323798", Continue);
QVERIFY(client->caption() != QString::fromUtf8(origTitle));
QEXPECT_FAIL("", "BUG 323798", Continue);
QCOMPARE(client->caption(), QString::fromUtf8(origTitle).simplified());
// and destroy the window again

View File

@ -1417,9 +1417,9 @@ void Client::fetchName()
QString Client::readName() const
{
if (info->name() && info->name()[0] != '\0')
return QString::fromUtf8(info->name());
return QString::fromUtf8(info->name()).simplified();
else
return KWindowSystem::readNameProperty(window(), XCB_ATOM_WM_NAME);
return KWindowSystem::readNameProperty(window(), XCB_ATOM_WM_NAME).simplified();
}
// The list is taken from http://www.unicode.org/reports/tr9/ (#154840)

View File

@ -560,6 +560,9 @@ void DesktopGridEffect::windowInputMouseEvent(QEvent* e)
}
} else if ((me->buttons() == Qt::MidButton || me->buttons() == Qt::RightButton) && windowMove == NULL) {
EffectWindow* w = windowAt(me->pos());
if (w && w->isDesktop()) {
w = nullptr;
}
if (w != NULL) {
int desktop = 0;
if (w->isOnAllDesktops()) {

View File

@ -37,6 +37,7 @@ DEALINGS IN THE SOFTWARE.
int main(int argc, char* argv[])
{
KLocalizedString::setApplicationDomain("kwin");
qputenv("QT_QPA_PLATFORM", QByteArrayLiteral("xcb"));
QApplication app(argc, argv);
QApplication::setWindowIcon(QIcon::fromTheme(QStringLiteral("dialog-warning")));
QCoreApplication::setApplicationName(QStringLiteral("kwin_killer_helper"));

View File

@ -45,6 +45,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include <QFutureWatcher>
#include <QProcess>
#include <QSocketNotifier>
#include <QStyle>
#include <QThread>
#include <QDebug>
#include <QWindow>
@ -114,6 +115,9 @@ ApplicationWayland::~ApplicationWayland()
}
waylandServer()->destroyXWaylandConnection();
}
if (QStyle *s = style()) {
s->unpolish(this);
}
waylandServer()->terminateClientConnections();
destroyCompositor();
}

View File

@ -93,12 +93,12 @@ ShellClient::~ShellClient() = default;
template <class T>
void ShellClient::initSurface(T *shellSurface)
{
m_caption = shellSurface->title();
m_caption = shellSurface->title().simplified();
connect(shellSurface, &T::titleChanged, this, &ShellClient::captionChanged);
connect(shellSurface, &T::destroyed, this, &ShellClient::destroyClient);
connect(shellSurface, &T::titleChanged, this,
[this] (const QString &s) {
m_caption = s;
m_caption = s.simplified();
emit captionChanged();
}
);