|
@ -126,7 +126,7 @@
|
|||
android:configChanges="keyboard|keyboardHidden|mcc|mnc|orientation|screenSize|locale|layoutDirection|smallestScreenSize|screenLayout"
|
||||
android:launchMode="singleTask"
|
||||
android:screenOrientation="portrait"
|
||||
android:windowSoftInputMode="adjustResize">
|
||||
android:windowSoftInputMode="adjustPan|adjustResize">
|
||||
<intent-filter>
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
|
||||
|
|
|
@ -179,6 +179,7 @@ class geckoClients
|
|||
}
|
||||
|
||||
void onBackPressed(boolean isFinishAllowed){
|
||||
mSession.goBackSession();
|
||||
if(mSession.canGoBack()){
|
||||
mSession.goBackSession();
|
||||
}
|
||||
|
|
|
@ -201,6 +201,7 @@ public class geckoSession extends GeckoSession implements GeckoSession.MediaDele
|
|||
|
||||
@Override
|
||||
public void onPageStart(@NonNull GeckoSession var1, @NonNull String var2) {
|
||||
mCanGoBack = true;
|
||||
if(mIsLoaded){
|
||||
if(!isPageLoading){
|
||||
mCurrentTitle = "loading";
|
||||
|
|
|
@ -18,8 +18,10 @@ import android.os.Handler;
|
|||
import android.speech.RecognizerIntent;
|
||||
import android.text.Editable;
|
||||
import android.text.TextWatcher;
|
||||
import android.view.GestureDetector;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
import android.view.WindowManager;
|
||||
import android.view.inputmethod.EditorInfo;
|
||||
import android.webkit.URLUtil;
|
||||
import android.widget.*;
|
||||
|
@ -38,6 +40,7 @@ import com.darkweb.genesissearchengine.appManager.landingManager.landingControll
|
|||
import com.darkweb.genesissearchengine.appManager.languageManager.languageController;
|
||||
import com.darkweb.genesissearchengine.appManager.orbotLogManager.orbotLogController;
|
||||
import com.darkweb.genesissearchengine.appManager.orbotManager.orbotController;
|
||||
import com.darkweb.genesissearchengine.appManager.settingManager.searchEngineManager.settingSearchController;
|
||||
import com.darkweb.genesissearchengine.appManager.settingManager.settingHomePage.settingController;
|
||||
import com.darkweb.genesissearchengine.appManager.tabManager.tabController;
|
||||
import com.darkweb.genesissearchengine.appManager.tabManager.tabRowModel;
|
||||
|
@ -49,6 +52,7 @@ import com.darkweb.genesissearchengine.constants.strings;
|
|||
import com.darkweb.genesissearchengine.dataManager.dataController;
|
||||
import com.darkweb.genesissearchengine.dataManager.dataEnums;
|
||||
import com.darkweb.genesissearchengine.helperManager.KeyboardUtils;
|
||||
import com.darkweb.genesissearchengine.helperManager.SimpleGestureFilter;
|
||||
import com.darkweb.genesissearchengine.helperManager.eventObserver;
|
||||
import com.darkweb.genesissearchengine.helperManager.helperMethod;
|
||||
import com.darkweb.genesissearchengine.pluginManager.pluginController;
|
||||
|
@ -77,6 +81,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
private homeViewController mHomeViewController;
|
||||
private homeModel mHomeModel;
|
||||
private geckoClients mGeckoClient = null;
|
||||
private GestureDetector mSwipeDirectionDetector;
|
||||
|
||||
/*View Webviews*/
|
||||
private NestedGeckoView mGeckoView = null;
|
||||
|
@ -97,16 +102,20 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
private Button mConnectButton;
|
||||
private Button mNewTab;
|
||||
private View mFindBar;
|
||||
private View mSearchEngineBar;
|
||||
private EditText mFindText;
|
||||
private TextView mFindCount;
|
||||
private ImageButton mVoiceInput;
|
||||
private ImageButton mMenu;
|
||||
private FrameLayout mNestedScroll;
|
||||
private ImageView mBlockerFullSceen;
|
||||
private TextView mCopyright;
|
||||
|
||||
/*Redirection Objects*/
|
||||
private boolean mPageClosed = false;
|
||||
private boolean isKeyboardOpened = false;
|
||||
private boolean isSuggestionChanged = false;
|
||||
private String mSearchBarPreviousText = strings.GENERIC_EMPTY_STR;
|
||||
|
||||
/*-------------------------------------------------------INITIALIZATION-------------------------------------------------------*/
|
||||
|
||||
|
@ -133,6 +142,13 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
initializeLocalEventHandlers();
|
||||
initLandingPage();
|
||||
initLocalLanguage();
|
||||
onInitResume(savedInstanceState != null);
|
||||
}
|
||||
|
||||
public void onInitResume(boolean pStatus){
|
||||
if(pStatus){
|
||||
mSplashScreen.animate().alpha(0);
|
||||
}
|
||||
}
|
||||
|
||||
public void onInitTheme(){
|
||||
|
@ -195,7 +211,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
|
||||
if(status.sSettingIsAppStarted){
|
||||
mHomeViewController.onPageFinished();
|
||||
mSplashScreen.setAlpha(0);
|
||||
mSplashScreen.animate().alpha(0);
|
||||
mHomeViewController.onProgressBarUpdate(100);
|
||||
}
|
||||
}
|
||||
|
@ -224,18 +240,21 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
mConnectButton = findViewById(R.id.Connect);
|
||||
mNewTab = findViewById(R.id.pTabCounter);
|
||||
mFindBar = findViewById(R.id.pFindBar);
|
||||
mSearchEngineBar = findViewById(R.id.pSearchEngineBar);
|
||||
mFindText = findViewById(R.id.pFindText);
|
||||
mFindCount = findViewById(R.id.pFindCount);
|
||||
mVoiceInput = findViewById(R.id.pVoiceInput);
|
||||
mMenu = findViewById(R.id.pMenu);
|
||||
mBlocker = findViewById(R.id.pBlocker);
|
||||
mNestedScroll = findViewById(R.id.pNestedScroll);
|
||||
mBlockerFullSceen = findViewById(R.id.pBlockerFullSceen);
|
||||
mCopyright = findViewById(R.id.pCopyright);
|
||||
|
||||
mGeckoView.setSaveEnabled(false);
|
||||
mGeckoView.setSaveFromParentEnabled(false);
|
||||
|
||||
mGeckoClient = new geckoClients();
|
||||
mHomeViewController.initialization(new homeViewCallback(),this,mNewTab, mWebViewContainer, mLoadingText, mProgressBar, mSearchbar, mSplashScreen, mLoadingIcon, mBannerAds,(ArrayList<historyRowModel>)dataController.getInstance().invokeSuggestion(dataEnums.eSuggestionCommands.M_GET_SUGGESTION, null), mGatewaySplash, mTopBar, mGeckoView, mBackSplash, mConnectButton, mFindBar, mFindText, mFindCount, mTopLayout, mVoiceInput, mMenu, mNestedScroll, mBlocker);
|
||||
mHomeViewController.initialization(new homeViewCallback(),this,mNewTab, mWebViewContainer, mLoadingText, mProgressBar, mSearchbar, mSplashScreen, mLoadingIcon, mBannerAds,(ArrayList<historyRowModel>)dataController.getInstance().invokeSuggestion(dataEnums.eSuggestionCommands.M_GET_SUGGESTION, null), mGatewaySplash, mTopBar, mGeckoView, mBackSplash, mConnectButton, mFindBar, mFindText, mFindCount, mTopLayout, mVoiceInput, mMenu, mNestedScroll, mBlocker, mBlockerFullSceen, mSearchEngineBar, mCopyright);
|
||||
mGeckoView.onSetHomeEvent(new nestedGeckoViewCallback());
|
||||
mGeckoClient.initialize(mGeckoView, new geckoViewCallback(), this,false);
|
||||
mGeckoClient.onValidateInitializeFromStartup();
|
||||
|
@ -261,30 +280,10 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
}
|
||||
}
|
||||
|
||||
float oldTouchValue;
|
||||
@Override
|
||||
public boolean dispatchTouchEvent(MotionEvent event) {
|
||||
|
||||
int action=event.getAction();
|
||||
|
||||
switch (action) {
|
||||
case (MotionEvent.ACTION_DOWN):
|
||||
oldTouchValue = event.getX();
|
||||
case (MotionEvent.ACTION_MOVE):
|
||||
if(mSplashScreen.getVisibility()==View.VISIBLE){
|
||||
float currentX = event.getX();
|
||||
if (oldTouchValue < currentX-100)
|
||||
{
|
||||
helperMethod.openActivity(orbotController.class, constants.CONST_LIST_HISTORY, homeController.this,true);
|
||||
}
|
||||
else if (oldTouchValue > currentX+100 )
|
||||
{
|
||||
helperMethod.openActivity(orbotLogController.class, constants.CONST_LIST_HISTORY, homeController.this,true);
|
||||
}
|
||||
}
|
||||
default:
|
||||
return super.onTouchEvent(event);
|
||||
}
|
||||
mSwipeDirectionDetector.onTouchEvent(event);
|
||||
return super.dispatchTouchEvent(event);
|
||||
}
|
||||
|
||||
public void initPreFixes() {
|
||||
|
@ -358,7 +357,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
mGeckoView.setSession(mTempSession);
|
||||
|
||||
mHomeViewController.onClearSelections(false);
|
||||
mHomeViewController.onUpdateSearchBar(mTempSession.getCurrentURL(),false);
|
||||
mHomeViewController.onUpdateSearchBar(mTempSession.getCurrentURL(),false,true);
|
||||
if(mTempSession.getProgress()>0 && mTempSession.getProgress()<100){
|
||||
mHomeViewController.onProgressBarUpdate(mTempSession.getProgress());
|
||||
}else {
|
||||
|
@ -428,7 +427,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
if (actionId == EditorInfo.IME_ACTION_NEXT || actionId == EditorInfo.IME_ACTION_GO || actionId == EditorInfo.IME_ACTION_DONE)
|
||||
{
|
||||
onSearchBarInvoked(v);
|
||||
mHomeViewController.onUpdateSearchBar(mGeckoClient.getSession().getCurrentURL(),true);
|
||||
mHomeViewController.onUpdateSearchBar(mGeckoClient.getSession().getCurrentURL(),true,true);
|
||||
mHomeViewController.onClearSelections(true);
|
||||
mGeckoClient.setLoading(true);
|
||||
final Handler handler = new Handler();
|
||||
|
@ -456,7 +455,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
helperMethod.hideKeyboard(homeController.this);
|
||||
status.sSettingIsAppStarted = true;
|
||||
pluginController.getInstance().onResetMessage();
|
||||
mHomeViewController.onUpdateSearchBar(mGeckoClient.getSession().getCurrentURL(),false);
|
||||
mHomeViewController.onUpdateSearchBar(mGeckoClient.getSession().getCurrentURL(),false,true);
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -477,17 +476,35 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
mSearchbar.setOnFocusChangeListener((v, hasFocus) -> {
|
||||
if(!hasFocus)
|
||||
{
|
||||
mHomeViewController.onUpdateSearchEngineBar(false);
|
||||
getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_ADJUST_RESIZE);
|
||||
mHomeViewController.initSearchBarFocus(false);
|
||||
if(!mGeckoClient.isLoading()){
|
||||
mHomeViewController.onUpdateSearchBar(mGeckoClient.getSession().getCurrentURL(),false);
|
||||
mHomeViewController.onUpdateSearchBar(mGeckoClient.getSession().getCurrentURL(),false,true);
|
||||
}
|
||||
if(isSuggestionChanged){
|
||||
isSuggestionChanged = false;
|
||||
mHomeViewController.initializeSuggestionView((ArrayList<historyRowModel>)dataController.getInstance().invokeSuggestion(dataEnums.eSuggestionCommands.M_GET_SUGGESTION, null));
|
||||
}
|
||||
}else {
|
||||
mHomeViewController.onUpdateSearchEngineBar(true);
|
||||
mHomeViewController.initSearchBarFocus(true);
|
||||
mHomeViewController.onUpdateSearchBar(mGeckoClient.getSession().getCurrentURL(),true);
|
||||
getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_ADJUST_NOTHING);
|
||||
mSearchbar.setText(strings.GENERIC_EMPTY_STR);
|
||||
}
|
||||
});
|
||||
|
||||
mSwipeDirectionDetector=new GestureDetector(this,new SimpleGestureFilter(){
|
||||
|
||||
@Override
|
||||
public boolean onSwipe(Direction direction) {
|
||||
if (direction==Direction.left){
|
||||
helperMethod.openActivity(orbotLogController.class, constants.CONST_LIST_HISTORY, homeController.this, true);
|
||||
}
|
||||
else if (direction==Direction.right){
|
||||
helperMethod.openActivity(orbotController.class, constants.CONST_LIST_HISTORY, homeController.this, true);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -501,15 +518,20 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
if(validated_url!=null){
|
||||
url = validated_url;
|
||||
}
|
||||
mHomeViewController.onUpdateSearchBar(url,false);
|
||||
mHomeViewController.onUpdateSearchBar(url,false,true);
|
||||
onLoadURL(url);
|
||||
}
|
||||
|
||||
public void onSuggestionInvoked(View view){
|
||||
String val = ((TextView)view.findViewById(R.id.hintCompletionUrl)).getText().toString();
|
||||
onLoadURL(val);
|
||||
mSearchbar.setSelection(0);
|
||||
mHomeViewController.onUpdateSearchBar(val,false);
|
||||
//String val = ((TextView)view.findViewById(R.id.hintCompletionUrl)).getText().toString();
|
||||
//onLoadURL(val);
|
||||
//mSearchbar.setSelection(0);
|
||||
//mHomeViewController.onUpdateSearchBar(val,false,true);
|
||||
}
|
||||
|
||||
public void onSuggestionMove(View view){
|
||||
String val = ((ImageButton)view).getTag().toString();
|
||||
mHomeViewController.onUpdateSearchBar(val,false,false);
|
||||
}
|
||||
|
||||
public void applyTheme(){
|
||||
|
@ -532,10 +554,10 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
initializeGeckoView(true, true);
|
||||
if(status.sOpenURLInNewTab){
|
||||
onLoadURL(helperMethod.getDomainName(status.sSettingSearchStatus));
|
||||
mHomeViewController. onUpdateSearchBar(helperMethod.getDomainName(status.sSettingSearchStatus),false);
|
||||
mHomeViewController. onUpdateSearchBar(helperMethod.getDomainName(status.sSettingSearchStatus),false,true);
|
||||
}else {
|
||||
onLoadURL("about:blank");
|
||||
mHomeViewController. onUpdateSearchBar(strings.HOME_BLANK_PAGE,false);
|
||||
mHomeViewController. onUpdateSearchBar(strings.HOME_BLANK_PAGE,false,true);
|
||||
}
|
||||
mHomeViewController.progressBarReset();
|
||||
mHomeViewController.onNewTab(isKeyboardOpened,isKeyboardOpenedTemp);
|
||||
|
@ -544,13 +566,10 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
|
||||
public void onOpenTabViewBoundary(View view){
|
||||
mGeckoClient.onRedrawPixel();
|
||||
final Handler handler = new Handler();
|
||||
mNewTab.setPressed(true);
|
||||
handler.postDelayed(() ->
|
||||
{
|
||||
mGeckoClient.onRedrawPixel();
|
||||
helperMethod.openActivity(tabController.class, constants.CONST_LIST_HISTORY, homeController.this,true);
|
||||
overridePendingTransition(R.anim.popup_anim_in, R.anim.popup_anim_out);
|
||||
}, 100);
|
||||
}
|
||||
|
||||
public void onNotificationInvoked(String message,enums.etype e_type){
|
||||
|
@ -580,6 +599,9 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
if(mFindBar.getVisibility() == View.VISIBLE){
|
||||
mHomeViewController.onUpdateFindBar(false);
|
||||
}
|
||||
else if(mSearchEngineBar.getVisibility() == View.VISIBLE){
|
||||
mHomeViewController.onUpdateSearchEngineBar(false);
|
||||
}
|
||||
else if(mGeckoClient.getFullScreenStatus()){
|
||||
mGeckoClient.onBackPressed(true);
|
||||
mHomeViewController.onClearSelections(true);
|
||||
|
@ -656,9 +678,15 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
}
|
||||
if(status.sSettingIsAppStarted){
|
||||
onStartApplication(null);
|
||||
tabRowModel model = (tabRowModel)dataController.getInstance().invokeTab(dataEnums.eTabCommands.GET_CURRENT_TAB, null);
|
||||
if(model!=null){
|
||||
onLoadTab(model.getSession(),true);
|
||||
}
|
||||
if((int)dataController.getInstance().invokeTab(dataEnums.eTabCommands.GET_TOTAL_TAB, null)<=0){
|
||||
//onNewTab(false, false);
|
||||
}
|
||||
if(!mSearchBarPreviousText.equals(strings.GENERIC_EMPTY_STR)){
|
||||
mSearchbar.setText(mSearchBarPreviousText);
|
||||
mSearchbar.requestFocus();
|
||||
mSearchBarPreviousText = strings.GENERIC_EMPTY_STR;
|
||||
}
|
||||
|
||||
super.onResume();
|
||||
|
@ -670,7 +698,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
if(resultCode == RESULT_OK && null != data){
|
||||
onSearchBarInvoked(mSearchbar);
|
||||
ArrayList<String> result = data.getStringArrayListExtra(RecognizerIntent.EXTRA_RESULTS);
|
||||
mHomeViewController.onUpdateSearchBar(result.get(0),false);
|
||||
mHomeViewController.onUpdateSearchBar(result.get(0),false,true);
|
||||
helperMethod.hideKeyboard(homeController.this);
|
||||
mGeckoClient.setLoading(true);
|
||||
final Handler handler = new Handler();
|
||||
|
@ -752,7 +780,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
initializeGeckoView(true, true);
|
||||
mHomeViewController.progressBarReset();
|
||||
mHomeViewController.onNewTab(false,isKeyboardOpened);
|
||||
mHomeViewController.onUpdateSearchBar(url,false);
|
||||
mHomeViewController.onUpdateSearchBar(url,false,true);
|
||||
mGeckoClient.loadURL(url);
|
||||
}
|
||||
|
||||
|
@ -799,6 +827,11 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
mGeckoClient.getSession().findInPage(mFindText.getText().toString(), GeckoSession.FINDER_FIND_MATCH_CASE & GeckoSession.FINDER_DISPLAY_HIGHLIGHT_ALL);
|
||||
}
|
||||
|
||||
public void onOpenSearchEngine(View view){
|
||||
mSearchBarPreviousText = mSearchbar.getText().toString();
|
||||
helperMethod.openActivity(settingSearchController.class,constants.CONST_LIST_HISTORY, homeController.this,true);
|
||||
}
|
||||
|
||||
public void onFindPrev(View view){
|
||||
mFindText.setText("0/0");
|
||||
mGeckoClient.getSession().findInPage(mFindText.getText().toString(), GeckoSession.FINDER_FIND_BACKWARDS & GeckoSession.FINDER_DISPLAY_HIGHLIGHT_ALL);
|
||||
|
@ -827,6 +860,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
}
|
||||
else if (menuId == R.id.menu9) {
|
||||
helperMethod.hideKeyboard(this);
|
||||
mGeckoClient.onRedrawPixel();
|
||||
helperMethod.openActivity(tabController.class, constants.CONST_LIST_HISTORY, homeController.this,true);
|
||||
}
|
||||
else if (menuId == R.id.menu8) {
|
||||
|
@ -937,7 +971,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
mHomeViewController.onSetBannerAdMargin((boolean)data.get(0),pluginController.getInstance().isAdvertLoaded());
|
||||
}
|
||||
else if(e_type.equals(enums.etype.on_url_load)){
|
||||
mHomeViewController.onUpdateLogs("Starting | Genesis Search");
|
||||
onOpenLinkNewTab(data.get(0).toString());
|
||||
onLoadURL(data.get(0).toString());
|
||||
}
|
||||
else if(e_type.equals(enums.etype.recheck_orbot)){
|
||||
|
@ -982,10 +1016,9 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
mHomeViewController.onProgressBarUpdate((int)data.get(0));
|
||||
}
|
||||
else if(e_type.equals(enums.etype.ON_UPDATE_TITLE_BAR)){
|
||||
mHomeViewController.onUpdateTitleBar((boolean)data.get(0));
|
||||
}
|
||||
else if(e_type.equals(enums.etype.on_url_load)){
|
||||
mHomeViewController.onUpdateSearchBar(dataToStr(data.get(0),mGeckoClient.getSession().getCurrentURL()),false);
|
||||
mHomeViewController.onUpdateSearchBar(dataToStr(data.get(0),mGeckoClient.getSession().getCurrentURL()),false,true);
|
||||
}
|
||||
else if(e_type.equals(enums.etype.back_list_empty)){
|
||||
if((int)dataController.getInstance().invokeTab(dataEnums.eTabCommands.GET_TOTAL_TAB, null)>1){
|
||||
|
@ -1039,10 +1072,10 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
pluginController.getInstance().setLanguage();
|
||||
initLocalLanguage();
|
||||
mHomeViewController.onPageFinished();
|
||||
mHomeViewController.onUpdateSearchBar(dataToStr(data.get(0),mGeckoClient.getSession().getCurrentURL()),false);
|
||||
mHomeViewController.onUpdateSearchBar(dataToStr(data.get(0),mGeckoClient.getSession().getCurrentURL()),false,true);
|
||||
}
|
||||
else if(e_type.equals(enums.etype.search_update)){
|
||||
mHomeViewController.onUpdateSearchBar(dataToStr(data.get(0),mGeckoClient.getSession().getCurrentURL()),false);
|
||||
mHomeViewController.onUpdateSearchBar(dataToStr(data.get(0),mGeckoClient.getSession().getCurrentURL()),false, true);
|
||||
}
|
||||
else if(e_type.equals(enums.etype.download_file_popup)){
|
||||
pluginController.getInstance().MessageManagerHandler(homeController.this,Collections.singletonList(dataToStr(data.get(0))),enums.eMessageEnums.M_DOWNLOAD_FILE);
|
||||
|
@ -1083,10 +1116,9 @@ public class homeController extends AppCompatActivity implements ComponentCallba
|
|||
}
|
||||
else if(e_type.equals(dataEnums.eTabCommands.M_UPDATE_PIXEL)){
|
||||
try{
|
||||
|
||||
dataController.getInstance().invokeTab(dataEnums.eTabCommands.M_UPDATE_PIXEL, Arrays.asList(data.get(1), mGeckoView.capturePixels()));
|
||||
}catch (Exception ignored){
|
||||
|
||||
}catch (Exception EX){
|
||||
EX.printStackTrace();
|
||||
}
|
||||
}
|
||||
else if(e_type.equals(enums.etype.FINDER_RESULT_CALLBACK)){
|
||||
|
|
|
@ -10,6 +10,7 @@ import android.content.pm.ActivityInfo;
|
|||
import android.content.res.Resources;
|
||||
import android.graphics.Color;
|
||||
import android.graphics.drawable.BitmapDrawable;
|
||||
import android.graphics.drawable.ColorDrawable;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.os.Build;
|
||||
import android.os.Handler;
|
||||
|
@ -21,9 +22,9 @@ import android.view.ViewGroup;
|
|||
import android.view.ViewOutlineProvider;
|
||||
import android.view.Window;
|
||||
import android.view.WindowManager;
|
||||
import android.view.animation.AccelerateDecelerateInterpolator;
|
||||
import android.view.animation.Animation;
|
||||
import android.view.animation.AnimationUtils;
|
||||
import android.view.animation.DecelerateInterpolator;
|
||||
import android.view.animation.Transformation;
|
||||
import android.view.inputmethod.EditorInfo;
|
||||
import android.view.inputmethod.InputMethodManager;
|
||||
import android.widget.*;
|
||||
|
@ -31,10 +32,7 @@ import androidx.annotation.RequiresApi;
|
|||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.appcompat.app.AppCompatDelegate;
|
||||
import androidx.constraintlayout.widget.ConstraintLayout;
|
||||
import androidx.coordinatorlayout.widget.CoordinatorLayout;
|
||||
import androidx.core.content.ContextCompat;
|
||||
import androidx.core.widget.NestedScrollView;
|
||||
|
||||
import com.darkweb.genesissearchengine.appManager.historyManager.historyRowModel;
|
||||
import com.darkweb.genesissearchengine.constants.*;
|
||||
import com.darkweb.genesissearchengine.dataManager.dataController;
|
||||
|
@ -55,7 +53,6 @@ import java.util.Collections;
|
|||
import java.util.Objects;
|
||||
import java.util.concurrent.Callable;
|
||||
import static android.content.Context.LAYOUT_INFLATER_SERVICE;
|
||||
import static androidx.appcompat.widget.ListPopupWindow.WRAP_CONTENT;
|
||||
import static org.mozilla.geckoview.GeckoSessionSettings.USER_AGENT_MODE_DESKTOP;
|
||||
|
||||
class homeViewController
|
||||
|
@ -81,6 +78,7 @@ class homeViewController
|
|||
private Button mNewTab;
|
||||
private PopupWindow popupWindow = null;
|
||||
private View mFindBar;
|
||||
private View mSearchEngineBar;
|
||||
private EditText mFindText;
|
||||
private TextView mFindCount;
|
||||
private FrameLayout mTopLayout;
|
||||
|
@ -88,12 +86,14 @@ class homeViewController
|
|||
private ImageButton mMenu;
|
||||
private FrameLayout mNestedScroll;
|
||||
private ImageView mBlocker;
|
||||
private ImageView mBlockerFullSceen;
|
||||
private TextView mCopyright;
|
||||
|
||||
/*Local Variables*/
|
||||
private Callable<String> mLogs = null;
|
||||
private boolean isLandscape = false;
|
||||
|
||||
void initialization(eventObserver.eventListener event, AppCompatActivity context, Button mNewTab, FrameLayout webviewContainer, TextView loadingText, AnimatedProgressBar progressBar, AutoCompleteTextView searchbar, ConstraintLayout splashScreen, ImageView loading, AdView banner_ads, ArrayList<historyRowModel> suggestions, ImageButton gateway_splash, LinearLayout top_bar, GeckoView gecko_view, ImageView backsplash, Button connect_button, View pFindBar, EditText pFindText, TextView pFindCount, FrameLayout pTopLayout, ImageButton pVoiceInput, ImageButton pMenu, FrameLayout pNestedScroll, ImageView pBlocker){
|
||||
void initialization(eventObserver.eventListener event, AppCompatActivity context, Button mNewTab, FrameLayout webviewContainer, TextView loadingText, AnimatedProgressBar progressBar, AutoCompleteTextView searchbar, ConstraintLayout splashScreen, ImageView loading, AdView banner_ads, ArrayList<historyRowModel> suggestions, ImageButton gateway_splash, LinearLayout top_bar, GeckoView gecko_view, ImageView backsplash, Button connect_button, View pFindBar, EditText pFindText, TextView pFindCount, FrameLayout pTopLayout, ImageButton pVoiceInput, ImageButton pMenu, FrameLayout pNestedScroll, ImageView pBlocker, ImageView pBlockerFullSceen, View mSearchEngineBar, TextView pCopyright){
|
||||
this.mContext = context;
|
||||
this.mProgressBar = progressBar;
|
||||
this.mSearchbar = searchbar;
|
||||
|
@ -118,6 +118,9 @@ class homeViewController
|
|||
this.mMenu = pMenu;
|
||||
this.mNestedScroll = pNestedScroll;
|
||||
this.mBlocker = pBlocker;
|
||||
this.mBlockerFullSceen = pBlockerFullSceen;
|
||||
this.mSearchEngineBar = mSearchEngineBar;
|
||||
this.mCopyright = pCopyright;
|
||||
|
||||
initSplashScreen();
|
||||
initializeSuggestionView(suggestions);
|
||||
|
@ -216,7 +219,7 @@ class homeViewController
|
|||
animatedColor ThreeToFour = new animatedColor(ContextCompat.getColor(mContext, R.color.c_background), ContextCompat.getColor(mContext, R.color.c_background));
|
||||
|
||||
ValueAnimator animator = ObjectAnimator.ofFloat(0f, 1f).setDuration(0);
|
||||
animator.setStartDelay(600);
|
||||
animator.setStartDelay(1200);
|
||||
animator.addUpdateListener(animation ->
|
||||
{
|
||||
float v = (float) animation.getAnimatedValue();
|
||||
|
@ -269,25 +272,15 @@ class homeViewController
|
|||
return;
|
||||
}
|
||||
|
||||
|
||||
autoCompleteAdapter suggestionAdapter = new autoCompleteAdapter(mContext, R.layout.hint_view, (ArrayList<historyRowModel>) suggestions.clone());
|
||||
|
||||
int width = Math.round(helperMethod.screenWidth());
|
||||
mSearchbar.setThreshold(2);
|
||||
mSearchbar.setAdapter(suggestionAdapter);
|
||||
mSearchbar.setDropDownVerticalOffset(helperMethod.pxFromDp(8));
|
||||
mSearchbar.setDropDownVerticalOffset(helperMethod.pxFromDp(0));
|
||||
mSearchbar.setDropDownWidth(width);
|
||||
mSearchbar.setDropDownHeight(WRAP_CONTENT);
|
||||
|
||||
Drawable drawable;
|
||||
Resources res = mContext.getResources();
|
||||
try {
|
||||
drawable = Drawable.createFromXml(res, res.getXml(R.xml.hox_rounded_corner_suggestion));
|
||||
mSearchbar.setDropDownBackgroundDrawable(drawable);
|
||||
mSearchbar.setOutlineProvider(ViewOutlineProvider.BACKGROUND);
|
||||
mSearchbar.setClipToOutline(true);
|
||||
} catch (Exception ignored) {
|
||||
}
|
||||
mSearchbar.setDropDownBackgroundDrawable(new ColorDrawable(mContext.getResources().getColor(R.color.c_background)));
|
||||
mSearchbar.setDropDownHeight(helperMethod.getScreenHeight(mContext)*75/100);
|
||||
mSearchbar.setInputType(EditorInfo.TYPE_TEXT_FLAG_NO_SUGGESTIONS);
|
||||
}
|
||||
|
||||
|
@ -297,18 +290,23 @@ class homeViewController
|
|||
mLoading.setAnimation(helperMethod.getRotationAnimation());
|
||||
mLoadingText.setAlpha(0);
|
||||
mLoadingText.setVisibility(View.VISIBLE);
|
||||
mLoadingText.animate().alpha(1);
|
||||
mLoadingText.animate().setStartDelay(0).alpha(1);
|
||||
|
||||
mConnectButton.setClickable(false);
|
||||
mGatewaySplash.setClickable(false);
|
||||
mBlocker.setClickable(true);
|
||||
mBlocker.setFocusable(true);
|
||||
}
|
||||
|
||||
void initHomePage(){
|
||||
mConnectButton.setClickable(false);
|
||||
mGatewaySplash.setClickable(false);
|
||||
|
||||
mConnectButton.animate().alpha(0.4f).withEndAction(this::initSplashLoading);
|
||||
mGatewaySplash.animate().alpha(0.4f);
|
||||
mConnectButton.animate().setDuration(200).alpha(0.4f).withEndAction(() -> {
|
||||
mCopyright.setVisibility(View.GONE);
|
||||
initSplashLoading();
|
||||
});
|
||||
mGatewaySplash.animate().setDuration(200).alpha(0.4f);
|
||||
}
|
||||
|
||||
private void initSplashScreen(){
|
||||
|
@ -327,7 +325,7 @@ class homeViewController
|
|||
void initProxyLoading(Callable<String> logs){
|
||||
this.mLogs = logs;
|
||||
|
||||
if(mSplashScreen.getAlpha()==1){
|
||||
if(mSplashScreen.getVisibility()==View.VISIBLE){
|
||||
new Thread(){
|
||||
public void run(){
|
||||
AppCompatActivity temp_context = mContext;
|
||||
|
@ -365,9 +363,9 @@ class homeViewController
|
|||
}
|
||||
private void splashScreenDisable(){
|
||||
mTopBar.setAlpha(1);
|
||||
if(mSplashScreen.getAlpha()>=1)
|
||||
if(mSplashScreen.getVisibility()==View.VISIBLE)
|
||||
{
|
||||
mSplashScreen.animate().setDuration(300).setStartDelay(500).alpha(0).withEndAction((this::triggerPostUI));
|
||||
mSplashScreen.animate().setStartDelay(1000).setDuration(500).alpha(0).withEndAction((this::triggerPostUI));
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
|
||||
initStatusBarColor();
|
||||
}
|
||||
|
@ -516,7 +514,7 @@ class homeViewController
|
|||
|
||||
private Handler searchBarUpdateHandler = new Handler();
|
||||
private String handlerLocalUrl = "";
|
||||
void onUpdateSearchBar(String url,boolean showProtocol){
|
||||
void onUpdateSearchBar(String url,boolean showProtocol, boolean pClearText){
|
||||
int delay = 0;
|
||||
handlerLocalUrl = url;
|
||||
|
||||
|
@ -528,7 +526,7 @@ class homeViewController
|
|||
searchBarUpdateHandler.postDelayed(() ->
|
||||
{
|
||||
searchBarUpdateHandler.removeMessages(100);
|
||||
triggerUpdateSearchBar(handlerLocalUrl,showProtocol);
|
||||
triggerUpdateSearchBar(handlerLocalUrl,showProtocol, pClearText);
|
||||
|
||||
}, delay);
|
||||
}
|
||||
|
@ -562,7 +560,22 @@ class homeViewController
|
|||
}
|
||||
}
|
||||
|
||||
private void triggerUpdateSearchBar(String url, boolean showProtocol){
|
||||
public void onUpdateSearchEngineBar(boolean pStatus)
|
||||
{
|
||||
mSearchEngineBar.animate().cancel();
|
||||
if(pStatus){
|
||||
mSearchEngineBar.setAlpha(0f);
|
||||
mSearchEngineBar.animate().setDuration(300).alpha(1);
|
||||
mSearchEngineBar.setVisibility(View.VISIBLE);
|
||||
}else {
|
||||
mSearchEngineBar.animate().setDuration(300).alpha(0).withEndAction(() -> {
|
||||
mSearchEngineBar.setAlpha(0f);
|
||||
mSearchEngineBar.setVisibility(View.GONE);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
private void triggerUpdateSearchBar(String url, boolean showProtocol, boolean pClearText){
|
||||
if (mSearchbar == null || url==null)
|
||||
{
|
||||
return;
|
||||
|
@ -608,22 +621,10 @@ class homeViewController
|
|||
|
||||
void onNewTab(boolean keyboard,boolean isKeyboardOpen){
|
||||
if(keyboard){
|
||||
|
||||
if(!isKeyboardOpen){
|
||||
final Handler handler = new Handler();
|
||||
handler.postDelayed(() ->
|
||||
{
|
||||
InputMethodManager imm = (InputMethodManager) mContext.getSystemService(Context.INPUT_METHOD_SERVICE);
|
||||
Objects.requireNonNull(imm).toggleSoftInput(InputMethodManager.RESULT_UNCHANGED_SHOWN, 0);
|
||||
}, 250);
|
||||
}
|
||||
|
||||
mSearchbar.requestFocus();
|
||||
mSearchbar.selectAll();
|
||||
}
|
||||
}
|
||||
Handler mProgressHandler = new Handler();
|
||||
Runnable mProgressBarRunnable = null;
|
||||
|
||||
void onUpdateLogs(String log){
|
||||
mLoadingText.setText(log);
|
||||
|
@ -635,62 +636,59 @@ class homeViewController
|
|||
}
|
||||
|
||||
void onProgressBarUpdate(int value){
|
||||
if(mProgressBarRunnable!=null){
|
||||
mProgressHandler.removeCallbacks(mProgressBarRunnable);
|
||||
}
|
||||
|
||||
if(mSplashScreen.getAlpha()>0){
|
||||
mProgressBar.setProgress(value*100);
|
||||
}
|
||||
if(value==100){
|
||||
mProgressBar.setAlpha(1f);
|
||||
|
||||
setProgressAnimate(mProgressBar,value);
|
||||
|
||||
mProgressBarRunnable = () -> {
|
||||
animation.removeAllListeners();
|
||||
animation.end();
|
||||
animation.cancel();
|
||||
mProgressBar.animate().cancel();
|
||||
mProgressBar.animate().alpha(0);
|
||||
};
|
||||
mProgressHandler.postDelayed(mProgressBarRunnable, 250);
|
||||
|
||||
return;
|
||||
}
|
||||
else if(mSplashScreen.getAlpha()==0) {
|
||||
mProgressBar.setVisibility(View.VISIBLE);
|
||||
|
||||
ProgressBarAnimation mProgressAnimation = new ProgressBarAnimation(mProgressBar, 1000);
|
||||
mProgressAnimation.setProgress(value*100);
|
||||
}
|
||||
|
||||
public class ProgressBarAnimation extends Animation {
|
||||
private ProgressBar mProgressBar;
|
||||
private int mTo;
|
||||
private int mFrom;
|
||||
private long mStepDuration;
|
||||
|
||||
/**
|
||||
* @param fullDuration - time required to fill progress from 0% to 100%
|
||||
*/
|
||||
public ProgressBarAnimation(ProgressBar progressBar, long fullDuration) {
|
||||
super();
|
||||
mProgressBar = progressBar;
|
||||
mStepDuration = fullDuration / progressBar.getMax();
|
||||
}
|
||||
|
||||
|
||||
public void setProgress(int progress) {
|
||||
if(progress == 10000){
|
||||
mProgressBar.animate().setStartDelay(100).alpha(0);
|
||||
}else {
|
||||
mProgressBar.animate().cancel();
|
||||
mProgressBar.animate().setStartDelay(50).alpha(1);
|
||||
}
|
||||
setProgressAnimate(mProgressBar,value);
|
||||
mProgressBar.setAlpha(1);
|
||||
}
|
||||
|
||||
private ObjectAnimator animation = null;
|
||||
private void setProgressAnimate(ProgressBar pb, int progressTo)
|
||||
{
|
||||
int progress = 0;
|
||||
if((progressTo)<mProgressBar.getProgress()){
|
||||
progress = 5;
|
||||
if (progress < 0) {
|
||||
progress = 0;
|
||||
}
|
||||
|
||||
if(animation!=null){
|
||||
animation.removeAllListeners();
|
||||
animation.end();
|
||||
animation.cancel();
|
||||
if (progress > mProgressBar.getMax()) {
|
||||
progress = mProgressBar.getMax();
|
||||
}
|
||||
|
||||
animation = ObjectAnimator.ofInt(pb, "progress", pb.getProgress(), progressTo * 100);
|
||||
animation.setDuration(progress);
|
||||
animation.setInterpolator(new DecelerateInterpolator());
|
||||
animation.setAutoCancel(true);
|
||||
animation.start();
|
||||
mTo = progress;
|
||||
|
||||
mFrom = mProgressBar.getProgress();
|
||||
setDuration(Math.abs(mTo - mFrom) * mStepDuration);
|
||||
mProgressBar.startAnimation(this);
|
||||
}
|
||||
|
||||
void onUpdateTitleBar(boolean pStatus){
|
||||
|
||||
@Override
|
||||
protected void applyTransformation(float interpolatedTime, Transformation t) {
|
||||
float value = mFrom + (mTo - mFrom) * interpolatedTime;
|
||||
mProgressBar.setProgress((int) value);
|
||||
}
|
||||
}
|
||||
|
||||
void onClearSelections(boolean hideKeyboard){
|
||||
mSearchbar.setFocusable(false);
|
||||
mSearchbar.setFocusableInTouchMode(true);
|
||||
|
@ -716,10 +714,21 @@ class homeViewController
|
|||
void onFullScreenUpdate(boolean status){
|
||||
int value = !status ? 1 : 0;
|
||||
|
||||
this.mBlocker.setVisibility(View.VISIBLE);
|
||||
this.mBlocker.setAlpha(1f);
|
||||
|
||||
if(status) {
|
||||
}else {
|
||||
this.mBlockerFullSceen.setVisibility(View.VISIBLE);
|
||||
this.mBlockerFullSceen.setAlpha(1f);
|
||||
}
|
||||
|
||||
if(status){
|
||||
this.mBlockerFullSceen.setVisibility(View.VISIBLE);
|
||||
this.mBlockerFullSceen.setAlpha(0f);
|
||||
this.mBlockerFullSceen.animate().setStartDelay(0).setDuration(200).alpha(1).withEndAction(() -> {
|
||||
mTopBar.setClickable(!status);
|
||||
disableEnableControls(!status, mTopBar);
|
||||
mTopBar.setAlpha(value);
|
||||
mBannerAds.setVisibility(View.GONE);
|
||||
|
||||
defaultFlag = mContext.getWindow().getDecorView().getSystemUiVisibility();
|
||||
final int flags = View.SYSTEM_UI_FLAG_LAYOUT_STABLE
|
||||
| View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
|
||||
|
@ -728,18 +737,7 @@ class homeViewController
|
|||
| View.SYSTEM_UI_FLAG_FULLSCREEN
|
||||
| View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY;
|
||||
mContext.getWindow().getDecorView().setSystemUiVisibility(flags);
|
||||
}else {
|
||||
}
|
||||
|
||||
final Handler handler = new Handler();
|
||||
handler.postDelayed(() ->
|
||||
{
|
||||
mTopBar.setClickable(!status);
|
||||
disableEnableControls(!status, mTopBar);
|
||||
mTopBar.setAlpha(value);
|
||||
mBannerAds.setVisibility(View.GONE);
|
||||
|
||||
if(status){
|
||||
mProgressBar.setVisibility(View.GONE);
|
||||
mTopBar.setVisibility(View.GONE);
|
||||
mBannerAds.setVisibility(View.GONE);
|
||||
|
@ -755,11 +753,17 @@ class homeViewController
|
|||
com.darkweb.genesissearchengine.constants.status.sFullScreenBrowsing = false;
|
||||
initTopBarPadding();
|
||||
|
||||
this.mBlocker.animate().setStartDelay(250).setDuration(200).alpha(0).withEndAction(() -> {
|
||||
mBlocker.setVisibility(View.GONE);
|
||||
this.mBlockerFullSceen.animate().setStartDelay(100).setDuration(200).alpha(0).withEndAction(() -> {
|
||||
mBlockerFullSceen.setVisibility(View.GONE);
|
||||
});
|
||||
});
|
||||
}
|
||||
else {
|
||||
mTopBar.setClickable(!status);
|
||||
disableEnableControls(!status, mTopBar);
|
||||
mTopBar.setAlpha(value);
|
||||
mBannerAds.setVisibility(View.GONE);
|
||||
|
||||
mProgressBar.setVisibility(View.VISIBLE);
|
||||
mTopBar.setVisibility(View.VISIBLE);
|
||||
mBannerAds.setVisibility(View.GONE);
|
||||
|
@ -770,23 +774,22 @@ class homeViewController
|
|||
mWebviewContainer.setLayoutParams(params);
|
||||
|
||||
ViewGroup.MarginLayoutParams params1 = (ViewGroup.MarginLayoutParams) mWebviewContainer.getLayoutParams();
|
||||
params1.setMargins(0, 0, 0,helperMethod.pxFromDp(60));
|
||||
params1.setMargins(0, 0, 0,helperMethod.pxFromDp(0));
|
||||
mGeckoView.setLayoutParams(params1);
|
||||
|
||||
com.darkweb.genesissearchengine.constants.status.sFullScreenBrowsing = (boolean) dataController.getInstance().invokePrefs(dataEnums.ePreferencesCommands.M_GET_BOOL, Arrays.asList(keys.SETTING_FULL_SCREEN_BROWSIING,true));
|
||||
initTopBarPadding();
|
||||
|
||||
this.mBlocker.animate().setStartDelay(250).setDuration(200).alpha(0).withEndAction(() -> {
|
||||
mBlocker.setVisibility(View.GONE);
|
||||
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
|
||||
mContext.getWindow().getDecorView().setSystemUiVisibility(View.SYSTEM_UI_FLAG_LIGHT_STATUS_BAR);
|
||||
}else {
|
||||
mContext.getWindow().setStatusBarColor(mContext.getResources().getColor(R.color.blue_dark));
|
||||
}
|
||||
|
||||
this.mBlockerFullSceen.animate().setStartDelay(0).setDuration(200).alpha(0).withEndAction(() -> {
|
||||
mBlockerFullSceen.setVisibility(View.GONE);
|
||||
});
|
||||
}
|
||||
}, 200);
|
||||
|
||||
}
|
||||
|
||||
|
@ -849,6 +852,9 @@ class homeViewController
|
|||
}
|
||||
}
|
||||
}
|
||||
if(msg.what == messages.MESSAGE_PROGRESSBAR_VALIDATE)
|
||||
{
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,21 +1,21 @@
|
|||
package com.darkweb.genesissearchengine.appManager.orbotLogManager;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.view.GestureDetector;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
import android.view.animation.AnimationUtils;
|
||||
import android.view.animation.LayoutAnimationController;
|
||||
import android.widget.TextView;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.view.MotionEventCompat;
|
||||
import androidx.core.widget.NestedScrollView;
|
||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
import com.darkweb.genesissearchengine.appManager.activityContextManager;
|
||||
import com.darkweb.genesissearchengine.appManager.helpManager.helpController;
|
||||
import com.darkweb.genesissearchengine.appManager.settingManager.logManager.settingLogController;
|
||||
import com.darkweb.genesissearchengine.constants.constants;
|
||||
import com.darkweb.genesissearchengine.constants.status;
|
||||
import com.darkweb.genesissearchengine.helperManager.SimpleGestureFilter;
|
||||
import com.darkweb.genesissearchengine.helperManager.eventObserver;
|
||||
import com.darkweb.genesissearchengine.helperManager.helperMethod;
|
||||
import com.example.myapplication.R;
|
||||
|
@ -36,19 +36,22 @@ public class orbotLogController extends AppCompatActivity {
|
|||
|
||||
private TextView mLogs;
|
||||
private boolean mActivityClosed = false;
|
||||
int mLogCounter = 0;
|
||||
private int mLogCounter = 0;
|
||||
private GestureDetector mSwipeDirectionDetector;
|
||||
|
||||
/* INITIALIZATIONS */
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
overridePendingTransition(R.anim.push_anim_out_reverse, R.anim.push_anim_in_reverse);
|
||||
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.orbot_log_view);
|
||||
|
||||
viewsInitializations();
|
||||
onUpdateLogs();
|
||||
initializeLogs();
|
||||
onScrollListener();
|
||||
onInitListener();
|
||||
}
|
||||
|
||||
public void viewsInitializations() {
|
||||
|
@ -60,6 +63,7 @@ public class orbotLogController extends AppCompatActivity {
|
|||
activityContextManager.getInstance().setOrbotLogController(this);
|
||||
mOrbotViewController = new orbotLogViewController(this, mLogs, mRecycleView);
|
||||
mOrbotModel = new orbotLogModel();
|
||||
|
||||
}
|
||||
|
||||
public void initializeLogs(){
|
||||
|
@ -90,7 +94,7 @@ public class orbotLogController extends AppCompatActivity {
|
|||
|
||||
/* LISTENERS */
|
||||
|
||||
private void onScrollListener(){
|
||||
private void onInitListener(){
|
||||
mMainScroll.getViewTreeObserver().addOnScrollChangedListener(() -> {
|
||||
int scrollY = mMainScroll.getScrollY();
|
||||
if(scrollY>0){
|
||||
|
@ -103,6 +107,18 @@ public class orbotLogController extends AppCompatActivity {
|
|||
mFloatingScroller.animate().alpha(0).withEndAction(() -> mFloatingScroller.setVisibility(View.GONE));
|
||||
}
|
||||
});
|
||||
|
||||
mSwipeDirectionDetector=new GestureDetector(this,new SimpleGestureFilter(){
|
||||
|
||||
@Override
|
||||
public boolean onSwipe(Direction direction) {
|
||||
if (direction==Direction.left || direction==Direction.right){
|
||||
finish();
|
||||
overridePendingTransition(R.anim.push_anim_in, R.anim.push_anim_out);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public void onUpdateLogs(){
|
||||
|
@ -161,6 +177,14 @@ public class orbotLogController extends AppCompatActivity {
|
|||
}
|
||||
}
|
||||
|
||||
/* Helper Methods */
|
||||
|
||||
public void onClose(View view){
|
||||
finish();
|
||||
overridePendingTransition(R.anim.push_anim_in, R.anim.push_anim_out);
|
||||
mActivityClosed = true;
|
||||
}
|
||||
|
||||
/* LOCAL OVERRIDES */
|
||||
|
||||
@Override
|
||||
|
@ -178,42 +202,13 @@ public class orbotLogController extends AppCompatActivity {
|
|||
|
||||
@Override
|
||||
public void onBackPressed() {
|
||||
finish();
|
||||
mActivityClosed = true;
|
||||
onClose(null);
|
||||
}
|
||||
|
||||
/* Helper Methods */
|
||||
|
||||
public void openLogSettings(View view) {
|
||||
helperMethod.openActivity(settingLogController.class, constants.CONST_LIST_HISTORY, this,true);
|
||||
}
|
||||
|
||||
public void onClose(View view){
|
||||
finish();
|
||||
mActivityClosed = true;
|
||||
}
|
||||
|
||||
float oldTouchValue;
|
||||
@Override
|
||||
public boolean dispatchTouchEvent(MotionEvent event) {
|
||||
|
||||
int action=event.getAction();
|
||||
|
||||
switch (action) {
|
||||
case (MotionEvent.ACTION_DOWN):
|
||||
oldTouchValue = event.getX();
|
||||
case (MotionEvent.ACTION_MOVE):
|
||||
float currentX = event.getX();
|
||||
if (oldTouchValue < currentX-100)
|
||||
{
|
||||
finish();
|
||||
}else {
|
||||
return super.onTouchEvent(event);
|
||||
}
|
||||
default:
|
||||
return super.onTouchEvent(event);
|
||||
}
|
||||
|
||||
mSwipeDirectionDetector.onTouchEvent(event);
|
||||
return super.dispatchTouchEvent(event);
|
||||
}
|
||||
|
||||
}
|
|
@ -1,22 +1,20 @@
|
|||
package com.darkweb.genesissearchengine.appManager.orbotManager;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.view.GestureDetector;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
import android.widget.LinearLayout;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.view.MotionEventCompat;
|
||||
|
||||
import com.darkweb.genesissearchengine.appManager.activityContextManager;
|
||||
import com.darkweb.genesissearchengine.appManager.bridgeManager.bridgeController;
|
||||
import com.darkweb.genesissearchengine.appManager.helpManager.helpController;
|
||||
import com.darkweb.genesissearchengine.appManager.homeManager.homeController;
|
||||
import com.darkweb.genesissearchengine.appManager.orbotLogManager.orbotLogController;
|
||||
import com.darkweb.genesissearchengine.constants.constants;
|
||||
import com.darkweb.genesissearchengine.constants.keys;
|
||||
import com.darkweb.genesissearchengine.constants.status;
|
||||
import com.darkweb.genesissearchengine.dataManager.dataController;
|
||||
import com.darkweb.genesissearchengine.dataManager.dataEnums;
|
||||
import com.darkweb.genesissearchengine.helperManager.SimpleGestureFilter;
|
||||
import com.darkweb.genesissearchengine.helperManager.eventObserver;
|
||||
import com.darkweb.genesissearchengine.helperManager.helperMethod;
|
||||
import com.darkweb.genesissearchengine.pluginManager.pluginController;
|
||||
|
@ -35,16 +33,20 @@ public class orbotController extends AppCompatActivity {
|
|||
private SwitchMaterial mBridgeSwitch;
|
||||
private SwitchMaterial mVpnSwitch;
|
||||
private LinearLayout mCustomizableBridgeMenu;
|
||||
private GestureDetector mSwipeDirectionDetector;
|
||||
|
||||
/* INITIALIZATIONS */
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
overridePendingTransition(R.anim.push_anim_in, R.anim.push_anim_out);
|
||||
|
||||
pluginController.getInstance().onCreate(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.orbot_settings_view);
|
||||
|
||||
viewsInitializations();
|
||||
onInitListener();
|
||||
}
|
||||
|
||||
public void viewsInitializations() {
|
||||
|
@ -63,6 +65,19 @@ public class orbotController extends AppCompatActivity {
|
|||
|
||||
/* LISTENERS */
|
||||
|
||||
private void onInitListener(){
|
||||
mSwipeDirectionDetector=new GestureDetector(this,new SimpleGestureFilter(){
|
||||
|
||||
@Override
|
||||
public boolean onSwipe(Direction direction) {
|
||||
if (direction==Direction.left || direction==Direction.right){
|
||||
onClose(null);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public class orbotModelCallback implements eventObserver.eventListener{
|
||||
@Override
|
||||
public Object invokeObserver(List<Object> data, Object e_type)
|
||||
|
@ -87,6 +102,11 @@ public class orbotController extends AppCompatActivity {
|
|||
dataController.getInstance().invokePrefs(dataEnums.ePreferencesCommands.M_SET_BOOL, Arrays.asList(keys.BRIDGE_VPN_ENABLED,status.sBridgeVPNStatus));
|
||||
}
|
||||
|
||||
public void onClose(View view){
|
||||
finish();
|
||||
overridePendingTransition(R.anim.push_anim_out_reverse, R.anim.push_anim_in_reverse);
|
||||
}
|
||||
|
||||
/* LOCAL OVERRIDES */
|
||||
|
||||
@Override
|
||||
|
@ -105,33 +125,13 @@ public class orbotController extends AppCompatActivity {
|
|||
|
||||
@Override
|
||||
public void onBackPressed() {
|
||||
finish();
|
||||
onClose(null);
|
||||
}
|
||||
|
||||
public void onClose(View view){
|
||||
finish();
|
||||
}
|
||||
|
||||
float oldTouchValue;
|
||||
@Override
|
||||
public boolean dispatchTouchEvent(MotionEvent event) {
|
||||
|
||||
int action=event.getAction();
|
||||
|
||||
switch (action) {
|
||||
case (MotionEvent.ACTION_DOWN):
|
||||
oldTouchValue = event.getX();
|
||||
case (MotionEvent.ACTION_MOVE):
|
||||
float currentX = event.getX();
|
||||
if (oldTouchValue < currentX-100)
|
||||
{
|
||||
finish();
|
||||
}else {
|
||||
return super.onTouchEvent(event);
|
||||
}
|
||||
default:
|
||||
return super.onTouchEvent(event);
|
||||
mSwipeDirectionDetector.onTouchEvent(event);
|
||||
return super.dispatchTouchEvent(event);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -122,11 +122,8 @@ public class tabController extends AppCompatActivity
|
|||
|
||||
public void onSwiped(RecyclerView.ViewHolder viewHolder, int direction) {
|
||||
int position = viewHolder.getAdapterPosition();
|
||||
|
||||
onClearTabBackup();
|
||||
onRemoveTab(position);
|
||||
mTabAdapter.notifyItemRemoved(position);
|
||||
initTabCount();
|
||||
onRemoveView(position);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -154,9 +151,8 @@ public class tabController extends AppCompatActivity
|
|||
}
|
||||
|
||||
public void onRemoveView(int pIndex){
|
||||
mHomeController.onCloseCurrentTab(mListModel.getList().get(pIndex).getSession());
|
||||
onClearTabBackup();
|
||||
//onRemoveTab(pIndex);
|
||||
onRemoveTab(pIndex);
|
||||
mListModel.getList().remove(pIndex);
|
||||
mTabAdapter.notifyItemRemoved(pIndex);
|
||||
onShowUndoDialog();
|
||||
}
|
||||
|
@ -167,9 +163,17 @@ public class tabController extends AppCompatActivity
|
|||
mHomeController.initTabCount();
|
||||
}
|
||||
|
||||
public void onClose(){
|
||||
onClearTabBackup();
|
||||
if(mListModel.getList().size()<=0){
|
||||
mHomeController.onNewTab(false, false);
|
||||
}
|
||||
finish();
|
||||
}
|
||||
|
||||
public void onNewTabInvoked(){
|
||||
mHomeController.onNewTab(true,false);
|
||||
finish();
|
||||
onClose();
|
||||
overridePendingTransition(R.anim.popup_anim_in, R.anim.popup_anim_out);
|
||||
}
|
||||
|
||||
|
@ -213,11 +217,11 @@ public class tabController extends AppCompatActivity
|
|||
onNewTabInvoked();
|
||||
}
|
||||
else if(pView.getId() == R.id.pCloseTab){
|
||||
mListModel.getList().clear();
|
||||
mtabViewController.onTrigger(tabEnums.eTabViewCommands.M_DISMISS_MENU, null);
|
||||
initTabCount();
|
||||
mRecycleView.animate().setDuration(300).alpha(0).withEndAction(() -> mTabAdapter.notifyDataSetChanged());
|
||||
onShowUndoDialog();
|
||||
for(int mCounter=0;mCounter<mListModel.getList().size();mCounter++){
|
||||
onRemoveView(mCounter);
|
||||
mCounter-=1;
|
||||
}
|
||||
}
|
||||
else if(pView.getId() == R.id.pOpenSetting){
|
||||
mtabViewController.onTrigger(tabEnums.eTabViewCommands.M_DISMISS_MENU, null);
|
||||
|
@ -231,7 +235,7 @@ public class tabController extends AppCompatActivity
|
|||
if(status.sSettingIsAppPaused && (level==80 || level==15))
|
||||
{
|
||||
dataController.getInstance().invokePrefs(dataEnums.ePreferencesCommands.M_SET_BOOL, Arrays.asList(keys.HOME_LOW_MEMORY,true));
|
||||
finish();
|
||||
onClose();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -262,7 +266,7 @@ public class tabController extends AppCompatActivity
|
|||
onClearSelection(null);
|
||||
}else {
|
||||
super.onBackPressed();
|
||||
finish();
|
||||
onClose();
|
||||
overridePendingTransition(R.anim.popup_anim_in, R.anim.popup_anim_out);
|
||||
}
|
||||
}
|
||||
|
@ -295,6 +299,7 @@ public class tabController extends AppCompatActivity
|
|||
mHomeController.onLoadTab((geckoSession)data.get(0),(boolean)data.get(1));
|
||||
}
|
||||
else if(e_type.equals(tabEnums.eTabAdapterCallback.ON_REMOVE_TAB_VIEW)){
|
||||
onClearTabBackup();
|
||||
onRemoveView((Integer) data.get(0));
|
||||
}
|
||||
return null;
|
||||
|
|
|
@ -21,17 +21,20 @@ class tabModel
|
|||
}
|
||||
|
||||
public void onRemoveTab(int pIndex){
|
||||
mBackupIndex.add(mModelList.remove(pIndex));
|
||||
mBackupIndex.add(mModelList.get(pIndex));
|
||||
}
|
||||
|
||||
public void onClearBackup(){
|
||||
for(int mCounter=0;mCounter<mBackupIndex.size();mCounter++){
|
||||
mBackupIndex.get(mCounter).getSession().closeSession();
|
||||
}
|
||||
mBackupIndex.clear();
|
||||
}
|
||||
|
||||
public int onLoadBackup(){
|
||||
int mSize = mBackupIndex.size();
|
||||
for(int mCounter=0;mCounter<mBackupIndex.size();mCounter++){
|
||||
mModelList.add(0,mBackupIndex.remove(mCounter));
|
||||
mModelList.add(0,mBackupIndex.remove(mBackupIndex.size()-1));
|
||||
mCounter-=1;
|
||||
}
|
||||
return mSize;
|
||||
|
|
|
@ -105,7 +105,7 @@ class tabViewController
|
|||
mTabOptionMenu.setBackgroundDrawable(new ColorDrawable(Color.TRANSPARENT));
|
||||
mTabOptionMenu.setAnimationStyle(R.style.popup_window_animation);
|
||||
mTabOptionMenu.setElevation(7);
|
||||
mTabOptionMenu.showAsDropDown(view,0, helperMethod.pxFromDp(-45));
|
||||
mTabOptionMenu.showAsDropDown(view,helperMethod.pxFromDp(-125), helperMethod.pxFromDp(-45));
|
||||
}
|
||||
|
||||
private void onCloseTabMenu() {
|
||||
|
@ -134,6 +134,7 @@ class tabViewController
|
|||
mToastLayoutRoot.setAlpha(0);
|
||||
mToastLayoutRoot.animate().alpha(1);
|
||||
|
||||
initTabCount();
|
||||
mDelayHandler.removeCallbacksAndMessages(null);
|
||||
mDelayHandler.postDelayed(() -> mToastLayoutRoot.animate().alpha(0).withEndAction(() -> mToastLayoutRoot.setVisibility(View.GONE)), 1500);
|
||||
}
|
||||
|
|
|
@ -6,4 +6,5 @@ public class messages
|
|||
|
||||
public final static int MESSAGE_UPDATE_LOADING_TEXT =1;
|
||||
public final static int MESSAGE_ON_URL_LOAD =2;
|
||||
public final static int MESSAGE_PROGRESSBAR_VALIDATE =3;
|
||||
}
|
||||
|
|
|
@ -116,10 +116,12 @@ public class suggestionDataModel {
|
|||
addSuggenstions("https://wowhead.com","Wow Head",true);
|
||||
addSuggenstions("https://bing.com","Bing",true);
|
||||
addSuggenstions("https://google.com","Google",true);
|
||||
addSuggenstions("https://boogle.store","Genesis Search",true);
|
||||
addSuggenstions("https://genesis.onion","Genesis Search",true);
|
||||
}
|
||||
|
||||
private void addSuggenstions(String url, String title,boolean isLoading){
|
||||
url = url.replace("boogle.store","genesis.onion");
|
||||
title = title.replace("boogle.store","Genesis Search").replace("boogle","genesis");
|
||||
url = helperMethod.removeLastSlash(url);
|
||||
if(url.length()>1500 || title.equals("$TITLE") || title.equals("loading")){
|
||||
return;
|
||||
|
|
|
@ -61,6 +61,7 @@ class tabDataModel
|
|||
int size = mTabs.size();
|
||||
for(int counter = 0; counter< size; counter++){
|
||||
mTabs.get(0).getSession().stop();
|
||||
mTabs.get(0).getSession().closeSession();
|
||||
mTabs.remove(0);
|
||||
}
|
||||
if(mTabs.size()>0){
|
||||
|
@ -68,6 +69,7 @@ class tabDataModel
|
|||
}
|
||||
|
||||
databaseController.getInstance().execSQL("DELETE FROM tab WHERE 1",null);
|
||||
|
||||
}
|
||||
|
||||
void closeTab(geckoSession mSession) {
|
||||
|
@ -158,7 +160,7 @@ class tabDataModel
|
|||
} catch (Throwable throwable) {
|
||||
throwable.printStackTrace();
|
||||
}
|
||||
}, 100);
|
||||
}, 500);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,102 @@
|
|||
package com.darkweb.genesissearchengine.helperManager;
|
||||
|
||||
import android.view.GestureDetector.SimpleOnGestureListener;
|
||||
import android.view.MotionEvent;
|
||||
|
||||
public class SimpleGestureFilter extends SimpleOnGestureListener{
|
||||
|
||||
@Override
|
||||
public boolean onFling(MotionEvent e1, MotionEvent e2, float velocityX, float velocityY) {
|
||||
|
||||
float x1 = e1.getX();
|
||||
float y1 = e1.getY();
|
||||
|
||||
float x2 = e2.getX();
|
||||
float y2 = e2.getY();
|
||||
|
||||
Direction direction = getDirection(x1,y1,x2,y2);
|
||||
return onSwipe(direction);
|
||||
}
|
||||
|
||||
public boolean onSwipe(Direction direction){
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Given two points in the plane p1=(x1, x2) and p2=(y1, y1), this method
|
||||
* returns the direction that an arrow pointing from p1 to p2 would have.
|
||||
* @param x1 the x position of the first point
|
||||
* @param y1 the y position of the first point
|
||||
* @param x2 the x position of the second point
|
||||
* @param y2 the y position of the second point
|
||||
* @return the direction
|
||||
*/
|
||||
public Direction getDirection(float x1, float y1, float x2, float y2){
|
||||
double angle = getAngle(x1, y1, x2, y2);
|
||||
return Direction.get(angle);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* Finds the angle between two points in the plane (x1,y1) and (x2, y2)
|
||||
* The angle is measured with 0/360 being the X-axis to the right, angles
|
||||
* increase counter clockwise.
|
||||
*
|
||||
* @param x1 the x position of the first point
|
||||
* @param y1 the y position of the first point
|
||||
* @param x2 the x position of the second point
|
||||
* @param y2 the y position of the second point
|
||||
* @return the angle between two points
|
||||
*/
|
||||
public double getAngle(float x1, float y1, float x2, float y2) {
|
||||
|
||||
double rad = Math.atan2(y1-y2,x2-x1) + Math.PI;
|
||||
return (rad*180/Math.PI + 180)%360;
|
||||
}
|
||||
|
||||
|
||||
public enum Direction{
|
||||
up,
|
||||
down,
|
||||
left,
|
||||
right;
|
||||
|
||||
/**
|
||||
* Returns a direction given an angle.
|
||||
* Directions are defined as follows:
|
||||
*
|
||||
* Up: [45, 135]
|
||||
* Right: [0,45] and [315, 360]
|
||||
* Down: [225, 315]
|
||||
* Left: [135, 225]
|
||||
*
|
||||
* @param angle an angle from 0 to 360 - e
|
||||
* @return the direction of an angle
|
||||
*/
|
||||
public static Direction get(double angle){
|
||||
if(inRange(angle, 45, 135)){
|
||||
return Direction.up;
|
||||
}
|
||||
else if(inRange(angle, 0,45) || inRange(angle, 315, 360)){
|
||||
return Direction.right;
|
||||
}
|
||||
else if(inRange(angle, 225, 315)){
|
||||
return Direction.down;
|
||||
}
|
||||
else{
|
||||
return Direction.left;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @param angle an angle
|
||||
* @param init the initial bound
|
||||
* @param end the final bound
|
||||
* @return returns true if the given angle is in the interval [init, end).
|
||||
*/
|
||||
private static boolean inRange(double angle, float init, float end){
|
||||
return (angle >= init) && (angle < end);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -8,6 +8,7 @@ import android.view.View;
|
|||
import android.view.ViewGroup;
|
||||
import android.widget.ArrayAdapter;
|
||||
import android.widget.Filter;
|
||||
import android.widget.ImageButton;
|
||||
import android.widget.TextView;
|
||||
import com.darkweb.genesissearchengine.appManager.historyManager.historyRowModel;
|
||||
import com.darkweb.genesissearchengine.constants.strings;
|
||||
|
@ -39,6 +40,7 @@ public class autoCompleteAdapter extends ArrayAdapter<historyRowModel> {
|
|||
|
||||
TextView customerNameLabel = v.findViewById(R.id.hintCompletionTitle);
|
||||
TextView myTv = v.findViewById( R.id.hintCompletionUrl);
|
||||
ImageButton mMoveURL = v.findViewById( R.id.pMoveURL);
|
||||
|
||||
if (customerNameLabel != null) {
|
||||
if(customer.getHeader().equals(strings.GENERIC_EMPTY_STR)){
|
||||
|
@ -47,6 +49,7 @@ public class autoCompleteAdapter extends ArrayAdapter<historyRowModel> {
|
|||
customerNameLabel.setText(customer.getHeader());
|
||||
}
|
||||
myTv.setText(customer.getDescription());
|
||||
mMoveURL.setTag(customer.getDescription());
|
||||
}
|
||||
}
|
||||
return v;
|
||||
|
@ -72,20 +75,16 @@ public class autoCompleteAdapter extends ArrayAdapter<historyRowModel> {
|
|||
if(constraint != null && !constraint.equals("about:blank")) {
|
||||
suggestions.clear();
|
||||
for (historyRowModel customer : itemsAll) {
|
||||
if(suggestions.size()>10){
|
||||
if(suggestions.size()>4){
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
if(!customer.getHeader().equals("$TITLE") && customer.getHeader().length()>2 && customer.getDescription().toLowerCase().length()>2 && (customer.getHeader().toLowerCase().contains(constraint.toString().toLowerCase()) || customer.getDescription().toLowerCase().contains(constraint.toString().toLowerCase()))){
|
||||
if(!customer.getHeader().equals("$TITLE") && customer.getHeader().length()>2 && customer.getDescription().toLowerCase().length()>2 && (customer.getHeader().toLowerCase().contains(constraint.toString().toLowerCase()) || constraint.toString().toLowerCase().toLowerCase().contains(customer.getHeader()) || constraint.toString().toLowerCase().contains(customer.getDescription().toLowerCase()) || customer.getDescription().toLowerCase().contains(constraint.toString().toLowerCase()))){
|
||||
Log.i("memememe:","memememe:"+constraint.toString().toLowerCase().replace("https://","").replace("http://",""));
|
||||
Log.i("memememe1:","memememe2:"+customer.getDescription().replace("https://","").replace("http://",""));
|
||||
|
||||
if(!constraint.toString().toLowerCase().replace("https://","").replace("http://","").equals(customer.getDescription().replace("https://","").replace("http://",""))){
|
||||
suggestions.add(customer);
|
||||
}
|
||||
}
|
||||
}
|
||||
FilterResults filterResults = new FilterResults();
|
||||
filterResults.values = suggestions;
|
||||
filterResults.count = suggestions.size();
|
||||
|
@ -98,7 +97,7 @@ public class autoCompleteAdapter extends ArrayAdapter<historyRowModel> {
|
|||
protected void publishResults(CharSequence constraint, FilterResults results)
|
||||
{
|
||||
try{
|
||||
if(results != null && results.count > 0) {
|
||||
if(results != null) {
|
||||
ArrayList<historyRowModel> filteredList = (ArrayList<historyRowModel>)((ArrayList<historyRowModel>)results.values).clone();
|
||||
|
||||
clear();
|
||||
|
|
|
@ -246,6 +246,16 @@ public class helperMethod
|
|||
context.startActivity(myIntent);
|
||||
}
|
||||
|
||||
public static void openActivityReverse( Class<?> cls,int type,AppCompatActivity context,boolean animation){
|
||||
Intent myIntent = new Intent(context, cls);
|
||||
myIntent.putExtra(keys.PROXY_LIST_TYPE, type);
|
||||
if(!animation){
|
||||
myIntent.addFlags(FLAG_ACTIVITY_NO_ANIMATION);
|
||||
}
|
||||
|
||||
context.startActivity(myIntent);
|
||||
}
|
||||
|
||||
public static void restartActivity( Intent pIntent, AppCompatActivity pContext){
|
||||
pContext.finish();
|
||||
pContext.startActivity(pIntent);
|
||||
|
|
|
@ -162,9 +162,9 @@ class orbotManager
|
|||
mLogsStarted = true;
|
||||
}
|
||||
else {
|
||||
logs = logs.replaceAll("[^a-zA-Z0-9%\\s+]", "");
|
||||
logs = helperMethod.capitalizeString(logs);
|
||||
logs = logs.replace("(","").replace(":","_FERROR_").replace("NOTICE","").replace(")","").replace("_FERROR_","");
|
||||
// logs = logs.replaceAll("[^a-zA-Z0-9%\\s+]", "");
|
||||
// logs = helperMethod.capitalizeString(logs);
|
||||
// logs = logs.replace("(","").replace(":","_FERROR_").replace("NOTICE","").replace(")","").replace("_FERROR_","");
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<translate xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:fromXDelta="-100%"
|
||||
android:toXDelta="0"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="250"/>
|
||||
</set>
|
|
@ -0,0 +1,11 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<translate
|
||||
android:duration="250"
|
||||
android:fromXDelta="0%"
|
||||
android:fromYDelta="0%"
|
||||
android:toXDelta="-100%"
|
||||
android:toYDelta="0%" />
|
||||
</set>
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<translate xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:fromXDelta="0"
|
||||
android:toXDelta="100%"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="250"/>
|
||||
</set>
|
|
@ -0,0 +1,11 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shareInterpolator="false">
|
||||
<translate
|
||||
android:duration="250"
|
||||
android:fromXDelta="100%"
|
||||
android:fromYDelta="0%"
|
||||
android:toXDelta="0%"
|
||||
android:toYDelta="0%" />
|
||||
</set>
|
|
@ -1,6 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<translate
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="250"
|
||||
android:fromXDelta="0%p"
|
||||
android:toXDelta="100%p"/>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<translate xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:fromXDelta="0"
|
||||
android:toXDelta="100%"
|
||||
android:interpolator="@android:anim/decelerate_interpolator"
|
||||
android:duration="300"/>
|
||||
</set>
|
|
@ -14,10 +14,10 @@
|
|||
android:bottom="0dp">
|
||||
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="#ffffff"/>
|
||||
<solid android:color="@color/c_background"/>
|
||||
<stroke
|
||||
android:width="1dp"
|
||||
android:color="@color/white_dark"/>
|
||||
android:color="@color/c_edittext_background_dark"/>
|
||||
</shape>
|
||||
</item>
|
||||
</ripple>
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:color="@color/c_alert_background" android:layout_height="match_parent" android:layout_width="match_parent">
|
||||
|
||||
<item android:id="@android:id/mask">
|
||||
<shape android:shape="rectangle">
|
||||
|
||||
|
@ -16,6 +17,9 @@
|
|||
android:topLeftRadius="6dp"
|
||||
android:topRightRadius="6dp"/>
|
||||
|
||||
<item name="android:shadowColor">#000000</item>
|
||||
<item name="android:shadowRadius">5</item>
|
||||
<item name="android:shadowDy">3</item>
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
|
@ -39,6 +43,8 @@
|
|||
android:endColor="@color/c_alert_background"
|
||||
android:startColor="@color/c_alert_background"
|
||||
android:type="linear" />
|
||||
|
||||
|
||||
</shape>
|
||||
</item>
|
||||
</ripple>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<solid android:color="@color/white"/>
|
||||
<solid android:color="@color/c_edittext_background"/>
|
||||
|
||||
<corners
|
||||
android:bottomLeftRadius="0dp"
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
|
||||
<item android:left="-5dp" android:right="-5dp" android:top="0dp" android:bottom="-5dp">
|
||||
<item android:left="-5dp" android:right="-5dp" android:top="0dp" android:bottom="-15dp">
|
||||
<shape
|
||||
android:shape="rectangle">
|
||||
<stroke android:width="4dp" android:color="@color/secondary" />
|
||||
<solid android:color="#050c14" />
|
||||
<stroke android:width="4dp" android:color="#7700B3B3" />
|
||||
<solid android:color="#181b25" />
|
||||
</shape>
|
||||
</item>
|
||||
</layer-list>
|
|
@ -0,0 +1,10 @@
|
|||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24"
|
||||
android:tint="?attr/colorControlNormal">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M5,15h2V8.41L18.59,20L20,18.59L8.41,7H15V5H5V15z"/>
|
||||
</vector>
|
Before Width: | Height: | Size: 39 KiB After Width: | Height: | Size: 32 KiB |
Before Width: | Height: | Size: 43 KiB After Width: | Height: | Size: 47 KiB |
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 864 KiB After Width: | Height: | Size: 875 KiB |
After Width: | Height: | Size: 864 KiB |
|
@ -0,0 +1,60 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/pPopupFindContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/pNavigationContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:background="@color/c_edittext_background_dark"
|
||||
android:paddingBottom="1dp"
|
||||
android:elevation="8dp"
|
||||
android:onClick="onOpenSearchEngine"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
<LinearLayout
|
||||
android:id="@+id/pNavigationContainerInner"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:background="@color/c_background"
|
||||
android:elevation="8dp"
|
||||
android:onClick="onOpenSearchEngine"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imageView"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="45dp"
|
||||
android:contentDescription="@string/GENERAL_TODO"
|
||||
android:padding="6.5dp"
|
||||
android:layout_marginStart="2dp"
|
||||
android:paddingEnd="4dp"
|
||||
app:srcCompat="@xml/ic_baseline_search"
|
||||
tools:ignore="RtlSymmetry"
|
||||
app:tint="@color/c_navigation_tint" />
|
||||
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="3"
|
||||
android:paddingTop="11dp"
|
||||
android:layout_marginStart="6dp"
|
||||
android:text="@string/GENERAL_SEARCH_ENGINE"
|
||||
android:textColor="@color/c_text_v1"
|
||||
android:textSize="15sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
@ -1,50 +1,77 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingRight="0dp"
|
||||
android:paddingLeft="0dp"
|
||||
android:paddingBottom="0dp"
|
||||
android:elevation="0dp"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:paddingTop="10dp"
|
||||
android:paddingBottom="10dp"
|
||||
android:orientation="vertical"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@xml/gx_side_item_suggestions"
|
||||
android:onClick="onSuggestionInvoked"
|
||||
android:background="@xml/gx_side_item_suggestions">
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:orientation="horizontal"
|
||||
tools:ignore="UselessParent">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:layout_weight="1"
|
||||
android:paddingTop="10dp"
|
||||
android:paddingBottom="10dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/hintCompletionTitle"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:clickable="false"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:clickable="false"
|
||||
android:ellipsize="end"
|
||||
android:paddingLeft="10dp"
|
||||
android:paddingRight="10dp"
|
||||
android:textColor="@color/black"
|
||||
android:singleLine="true"
|
||||
android:textSize="14sp"
|
||||
android:ellipsize="end"
|
||||
android:text="@string/GENERAL_DEFAULT_HINT_SUGGESTION" />
|
||||
android:text="@string/GENERAL_DEFAULT_HINT_SUGGESTION"
|
||||
android:textColor="@color/c_text_v1"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/hintCompletionUrl"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:clickable="false"
|
||||
android:layout_width="wrap_content"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="end"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingLeft="10dp"
|
||||
android:paddingRight="10dp"
|
||||
android:textColor="@color/holo_dark_gray"
|
||||
android:textSize="12.5sp"
|
||||
android:text="@string/GENERAL_DEFAULT_HINT_SUGGESTION" />
|
||||
android:singleLine="true"
|
||||
android:text="@string/GENERAL_DEFAULT_HINT_SUGGESTION"
|
||||
android:textColor="@color/c_text_v6"
|
||||
android:textSize="12.5sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/pMoveURL"
|
||||
android:layout_width="55dp"
|
||||
android:padding="8dp"
|
||||
android:layout_height="55dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:src="@xml/ic_arrow_right"
|
||||
android:tag="@string/GENERAL_TODO"
|
||||
android:onClick="onSuggestionMove"
|
||||
android:layout_margin="2dp"
|
||||
android:background="@xml/gx_ripple_default_round"
|
||||
android:tint="@color/c_navigation_tint"
|
||||
android:rotation="225"
|
||||
android:contentDescription="@string/GENERAL_TODO" />
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
|
@ -24,13 +24,13 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:background="@color/c_background_keyboard"
|
||||
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
|
||||
android:translationZ="10dp">
|
||||
android:translationZ="3dp">
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/pTopLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:animateLayoutChanges="true"
|
||||
android:animateLayoutChanges="false"
|
||||
android:background="#00000000"
|
||||
android:clipToPadding="false"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
|
@ -87,6 +87,7 @@
|
|||
android:animateLayoutChanges="true"
|
||||
android:background="@xml/gx_generic_input"
|
||||
android:completionHintView="@layout/hint_view"
|
||||
android:dropDownAnchor="@id/pSearchEngineBar"
|
||||
android:ems="10"
|
||||
android:hint="@string/GENERAL_SEARCH_HINT"
|
||||
android:importantForAutofill="no"
|
||||
|
@ -94,7 +95,7 @@
|
|||
android:maxLines="1"
|
||||
android:paddingLeft="38dp"
|
||||
android:paddingRight="15dp"
|
||||
android:popupElevation="5dp"
|
||||
android:popupElevation="0dp"
|
||||
android:selectAllOnFocus="true"
|
||||
android:text="@string/GENERAL_HOME_URL"
|
||||
android:textColor="@color/c_text_v1"
|
||||
|
@ -175,8 +176,8 @@
|
|||
</com.google.android.material.appbar.AppBarLayout>
|
||||
|
||||
<androidx.core.widget.NestedScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:id="@+id/pNestedScroll"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="fill_vertical"
|
||||
android:layout_marginTop="0dp"
|
||||
|
@ -198,7 +199,7 @@
|
|||
android:id="@+id/pProgressBar"
|
||||
style="@style/Base.Widget.AppCompat.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="4dp"
|
||||
android:layout_height="5dp"
|
||||
android:layout_marginTop="-1dp"
|
||||
android:alpha="0"
|
||||
android:background="@color/clear_alpha"
|
||||
|
@ -227,14 +228,15 @@
|
|||
<FrameLayout
|
||||
android:id="@+id/pSplashLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:animateLayoutChanges="true"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/pSplashScreen"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@xml/hox_rounded_corner_container_bottom"
|
||||
android:clickable="true"
|
||||
android:background="@color/landing_ease_blue_splash"
|
||||
android:animateLayoutChanges="true"
|
||||
android:focusable="true">
|
||||
|
||||
<ImageView
|
||||
|
@ -256,10 +258,9 @@
|
|||
android:id="@+id/pImageDivider"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="190dp"
|
||||
android:layout_marginTop="103dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/GENERAL_TODO"
|
||||
android:paddingBottom="15dp"
|
||||
android:src="@drawable/glide"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
|
@ -280,23 +281,24 @@
|
|||
<View
|
||||
android:id="@+id/view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="2dp"
|
||||
android:layout_marginStart="20dp"
|
||||
android:layout_marginBottom="11dp"
|
||||
android:background="#0A1727"
|
||||
android:elevation="2dp"
|
||||
android:layout_height="3dp"
|
||||
android:alpha="0.5"
|
||||
android:elevation="4dp"
|
||||
android:background="#264d73"
|
||||
app:layout_constraintBottom_toTopOf="@+id/pCopyright"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/pCopyright"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="21dp"
|
||||
android:layout_marginBottom="14dp"
|
||||
android:text="Copyright © by Genesis Technologies"
|
||||
android:textColor="#004d4d"
|
||||
android:background="#0A1727"
|
||||
android:paddingStart="10dp"
|
||||
android:paddingTop="10dp"
|
||||
android:paddingBottom="10dp"
|
||||
android:text="Copyright © by Genesis Technologies | Built 1.0.2.2"
|
||||
android:textColor="#4a6868"
|
||||
android:textSize="13sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
|
@ -336,17 +338,18 @@
|
|||
android:id="@+id/pOrbotLogs"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="22dp"
|
||||
android:layout_marginEnd="23dp"
|
||||
android:layout_marginStart="18dp"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:background="@xml/hx_border_left"
|
||||
android:ellipsize="end"
|
||||
android:gravity="start"
|
||||
android:maxHeight="250dp"
|
||||
android:paddingStart="20dp"
|
||||
android:paddingTop="10dp"
|
||||
android:maxLines="4"
|
||||
android:minHeight="80dp"
|
||||
android:paddingStart="15dp"
|
||||
android:paddingTop="18dp"
|
||||
android:paddingRight="20dp"
|
||||
android:paddingBottom="10dp"
|
||||
android:paddingBottom="15dp"
|
||||
android:text="@string/HOME_LOADING"
|
||||
android:textAlignment="textStart"
|
||||
android:textColor="@color/white"
|
||||
|
@ -374,11 +377,28 @@
|
|||
android:layout_width="90dp"
|
||||
android:layout_height="90dp"
|
||||
android:layout_marginStart="5dp"
|
||||
android:layout_marginTop="85dp"
|
||||
android:contentDescription="@string/GENERAL_TODO"
|
||||
android:translationZ="3dp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/pImageDivider"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/pImageDivider"
|
||||
app:srcCompat="@drawable/genesis_logo_bordered" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/pBlocker"
|
||||
android:layout_width="189dp"
|
||||
android:layout_height="65dp"
|
||||
android:layout_marginTop="14dp"
|
||||
android:layout_marginBottom="13dp"
|
||||
android:clickable="false"
|
||||
android:contentDescription="@string/GENERAL_TODO"
|
||||
android:focusable="false"
|
||||
android:translationZ="3dp"
|
||||
app:layout_constraintBottom_toTopOf="@+id/view"
|
||||
app:layout_constraintEnd_toEndOf="@+id/pSettings"
|
||||
app:layout_constraintStart_toStartOf="@+id/Connect"
|
||||
app:layout_constraintTop_toBottomOf="@+id/pOrbotLogs" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/pInfo4"
|
||||
android:layout_width="wrap_content"
|
||||
|
@ -392,7 +412,7 @@
|
|||
android:paddingRight="15dp"
|
||||
android:text="Secured by Tor Network"
|
||||
android:textAlignment="textStart"
|
||||
android:textColor="#6a9495"
|
||||
android:textColor="#bfbfbf"
|
||||
android:textFontWeight="5"
|
||||
android:textSize="12.5sp"
|
||||
android:textStyle="bold"
|
||||
|
@ -415,7 +435,7 @@
|
|||
android:paddingRight="15dp"
|
||||
android:text="Builtin Onion Search Engine"
|
||||
android:textAlignment="textStart"
|
||||
android:textColor="#6a9495"
|
||||
android:textColor="#bfbfbf"
|
||||
android:textFontWeight="5"
|
||||
android:textSize="12.5sp"
|
||||
android:textStyle="bold"
|
||||
|
@ -438,7 +458,7 @@
|
|||
android:paddingRight="15dp"
|
||||
android:text="No Record and Digital Fingerprinting"
|
||||
android:textAlignment="textStart"
|
||||
android:textColor="#6a9495"
|
||||
android:textColor="#bfbfbf"
|
||||
android:textFontWeight="5"
|
||||
android:textSize="12.5sp"
|
||||
android:textStyle="bold"
|
||||
|
@ -453,10 +473,10 @@
|
|||
android:layout_width="90dp"
|
||||
android:layout_height="90dp"
|
||||
android:layout_marginStart="5dp"
|
||||
android:layout_marginTop="15dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:translationZ="3dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/pImageDivider"
|
||||
app:layout_constraintTop_toBottomOf="@+id/pGenesisLogo"
|
||||
app:srcCompat="@drawable/sheild_logo_bordered" />
|
||||
|
||||
<TextView
|
||||
|
@ -472,7 +492,7 @@
|
|||
android:paddingRight="15dp"
|
||||
android:text="Secured by Tor Network"
|
||||
android:textAlignment="textStart"
|
||||
android:textColor="#6a9495"
|
||||
android:textColor="#bfbfbf"
|
||||
android:textFontWeight="5"
|
||||
android:textSize="12.5sp"
|
||||
android:textStyle="bold"
|
||||
|
@ -495,7 +515,7 @@
|
|||
android:paddingRight="15dp"
|
||||
android:text="Builtin Onion Search Engine"
|
||||
android:textAlignment="textStart"
|
||||
android:textColor="#6a9495"
|
||||
android:textColor="#bfbfbf"
|
||||
android:textFontWeight="5"
|
||||
android:textSize="12.5sp"
|
||||
android:textStyle="bold"
|
||||
|
@ -518,7 +538,7 @@
|
|||
android:paddingRight="15dp"
|
||||
android:text="No Record and Digital Fingerprinting"
|
||||
android:textAlignment="textStart"
|
||||
android:textColor="#6a9495"
|
||||
android:textColor="#bfbfbf"
|
||||
android:textFontWeight="5"
|
||||
android:textSize="12.5sp"
|
||||
android:textStyle="bold"
|
||||
|
@ -578,17 +598,27 @@
|
|||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/pBlocker"
|
||||
<include
|
||||
android:id="@+id/pSearchEngineBar"
|
||||
layout="@layout/popup_search_engine"
|
||||
android:layout_width="match_parent"
|
||||
android:clickable="true"
|
||||
android:alpha="0"
|
||||
android:layout_height="wrap_content"
|
||||
android:elevation="8dp"
|
||||
android:visibility="gone"
|
||||
android:layout_height="match_parent"
|
||||
tools:srcCompat="@tools:sample/avatars"
|
||||
android:background="@color/black"
|
||||
android:contentDescription="@string/GENERAL_TODO"
|
||||
android:focusable="true" />
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/pAdView" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/pBlockerFullSceen"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:alpha="0"
|
||||
android:background="@color/black"
|
||||
android:clickable="true"
|
||||
android:contentDescription="@string/GENERAL_TODO"
|
||||
android:focusable="true"
|
||||
android:visibility="gone"
|
||||
tools:srcCompat="@tools:sample/avatars" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
@ -213,7 +213,7 @@
|
|||
android:layout_marginStart="5dp"
|
||||
android:layout_marginEnd="5dp"
|
||||
app:tint="@color/c_icon_tint"
|
||||
android:src="@drawable/ic_baseline_search"
|
||||
android:src="@xml/ic_baseline_search"
|
||||
android:contentDescription="@string/GENERAL_TODO" />
|
||||
|
||||
<LinearLayout
|
||||
|
|
|
@ -10,8 +10,9 @@
|
|||
android:layout_height="wrap_content">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="200dp"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:elevation="7dp"
|
||||
android:orientation="vertical"
|
||||
android:background="@xml/hx_menu_popup"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
|
|
|
@ -43,6 +43,7 @@
|
|||
<color name="c_profile_radial_inner">#2c2b31</color>
|
||||
<color name="c_profile_radial_outer">#2c2b31</color>
|
||||
<color name="c_edittext_background">#3c3946</color>
|
||||
<color name="c_edittext_background_dark">#24222a</color>
|
||||
<color name="c_menu_drop_shadow_05">#00000000</color>
|
||||
<color name="c_menu_drop_shadow_10">#00000000</color>
|
||||
<color name="c_menu_drop_shadow_15">#00000000</color>
|
||||
|
@ -69,7 +70,7 @@
|
|||
<color name="blue">#0066FF</color>
|
||||
<color name="ease_blue_light">#fdfeff</color>
|
||||
<color name="ease_blue">#4d88ff</color>
|
||||
<color name="landing_ease_blue">#212d45</color>
|
||||
<color name="landing_ease_blue">#0A1727</color>
|
||||
<color name="landing_ease_blue_light_1">#eef1f7</color>
|
||||
<color name="landing_ease_blue_light_2">#eef1f7</color>
|
||||
<color name="cursor_blue">#3385ff</color>
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
<string name="app_name" translatable="false">Genesis</string>
|
||||
<string name="GENERAL_SEARCH_HINT" translatable="false">Search or type web address</string>
|
||||
<string name="GENERAL_FIND_HINT" translatable="false">Find in page</string>
|
||||
<string name="GENERAL_SEARCH_ENGINE" translatable="false">Search Engine</string>
|
||||
<string name="GENERAL_HOME_URL" translatable="false">https://genesis.onion</string>
|
||||
<string name="GENERAL_ERROR_TITLE" translatable="false">\u0020\u0020\u0020Opps! Some Thing Went Wrong</string>
|
||||
<string name="GENERAL_TODO" translatable="false">TODO</string>
|
||||
|
|
|
@ -45,6 +45,7 @@
|
|||
<color name="c_profile_radial_inner">#000000</color>
|
||||
<color name="c_profile_radial_outer">#ffffff</color>
|
||||
<color name="c_edittext_background">#f1f3f4</color>
|
||||
<color name="c_edittext_background_dark">#f5f5f5</color>
|
||||
<color name="c_button_warning">#610505</color>
|
||||
<color name="c_rateus_warning">#b3b3b3</color>
|
||||
<color name="c_splash_buttons">#ffffff</color>
|
||||
|
@ -70,8 +71,8 @@
|
|||
<color name="blue">#0066FF</color>
|
||||
<color name="ease_blue_light">#fdfeff</color>
|
||||
<color name="ease_blue">#4d88ff</color>
|
||||
<color name="landing_ease_blue">#111722</color>
|
||||
<color name="landing_ease_blue_splash">#192234</color>
|
||||
<color name="landing_ease_blue">#0A1727</color>
|
||||
<color name="landing_ease_blue_splash">#191919</color>
|
||||
<color name="landing_ease_blue_light_1">#eef1f7</color>
|
||||
<color name="landing_ease_blue_light_2">#eef1f7</color>
|
||||
<color name="cursor_blue">#3385ff</color>
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
<string name="app_name" translatable="false">Genesis</string>
|
||||
<string name="GENERAL_SEARCH_HINT" translatable="false">Search or type web address</string>
|
||||
<string name="GENERAL_FIND_HINT" translatable="false">Find in page</string>
|
||||
<string name="GENERAL_SEARCH_ENGINE" translatable="false">Search Engine</string>
|
||||
<string name="GENERAL_HOME_URL" translatable="false">https://genesis.onion</string>
|
||||
<string name="GENERAL_ERROR_TITLE" translatable="false">\u0020\u0020\u0020Opps! Some Thing Went Wrong</string>
|
||||
<string name="GENERAL_TODO" translatable="false">TODO</string>
|
||||
|
@ -312,7 +313,7 @@
|
|||
<!-- Home View -->
|
||||
<string name="HOME_TAB_TEXT" translatable="false">1</string>
|
||||
<string name="HOME_CONNECT" translatable="false">Connect</string>
|
||||
<string name="HOME_LOADING" translatable="false">Idle | Waiting to start</string>
|
||||
<string name="HOME_LOADING" translatable="false">Idle | Genesis on standby at the moment</string>
|
||||
<string name="HOME_LOADING_STATIC" translatable="false">~ Genesis on standby at the moment</string>
|
||||
|
||||
<!-- Landing Page -->
|
||||
|
|