mirror of
https://github.com/DeviceFarmer/stf.git
synced 2026-04-25 02:05:15 +02:00
Refactoring ADB add keys to its own directive so it can be shared.
This commit is contained in:
@@ -1,7 +1,5 @@
|
||||
module.exports = function AdbKeysCtrl($scope, AdbKeysService) {
|
||||
|
||||
|
||||
|
||||
$scope.adbKeys = [
|
||||
{
|
||||
title: 'PC1264',
|
||||
@@ -20,14 +18,4 @@ module.exports = function AdbKeysCtrl($scope, AdbKeysService) {
|
||||
|
||||
|
||||
|
||||
$scope.toggleAddKey = function () {
|
||||
$scope.showAdd = !$scope.showAdd
|
||||
}
|
||||
|
||||
$scope.$watch('key', function (newValue) {
|
||||
if (newValue && !$scope.title) {
|
||||
$scope.title = AdbKeysService.hostNameFromKey(newValue)
|
||||
}
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user