ConfigEditFragment: Add a field for the optional pre-shared key
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
This commit is contained in:
		
							parent
							
								
									3d6109e6d9
								
							
						
					
					
						commit
						cd868bc997
					
				@ -62,10 +62,27 @@
 | 
				
			|||||||
            app:filter="@{KeyInputFilter.newInstance()}" />
 | 
					            app:filter="@{KeyInputFilter.newInstance()}" />
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        <TextView
 | 
					        <TextView
 | 
				
			||||||
            android:id="@+id/allowed_ips_label"
 | 
					            android:id="@+id/pre_shared_key_label"
 | 
				
			||||||
            android:layout_width="match_parent"
 | 
					            android:layout_width="match_parent"
 | 
				
			||||||
            android:layout_height="wrap_content"
 | 
					            android:layout_height="wrap_content"
 | 
				
			||||||
            android:layout_below="@+id/public_key_text"
 | 
					            android:layout_below="@+id/public_key_text"
 | 
				
			||||||
 | 
					            android:labelFor="@+id/pre_shared_key_text"
 | 
				
			||||||
 | 
					            android:text="@string/pre_shared_key" />
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        <EditText
 | 
				
			||||||
 | 
					            android:id="@+id/pre_shared_key_text"
 | 
				
			||||||
 | 
					            android:layout_width="match_parent"
 | 
				
			||||||
 | 
					            android:layout_height="wrap_content"
 | 
				
			||||||
 | 
					            android:layout_below="@+id/pre_shared_key_label"
 | 
				
			||||||
 | 
					            android:hint="@string/hint_optional"
 | 
				
			||||||
 | 
					            android:inputType="textNoSuggestions"
 | 
				
			||||||
 | 
					            android:text="@={item.preSharedKey}" />
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        <TextView
 | 
				
			||||||
 | 
					            android:id="@+id/allowed_ips_label"
 | 
				
			||||||
 | 
					            android:layout_width="match_parent"
 | 
				
			||||||
 | 
					            android:layout_height="wrap_content"
 | 
				
			||||||
 | 
					            android:layout_below="@+id/pre_shared_key_text"
 | 
				
			||||||
            android:labelFor="@+id/allowed_ips_text"
 | 
					            android:labelFor="@+id/allowed_ips_text"
 | 
				
			||||||
            android:text="@string/allowed_ips" />
 | 
					            android:text="@string/allowed_ips" />
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -19,6 +19,7 @@
 | 
				
			|||||||
    <string name="generate">Generate</string>
 | 
					    <string name="generate">Generate</string>
 | 
				
			||||||
    <string name="hint_automatic">(auto)</string>
 | 
					    <string name="hint_automatic">(auto)</string>
 | 
				
			||||||
    <string name="hint_generated">(generated)</string>
 | 
					    <string name="hint_generated">(generated)</string>
 | 
				
			||||||
 | 
					    <string name="hint_optional">(optional)</string>
 | 
				
			||||||
    <string name="hint_random">(random)</string>
 | 
					    <string name="hint_random">(random)</string>
 | 
				
			||||||
    <string name="iface">Interface</string>
 | 
					    <string name="iface">Interface</string>
 | 
				
			||||||
    <string name="listen_port">Listen port</string>
 | 
					    <string name="listen_port">Listen port</string>
 | 
				
			||||||
@ -28,6 +29,7 @@
 | 
				
			|||||||
    <string name="peer">Peer</string>
 | 
					    <string name="peer">Peer</string>
 | 
				
			||||||
    <string name="persistent_keepalive">Persistent keepalive</string>
 | 
					    <string name="persistent_keepalive">Persistent keepalive</string>
 | 
				
			||||||
    <string name="placeholder_text">No configuration selected</string>
 | 
					    <string name="placeholder_text">No configuration selected</string>
 | 
				
			||||||
 | 
					    <string name="pre_shared_key">Pre-shared key</string>
 | 
				
			||||||
    <string name="primary_config">Primary configuration</string>
 | 
					    <string name="primary_config">Primary configuration</string>
 | 
				
			||||||
    <string name="primary_config_summary">This configuration will be controlled by the quick settings tile</string>
 | 
					    <string name="primary_config_summary">This configuration will be controlled by the quick settings tile</string>
 | 
				
			||||||
    <string name="private_key">Private key</string>
 | 
					    <string name="private_key">Private key</string>
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user