Updated Permissions and Transproxy screens
Included a checkbox in Permission screen to account for users who do not wish to grant root permissions. Updated radio buttons in Transproxy screen
This commit is contained in:
parent
026a7ca4c9
commit
4f333e370d
|
@ -39,6 +39,7 @@
|
||||||
<TextView android:layout_width="wrap_content" android:textColor="#ffffff" android:layout_height="wrap_content" android:background="#222222" android:textSize="8pt" android:padding="6px" android:id="@+id/WizardTextBody1" android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text"></TextView>
|
<TextView android:layout_width="wrap_content" android:textColor="#ffffff" android:layout_height="wrap_content" android:background="#222222" android:textSize="8pt" android:padding="6px" android:id="@+id/WizardTextBody1" android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text"></TextView>
|
||||||
<Button android:layout_width="wrap_content" android:visibility="gone" android:layout_height="wrap_content" android:gravity="center" android:text="Grant Permission" android:id="@+id/grantPermissions" android:layout_gravity="center"></Button>
|
<Button android:layout_width="wrap_content" android:visibility="gone" android:layout_height="wrap_content" android:gravity="center" android:text="Grant Permission" android:id="@+id/grantPermissions" android:layout_gravity="center"></Button>
|
||||||
<TextView android:layout_width="wrap_content" android:visibility="gone" android:textColor="#ffffff" android:layout_height="wrap_content" android:background="#222222" android:textSize="8pt" android:padding="6px" android:id="@+id/WizardTextBody2" android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text"></TextView>
|
<TextView android:layout_width="wrap_content" android:visibility="gone" android:textColor="#ffffff" android:layout_height="wrap_content" android:background="#222222" android:textSize="8pt" android:padding="6px" android:id="@+id/WizardTextBody2" android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text"></TextView>
|
||||||
|
<CheckBox android:id="@+id/checkBox" android:visibility="gone" android:layout_gravity="center" android:text="@string/wizard_permissions_consent" android:layout_height="wrap_content" android:layout_width="wrap_content"></CheckBox>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
|
|
|
@ -41,12 +41,17 @@
|
||||||
android:layout_height="fill_parent"
|
android:layout_height="fill_parent"
|
||||||
android:padding="3px">
|
android:padding="3px">
|
||||||
<TextView android:text="@string/wizard_transproxy_msg" android:textColor="#ffffff" android:id="@+id/WizardRootTextView01" android:layout_width="wrap_content" android:layout_height="wrap_content"></TextView>
|
<TextView android:text="@string/wizard_transproxy_msg" android:textColor="#ffffff" android:id="@+id/WizardRootTextView01" android:layout_width="wrap_content" android:layout_height="wrap_content"></TextView>
|
||||||
|
<RadioGroup android:id="@+id/radioGroup" android:layout_height="wrap_content" android:layout_width="wrap_content">
|
||||||
|
<RadioButton android:checked="true" android:text="@string/wizard_configure_all" android:id="@+id/radio0" android:layout_height="wrap_content" android:layout_width="wrap_content"></RadioButton>
|
||||||
<CheckBox android:layout_marginTop="20px" android:text="@string/wizard_configure_all" android:id="@+id/WizardRootCheckBox01" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center"></CheckBox>
|
<TextView android:layout_height="wrap_content"
|
||||||
<TextView android:text="@string/wizard_transproxy_hint" android:textColor="#ffffff" android:layout_width="wrap_content" android:layout_height="wrap_content" android:paddingBottom="20dip"></TextView>
|
android:text="@string/wizard_transproxy_hint"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
<Button android:text="@string/wizard_configure_select_apps" android:id="@+id/WizardRootButton01" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center"/>
|
android:textSize="15sp"
|
||||||
|
android:paddingBottom="10dip">
|
||||||
|
</TextView>
|
||||||
|
<RadioButton android:text="@string/wizard_configure_select_apps" android:id="@+id/radio1" android:layout_height="wrap_content" android:layout_width="wrap_content"></RadioButton>
|
||||||
|
<RadioButton android:text="@string/wizard_transproxy_none" android:id="@+id/radio2" android:layout_height="wrap_content" android:layout_width="wrap_content"></RadioButton>
|
||||||
|
</RadioGroup>
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
|
@ -88,7 +88,6 @@
|
||||||
<string name="wizard_permissions_msg_stock"> While it is not required, Orbot can become a more powerful tool if your device has root access. Use the button below to grant Orbot superpowers! </string>
|
<string name="wizard_permissions_msg_stock"> While it is not required, Orbot can become a more powerful tool if your device has root access. Use the button below to grant Orbot superpowers! </string>
|
||||||
|
|
||||||
<string name="wizard_permissions_no_root">If you don\'t have root access or have no idea what we\'re talking about, just be sure to use apps made to work with Orbot.</string>
|
<string name="wizard_permissions_no_root">If you don\'t have root access or have no idea what we\'re talking about, just be sure to use apps made to work with Orbot.</string>
|
||||||
<string name="wizard_permissions_consent">I understand and would like to continue without root</string>
|
|
||||||
|
|
||||||
<string name="wizard_permission_enable_root">Grant Root for Orbot</string>
|
<string name="wizard_permission_enable_root">Grant Root for Orbot</string>
|
||||||
<string name="wizard_configure">Configure Torification</string>
|
<string name="wizard_configure">Configure Torification</string>
|
||||||
|
@ -137,6 +136,7 @@
|
||||||
<string name="wizard_permissions_root_msg1">Orbot has detected that you have root permissions enabled. To enable \'Transparent Proxying\', please grant superuser privileges to Orbot</string>
|
<string name="wizard_permissions_root_msg1">Orbot has detected that you have root permissions enabled. To enable \'Transparent Proxying\', please grant superuser privileges to Orbot</string>
|
||||||
<string name="wizard_permissions_root_msg2">If you choose to continue without providing superuser privileges, make sure to use apps made to work with orbot</string>
|
<string name="wizard_permissions_root_msg2">If you choose to continue without providing superuser privileges, make sure to use apps made to work with orbot</string>
|
||||||
<string name="wizard_permissions_msg">Orbot has detected that you do not have root permissions.\nTransparent Proxying is not possible without superuser privileges.\nMake sure to use apps that have been configured to work with Orbot</string>
|
<string name="wizard_permissions_msg">Orbot has detected that you do not have root permissions.\nTransparent Proxying is not possible without superuser privileges.\nMake sure to use apps that have been configured to work with Orbot</string>
|
||||||
|
<string name="wizard_permissions_consent">I understand and would like to continue without root</string>
|
||||||
<!-- TipsAndTricks screen -->
|
<!-- TipsAndTricks screen -->
|
||||||
<string name="wizard_tips_title">Orbot configured Apps</string>
|
<string name="wizard_tips_title">Orbot configured Apps</string>
|
||||||
<string name="wizard_tips_gibberbot">Gibberbot - Secure instant messaging client for Android</string>
|
<string name="wizard_tips_gibberbot">Gibberbot - Secure instant messaging client for Android</string>
|
||||||
|
|
|
@ -24,7 +24,8 @@ import android.widget.Toast;
|
||||||
public class ConfigureTransProxy extends Activity implements TorConstants {
|
public class ConfigureTransProxy extends Activity implements TorConstants {
|
||||||
|
|
||||||
private Context context;
|
private Context context;
|
||||||
private int flag =0;
|
private int flag = 0;
|
||||||
|
|
||||||
protected void onCreate(Bundle savedInstanceState)
|
protected void onCreate(Bundle savedInstanceState)
|
||||||
{
|
{
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
|
@ -63,8 +64,15 @@ public class ConfigureTransProxy extends Activity implements TorConstants {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onCheckedChanged(RadioGroup group, int checkedId){
|
public void onCheckedChanged(RadioGroup group, int checkedId){
|
||||||
|
Button next = ((Button)findViewById(R.id.btnWizard2));
|
||||||
|
next.setOnClickListener(new View.OnClickListener() {
|
||||||
|
|
||||||
flag = 0;
|
@Override
|
||||||
|
public void onClick(View v) {
|
||||||
|
|
||||||
|
showWizardFinal();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
RadioButton rb0 = (RadioButton)findViewById(R.id.radio0);
|
RadioButton rb0 = (RadioButton)findViewById(R.id.radio0);
|
||||||
RadioButton rb1 = (RadioButton)findViewById(R.id.radio1);
|
RadioButton rb1 = (RadioButton)findViewById(R.id.radio1);
|
||||||
|
@ -90,6 +98,16 @@ public class ConfigureTransProxy extends Activity implements TorConstants {
|
||||||
pEdit1.putBoolean(PREF_TRANSPARENT_ALL, false);
|
pEdit1.putBoolean(PREF_TRANSPARENT_ALL, false);
|
||||||
pEdit1.commit();
|
pEdit1.commit();
|
||||||
|
|
||||||
|
next.setOnClickListener(new View.OnClickListener() {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onClick(View v) {
|
||||||
|
|
||||||
|
context.startActivity(new Intent(context, AppManager.class));
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -14,6 +14,9 @@ import android.preference.PreferenceManager;
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.widget.Button;
|
import android.widget.Button;
|
||||||
|
import android.widget.CheckBox;
|
||||||
|
import android.widget.CompoundButton;
|
||||||
|
import android.widget.CompoundButton.OnCheckedChangeListener;
|
||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
import android.widget.Toast;
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
@ -110,6 +113,38 @@ public class Permissions extends Activity implements TorConstants {
|
||||||
|
|
||||||
Button back = ((Button)findViewById(R.id.btnWizard1));
|
Button back = ((Button)findViewById(R.id.btnWizard1));
|
||||||
Button next = ((Button)findViewById(R.id.btnWizard2));
|
Button next = ((Button)findViewById(R.id.btnWizard2));
|
||||||
|
next.setClickable(false);
|
||||||
|
|
||||||
|
CheckBox consent = (CheckBox)findViewById(R.id.checkBox);
|
||||||
|
consent.setVisibility(CheckBox.VISIBLE);
|
||||||
|
|
||||||
|
consent.setOnCheckedChangeListener(new OnCheckedChangeListener (){
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCheckedChanged(CompoundButton buttonView,
|
||||||
|
boolean isChecked) {
|
||||||
|
|
||||||
|
|
||||||
|
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context);
|
||||||
|
|
||||||
|
Editor pEdit = prefs.edit();
|
||||||
|
|
||||||
|
pEdit.putBoolean(PREF_TRANSPARENT, isChecked);
|
||||||
|
pEdit.putBoolean(PREF_TRANSPARENT_ALL, isChecked);
|
||||||
|
|
||||||
|
pEdit.commit();
|
||||||
|
|
||||||
|
Button next = ((Button)findViewById(R.id.btnWizard2));
|
||||||
|
if(isChecked)
|
||||||
|
next.setClickable(true);
|
||||||
|
else
|
||||||
|
next.setClickable(false);
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
grantPermissions.setOnClickListener(new View.OnClickListener() {
|
grantPermissions.setOnClickListener(new View.OnClickListener() {
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue