Merge lp:~lukas-kde/qtubuntu/liveCaption into lp:qtubuntu

Proposed by Lukáš Tinkl
Status: Merged
Approved by: Daniel d'Andrada
Approved revision: 286
Merged at revision: 281
Proposed branch: lp:~lukas-kde/qtubuntu/liveCaption
Merge into: lp:qtubuntu
Diff against target: 38 lines (+9/-1)
2 files modified
src/ubuntumirclient/window.cpp (+8/-1)
src/ubuntumirclient/window.h (+1/-0)
To merge this branch: bzr merge lp:~lukas-kde/qtubuntu/liveCaption
Reviewer Review Type Date Requested Status
Daniel d'Andrada (community) Approve
PS Jenkins bot continuous-integration Approve
Review via email: mp+272756@code.launchpad.net

Commit message

Override QPlatformWindow::setWindowTitle() and update the caption accordingly

Description of the change

Override QPlatformWindow::setWindowTitle() and update the caption accordingly

Cf. https://bugs.launchpad.net/ubuntu/+source/unity-api/+bug/1497092

* Are there any related MPs required for this MP to build/function as expected? Please list.

No

* Did you perform an exploratory manual test run of your code change and any related functionality?

Yes

* Did you make sure that your branch does not contain spurious tags?

Yes

* If you changed the packaging (debian), did you subscribe the ubuntu-unity team to this MP?

Yes

* If you changed the UI, has there been a design review?

N/A

To post a comment you must log in.
lp:~lukas-kde/qtubuntu/liveCaption updated
283. By Lukáš Tinkl

remove debug

284. By Lukáš Tinkl

recognize the back/forward buttons

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Daniel d'Andrada (dandrader) wrote :

The changes in src/ubuntumirclient/input.cpp are completely unrelated. Please put them in a separate MP.

review: Needs Fixing
Revision history for this message
Daniel d'Andrada (dandrader) wrote :

You should override QPlatformWindow::setWindowTitle instead of listening to QWindow::windowTitleChanged

review: Needs Fixing
Revision history for this message
Daniel d'Andrada (dandrader) wrote :

Should we append the application display name to the window title, as the QPlatformWindow::setWindowTitle suggests?

Revision history for this message
Daniel d'Andrada (dandrader) wrote :

> Should we append the application display name to the window title, as the
> QPlatformWindow::setWindowTitle suggests?

hmm... we might just leave it for a layer higher up, like unity8

lp:~lukas-kde/qtubuntu/liveCaption updated
285. By Lukáš Tinkl

override setWindowTitle()

286. By Lukáš Tinkl

remove unrelated input.cpp changes

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Daniel d'Andrada (dandrader) wrote :

Looks good to me.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/ubuntumirclient/window.cpp'
2--- src/ubuntumirclient/window.cpp 2015-08-28 08:12:42 +0000
3+++ src/ubuntumirclient/window.cpp 2015-09-29 18:14:27 +0000
4@@ -23,7 +23,6 @@
5
6 // Qt
7 #include <qpa/qwindowsysteminterface.h>
8-#include <qpa/qwindowsysteminterface.h>
9 #include <QMutex>
10 #include <QMutexLocker>
11 #include <QSize>
12@@ -410,6 +409,14 @@
13 }
14 }
15
16+void UbuntuWindow::setWindowTitle(const QString &title)
17+{
18+ MirSurfaceSpec *spec = mir_connection_create_spec_for_changes(d->connection);
19+ mir_surface_spec_set_name(spec, title.toUtf8().constData());
20+ mir_surface_apply_spec(d->surface, spec);
21+ mir_surface_spec_release(spec);
22+}
23+
24 void* UbuntuWindow::eglSurface() const
25 {
26 return d->eglSurface;
27
28=== modified file 'src/ubuntumirclient/window.h'
29--- src/ubuntumirclient/window.h 2015-05-12 17:30:15 +0000
30+++ src/ubuntumirclient/window.h 2015-09-29 18:14:27 +0000
31@@ -40,6 +40,7 @@
32 void setGeometry(const QRect&) override;
33 void setWindowState(Qt::WindowState state) override;
34 void setVisible(bool visible) override;
35+ void setWindowTitle(const QString &title) override;
36
37 // New methods.
38 void* eglSurface() const;

Subscribers

People subscribed via source and target branches