diff options
rename selectedAccount to selectedAddress
Diffstat (limited to 'ui/app/accounts')
-rw-r--r-- | ui/app/accounts/account-list-item.js | 4 | ||||
-rw-r--r-- | ui/app/accounts/index.js | 11 |
2 files changed, 4 insertions, 11 deletions
diff --git a/ui/app/accounts/account-list-item.js b/ui/app/accounts/account-list-item.js index 74ecef07f..2a3c13d05 100644 --- a/ui/app/accounts/account-list-item.js +++ b/ui/app/accounts/account-list-item.js @@ -15,10 +15,10 @@ function AccountListItem () { } AccountListItem.prototype.render = function () { - const { identity, selectedAccount, accounts, onShowDetail } = this.props + const { identity, selectedAddress, accounts, onShowDetail } = this.props const checksumAddress = identity && identity.address && ethUtil.toChecksumAddress(identity.address) - const isSelected = selectedAccount === identity.address + const isSelected = selectedAddress === identity.address const account = accounts[identity.address] const selectedClass = isSelected ? '.selected' : '' diff --git a/ui/app/accounts/index.js b/ui/app/accounts/index.js index e6f376735..7c35a83dd 100644 --- a/ui/app/accounts/index.js +++ b/ui/app/accounts/index.js @@ -19,7 +19,7 @@ function mapStateToProps (state) { accounts: state.metamask.accounts, identities: state.metamask.identities, unconfTxs: state.metamask.unconfTxs, - selectedAccount: state.metamask.selectedAccount, + selectedAddress: state.metamask.selectedAddress, scrollToBottom: state.appState.scrollToBottom, pending, keyrings: state.metamask.keyrings, @@ -80,7 +80,7 @@ AccountsScreen.prototype.render = function () { return h(AccountListItem, { key: `acct-panel-${identity.address}`, identity, - selectedAccount: this.props.selectedAccount, + selectedAddress: this.props.selectedAddress, accounts: this.props.accounts, onShowDetail: this.onShowDetail.bind(this), pending, @@ -139,13 +139,6 @@ AccountsScreen.prototype.navigateToConfTx = function () { this.props.dispatch(actions.showConfTxPage()) } -AccountsScreen.prototype.onSelect = function (address, event) { - event.stopPropagation() - // if already selected, deselect - if (this.props.selectedAccount === address) address = null - this.props.dispatch(actions.setSelectedAccount(address)) -} - AccountsScreen.prototype.onShowDetail = function (address, event) { event.stopPropagation() this.props.dispatch(actions.showAccountDetail(address)) |