From e0a14223457d9dedee7ff1b0020e3eeaff5f58d4 Mon Sep 17 00:00:00 2001 From: David Kelly Date: Thu, 6 Apr 2017 12:07:51 -0700 Subject: [PATCH] pal selection changes --- interface/resources/qml/hifi/Pal.qml | 11 ++++++++--- interface/resources/qml/styles-uit/HifiConstants.qml | 1 + 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/interface/resources/qml/hifi/Pal.qml b/interface/resources/qml/hifi/Pal.qml index 66803621ec..2f10f0fdf5 100644 --- a/interface/resources/qml/hifi/Pal.qml +++ b/interface/resources/qml/hifi/Pal.qml @@ -436,7 +436,7 @@ Rectangle { rowDelegate: Rectangle { // The only way I know to specify a row height. // Size height: rowHeight + (styleData.selected ? 15 : 0); - color: rowColor(styleData.selected, styleData.alternate); + color: nearbyRowColor(styleData.selected, styleData.alternate); } // This Item refers to the contents of each Cell @@ -764,7 +764,7 @@ Rectangle { rowDelegate: Rectangle { // Size height: rowHeight; - color: rowColor(styleData.selected, styleData.alternate); + color: connectionsRowColor(styleData.selected, styleData.alternate); } // This Item refers to the contents of each Cell @@ -1184,9 +1184,12 @@ Rectangle { } } - function rowColor(selected, alternate) { + function nearbyRowColor(selected, alternate) { return selected ? hifi.colors.orangeHighlight : alternate ? hifi.colors.tableRowLightEven : hifi.colors.tableRowLightOdd; } + function connectionsRowColor(selected, alternate) { + return selected ? hifi.colors.lightBlueHighlight : alternate ? hifi.colors.tableRowLightEven : hifi.colors.tableRowLightOdd; + } function findNearbySessionIndex(sessionId, optionalData) { // no findIndex in .qml var data = optionalData || nearbyUserModelData, length = data.length; for (var i = 0; i < length; i++) { @@ -1257,6 +1260,8 @@ Rectangle { selectionTimer.userIndex = userIndex; selectionTimer.start(); } + // in any case make sure we are in the nearby tab + activeTab="nearbyTab"; break; // Received an "updateUsername()" request from the JS case 'updateUsername': diff --git a/interface/resources/qml/styles-uit/HifiConstants.qml b/interface/resources/qml/styles-uit/HifiConstants.qml index 386af206e1..7b6efbd573 100644 --- a/interface/resources/qml/styles-uit/HifiConstants.qml +++ b/interface/resources/qml/styles-uit/HifiConstants.qml @@ -72,6 +72,7 @@ Item { readonly property color magentaAccent: "#A2277C" readonly property color checkboxCheckedRed: "#FF0000" readonly property color checkboxCheckedBorderRed: "#D00000" + readonly property color lightBlueHighlight: "#d6f6ff" // Semitransparent readonly property color darkGray30: "#4d121212"