2 * Copyright (C) 2013 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 0.1
19import Unity.Notifications 1.0
24 property alias iconSource: avatarIcon.source
25 property alias secondaryIconSource: secondaryIcon.source
26 property alias summary: summaryLabel.text
27 property alias body: bodyLabel.text
29 property var notificationId
31 property var notification
33 implicitHeight: childrenRect.height
34 color: Qt.rgba(0, 0, 0, 0.85)
40 anchors.fill: contentColumn
41 objectName: "interactiveArea"
42 enabled: notification.type == Notification.Interactive
43 onClicked: notification.notification.invokeAction(actionRepeater.itemAt(0).actionId)
55 height: childrenRect.height + spacing
61 spacing: contentColumn.spacing
73 visible: iconSource !== undefined && iconSource != ""
77 fillMode: Image.PreserveAspectCrop
84 objectName: "secondaryIcon"
87 visible: source !== undefined && source != ""
88 fillMode: Image.PreserveAspectCrop
93 width: parent.width - x
98 objectName: "summaryLabel"
106 elide: Text.ElideRight
112 objectName: "bodyLabel"
121 wrapMode: Text.WordWrap
123 elide: Text.ElideRight
131 objectName: "buttonRow"
132 spacing: contentColumn.spacing
133 layoutDirection: Qt.RightToLeft
134 visible: notification.type == Notification.SnapDecision
142 model: notification.actions
145 objectName: "button" + index
146 color: Positioner.isFirstItem ? "#d85317" : "#cdcdcb"
147 width: (buttonRow.width - buttonRow.spacing) / 2
150 property string actionId: id
151 onClicked: notification.notification.invokeAction(id)
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