on xenial help sign in
Merge trunk
21a944dMichal Hruby
debian/changelog+7
@@ -1,3 +1,10 @@
1+unity8 (7.86+14.10.20140507.3-0ubuntu1) utopic; urgency=low
2+
3+ [ Michał Sawicz ]
4+ * Remove HUD from the bottom edge. Again.
5+
6+ -- Ubuntu daily release <ps-jenkins@lists.canonical.com> Wed, 07 May 2014 11:14:30 +0000
7+
1unity8 (7.86+14.10.20140505-0ubuntu1) utopic; urgency=low
8unity8 (7.86+14.10.20140505-0ubuntu1) utopic; urgency=low
2
9
3 [ Ted Gould ]
10 [ Ted Gould ]
debian/unity8.install−1
@@ -1,7 +1,6 @@
1data/unity8.conf usr/share/upstart/sessions/
1data/unity8.conf usr/share/upstart/sessions/
2usr/bin/unity8
2usr/bin/unity8
3usr/share/applications/unity8.desktop
3usr/share/applications/unity8.desktop
4−usr/share/unity8/Bottombar
5usr/share/unity8/Greeter
4usr/share/unity8/Greeter
6usr/share/unity8/Hud
5usr/share/unity8/Hud
7usr/share/unity8/Launcher
6usr/share/unity8/Launcher
plugins/Utils/CMakeLists.txt−1
@@ -11,7 +11,6 @@ include_directories(
11)
11)
12
12
13set(QMLPLUGIN_SRC
13set(QMLPLUGIN_SRC
14− bottombarvisibilitycommunicatorshell.cpp
15 qlimitproxymodelqml.cpp
14 qlimitproxymodelqml.cpp
16 qsortfilterproxymodelqml.cpp
15 qsortfilterproxymodelqml.cpp
17 timeformatter.cpp
16 timeformatter.cpp
plugins/Utils/bottombarvisibilitycommunicatorshell.cppdeleted−49
@@ -1,49 +0,0 @@
1−/*
2− * Copyright (C) 2012 Canonical, Ltd.
3− *
4− * This program is free software; you can redistribute it and/or modify
5− * it under the terms of the GNU General Public License as published by
6− * the Free Software Foundation; version 3.
7− *
8− * This program is distributed in the hope that it will be useful,
9− * but WITHOUT ANY WARRANTY; without even the implied warranty of
10− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11− * GNU General Public License for more details.
12− *
13− * You should have received a copy of the GNU General Public License
14− * along with this program. If not, see <http://www.gnu.org/licenses/>.
15− */
16−
17−#include "bottombarvisibilitycommunicatorshell.h"
18−
19−BottomBarVisibilityCommunicatorShell::BottomBarVisibilityCommunicatorShell()
20− : m_forceHidden(false),
21− m_position(0)
22−{
23−}
24−
25−bool BottomBarVisibilityCommunicatorShell::forceHidden() const
26−{
27− return m_forceHidden;
28−}
29−
30−double BottomBarVisibilityCommunicatorShell::position() const
31−{
32− return m_position;
33−}
34−
35−void BottomBarVisibilityCommunicatorShell::setForceHidden(bool forceHidden)
36−{
37− if (forceHidden != m_forceHidden) {
38− m_forceHidden = forceHidden;
39− Q_EMIT forceHiddenChanged(forceHidden);
40− }
41−}
42−
43−void BottomBarVisibilityCommunicatorShell::setPosition(double position)
44−{
45− if (position != m_position) {
46− m_position = position;
47− Q_EMIT positionChanged(position);
48− }
49−}
plugins/Utils/bottombarvisibilitycommunicatorshell.hdeleted−59
@@ -1,59 +0,0 @@
1−/*
2− * Copyright (C) 2012 Canonical, Ltd.
3− *
4− * This program is free software; you can redistribute it and/or modify
5− * it under the terms of the GNU General Public License as published by
6− * the Free Software Foundation; version 3.
7− *
8− * This program is distributed in the hope that it will be useful,
9− * but WITHOUT ANY WARRANTY; without even the implied warranty of
10− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11− * GNU General Public License for more details.
12− *
13− * You should have received a copy of the GNU General Public License
14− * along with this program. If not, see <http://www.gnu.org/licenses/>.
15− */
16−
17−#ifndef BOTTOMBARVISIBILITYCOMMUNICATORSHELL_H
18−#define BOTTOMBARVISIBILITYCOMMUNICATORSHELL_H
19−
20−#include <QObject>
21−
22−class QDBusInterface;
23−
24−/** This is an internal class used to talk with the bottom bar used by either
25− * applications or the SDK.
26− * There is a method to force the bottom bar to be hidden or otherwise behave as usual
27− */
28−
29−class BottomBarVisibilityCommunicatorShell : public QObject
30−{
31− Q_OBJECT
32− Q_PROPERTY(bool forceHidden READ forceHidden WRITE setForceHidden NOTIFY forceHiddenChanged)
33− Q_PROPERTY(double position READ position WRITE setPosition NOTIFY positionChanged)
34−
35− Q_CLASSINFO("D-Bus Interface", "com.canonical.Shell.BottomBarVisibilityCommunicator")
36−public:
37− static BottomBarVisibilityCommunicatorShell& instance() {
38− static BottomBarVisibilityCommunicatorShell instance;
39− return instance;
40− }
41−
42− bool forceHidden() const;
43− void setForceHidden(bool forceHidden);
44−
45− double position() const;
46− void setPosition(double position);
47−
48−Q_SIGNALS:
49− void forceHiddenChanged(bool forceHidden);
50− void positionChanged(double position);
51−
52−private:
53− BottomBarVisibilityCommunicatorShell();
54−
55− bool m_forceHidden;
56− double m_position;
57−};
58−
59−#endif
plugins/Utils/plugin.cpp−10
@@ -26,16 +26,12 @@
26#include "plugin.h"
26#include "plugin.h"
27
27
28// local
28// local
29−#include "bottombarvisibilitycommunicatorshell.h"
30#include "qlimitproxymodelqml.h"
29#include "qlimitproxymodelqml.h"
31#include "qsortfilterproxymodelqml.h"
30#include "qsortfilterproxymodelqml.h"
32#include "timeformatter.h"
31#include "timeformatter.h"
33#include "unitymenumodelpaths.h"
32#include "unitymenumodelpaths.h"
34#include "easingcurve.h"
33#include "easingcurve.h"
35
34
36−static const char* BOTTOM_BAR_VISIBILITY_COMMUNICATOR_DBUS_PATH = "/BottomBarVisibilityCommunicator";
37−static const char* DBUS_SERVICE = "com.canonical.Shell.BottomBarVisibilityCommunicator";
38−
39void UtilsPlugin::registerTypes(const char *uri)
35void UtilsPlugin::registerTypes(const char *uri)
40{
36{
41 Q_ASSERT(uri == QLatin1String("Utils"));
37 Q_ASSERT(uri == QLatin1String("Utils"));
@@ -45,16 +41,10 @@ void UtilsPlugin::registerTypes(const char *uri)
45 qmlRegisterType<UnityMenuModelPaths>(uri, 0, 1, "UnityMenuModelPaths");
41 qmlRegisterType<UnityMenuModelPaths>(uri, 0, 1, "UnityMenuModelPaths");
46 qmlRegisterType<TimeFormatter>(uri, 0, 1, "TimeFormatter");
42 qmlRegisterType<TimeFormatter>(uri, 0, 1, "TimeFormatter");
47 qmlRegisterType<GDateTimeFormatter>(uri, 0, 1, "GDateTimeFormatter");
43 qmlRegisterType<GDateTimeFormatter>(uri, 0, 1, "GDateTimeFormatter");
48− qmlRegisterUncreatableType<BottomBarVisibilityCommunicatorShell>(uri, 0, 1, "BottomBarVisibilityCommunicatorShell", "Can't create BottomBarVisibilityCommunicatorShell");
49 qmlRegisterType<EasingCurve>(uri, 0, 1, "EasingCurve");
44 qmlRegisterType<EasingCurve>(uri, 0, 1, "EasingCurve");
50}
45}
51
46
52void UtilsPlugin::initializeEngine(QQmlEngine *engine, const char *uri)
47void UtilsPlugin::initializeEngine(QQmlEngine *engine, const char *uri)
53{
48{
54 QQmlExtensionPlugin::initializeEngine(engine, uri);
49 QQmlExtensionPlugin::initializeEngine(engine, uri);
55−
56− QDBusConnection::sessionBus().registerService(DBUS_SERVICE);
57− BottomBarVisibilityCommunicatorShell *bottomBarVisibilityCommunicator = &BottomBarVisibilityCommunicatorShell::instance();
58− QDBusConnection::sessionBus().registerObject(BOTTOM_BAR_VISIBILITY_COMMUNICATOR_DBUS_PATH, bottomBarVisibilityCommunicator, QDBusConnection::ExportAllContents);
59− engine->rootContext()->setContextProperty("bottomBarVisibilityCommunicatorShell", bottomBarVisibilityCommunicator);
60}
50}
po/lv.po+21−21
@@ -8,27 +8,27 @@ msgstr ""
8"Project-Id-Version: unity\n"
8"Project-Id-Version: unity\n"
9"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
9"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
10"POT-Creation-Date: 2014-04-10 11:13-0400\n"
10"POT-Creation-Date: 2014-04-10 11:13-0400\n"
11−"PO-Revision-Date: 2014-01-11 16:48+0000\n"
11+"PO-Revision-Date: 2014-05-07 18:17+0000\n"
12"Last-Translator: Jānis-Marks Gailis <jeanmarc.gailis@gmail.com>\n"
12"Last-Translator: Jānis-Marks Gailis <jeanmarc.gailis@gmail.com>\n"
13"Language-Team: Latvian <lv@li.org>\n"
13"Language-Team: Latvian <lv@li.org>\n"
14"MIME-Version: 1.0\n"
14"MIME-Version: 1.0\n"
15"Content-Type: text/plain; charset=UTF-8\n"
15"Content-Type: text/plain; charset=UTF-8\n"
16"Content-Transfer-Encoding: 8bit\n"
16"Content-Transfer-Encoding: 8bit\n"
17−"X-Launchpad-Export-Date: 2014-05-01 06:43+0000\n"
17+"X-Launchpad-Export-Date: 2014-05-08 06:40+0000\n"
18−"X-Generator: Launchpad (build 16985)\n"
18+"X-Generator: Launchpad (build 16996)\n"
19
19
20#: plugins/Unity/Launcher/launcheritem.cpp:43
20#: plugins/Unity/Launcher/launcheritem.cpp:43
21#: plugins/Unity/Launcher/launcheritem.cpp:73
21#: plugins/Unity/Launcher/launcheritem.cpp:73
22msgid "Lock to Launcher"
22msgid "Lock to Launcher"
23−msgstr ""
23+msgstr "Pieslēgt palaidējam"
24
24
25#: plugins/Unity/Launcher/launcheritem.cpp:73
25#: plugins/Unity/Launcher/launcheritem.cpp:73
26msgid "Unlock from Launcher"
26msgid "Unlock from Launcher"
27−msgstr ""
27+msgstr "Atslēgt no palaidēja"
28
28
29#: qml/Components/EdgeDemoOverlay.qml:151
29#: qml/Components/EdgeDemoOverlay.qml:151
30msgid "Skip intro"
30msgid "Skip intro"
31−msgstr ""
31+msgstr "Izlaist Intro"
32
32
33#: qml/Components/EdgeDemo.qml:113
33#: qml/Components/EdgeDemo.qml:113
34msgid "Right edge"
34msgid "Right edge"
@@ -36,7 +36,7 @@ msgstr "Labā mala"
36
36
37#: qml/Components/EdgeDemo.qml:114
37#: qml/Components/EdgeDemo.qml:114
38msgid "Try swiping from the right edge to unlock the phone"
38msgid "Try swiping from the right edge to unlock the phone"
39−msgstr ""
39+msgstr "Mēģiniet iesvelt no labās malas, lai atbloķētu tālruni"
40
40
41#: qml/Components/EdgeDemo.qml:145
41#: qml/Components/EdgeDemo.qml:145
42msgid "Top edge"
42msgid "Top edge"
@@ -44,7 +44,7 @@ msgstr "Augšējā mala"
44
44
45#: qml/Components/EdgeDemo.qml:146
45#: qml/Components/EdgeDemo.qml:146
46msgid "Try swiping from the top edge to access the indicators"
46msgid "Try swiping from the top edge to access the indicators"
47−msgstr ""
47+msgstr "Mēģiniet iesvelt no augšējās malas, lai piekļūt pie indikatoriem"
48
48
49#: qml/Components/EdgeDemo.qml:171
49#: qml/Components/EdgeDemo.qml:171
50msgid "Close"
50msgid "Close"
@@ -78,15 +78,15 @@ msgstr "Nesen veiktās meklēšanas"
78
78
79#: qml/Components/SeeMore.qml:35
79#: qml/Components/SeeMore.qml:35
80msgid "See more"
80msgid "See more"
81−msgstr ""
81+msgstr "Redzēt vairāk"
82
82
83#: qml/Components/SeeMore.qml:58
83#: qml/Components/SeeMore.qml:58
84msgid "See less"
84msgid "See less"
85−msgstr ""
85+msgstr "Redzēt mazāk"
86
86
87#: qml/Dash/DashApps.qml:37
87#: qml/Dash/DashApps.qml:37
88msgid "Recent"
88msgid "Recent"
89−msgstr ""
89+msgstr "Nesens"
90
90
91#: qml/Dash/PreviewListView.qml:52
91#: qml/Dash/PreviewListView.qml:52
92#, qt-format
92#, qt-format
@@ -95,23 +95,23 @@ msgstr ""
95
95
96#: qml/Dash/Previews/PreviewActionCombo.qml:34
96#: qml/Dash/Previews/PreviewActionCombo.qml:34
97msgid "More..."
97msgid "More..."
98−msgstr ""
98+msgstr "Vairāk..."
99
99
100#: qml/Dash/Previews/PreviewActionCombo.qml:34
100#: qml/Dash/Previews/PreviewActionCombo.qml:34
101msgid "Less..."
101msgid "Less..."
102−msgstr ""
102+msgstr "Mazāk..."
103
103
104#: qml/Dash/Previews/PreviewRatingInput.qml:81
104#: qml/Dash/Previews/PreviewRatingInput.qml:81
105msgid "Rate this"
105msgid "Rate this"
106−msgstr ""
106+msgstr "Novērtēt šo"
107
107
108#: qml/Dash/Previews/PreviewRatingInput.qml:126
108#: qml/Dash/Previews/PreviewRatingInput.qml:126
109msgid "Add a review"
109msgid "Add a review"
110−msgstr ""
110+msgstr "Komentēt"
111
111
112#: qml/Dash/Previews/PreviewRatingInput.qml:166
112#: qml/Dash/Previews/PreviewRatingInput.qml:166
113msgid "Send"
113msgid "Send"
114−msgstr ""
114+msgstr "Sūtīt"
115
115
116#: qml/Greeter/Greeter.qml:151
116#: qml/Greeter/Greeter.qml:151
117msgid "Swipe to unlock"
117msgid "Swipe to unlock"
@@ -119,16 +119,16 @@ msgstr ""
119
119
120#: qml/Greeter/Lockscreen.qml:149
120#: qml/Greeter/Lockscreen.qml:149
121msgid "Emergency Call"
121msgid "Emergency Call"
122−msgstr ""
122+msgstr "Neatliekamās Palīdzības zvans"
123
123
124#: qml/Greeter/PassphraseLockscreen.qml:59
124#: qml/Greeter/PassphraseLockscreen.qml:59
125#, qt-format
125#, qt-format
126msgid "Hello %1"
126msgid "Hello %1"
127−msgstr ""
127+msgstr "Sveiki, %1"
128
128
129#: qml/Greeter/PassphraseLockscreen.qml:59
129#: qml/Greeter/PassphraseLockscreen.qml:59
130msgid "Hello"
130msgid "Hello"
131−msgstr ""
131+msgstr "Sveiki"
132
132
133#: qml/Hud/HudParametrizedActionsPage.qml:132
133#: qml/Hud/HudParametrizedActionsPage.qml:132
134msgid "Confirm"
134msgid "Confirm"
@@ -152,7 +152,7 @@ msgstr "Runa..."
152
152
153#: qml/Notifications/NotificationMenuItemFactory.qml:91
153#: qml/Notifications/NotificationMenuItemFactory.qml:91
154msgid "Show password"
154msgid "Show password"
155−msgstr ""
155+msgstr "Rādīt paroli"
156
156
157#: qml/Notifications/NotificationMenuItemFactory.qml:103
157#: qml/Notifications/NotificationMenuItemFactory.qml:103
158msgid "Please enter SIM PIN"
158msgid "Please enter SIM PIN"
@@ -165,4 +165,4 @@ msgstr "Meklēt"
165#: qml/Shell.qml:348
165#: qml/Shell.qml:348
166#, qt-format
166#, qt-format
167msgid "Please enter %1"
167msgid "Please enter %1"
168−msgstr ""
168+msgstr "Lūdzu ievadiet %1"
qml/Bottombar/Bottombar.qmldeleted−227
@@ -1,227 +0,0 @@
1−/*
2− * Copyright (C) 2013 Canonical, Ltd.
3− *
4− * This program is free software; you can redistribute it and/or modify
5− * it under the terms of the GNU General Public License as published by
6− * the Free Software Foundation; version 3.
7− *
8− * This program is distributed in the hope that it will be useful,
9− * but WITHOUT ANY WARRANTY; without even the implied warranty of
10− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11− * GNU General Public License for more details.
12− *
13− * You should have received a copy of the GNU General Public License
14− * along with this program. If not, see <http://www.gnu.org/licenses/>.
15− */
16−
17−import QtQuick 2.0
18−import "../Components"
19−import Utils 0.1
20−import Unity.Application 0.1
21−import Ubuntu.Gestures 0.1
22−import Ubuntu.Components 0.1
23−
24−Item {
25− id: bottombar
26−
27− // Whether there's an application on foreground (as opposed to have shell's Dash on foreground)
28− property bool applicationIsOnForeground
29−
30− property variant theHud
31− property bool enabled: false
32− property bool preventHiding: dragArea.dragging
33− readonly property real bottomEdgeButtonCenterDistance: units.gu(34)
34−
35− state: "hidden"
36−
37− function hide() {
38− dismissTimer.stop()
39− bottombar.state = "hidden"
40− }
41−
42− onApplicationIsOnForegroundChanged: {
43− if (!applicationIsOnForeground) {
44− hide()
45− }
46− }
47−
48− onStateChanged: {
49− if (state == "hidden") {
50− dismissTimer.stop()
51− bottomBarVisibilityCommunicatorShell.forceHidden = false
52− } else {
53− dismissTimer.restart()
54− }
55− }
56−
57− onPreventHidingChanged: {
58− if (!preventHiding) {
59− if (state == "hint" || state == "reveal")
60− hide()
61− }
62−
63− if (dismissTimer.running) {
64− dismissTimer.restart();
65− }
66− }
67−
68− Timer {
69− id: dismissTimer
70− interval: 1000
71− onTriggered: {
72− if (!bottombar.preventHiding) {
73− bottombar.state = "hidden"
74− } else {
75− dismissTimer.restart()
76− }
77− }
78− }
79−
80− HudButton {
81− id: hudButton
82−
83− readonly property bool centeredHud: parent.width < units.gu(68) // Nexus 7 has 67 gu width
84−
85− x: centeredHud ? parent.width / 2 - width / 2 : MathUtils.clamp(dragArea.touchStartX - (width / 2), 0, bottombar.width - width)
86− y: bottombar.height - bottomEdgeButtonCenterDistance - (height / 2) - bottomMargin
87− z: 1
88− visible: opacity != 0
89−
90− mouseOver: {
91− if (dragArea.status === DirectionalDragArea.Recognized) {
92− var touchLocal = mapFromItem(dragArea, dragArea.touchX, dragArea.touchY)
93− return touchLocal.x > 0 && touchLocal.x < width
94− && touchLocal.y > 0 && touchLocal.y < height
95− } else {
96− return false
97− }
98− }
99−
100− onClicked: theHud.show()
101−
102− Behavior on bottomMargin {
103− NumberAnimation{duration: hudButton.opacity < 0.01 ? 200 : 70; easing.type: Easing.OutQuart}
104− }
105−
106− Behavior on opacity {
107− NumberAnimation{duration: 200; easing.type: Easing.OutCubic}
108− }
109− }
110−
111− Connections {
112− target: theHud
113− onShownChanged: {
114− bottomBarVisibilityCommunicatorShell.forceHidden = theHud.shown
115− if (theHud.shown) {
116− bottombar.state = "hidden"
117− }
118− }
119− }
120−
121− EdgeDragArea {
122− id: dragArea
123− objectName: "hudDragArea"
124− width: parent.width
125− height: shell.edgeSize
126− anchors.bottom: parent.bottom
127−
128− distanceThreshold: units.gu(8)
129− enabled: !theHud.shown && bottombar.enabled && applicationIsOnForeground
130− direction: Direction.Upwards
131− maxSilenceTime: 2000
132−
133− property int previousStatus: -1
134− property real touchStartX: -1
135−
136− readonly property real distanceFromThreshold: (-distance) - distanceThreshold // distance is negative
137− readonly property real revealDistance: units.gu(2)
138− readonly property real commitDistance: units.gu(6)
139− readonly property real commitProgress: MathUtils.clamp(distanceFromThreshold / commitDistance, 0, 1)
140−
141− onStatusChanged: {
142− if (status === DirectionalDragArea.WaitingForTouch) {
143− if (previousStatus == DirectionalDragArea.Recognized) {
144− if (hudButton.mouseOver) {
145− hudButton.clicked()
146− }
147− }
148− } else if (status === DirectionalDragArea.Undecided) {
149− if (!hudButton.centeredHud) {
150− touchStartX = touchX
151− }
152− } else if (status === DirectionalDragArea.Recognized) {
153− bottombar.state = "hint"
154− }
155− previousStatus = status
156− }
157−
158− onDistanceChanged: {
159− if (status === DirectionalDragArea.Recognized) {
160− if (distanceFromThreshold > commitDistance)
161− bottombar.state = "shown"
162− else if (distanceFromThreshold > revealDistance)
163− bottombar.state = "reveal"
164− }
165− }
166− }
167−
168− Item {
169− id: dismissArea
170− anchors {
171− top: parent.top
172− left: parent.left
173− right: parent.right
174− }
175− height: parent.height - bottomBarVisibilityCommunicatorShell.position
176−
177− MouseArea {
178− anchors.fill: parent
179− enabled: bottombar.state == "shown"
180− onPressed: {
181− bottomBarVisibilityCommunicatorShell.forceHidden = true
182− bottombar.state = "hidden"
183− }
184− }
185−
186− InputFilterArea {
187− anchors.fill: parent
188− blockInput: (hudButton.opacity == 1)
189− }
190− }
191−
192− MouseArea {
193− anchors {
194− top: dismissArea.bottom
195− left: parent.left
196− right: parent.right
197− bottom: parent.bottom
198− }
199− enabled: bottombar.state == "shown" && bottomBarVisibilityCommunicatorShell.position > 0
200− onPressed: {
201− bottombar.state = "hidden"
202− }
203− }
204−
205− states: [
206− State {
207− name: "hidden"
208− PropertyChanges { target: hudButton; opacity: 0 }
209− PropertyChanges { target: hudButton; bottomMargin: units.gu(-2) }
210− },
211− State {
212− name: "hint"
213− extend: "hidden"
214− PropertyChanges { target: hudButton; opacity: 0.5 }
215− },
216− State {
217− name: "reveal"
218− extend: "hint"
219− PropertyChanges { target: hudButton; bottomMargin: units.gu(-2) + units.gu(2) * dragArea.commitProgress }
220− },
221− State {
222− name: "shown"
223− PropertyChanges { target: hudButton; opacity: 1 }
224− PropertyChanges { target: hudButton; bottomMargin: units.gu(0) }
225− }
226− ]
227−}
qml/Bottombar/HudButton.qmldeleted−64
@@ -1,64 +0,0 @@
1−/*
2− * Copyright (C) 2013 Canonical, Ltd.
3− *
4− * This program is free software; you can redistribute it and/or modify
5− * it under the terms of the GNU General Public License as published by
6− * the Free Software Foundation; version 3.
7− *
8− * This program is distributed in the hope that it will be useful,
9− * but WITHOUT ANY WARRANTY; without even the implied warranty of
10− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11− * GNU General Public License for more details.
12− *
13− * You should have received a copy of the GNU General Public License
14− * along with this program. If not, see <http://www.gnu.org/licenses/>.
15− */
16−
17−import QtQuick 2.0
18−import Ubuntu.Components 0.1
19−
20−Item {
21− id: item
22−
23− property bool mouseOver
24−
25− property int bottomMargin: units.gu(2)
26−
27− signal clicked()
28−
29− readonly property real scaleOnMouseOver: 1.2
30−
31− width: hudButton.width * scaleOnMouseOver
32− height: hudButton.height * scaleOnMouseOver
33−
34− Item {
35− id: hudButton
36−
37− anchors.centerIn: parent
38− height: units.gu(12)
39− width: height
40− opacity: item.mouseOver || abstractButton.pressed ? 1 : 0.7
41− scale: item.mouseOver || abstractButton.pressed ? scaleOnMouseOver : 1
42− Behavior on opacity {NumberAnimation{duration: 200; easing.type: Easing.OutQuart}}
43− Behavior on scale {NumberAnimation{duration: 200; easing.type: Easing.OutQuart}}
44−
45− AbstractButton {
46− id: abstractButton
47− anchors.fill: parent
48− style: Image {
49− anchors.fill: parent
50− source: "graphics/hud_invoke_button_active.png"
51− }
52−
53− onClicked: item.clicked()
54− }
55−
56− Image {
57− width: units.gu(4)
58− height: width
59− source: "graphics/hud.png"
60− anchors.centerIn: parent
61− fillMode: Image.PreserveAspectFit
62− }
63− }
64−}
qml/Bottombar/graphics/hud@20.pngdeleted

Binary file not shown.

qml/Bottombar/graphics/hud_invoke_button_active@20.pngdeleted

Binary file not shown.

qml/CMakeLists.txt−1
@@ -5,7 +5,6 @@ install(FILES ${QML_JS_FILES}
5 )
5 )
6
6
7set(QML_DIRS
7set(QML_DIRS
8− Bottombar
9 Components
8 Components
10 Dash
9 Dash
11 graphics
10 graphics
qml/Shell.qml+3−48
@@ -28,9 +28,7 @@ import "Dash"
28import "Greeter"
28import "Greeter"
29import "Launcher"
29import "Launcher"
30import "Panel"
30import "Panel"
31−import "Hud"
32import "Components"
31import "Components"
33−import "Bottombar"
34import "Notifications"
32import "Notifications"
35import Unity.Notifications 1.0 as NotificationBackend
33import Unity.Notifications 1.0 as NotificationBackend
36
34
@@ -308,7 +306,7 @@ FocusScope {
308
306
309 readonly property int backgroundTopMargin: -panel.panelHeight
307 readonly property int backgroundTopMargin: -panel.panelHeight
310
308
311− hides: [launcher, panel.indicators, hud]
309+ hides: [launcher, panel.indicators]
312 shown: false
310 shown: false
313 enabled: true
311 enabled: true
314 showAnimation: StandardAnimation { property: "opacity"; to: 1 }
312 showAnimation: StandardAnimation { property: "opacity"; to: 1 }
@@ -381,7 +379,7 @@ FocusScope {
381 objectName: "greeter"
379 objectName: "greeter"
382
380
383 available: true
381 available: true
384− hides: [launcher, panel.indicators, hud]
382+ hides: [launcher, panel.indicators]
385 shown: true
383 shown: true
386
384
387 defaultBackground: shell.background
385 defaultBackground: shell.background
@@ -424,7 +422,7 @@ FocusScope {
424 InputFilterArea {
422 InputFilterArea {
425 anchors.fill: parent
423 anchors.fill: parent
426 blockInput: ApplicationManager.focusedApplicationId.length === 0 || greeter.shown || lockscreen.shown || launcher.shown
424 blockInput: ApplicationManager.focusedApplicationId.length === 0 || greeter.shown || lockscreen.shown || launcher.shown
427− || panel.indicators.shown || hud.shown
425+ || panel.indicators.shown
428 }
426 }
429
427
430 Connections {
428 Connections {
@@ -488,47 +486,6 @@ FocusScope {
488 }
486 }
489 }
487 }
490
488
491− Hud {
492− id: hud
493−
494− width: parent.width > units.gu(60) ? units.gu(40) : parent.width
495− height: parent.height
496−
497− available: !greeter.shown && !panel.indicators.shown && !lockscreen.shown && edgeDemo.dashEnabled
498− shown: false
499− showAnimation: StandardAnimation { property: "y"; duration: hud.showableAnimationDuration; to: 0; easing.type: Easing.Linear }
500− hideAnimation: StandardAnimation { property: "y"; duration: hud.showableAnimationDuration; to: hudRevealer.closedValue; easing.type: Easing.Linear }
501−
502− Connections {
503− target: ApplicationManager
504− onFocusedApplicationIdChanged: hud.hide()
505− }
506− }
507−
508− Revealer {
509− id: hudRevealer
510−
511− enabled: hud.shown
512− width: hud.width
513− anchors.left: hud.left
514− height: parent.height
515− target: hud.revealerTarget
516− closedValue: height
517− openedValue: 0
518− direction: Qt.RightToLeft
519− orientation: Qt.Vertical
520− handleSize: hud.handleHeight
521− onCloseClicked: target.hide()
522− }
523−
524− Bottombar {
525− id: bottombar
526− theHud: hud
527− anchors.fill: parent
528− enabled: hud.available
529− applicationIsOnForeground: ApplicationManager.focusedApplicationId
530− }
531−
532 InputFilterArea {
489 InputFilterArea {
533 blockInput: launcher.shown
490 blockInput: launcher.shown
534 anchors {
491 anchors {
@@ -576,8 +533,6 @@ FocusScope {
576 onShownChanged: {
533 onShownChanged: {
577 if (shown) {
534 if (shown) {
578 panel.indicators.hide()
535 panel.indicators.hide()
579− hud.hide()
580− bottombar.hide()
581 }
536 }
582 }
537 }
583 }
538 }