2 * Copyright (C) 2013-2015 Canonical, Ltd.
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.
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.
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/>.
18import Ubuntu.Components 1.1
19import Unity.Application 0.1
21import "../Components/PanelState"
26 readonly property real panelHeight: indicatorArea.y + d.indicatorHeight
27 property alias indicators: __indicators
28 property alias callHint: __callHint
29 property bool fullscreenMode: false
30 property real indicatorAreaShowProgress: 1.0
32 opacity: fullscreenMode && indicators.fullyClosed ? 0.0 : 1.0
36 property real darkenedOpacity: 0.6
39 topMargin: panelHeight
45 opacity: indicators.unitProgress * darkenedOpacity
46 visible: !indicators.fullyClosed
50 onClicked: if (indicators.fullyOpened) indicators.hide();
51 hoverEnabled: true // should also eat hover events, otherwise they will pass through
57 objectName: "indicatorArea"
61 Behavior on anchors.topMargin {
62 NumberAnimation { duration: UbuntuAnimation.FastDuration; easing: UbuntuAnimation.StandardEasing }
65 transform: Translate {
66 y: indicators.state === "initial"
67 ? (1.0 - indicatorAreaShowProgress) * -d.indicatorHeight
75 leftMargin: -units.gu(1)
76 bottomMargin: -units.gu(1)
78 visible: !indicators.fullyClosed
79 source: "graphics/rectangular_dropshadow.sci"
83 id: indicatorAreaBackground
84 color: callHint.visible ? "green" : "black"
90 height: indicators.minimizedPanelHeight
92 Behavior on color { ColorAnimation { duration: UbuntuAnimation.FastDuration } }
98 top: indicatorAreaBackground.bottom
100 right: indicators.left
102 saturation: 1 - indicators.unitProgress
104 // Don't let input event pass trough
105 MouseArea { anchors.fill: parent }
111 bottom: indicators.bottom
112 right: indicators.left
113 topMargin: indicatorArea.anchors.topMargin + indicators.minimizedPanelHeight
116 source: "graphics/VerticalDivider.png"
123 right: indicators.left
125 height: indicators.minimizedPanelHeight
126 onClicked: { if (callHint.visible) { callHint.showLiveCall(); } }
131 objectName: "indicators"
139 width: root.width - (PanelState.buttonsVisible ? windowControlButtons.width : 0)
140 minimizedPanelHeight: units.gu(3)
141 expandedPanelHeight: units.gu(7)
142 openedHeight: root.height - indicatorOrangeLine.height
145 if (callHint.visible) {
146 return Math.max(root.width - (callHint.width + units.gu(2)), 0)
150 enableHint: !callHint.active && !fullscreenMode
151 showOnClick: !callHint.visible
152 panelColor: indicatorAreaBackground.color
155 if (callHint.active) {
156 callHint.showLiveCall();
161 anchors.bottomMargin: -indicatorOrangeLine.height
165 WindowControlButtons {
166 id: windowControlButtons
170 margins: units.gu(0.7)
172 height: indicators.minimizedPanelHeight - anchors.margins * 2
173 visible: PanelState.buttonsVisible
174 onClose: PanelState.close()
175 onMinimize: PanelState.minimize()
176 onMaximize: PanelState.maximize()
180 id: indicatorOrangeLine
182 top: indicators.bottom
183 left: indicators.left
184 right: indicators.right
192 left: PanelState.buttonsVisible ? windowControlButtons.right : parent.left
194 height: indicators.minimizedPanelHeight
195 visible: active && indicators.state == "initial"
201 objectName: "panelPriv"
202 readonly property real indicatorHeight: indicators.minimizedPanelHeight + indicatorOrangeLine.height
207 name: "onscreen" //fully opaque and visible at top edge of screen
208 when: !fullscreenMode
210 target: indicatorArea;
215 name: "offscreen" //pushed off screen
218 target: indicatorArea;
219 anchors.topMargin: indicators.state === "initial" ? -d.indicatorHeight : 0
222 target: indicators.showDragHandle;
223 anchors.bottomMargin: -units.gu(1)
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list