ubuntu-touch-coreapps-reviewers team mailing list archive
-
ubuntu-touch-coreapps-reviewers team
-
Mailing list archive
-
Message #04847
[Merge] lp:~verzegnassi-stefano/ubuntu-docviewer-app/reboot-update-sdcard-icon into lp:ubuntu-docviewer-app/reboot
Stefano Verzegnassi has proposed merging lp:~verzegnassi-stefano/ubuntu-docviewer-app/reboot-update-sdcard-icon into lp:ubuntu-docviewer-app/reboot.
Commit message:
Use SD card icon from official Suru theme
Requested reviews:
Ubuntu Document Viewer Developers (ubuntu-docviewer-dev)
Related bugs:
Bug #1476659 in Ubuntu Document Viewer App: "Update SD card icon"
https://bugs.launchpad.net/ubuntu-docviewer-app/+bug/1476659
For more details, see:
https://code.launchpad.net/~verzegnassi-stefano/ubuntu-docviewer-app/reboot-update-sdcard-icon/+merge/270532
Use SD card icon from official Suru theme
--
Your team Ubuntu Document Viewer Developers is requested to review the proposed merge of lp:~verzegnassi-stefano/ubuntu-docviewer-app/reboot-update-sdcard-icon into lp:ubuntu-docviewer-app/reboot.
=== modified file 'debian/control'
--- debian/control 2015-02-23 12:49:52 +0000
+++ debian/control 2015-09-09 13:30:05 +0000
@@ -28,6 +28,7 @@
Architecture: any
Depends: qtdeclarative5-qtquick2-plugin,
qtdeclarative5-ubuntu-ui-toolkit-plugin,
+ suru-icon-theme (>= 14.04+15.10.20150707-0ubuntu1),
${misc:Depends}
Description: Document Viewer application
Core Document Viewer application
=== removed file 'src/app/graphics/sd-card-symbolic.png'
Binary files src/app/graphics/sd-card-symbolic.png 2015-05-13 14:22:36 +0000 and src/app/graphics/sd-card-symbolic.png 1970-01-01 00:00:00 +0000 differ
=== modified file 'src/app/qml/documentPage/DocumentGridDelegate.qml'
--- src/app/qml/documentPage/DocumentGridDelegate.qml 2015-08-04 16:01:37 +0000
+++ src/app/qml/documentPage/DocumentGridDelegate.qml 2015-09-09 13:30:05 +0000
@@ -46,6 +46,7 @@
return Qt.formatDateTime(date, i18n.tr("dd-MM-yyyy hh:mm"))
}
+<<<<<<< TREE
title: model.name
text: formattedDateTime()
subText: Utils.printSize(i18n, model.size)
@@ -110,4 +111,171 @@
}*/
DocumentDelegateActions { id: documentDelegateActions }
+=======
+ Rectangle {
+ anchors { fill: parent; margins: units.gu(0.5) }
+
+ color: Qt.lighter(UbuntuColors.lightGrey)
+ clip: true
+
+ Loader {
+ id: selectionIcon
+
+ anchors {
+ right: parent.right
+ top: parent.top
+ }
+
+ z: 10
+
+ width: (status === Loader.Ready) ? item.implicitWidth : 0
+ visible: (status === Loader.Ready) && (item.width === item.implicitWidth)
+ Behavior on opacity {
+ NumberAnimation {
+ duration: UbuntuAnimation.SnapDuration
+ }
+ }
+ }
+
+ Icon {
+ id: extStorageIcon
+
+ width: units.gu(4)
+ height: units.gu(4)
+ anchors {
+ left: parent.left
+ top: parent.top
+ margins: units.gu(0.5)
+ }
+
+ visible: model.isFromExternalStorage
+ name: "sdcard-symbolic"
+ }
+
+ // Document mimetype icon
+ Icon {
+ anchors.centerIn: parent
+ anchors.verticalCenterOffset: - infoColumn.height * 0.3
+
+ width: units.gu(8); height: width
+
+ // At the moment the suru icon theme doesn't have much icons.
+ // Just some note for the future:
+ // TODO: Add icons for Office/ODF documents
+ // TODO: Whenever there will be icons for source code files, add them.
+ name: {
+ if (model.mimetype.substring(0, 5) === "text/")
+ return "text-x-generic-symbolic"
+
+ if (model.mimetype.substring(0, 5) === "image")
+ return "image-x-generic-symbolic"
+
+ if (model.mimetype === "application/pdf")
+ return "application-pdf-symbolic"
+
+ if (model.mimetype === "application/vnd.oasis.opendocument.text"
+ || model.mimetype === "application/msword"
+ || model.mimetype === "application/vnd.openxmlformats-officedocument.wordprocessingml.document")
+ return "x-office-document-symbolic"
+
+ if (model.mimetype === "application/vnd.oasis.opendocument.spreadsheet"
+ || model.mimetype === "application/vnd.ms-excel"
+ || model.mimetype === "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet")
+ return "x-office-spreadsheet-symbolic"
+
+ if (model.mimetype === "application/vnd.oasis.opendocument.presentation"
+ || model.mimetype === "application/vnd.ms-powerpoint"
+ || model.mimetype === "application/vnd.openxmlformats-officedocument.presentationml.presentation")
+ return "x-office-presentation-symbolic"
+
+ return "package-x-generic-symbolic"
+ }
+ }
+
+ // Cover
+ /* Image {
+ anchors.fill: parent
+
+ source: {
+ if (model.cover !== "" && typeof model.cover !== "undefined")
+ return model.cover
+
+ if (model.mimetype.toString().indexOf("image") !== -1)
+ return model.path
+
+ return ""
+ }
+
+ sourceSize.width: width
+ fillMode: Image.PreserveAspectCrop
+ }*/
+
+ // Document info overlay
+ Rectangle {
+ id: overlay
+
+ anchors {
+ left: parent.left
+ right: parent.right
+ bottom: parent.bottom
+ }
+
+ height: infoColumn.height + units.gu(1)
+
+ color: UbuntuColors.darkGrey
+ opacity: 0.75
+ layer.enabled: true
+
+ // Document info
+ Column {
+ id: infoColumn
+ anchors {
+ left: parent.left;
+ right: parent.right
+ verticalCenter: parent.verticalCenter
+ margins: units.gu(0.5)
+ }
+
+ Label {
+ text: model.name
+ color: "white"
+
+ elide: Text.ElideRight
+ font.weight: Font.DemiBold
+ fontSize: "small"
+
+ anchors { left: parent.left; right: parent.right }
+ }
+
+ Label {
+ text: formattedDateTime()
+ color: "white"
+ fontSize: "small"
+
+ anchors { left: parent.left; right: parent.right }
+ }
+
+ Label {
+ text: Utils.printSize(i18n, model.size)
+ color: "white"
+ fontSize: "small"
+
+ anchors { left: parent.left; right: parent.right }
+ }
+ } // Document info end
+ }
+
+ states: [
+ State {
+ name: "select"
+ when: selectionMode || selected
+ PropertyChanges {
+ target: selectionIcon
+ source: Qt.resolvedUrl("../upstreamComponents/ListItemWithActionsCheckBox.qml")
+ anchors.margins: units.gu(1)
+ }
+ }
+ ]
+ }
+>>>>>>> MERGE-SOURCE
}
=== modified file 'src/app/qml/documentPage/DocumentListDelegate.qml'
--- src/app/qml/documentPage/DocumentListDelegate.qml 2015-08-04 16:01:37 +0000
+++ src/app/qml/documentPage/DocumentListDelegate.qml 2015-09-09 13:30:05 +0000
@@ -124,7 +124,7 @@
Icon {
anchors.fill: parent
- source: Qt.resolvedUrl("../../graphics/sd-card-symbolic.png")
+ name: "sdcard-symbolic"
}
}
}
Follow ups