File tree Expand file tree Collapse file tree 8 files changed +42
-4
lines changed Expand file tree Collapse file tree 8 files changed +42
-4
lines changed Original file line number Diff line number Diff line change 22
33## Current Master
44
5+ - Add support for the new, default Ropsten Test Network.
56- Fix bug that would cause MetaMask to occasionally lose its StreamProvider connection and drop requests.
67
78## 2.13.8 2016-11-16
Original file line number Diff line number Diff line change 11const MAINET_RPC_URL = 'https://mainnet.infura.io/metamask'
2- const TESTNET_RPC_URL = 'https://morden.infura.io/metamask'
2+ const TESTNET_RPC_URL = 'https://ropsten.infura.io/metamask'
3+ const MORDEN_RPC_URL = 'https://morden.infura.io/metamask'
34const DEFAULT_RPC_URL = TESTNET_RPC_URL
45
56global . METAMASK_DEBUG = 'GULP_METAMASK_DEBUG'
@@ -10,5 +11,6 @@ module.exports = {
1011 default : DEFAULT_RPC_URL ,
1112 mainnet : MAINET_RPC_URL ,
1213 testnet : TESTNET_RPC_URL ,
14+ morden : MORDEN_RPC_URL ,
1315 } ,
1416}
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ const rp = require('request-promise')
55
66const TESTNET_RPC = MetamaskConfig . network . testnet
77const MAINNET_RPC = MetamaskConfig . network . mainnet
8+ const MORDEN_RPC = MetamaskConfig . network . morden
89const txLimit = 40
910
1011/* The config-manager is a convenience object
@@ -148,6 +149,9 @@ ConfigManager.prototype.getCurrentRpcAddress = function () {
148149 case 'testnet' :
149150 return TESTNET_RPC
150151
152+ case 'morden' :
153+ return MORDEN_RPC
154+
151155 default :
152156 return provider && provider . rpcTarget ? provider . rpcTarget : TESTNET_RPC
153157 }
Original file line number Diff line number Diff line change @@ -235,14 +235,23 @@ App.prototype.renderNetworkDropdown = function () {
235235 } ) ,
236236
237237 h ( DropMenuItem , {
238- label : 'Morden Test Network' ,
238+ label : 'Ropsten Test Network' ,
239239 closeMenu : ( ) => this . setState ( { isNetworkMenuOpen : false } ) ,
240240 action : ( ) => props . dispatch ( actions . setProviderType ( 'testnet' ) ) ,
241241 icon : h ( '.menu-icon.red-dot' ) ,
242242 activeNetworkRender : props . network ,
243243 provider : props . provider ,
244244 } ) ,
245245
246+ h ( DropMenuItem , {
247+ label : 'Morden Test Network' ,
248+ closeMenu : ( ) => this . setState ( { isNetworkMenuOpen : false } ) ,
249+ action : ( ) => props . dispatch ( actions . setProviderType ( 'morden' ) ) ,
250+ icon : h ( '.menu-icon.red-dot' ) ,
251+ activeNetworkRender : props . network ,
252+ provider : props . provider ,
253+ } ) ,
254+
246255 h ( DropMenuItem , {
247256 label : 'Localhost 8545' ,
248257 closeMenu : ( ) => this . setState ( { isNetworkMenuOpen : false } ) ,
Original file line number Diff line number Diff line change @@ -41,9 +41,12 @@ DropMenuItem.prototype.activeNetworkRender = function () {
4141 case 'Main Ethereum Network' :
4242 if ( providerType === 'mainnet' ) return h ( '.check' , '✓' )
4343 break
44- case 'Morden Test Network' :
44+ case 'Ropsten Test Network' :
4545 if ( provider . type === 'testnet' ) return h ( '.check' , '✓' )
4646 break
47+ case 'Morden Test Network' :
48+ if ( provider . type === 'morden' ) return h ( '.check' , '✓' )
49+ break
4750 case 'Localhost 8545' :
4851 if ( activeNetwork === 'http://localhost:8545' ) return h ( '.check' , '✓' )
4952 break
Original file line number Diff line number Diff line change @@ -36,13 +36,20 @@ Network.prototype.render = function () {
3636 } else if ( providerName === 'mainnet' ) {
3737 hoverText = 'Main Ethereum Network'
3838 iconName = 'ethereum-network'
39+ } else if ( providerName === 'testnet' ) {
40+ hoverText = 'Ropsten Test Network'
41+ iconName = 'ropsten-test-network'
42+ } else if ( parseInt ( networkNumber ) === 3 ) {
43+ hoverText = 'Ropsten Test Network'
44+ iconName = 'ropsten-test-network'
3945 } else if ( parseInt ( networkNumber ) === 2 ) {
4046 hoverText = 'Morden Test Network'
4147 iconName = 'morden-test-network'
4248 } else {
4349 hoverText = 'Unknown Private Network'
4450 iconName = 'unknown-private-network'
4551 }
52+
4653 return (
4754 h ( '#network_component.flex-center.pointer' , {
4855 style : {
@@ -63,6 +70,15 @@ Network.prototype.render = function () {
6370 } } ,
6471 'Ethereum Main Net' ) ,
6572 ] )
73+ case 'ropsten-test-network' :
74+ return h ( '.network-indicator' , [
75+ h ( '.menu-icon.red-dot' ) ,
76+ h ( '.network-name' , {
77+ style : {
78+ color : '#ff6666' ,
79+ } } ,
80+ 'Ropsten Test Net' ) ,
81+ ] )
6682 case 'morden-test-network' :
6783 return h ( '.network-indicator' , [
6884 h ( '.menu-icon.red-dot' ) ,
Original file line number Diff line number Diff line change @@ -213,7 +213,7 @@ hr.horizontal-line {
213213 background : rgb (0 , 163 , 68 );
214214 border-radius : 20px ;
215215}
216- .morden -icon {
216+ .testnet -icon {
217217 background : # 2465E1 ;
218218}
219219
Original file line number Diff line number Diff line change @@ -9,6 +9,9 @@ module.exports = function(address, network) {
99 case 2 : // morden test net
1010 link = `http://testnet.etherscan.io/address/${ address } `
1111 break
12+ case 3 : // ropsten test net
13+ link = ''
14+ break
1215 default :
1316 link = ''
1417 break
You can’t perform that action at this time.
0 commit comments