← Back to team overview

ubuntu-touch-coreapps-reviewers team mailing list archive

[Merge] lp:~verzegnassi-stefano/ubuntu-terminal-app/hide-terminal-data-on-auth into lp:ubuntu-terminal-app

 

Stefano Verzegnassi has proposed merging lp:~verzegnassi-stefano/ubuntu-terminal-app/hide-terminal-data-on-auth into lp:ubuntu-terminal-app.

Commit message:
Hide terminal data until the access is granted (using a FastBlur).

Requested reviews:
  Ubuntu Terminal Developers (ubuntu-terminal-dev)
Related bugs:
  Bug #1488481 in Ubuntu Terminal App: "BQ (r24): terminal-app shows terminal data when asking for password"
  https://bugs.launchpad.net/ubuntu-terminal-app/+bug/1488481

For more details, see:
https://code.launchpad.net/~verzegnassi-stefano/ubuntu-terminal-app/hide-terminal-data-on-auth/+merge/288040

Hide terminal data until the access is granted (using a FastBlur).

Screenshot (with 'top' command):
https://drive.google.com/open?id=0By4kAplbFcE6ek5XT2FiMXM2eWs
-- 
Your team Ubuntu Terminal Developers is requested to review the proposed merge of lp:~verzegnassi-stefano/ubuntu-terminal-app/hide-terminal-data-on-auth into lp:ubuntu-terminal-app.
=== modified file 'src/app/qml/AuthenticationService.qml'
--- src/app/qml/AuthenticationService.qml	2016-01-09 01:47:56 +0000
+++ src/app/qml/AuthenticationService.qml	2016-03-03 23:14:57 +0000
@@ -26,6 +26,9 @@
 Item {
     id: authenticationService
 
+    property var __authDialog
+    readonly property bool isDialogVisible: __authDialog != null
+
     signal granted()
     signal denied()
 
@@ -63,6 +66,8 @@
 
         authentication_dialog.passwordEntered.connect( verify_password );
         authentication_dialog.dialogCanceled.connect( denied );
+
+        __authDialog = authentication_dialog
     }
 
     PamAuthentication {

=== modified file 'src/app/qml/TerminalPage.qml'
--- src/app/qml/TerminalPage.qml	2016-01-22 18:01:49 +0000
+++ src/app/qml/TerminalPage.qml	2016-03-03 23:14:57 +0000
@@ -3,6 +3,9 @@
 import Ubuntu.Components.Popups 1.3
 import QMLTermWidget 1.0
 
+// For FastBlur
+import QtGraphicalEffects 1.0
+
 Page {
     id: terminalPage
     property alias terminalContainer: terminalContainer
@@ -29,6 +32,12 @@
             right: parent.right;
             bottom: keyboardBarLoader.top
         }
+
+        // Hide terminal data when the access is still not granted
+        layer.enabled: authService.isDialogVisible
+        layer.effect: FastBlur {
+            radius: units.gu(6)
+        }
     }
 
 

=== modified file 'src/app/qml/ubuntu-terminal-app.qml'
--- src/app/qml/ubuntu-terminal-app.qml	2016-02-07 18:24:56 +0000
+++ src/app/qml/ubuntu-terminal-app.qml	2016-03-03 23:14:57 +0000
@@ -16,6 +16,7 @@
     height: units.gu(55)
 
     AuthenticationService {
+        id: authService
         onDenied: Qt.quit();
     }
 


Follow ups