Bug Fixes

Bug Fixes
master
Abdul Mannan Saeed 2022-05-16 16:43:26 +05:00
parent 0df46d2642
commit f8f6da540b
53 changed files with 117 additions and 94 deletions

View File

@ -86,7 +86,7 @@
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/alert/layout/popup_download_full.xml" value="0.33" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/alert/layout/popup_download_url.xml" value="0.5" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/alert/layout/popup_file_longpress.xml" value="0.33" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/alert/layout/popup_find.xml" value="0.5" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/alert/layout/popup_find.xml" value="0.33" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/alert/layout/popup_panic.xml" value="0.67" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/alert/layout/popup_rate_failure.xml" value="0.5" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/alert/layout/popup_rate_us.xml" value="0.33" />
@ -118,6 +118,7 @@
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/shared/listviews/layout/history_bookmark_menu.xml" value="0.18541666666666667" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/tab/layout/tab_grid_view.xml" value="0.67" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/tab/layout/tab_menu.xml" value="0.18541666666666667" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/tab/layout/tab_row_view.xml" value="0.1390625" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/layouts/tab/layout/tab_view.xml" value="0.18541666666666667" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/menu/menu_main.xml" value="0.33" />
<entry key="..\:/workspace/Genesis-Android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml" value="0.1935" />

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -139,15 +139,15 @@
width: 10px;
height: 10px;
position: relative;
top:-52px;
top:-32px;
left:92%;
}
.sidebar__list-logo{
max-width: 190px;
max-width: 220px;
width: 100%;
cursor: pointer;
margin-bottom: 40px;
margin-top: 50px;
cursor: pointer !important;
margin-bottom: 20px;
margin-top: 20px;
margin-left: 10px;
pointer-events: none;
}

File diff suppressed because one or more lines are too long

View File

@ -138,15 +138,15 @@
width: 10px;
height: 10px;
position: relative;
top:-52px;
top:-32px;
left:92%;
}
.sidebar__list-logo{
max-width: 190px;
max-width: 220px;
width: 100%;
cursor: pointer;
margin-bottom: 40px;
margin-top: 50px;
cursor: pointer !important;
margin-bottom: 20px;
margin-top: 20px;
margin-left: 10px;
pointer-events: none;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 324 KiB

After

Width:  |  Height:  |  Size: 294 KiB

View File

@ -456,7 +456,6 @@ geckoSession extends GeckoSession implements MediaSession.Delegate, GeckoSession
mContext.get().runOnUiThread(() -> {
event.invokeObserver(Arrays.asList(mProgress, mSessionID), enums.etype.progress_update);
});
event.invokeObserver(Arrays.asList(mCurrentURL, mSessionID, mCurrentTitle, m_current_url_id, mTheme), enums.etype.M_UPDATE_PIXEL_BACKGROUND);
}
mPreviousErrorPage = false;
} else {
@ -795,7 +794,6 @@ geckoSession extends GeckoSession implements MediaSession.Delegate, GeckoSession
onSessionReinit();
}
event.invokeObserver(Arrays.asList(mCurrentURL, mSessionID, mCurrentTitle, m_current_url_id, mTheme), enums.etype.M_UPDATE_PIXEL_BACKGROUND);
event.invokeObserver(Arrays.asList(mCurrentURL, mSessionID, mCurrentTitle, mTheme), enums.etype.ON_EXPAND_TOP_BAR);
mPrevURL = mCurrentURL;
}

View File

