|
@ -84,6 +84,7 @@
|
|||
android:windowSoftInputMode="adjustPan" />
|
||||
<activity
|
||||
android:name="com.darkweb.genesissearchengine.appManager.settingManager.notificationManager.settingNotificationController"
|
||||
android:launchMode="singleTop"
|
||||
android:configChanges="keyboard|keyboardHidden|orientation|screenSize|uiMode"
|
||||
android:windowSoftInputMode="adjustPan" />
|
||||
<activity
|
||||
|
@ -220,6 +221,16 @@
|
|||
</intent-filter>
|
||||
</receiver>
|
||||
|
||||
<provider
|
||||
android:name="androidx.core.content.FileProvider"
|
||||
android:authorities="com.darkweb.genesissearchengine.fileprovider"
|
||||
android:exported="false"
|
||||
android:grantUriPermissions="true">
|
||||
<meta-data
|
||||
android:name="android.support.FILE_PROVIDER_PATHS"
|
||||
android:resource="@xml/provider_paths" />
|
||||
</provider>
|
||||
|
||||
<provider
|
||||
android:name="androidx.core.content.FileProvider"
|
||||
android:authorities="com.darkweb.genesissearchengine.provider"
|
||||
|
|
|
@ -426,7 +426,7 @@ public class bookmarkAdapter extends RecyclerView.Adapter<bookmarkAdapter.listVi
|
|||
public void run(){
|
||||
try {
|
||||
mHindTypeIconTemp.setImageDrawable(null);
|
||||
mEvent.invokeObserver(Arrays.asList(mHindTypeIconTemp, "https://" + helperMethod.getDomainName(model.getDescription())), enums.etype.fetch_favicon);
|
||||
mEvent.invokeObserver(Arrays.asList(mHindTypeIconTemp, "http://" + helperMethod.getDomainName(model.getDescription())), enums.etype.fetch_favicon);
|
||||
while (true){
|
||||
int mCounter=0;
|
||||
if(mHindTypeIconTemp.isAttachedToWindow() || mHindTypeIconTemp.getDrawable()==null){
|
||||
|
|
|
@ -2,8 +2,10 @@ package com.darkweb.genesissearchengine.appManager.historyManager;
|
|||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
import android.content.res.Resources;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.os.Handler;
|
||||
import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
|
@ -29,7 +31,9 @@ import java.util.Arrays;
|
|||
import java.util.Calendar;
|
||||
import java.util.Collections;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import systems.intelligo.slight.ImageLoader;
|
||||
|
||||
|
@ -56,6 +60,7 @@ public class historyAdapter extends RecyclerView.Adapter<historyAdapter.listView
|
|||
private eventObserver.eventListener mEvent;
|
||||
private String mFilter = strings.GENERIC_EMPTY_STR;
|
||||
private boolean mLongPressedMenuActive = false;
|
||||
private Map<String, Drawable> mWebIcon = new HashMap<>();
|
||||
|
||||
/*Local Variables*/
|
||||
|
||||
|
@ -273,6 +278,10 @@ public class historyAdapter extends RecyclerView.Adapter<historyAdapter.listView
|
|||
}
|
||||
}
|
||||
|
||||
public void onClearAdapter(){
|
||||
mWebIcon.clear();
|
||||
}
|
||||
|
||||
@SuppressLint("ClickableViewAccessibility")
|
||||
public void onSwipe(View pItemView, String pUrl, View pMenuItem, ImageView pLogoImage, int pId, Date pDate){
|
||||
|
||||
|
@ -473,7 +482,11 @@ public class historyAdapter extends RecyclerView.Adapter<historyAdapter.listView
|
|||
|
||||
if(model.getDescription().contains("boogle.store") || model.getDescription().contains("genesis.onion")){
|
||||
mFaviconLogo.setImageDrawable(itemView.getResources().getDrawable(R.drawable.genesis));
|
||||
}else{
|
||||
}
|
||||
else if(mWebIcon.containsKey(model.getDescription())){
|
||||
mFaviconLogo.setImageDrawable(mWebIcon.get(model.getDescription()));
|
||||
}
|
||||
else{
|
||||
new Thread(){
|
||||
public void run(){
|
||||
try {
|
||||
|
@ -482,19 +495,35 @@ public class historyAdapter extends RecyclerView.Adapter<historyAdapter.listView
|
|||
while (true){
|
||||
int mCounter=0;
|
||||
if(mHindTypeIconTemp.isAttachedToWindow() || mHindTypeIconTemp.getDrawable()==null){
|
||||
sleep(50);
|
||||
sleep(10);
|
||||
mCounter+=1;
|
||||
}else {
|
||||
Log.i("BREAK","");
|
||||
break;
|
||||
}
|
||||
if(mCounter>6){
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
mContext.runOnUiThread(() -> {
|
||||
Bitmap mBitmap = helperMethod.drawableToBitmap(mHindTypeIconTemp.getDrawable());
|
||||
mFaviconLogo.setImageBitmap(mBitmap);
|
||||
mFaviconLogo.setColorFilter(null);
|
||||
mFaviconLogo.clearColorFilter();
|
||||
mFaviconLogo.setImageTintList(null);
|
||||
mFaviconLogo.setClipToOutline(true);
|
||||
mWebIcon.put(model.getDescription(),mHindTypeIconTemp.getDrawable());
|
||||
if(mHindTypeIconTemp.getDrawable() != null){
|
||||
mFaviconLogo.setImageDrawable(mHindTypeIconTemp.getDrawable());
|
||||
}else {
|
||||
Resources res = itemView.getContext().getResources();
|
||||
try {
|
||||
mFaviconLogo.setImageDrawable(Drawable.createFromXml(res, res.getXml(R.xml.ic_baseline_browser)));
|
||||
} catch (Exception ignored) {
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
|
|
@ -9,6 +9,8 @@ import android.content.Intent;
|
|||
import android.content.pm.ActivityInfo;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.content.pm.ResolveInfo;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.graphics.Matrix;
|
||||
import android.graphics.Rect;
|
||||
import android.graphics.RectF;
|
||||
|
@ -62,7 +64,9 @@ import java.io.IOException;
|
|||
import java.io.OutputStream;
|
||||
import java.lang.ref.WeakReference;
|
||||
import java.net.URLEncoder;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Arrays;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
|
@ -663,19 +667,37 @@ public class geckoSession extends GeckoSession implements GeckoSession.MediaDele
|
|||
}
|
||||
}
|
||||
|
||||
private boolean createAndSaveFileFromBase64Url(String url) {
|
||||
private void saveImage(Bitmap finalBitmap) {
|
||||
|
||||
if(!url.startsWith("data") && !url.startsWith("blob")){
|
||||
return false;
|
||||
String root = Environment.getExternalStorageDirectory().toString();
|
||||
File myDir = new File(root + "/saved_images");
|
||||
myDir.mkdirs();
|
||||
|
||||
String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss").format(new Date());
|
||||
String fname = "Shutta_"+ timeStamp +".jpg";
|
||||
|
||||
File file = new File(myDir, fname);
|
||||
if (file.exists()) file.delete ();
|
||||
try {
|
||||
FileOutputStream out = new FileOutputStream(file);
|
||||
finalBitmap.compress(Bitmap.CompressFormat.JPEG, 100, out);
|
||||
out.flush();
|
||||
out.close();
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
else if(url.startsWith("blob")){
|
||||
Toast toast = Toast.makeText(mContext.get().getApplicationContext(),
|
||||
"Unable to download urls that contain prefix blob. Not Supported",
|
||||
Toast.LENGTH_SHORT);
|
||||
|
||||
toast.show();
|
||||
/* Checks if external storage is available for read and write */
|
||||
public boolean isExternalStorageWritable() {
|
||||
String state = Environment.getExternalStorageState();
|
||||
if (Environment.MEDIA_MOUNTED.equals(state)) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private boolean createAndSaveFileFromBase64Url(String url) {
|
||||
|
||||
try{
|
||||
File path = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS);
|
||||
|
@ -731,7 +753,7 @@ public class geckoSession extends GeckoSession implements GeckoSession.MediaDele
|
|||
String channel_id = createNotificationChannel(mContext.get().getApplicationContext());
|
||||
assert channel_id != null;
|
||||
NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(mContext.get().getApplicationContext(), channel_id)
|
||||
.setSmallIcon(R.xml.ic_download)
|
||||
.setSmallIcon(R.drawable.ic_download)
|
||||
.setContentTitle(filename)
|
||||
.setContentIntent(pIntent);
|
||||
|
||||
|
@ -741,7 +763,7 @@ public class geckoSession extends GeckoSession implements GeckoSession.MediaDele
|
|||
NotificationManager notificationManager = (NotificationManager) mContext.get().getApplicationContext().getSystemService(Context.NOTIFICATION_SERVICE);
|
||||
notificationManager.notify(notificationId, notificationBuilder.build());
|
||||
|
||||
} catch (IOException e) {
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
|
|
|
@ -183,7 +183,7 @@ public class hintAdapter extends RecyclerView.Adapter<hintAdapter.listViewHolder
|
|||
public void run(){
|
||||
try {
|
||||
mHindTypeIconTemp.setImageDrawable(null);
|
||||
mEvent.invokeObserver(Arrays.asList(mHindTypeIconTemp, "https://" + helperMethod.getDomainName(model.getDescription())), enums.etype.fetch_favicon);
|
||||
mEvent.invokeObserver(Arrays.asList(mHindTypeIconTemp, "http://" + helperMethod.getDomainName(model.getDescription())), enums.etype.fetch_favicon);
|
||||
while (true){
|
||||
int mCounter=0;
|
||||
if(mHindTypeIconTemp.isAttachedToWindow() || mHindTypeIconTemp.getDrawable()==null){
|
||||
|
|
|
@ -846,7 +846,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
|
||||
mEdittextChanged.removeCallbacks(postToServerRunnable);
|
||||
mSuggestions = (ArrayList<historyRowModel>)dataController.getInstance().invokeSuggestions(dataEnums.eSuggestionCommands.M_GET_SUGGESTIONS, Collections.singletonList(mText));
|
||||
mEdittextChanged.postDelayed(postToServerRunnable, 150);
|
||||
mEdittextChanged.postDelayed(postToServerRunnable, 350);
|
||||
return;
|
||||
}
|
||||
if(mSuggestions.size()>0){
|
||||
|
@ -859,7 +859,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
mSearchBarLoading = true;
|
||||
mEdittextChanged.postDelayed(postToServerRunnable, 0);
|
||||
}else{
|
||||
mEdittextChanged.postDelayed(postToServerRunnable, 150);
|
||||
mEdittextChanged.postDelayed(postToServerRunnable, 350);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -952,7 +952,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
final Handler handler = new Handler();
|
||||
handler.postDelayed(() -> {
|
||||
mSearchBarLoading = false;
|
||||
}, 150);
|
||||
}, 350);
|
||||
};
|
||||
|
||||
public void onSearchBarInvoked(View view){
|
||||
|
@ -1377,6 +1377,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
pluginController.getInstance().onLanguageInvoke(Collections.singletonList(this), pluginEnums.eLangManager.M_INIT_LOCALE);
|
||||
mHomeViewController.onUpdateSearchEngineBar(false, 0);
|
||||
mNewTab.setPressed(false);
|
||||
pluginController.getInstance().onMessageManagerInvoke(null, M_RESET);
|
||||
}
|
||||
|
||||
status.mThemeApplying = false;
|
||||
|
|
|
@ -206,7 +206,7 @@ public class suggestionDataModel implements SpellCheckerSession.SpellCheckerSess
|
|||
|
||||
if(pQuery.length()>0){
|
||||
if(!pQuery.equals("about:blank")){
|
||||
mCurrentList.add( mSize,new historyRowModel(pQuery, strings.GENERIC_EMPTY_STR,-1));
|
||||
mCurrentList.add( 0,new historyRowModel(pQuery, strings.GENERIC_EMPTY_STR,-1));
|
||||
}
|
||||
}
|
||||
if(mCurrentList.size()<=0) {
|
||||
|
|
|
@ -6,6 +6,7 @@ import android.app.NotificationManager;
|
|||
import android.app.PendingIntent;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.graphics.Color;
|
||||
import android.os.SystemClock;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.app.NotificationCompat;
|
||||
|
@ -53,8 +54,9 @@ class notifictionManager
|
|||
private Notification getNotification () {
|
||||
NotificationCompat.Builder builder = new NotificationCompat.Builder(mAppContext.get().getApplicationContext(), CONST_NOTIFICATION_ID_NAME) ;
|
||||
builder.setContentTitle(CONST_NOTIFICATION_TITLE) ;
|
||||
builder.setSmallIcon(R.drawable.notification_logo);
|
||||
builder.setSmallIcon(R.mipmap.ic_stat_tor_logo);
|
||||
builder.setAutoCancel(true);
|
||||
builder.setColor(Color.parseColor("#84989f"));
|
||||
builder.setChannelId(CONST_NOTIFICATION_ID_NAME);
|
||||
return builder.build();
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@ class orbotManager
|
|||
|
||||
/*Private Variables*/
|
||||
|
||||
private WeakReference<Context> mAppContext;
|
||||
private WeakReference<AppCompatActivity> mAppContext;
|
||||
private boolean mLogsStarted = false;
|
||||
|
||||
/*Initialization*/
|
||||
|
@ -46,7 +46,7 @@ class orbotManager
|
|||
orbotLocalConstants.mIsManualBridge = status.sBridgeGatewayManual;
|
||||
orbotLocalConstants.mManualBridgeType = status.sBridgeCustomType;
|
||||
Prefs.putBridgesEnabled(status.sBridgeStatus);
|
||||
Intent mServiceIntent = new Intent(mAppContext.get().getApplicationContext(), OrbotService.class);
|
||||
Intent mServiceIntent = new Intent(mAppContext.get(), OrbotService.class);
|
||||
mServiceIntent.setAction(ACTION_START);
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
||||
mAppContext.get().getApplicationContext().startForegroundService(mServiceIntent);
|
||||
|
|
Before Width: | Height: | Size: 996 B |
Before Width: | Height: | Size: 511 B After Width: | Height: | Size: 511 B |
After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 978 B After Width: | Height: | Size: 978 B |
After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
After Width: | Height: | Size: 1.9 KiB |
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 831 B |
|
@ -53,6 +53,5 @@ dependencies {
|
|||
implementation 'com.offbynull.portmapper:portmapper:2.0.5'
|
||||
implementation 'info.guardianproject:jtorctl:0.4'
|
||||
implementation 'com.github.tladesignz:IPtProxy:0.5.2'
|
||||
|
||||
testImplementation 'junit:junit:4.13.2'
|
||||
}
|
||||
|
|
|
@ -90,6 +90,8 @@ import java.util.concurrent.TimeoutException;
|
|||
|
||||
import IPtProxy.IPtProxy;
|
||||
|
||||
import static android.content.Intent.FLAG_ACTIVITY_NEW_TASK;
|
||||
|
||||
public class OrbotService extends VpnService implements TorServiceConstants, OrbotConstants {
|
||||
|
||||
public final static String BINARY_TOR_VERSION = org.torproject.android.binary.TorServiceConstants.BINARY_TOR_VERSION;
|
||||
|
@ -195,7 +197,7 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
}
|
||||
|
||||
private void showConnectedToTorNetworkNotification() {
|
||||
showToolbarNotification(getString(R.string.status_activated), NOTIFY_ID, R.drawable.ic_stat_tor_logo);
|
||||
showToolbarNotification(getString(R.string.status_activated), NOTIFY_ID, R.mipmap.ic_stat_tor_logo);
|
||||
}
|
||||
|
||||
private boolean findExistingTorDaemon() {
|
||||
|
@ -262,7 +264,7 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
.setCategory(Notification.CATEGORY_SERVICE)
|
||||
.setContentTitle("Genesis")
|
||||
.setColor(Color.parseColor("#84989f"))
|
||||
.setSmallIcon(R.drawable.ic_stat_tor_logo)
|
||||
.setSmallIcon(R.mipmap.ic_stat_tor_logo)
|
||||
.setOngoing(Prefs.persistNotifications());
|
||||
}
|
||||
|
||||
|
@ -270,9 +272,13 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
if (conn != null) { // only add new identity action when there is a connection
|
||||
Intent intentRefresh = new Intent(CMD_NEWNYM);
|
||||
PendingIntent pendingIntentNewNym = PendingIntent.getBroadcast(this, 0, intentRefresh, PendingIntent.FLAG_UPDATE_CURRENT);
|
||||
mNotifyBuilder.addAction(R.drawable.ic_refresh_white_24dp, getString(R.string.menu_new_identity), pendingIntentNewNym);
|
||||
mNotifyBuilder.addAction(0, getString(R.string.menu_new_identity), pendingIntentNewNym);
|
||||
}
|
||||
|
||||
Intent intentRefresh = new Intent(CMD_setting);
|
||||
PendingIntent pendingIntentNewNym = PendingIntent.getBroadcast(this, 0, intentRefresh, PendingIntent.FLAG_UPDATE_CURRENT);
|
||||
mNotifyBuilder.addAction(0, "Notification Settings", pendingIntentNewNym);
|
||||
|
||||
mNotifyBuilder.setContentText(notifyMsg)
|
||||
.setSmallIcon(icon)
|
||||
.setTicker(notifyType != NOTIFY_ID ? notifyMsg : null);
|
||||
|
@ -320,7 +326,7 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
public void onTaskRemoved(Intent rootIntent) {
|
||||
Log.d(OrbotConstants.TAG, "task removed");
|
||||
Intent intent = new Intent(this, DummyActivity.class);
|
||||
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
||||
intent.addFlags(FLAG_ACTIVITY_NEW_TASK);
|
||||
startActivity(intent);
|
||||
}
|
||||
|
||||
|
@ -512,6 +518,7 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
|
||||
IntentFilter filter = new IntentFilter();
|
||||
filter.addAction(CMD_NEWNYM);
|
||||
filter.addAction(CMD_setting);
|
||||
filter.addAction(CMD_ACTIVE);
|
||||
mActionBroadcastReceiver = new ActionBroadcastReceiver();
|
||||
registerReceiver(mActionBroadcastReceiver, filter);
|
||||
|
@ -1158,12 +1165,16 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
}
|
||||
}
|
||||
|
||||
public void notificationSetting() {
|
||||
|
||||
}
|
||||
|
||||
public void newIdentity() {
|
||||
if (conn != null) { // it is possible to not have a connection yet, and someone might try to newnym
|
||||
new Thread() {
|
||||
public void run() {
|
||||
try {
|
||||
int iconId = R.drawable.ic_stat_tor_logo;
|
||||
int iconId = R.mipmap.ic_stat_tor_logo;
|
||||
|
||||
if (conn != null) {
|
||||
if (mCurrentStatus.equals(STATUS_ON) && Prefs.expandedNotifications())
|
||||
|
@ -1774,7 +1785,10 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
requestTorRereadConfig();
|
||||
} else if (action.equals(CMD_NEWNYM)) {
|
||||
newIdentity();
|
||||
} else if (action.equals(CMD_ACTIVE)) {
|
||||
} else if (action.equals(CMD_setting)) {
|
||||
notificationSetting();
|
||||
}
|
||||
else if (action.equals(CMD_ACTIVE)) {
|
||||
sendSignalActive();
|
||||
} else if (action.equals(CMD_SET_EXIT)) {
|
||||
setExitNode(mIntent.getStringExtra("exit"));
|
||||
|
@ -1857,6 +1871,17 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
return self;
|
||||
}
|
||||
|
||||
public void onSettingRegister(){
|
||||
try {
|
||||
Intent intent = null;
|
||||
intent = new Intent(this, Class.forName("com.darkweb.genesissearchengine.appManager.settingManager.notificationManager.settingNotificationController"));
|
||||
intent.setFlags(FLAG_ACTIVITY_NEW_TASK);
|
||||
getApplicationContext().startActivity(intent);
|
||||
} catch (ClassNotFoundException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
public void disableNotification(){
|
||||
if(mNotificationManager!=null){
|
||||
mNotificationManager.cancel(NOTIFY_ID);
|
||||
|
@ -1867,12 +1892,12 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
|
||||
public void enableTorNotificationNoBandwidth(){
|
||||
orbotLocalConstants.mNotificationStatus = 1;
|
||||
showToolbarNotification("Connected to the Tor network", HS_NOTIFY_ID, R.drawable.ic_stat_tor_logo);
|
||||
showToolbarNotification("Connected to the Tor network", HS_NOTIFY_ID, R.mipmap.ic_stat_tor_logo);
|
||||
}
|
||||
|
||||
public void enableNotification(){
|
||||
orbotLocalConstants.mNotificationStatus = 1;
|
||||
showToolbarNotification(0+"kbps ⇣ / " +0+"kbps ⇡", HS_NOTIFY_ID, R.drawable.ic_stat_tor_logo);
|
||||
showToolbarNotification(0+"kbps ⇣ / " +0+"kbps ⇡", HS_NOTIFY_ID, R.mipmap.ic_stat_tor_logo);
|
||||
}
|
||||
|
||||
private class ActionBroadcastReceiver extends BroadcastReceiver {
|
||||
|
@ -1882,6 +1907,10 @@ public class OrbotService extends VpnService implements TorServiceConstants, Orb
|
|||
newIdentity();
|
||||
break;
|
||||
}
|
||||
case CMD_setting: {
|
||||
onSettingRegister();
|
||||
break;
|
||||
}
|
||||
case CMD_ACTIVE: {
|
||||
sendSignalActive();
|
||||
break;
|
||||
|
|
|
@ -92,11 +92,11 @@ public class TorEventHandler implements EventHandler, TorServiceConstants {
|
|||
|
||||
if (lastWritten > BW_THRESDHOLD || lastRead > BW_THRESDHOLD) {
|
||||
|
||||
int iconId = R.drawable.ic_stat_tor_logo;
|
||||
int iconId = R.mipmap.ic_stat_tor_logo;
|
||||
|
||||
if (read > 0 || written > 0){
|
||||
if(orbotLocalConstants.mIsTorInitialized){
|
||||
iconId = R.drawable.ic_stat_tor_logo;
|
||||
iconId = R.mipmap.ic_stat_tor_logo;
|
||||
}else {
|
||||
iconId = R.drawable.ic_stat_starting_tor_logo;
|
||||
}
|
||||
|
|
|
@ -103,6 +103,7 @@ public interface TorServiceConstants {
|
|||
// actions for internal command Intents
|
||||
String CMD_SIGNAL_HUP = "signal_hup";
|
||||
String CMD_NEWNYM = "newnym";
|
||||
String CMD_setting = "setting";
|
||||
String CMD_SET_EXIT = "setexit";
|
||||
String CMD_ACTIVE = "ACTIVE";
|
||||
|
||||
|
|
Before Width: | Height: | Size: 766 B |
After Width: | Height: | Size: 511 B |
After Width: | Height: | Size: 978 B |
After Width: | Height: | Size: 1.5 KiB |
After Width: | Height: | Size: 2.1 KiB |