@ -424,7 +424,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
if (!status.mThemeApplying) {
mHomeViewController.onUpdateSearchBar(model.getSession().getCurrentURL(), false, false, false);
}
onLoadTab(model.getSession(), false, true, false);
onLoadTab(model.getSession(), false, true, false, true);
} else {
onNewIntent(getIntent());
onOpenLinkNewTab(helperMethod.getDomainName(mHomeModel.getSearchEngine()));
@ -679,7 +679,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
return mGeckoClient.getSecurityInfo();
}
public void onLoadTab(geckoSession mTempSession, boolean isSessionClosed, boolean pExpandAppBar, boolean pForced) {
public void onLoadTab(geckoSession mTempSession, boolean isSessionClosed, boolean pExpandAppBar, boolean pForced, boolean pGeneratePixel) {
if (!isSessionClosed) {
dataController.getInstance().invokeTab(dataEnums.eTabCommands.MOVE_TAB_TO_TOP, Collections.singletonList(mTempSession));
@ -717,7 +717,9 @@ public class homeController extends AppCompatActivity implements ComponentCallba
mHomeViewController.onUpdateStatusBarTheme(mGeckoClient.getTheme(), false);
try {
mRenderedBitmap = mGeckoView.capturePixels();
if(pGeneratePixel){
mRenderedBitmap = mGeckoView.capturePixels();
}
} catch (Exception ignored) {
}
@ -736,7 +738,9 @@ public class homeController extends AppCompatActivity implements ComponentCallba
mHomeViewController.onProgressBarUpdate(mTempSession.getProgress(), true);
}
//}
dataController.getInstance().invokeTab(dataEnums.eTabCommands.M_UPDATE_PIXEL, Arrays.asList(mGeckoClient.getSession().getSessionID(), mRenderedBitmap, null, mGeckoView, false));
if(pGeneratePixel){
dataController.getInstance().invokeTab(dataEnums.eTabCommands.M_UPDATE_PIXEL, Arrays.asList(mGeckoClient.getSession().getSessionID(), mRenderedBitmap, null, mGeckoView, false));
}
TouchView(mGeckoView);
TouchView(mNestedScroll);
@ -1185,7 +1189,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
tabRowModel model = (tabRowModel) dataController.getInstance().invokeTab(dataEnums.eTabCommands.GET_RECENT_TAB, null);
if (model != null && !mGeckoClient.getSession().getSessionID().equals(model.getSession().getSessionID())) {
mHomeViewController.onUpdateSearchBar(model.getSession().getCurrentURL(), false, false, true);
onLoadTab(model.getSession(), false, true, false);
onLoadTab(model.getSession(), false, true, false, true);
}
}
@ -1635,7 +1639,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
}
} else {
if (!model.getSession().getSessionID().equals(mGeckoClient.getSession().getSessionID())) {
onLoadTab(model.getSession(), false, true, false);
onLoadTab(model.getSession(), false, true, false, true);
}
if (mGeckoClient.getSession().getProgress() != 100) {
mHomeViewController.onProgressBarUpdate(mGeckoClient.getSession().getProgress(), true);
@ -1804,7 +1808,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
if (model != null) {
if (mTabFragment.getVisibility() != View.VISIBLE) {
onLoadTab(model.getSession(), true, true, false);
onLoadTab(model.getSession(), true, true, false, false);
}
return true;
} else {
@ -2317,7 +2321,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
} else if (e_type.equals(enums.etype.M_HOME_PAGE)) {
geckoSession mSession = (geckoSession) dataController.getInstance().invokeTab(dataEnums.eTabCommands.M_HOME_PAGE, null);
if (mSession != null) {
onLoadTab(mSession, false, true, false);
onLoadTab(mSession, false, true, false, false);
}
return dataController.getInstance().invokeTab(dataEnums.eTabCommands.M_HOME_PAGE, null);
}
@ -2563,7 +2567,7 @@ public class homeController extends AppCompatActivity implements ComponentCallba
} else if (e_type.equals(enums.etype.M_OPEN_SESSION)) {
tabRowModel model = (tabRowModel) dataController.getInstance().invokeTab(dataEnums.eTabCommands.GET_CURRENT_TAB, null);
if (model != null) {
onLoadTab(model.getSession(), false, true, false);
onLoadTab(model.getSession(), false, true, false, true);
if (model.getSession().getCurrentURL().equals("about:blank") && status.sOpenURLInNewTab) {
onLoadURL(helperMethod.getDomainName(mHomeModel.getSearchEngine()));
} else {

View File

@ -140,7 +140,7 @@ public class settingGeneralController extends AppCompatActivity {
status.mThemeApplying = true;
//activityContextManager.getInstance().getHomeController().onReInitTheme();
activityContextManager.getInstance().getHomeController().onReInitTheme();
new Handler().postDelayed(() ->
{
try {
@ -148,9 +148,9 @@ public class settingGeneralController extends AppCompatActivity {
activityContextManager.getInstance().getSettingController().onInitTheme();
activityContextManager.getInstance().getHomeController().onCloseAllTabs();
//onBackPressed();
//overridePendingTransition(R.anim.fade_in_lang, R.anim.fade_out_lang);
//helperMethod.openActivity(settingGeneralController.class, constants.CONST_LIST_HISTORY, settingGeneralController.this, true);
onBackPressed();
overridePendingTransition(R.anim.fade_in_lang, R.anim.fade_out_lang);
helperMethod.openActivity(settingGeneralController.class, constants.CONST_LIST_HISTORY, settingGeneralController.this, true);
}
}catch (Exception ex){}

View File

@ -644,7 +644,7 @@ public class tabController extends Fragment {
} else if (e_type.equals(tabEnums.eTabAdapterCallback.ON_LOAD_TAB)) {
mClosed = true;
mtabViewController.onTrigger(tabEnums.eTabViewCommands.ON_HOLD_BLOCKER, null);
mHomeController.onLoadTab((geckoSession) data.get(0), (boolean) data.get(1), true, true);
mHomeController.onLoadTab((geckoSession) data.get(0), (boolean) data.get(1), true, true, false);
} else if (e_type.equals(tabEnums.eTabAdapterCallback.ON_REMOVE_TAB_VIEW)) {
onInitRemoveView((Integer) data.get(0), true, true);
initTabCount(400);

View File

@ -80,6 +80,9 @@ public class tabRowModel {
public Bitmap getBitmap() {
return mBitmap;
}
public void resetBitmap() {
mBitmap = null;
}
public String getDate() {
return mDate;

View File

@ -84,6 +84,18 @@ class tabDataModel {
return enums.AddTabCallback.TAB_FULL;
}
if (mTabs.size() > 2) {
for(int counter=mTabs.size()-1;counter>1;counter--){
if(!mTabs.get(counter).getSession().isLoaded()){
mTabs.get(counter).resetBitmap();
}
mTabs.get(counter).getSession().stop();
mTabs.get(counter).getSession().setActive(false);
mTabs.get(counter).getSession().close();
}
}
if (pIsDataSavable) {
String[] params = new String[3];
params[0] = mTabModel.getSession().getTitle();

View File

@ -52,7 +52,7 @@ public class appLovinManager implements MaxAdViewAdListener {
}
private boolean isAdvertLoaded() {
return bannerAdsLoaded;
return false;
}
/* Overriden Methods */

View File

@ -285,7 +285,7 @@ public class pluginController {
} else if (pEventType.equals(M_DOWNLOAD_FILE_MANUAL)) {
((homeController) mHomeController.get()).onManualDownload(pData.get(0).toString());
} else if (pEventType.equals(M_LOAD_NEW_TAB)) {
((homeController) mHomeController.get()).onLoadTab((geckoSession) pData.get(pData.size() - 2), false, false, false);
((homeController) mHomeController.get()).onLoadTab((geckoSession) pData.get(pData.size() - 2), false, false, true, true);
} else if (pEventType.equals(M_OPEN_LINK_NEW_TAB)) {
((homeController) mHomeController.get()).postNewLinkTabAnimationInBackgroundTrigger(pData.get(0).toString());

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 64 KiB

After

Width:  |  Height:  |  Size: 59 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 366 KiB

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 366 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 715 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 901 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 366 KiB

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 901 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 366 KiB

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 366 KiB

After

Width:  |  Height:  |  Size: 72 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 366 KiB

After

Width:  |  Height:  |  Size: 124 KiB

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background" />
<foreground android:drawable="@mipmap/ic_launcher_foreground" />
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
</adaptive-icon>

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background" />
<foreground android:drawable="@mipmap/ic_launcher_foreground" />
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
</adaptive-icon>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.4 KiB

After

Width:  |  Height:  |  Size: 8.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 KiB

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.6 KiB

After

Width:  |  Height:  |  Size: 5.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

After

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 80 KiB

After

Width:  |  Height:  |  Size: 66 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 34 KiB

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 44 KiB

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 135 KiB

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 56 KiB

After

Width:  |  Height:  |  Size: 49 KiB

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="ic_launcher_background">#FFFFFF</color>
<color name="ic_launcher_background">#3DDC84</color>
</resources>

View File

@ -25,6 +25,7 @@ import android.content.IntentFilter;
import android.content.ServiceConnection;
import android.content.SharedPreferences;
import android.content.pm.PackageManager;
import android.graphics.Color;
import android.net.ConnectivityManager;
import android.net.NetworkInfo;
import android.net.Uri;
@ -205,6 +206,7 @@ public class OrbotService extends VpnService implements OrbotConstants {
.setContentTitle(getString(R.string.app_name))
.setSmallIcon(R.mipmap.ic_stat_tor_logo)
.setContentIntent(pendIntent)
.setColor(Color.rgb( 255, 158, 47))
.setCategory(Notification.CATEGORY_SERVICE)
.setOngoing(org.torproject.android.service.util.Prefs.persistNotifications());
}
@ -887,51 +889,55 @@ public class OrbotService extends VpnService implements OrbotConstants {
@Override
public void onServiceConnected(ComponentName componentName, IBinder iBinder) {
new Thread(){
public void run(){
TorService torService = ((TorService.LocalBinder) iBinder).getService();
while ((conn = torService.getTorControlConnection())==null)
{
try {
sleep(500);
} catch (InterruptedException e) {
e.printStackTrace();
}
}
try {
sleep(1000);
} catch (InterruptedException e) {
e.printStackTrace();
}
mOrbotRawEventListener = new OrbotRawEventListener(OrbotService.this);
ArrayList<String> events = new ArrayList<>(Arrays.asList(TorControlCommands.EVENT_OR_CONN_STATUS,
TorControlCommands.EVENT_CIRCUIT_STATUS, TorControlCommands.EVENT_NOTICE_MSG,
TorControlCommands.EVENT_WARN_MSG, TorControlCommands.EVENT_ERR_MSG,
TorControlCommands.EVENT_BANDWIDTH_USED, TorControlCommands.EVENT_NEW_DESC,
TorControlCommands.EVENT_ADDRMAP));
if (Prefs.useDebugLogging()) {
events.add(TorControlCommands.EVENT_DEBUG_MSG);
events.add(TorControlCommands.EVENT_INFO_MSG);
}
if (Prefs.useDebugLogging() || Prefs.showExpandedNotifications())
events.add(TorControlCommands.EVENT_STREAM_STATUS);
if (conn != null) {
try {
conn.addRawEventListener(mOrbotRawEventListener);
conn.authenticate(new byte[0]);
conn.setEvents(events);
logNotice(getString(R.string.log_notice_added_event_handler));
} catch (IOException e) {
e.printStackTrace();
}
initControlConnection();
}
}
}.start();
//moved torService to a local variable, since we only need it once
TorService torService = ((TorService.LocalBinder) iBinder).getService();
while ((conn = torService.getTorControlConnection())==null)
{
try {
sleep(500);
} catch (InterruptedException e) {
e.printStackTrace();
}
}
try {
sleep(1000);
} catch (InterruptedException e) {
e.printStackTrace();
}
mOrbotRawEventListener = new OrbotRawEventListener(OrbotService.this);
ArrayList<String> events = new ArrayList<>(Arrays.asList(TorControlCommands.EVENT_OR_CONN_STATUS,
TorControlCommands.EVENT_CIRCUIT_STATUS, TorControlCommands.EVENT_NOTICE_MSG,
TorControlCommands.EVENT_WARN_MSG, TorControlCommands.EVENT_ERR_MSG,
TorControlCommands.EVENT_BANDWIDTH_USED, TorControlCommands.EVENT_NEW_DESC,
TorControlCommands.EVENT_ADDRMAP));
if (Prefs.useDebugLogging()) {
events.add(TorControlCommands.EVENT_DEBUG_MSG);
events.add(TorControlCommands.EVENT_INFO_MSG);
}
if (Prefs.useDebugLogging() || Prefs.showExpandedNotifications())
events.add(TorControlCommands.EVENT_STREAM_STATUS);
if (conn != null) {
try {
conn.addRawEventListener(mOrbotRawEventListener);
conn.authenticate(new byte[0]);
conn.setEvents(events);
logNotice(getString(R.string.log_notice_added_event_handler));
} catch (IOException e) {
e.printStackTrace();
}
initControlConnection();
}
}
@Override

Binary file not shown.

Before

Width:  |  Height:  |  Size: 760 B

After

Width:  |  Height:  |  Size: 901 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 901 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.5 KiB

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.4 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Orbot</string>
<string name="orbot_vpn">Orbot VPN</string>
<string name="app_name">Orion</string>
<string name="orbot_vpn">Orion VPN</string>
<string name="app_description">Orbot is a free proxy app that empowers other apps to use the internet more securely. Orbot uses Tor to encrypt your Internet traffic and then hides it by bouncing through a series of computers around the world. Tor is free software and an open network that helps you defend against a form of network surveillance that threatens personal freedom and privacy, confidential business activities and relationships, and state security known as traffic analysis.</string>
<string name="status_starting_up">Orbot is Starting&#8230;</string>
<string name="status_activated">Connected to the Tor Network</string>