From daf89f4111f1cd63b80c6467684be3e448b98e70 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D8=A3=D8=AD=D9=85=D8=AF=20=D8=A7=D9=84=D9=85=D8=AD=D9=85?= =?UTF-8?q?=D9=88=D8=AF=D9=8A=20=28Ahmed=20El-Mahmoudy=29?= Date: Tue, 30 Sep 2014 08:45:21 +0200 Subject: [PATCH] Added patch to remove GMS stuff --- metadata/com.lgallardo.qbittorrentclient.txt | 7 +- .../remove_admob.diff | 212 ++++++++++++++++++ 2 files changed, 213 insertions(+), 6 deletions(-) create mode 100644 metadata/com.lgallardo.qbittorrentclient/remove_admob.diff diff --git a/metadata/com.lgallardo.qbittorrentclient.txt b/metadata/com.lgallardo.qbittorrentclient.txt index 2a4d174cdb..f5557ae826 100644 --- a/metadata/com.lgallardo.qbittorrentclient.txt +++ b/metadata/com.lgallardo.qbittorrentclient.txt @@ -1,4 +1,3 @@ -Disabled:play-services Categories:Internet License:GPLv3+ Web Site:https://github.com/lgallard/qBittorrent-Client/blob/HEAD/README.md @@ -24,8 +23,8 @@ Repo Type:git Repo:https://github.com/lgallard/qBittorrent-Client/ Build:2.0,200 - disable=gcm commit=dbcb9d2ca3deba6fbd3d7cc5045fb91e10e8322a + patch=remove_admob.diff subdir=qBittorrentClient srclibs=ApacheHttpClient@4.3.5,ApacheHttpCore@4.3.2 rm=qBittorrentClient/libs/* @@ -42,10 +41,6 @@ Build:2.0,200 cp $$ApacheHttpCore$$/httpcore/target/httpcore-4.3.2.jar $$ApacheHttpClient$$/httpclient/target/httpclient-4.3.5.jar $$ApacheHttpClient$$/httpmime/target/httpmime-4.3.5.jar libs/ -Maintainer Notes: -Waiting for https://github.com/lgallard/qBittorrent-Client/issues/1 -. - Auto Update Mode:None Update Check Mode:RepoManifest diff --git a/metadata/com.lgallardo.qbittorrentclient/remove_admob.diff b/metadata/com.lgallardo.qbittorrentclient/remove_admob.diff new file mode 100644 index 0000000000..7959fc7fe6 --- /dev/null +++ b/metadata/com.lgallardo.qbittorrentclient/remove_admob.diff @@ -0,0 +1,212 @@ +diff --git a/qBittorrentClient/AndroidManifest.xml b/qBittorrentClient/AndroidManifest.xml +index 66b74b3..09b6f95 100644 +--- a/qBittorrentClient/AndroidManifest.xml ++++ b/qBittorrentClient/AndroidManifest.xml +@@ -145,16 +145,6 @@ + android:name="com.lgallardo.qbittorrentclient.OptionsActivity" + android:label="Options" > + +- +- +- +- +- /> + + +- +\ No newline at end of file ++ +diff --git a/qBittorrentClient/res/layout-large/activity_main.xml b/qBittorrentClient/res/layout-large/activity_main.xml +index c6e4215..462c7c3 100644 +--- a/qBittorrentClient/res/layout-large/activity_main.xml ++++ b/qBittorrentClient/res/layout-large/activity_main.xml +@@ -21,20 +21,10 @@ + android:layout_height="wrap_content" + android:orientation="vertical" > + +- +- + + +@@ -62,4 +52,4 @@ + android:divider="@android:color/transparent" + android:dividerHeight="0dp" /> + +- +\ No newline at end of file ++ +diff --git a/qBittorrentClient/res/layout/activity_main.xml b/qBittorrentClient/res/layout/activity_main.xml +index 29b0445..b5b87f8 100644 +--- a/qBittorrentClient/res/layout/activity_main.xml ++++ b/qBittorrentClient/res/layout/activity_main.xml +@@ -21,20 +21,10 @@ + android:layout_height="wrap_content" + android:orientation="vertical" > + +- +- + + + + +- +\ No newline at end of file ++ +diff --git a/qBittorrentClient/src/com/lgallardo/qbittorrentclient/MainActivity.java b/qBittorrentClient/src/com/lgallardo/qbittorrentclient/MainActivity.java +index 93bd612..39c72fd 100644 +--- a/qBittorrentClient/src/com/lgallardo/qbittorrentclient/MainActivity.java ++++ b/qBittorrentClient/src/com/lgallardo/qbittorrentclient/MainActivity.java +@@ -48,9 +48,6 @@ import android.widget.ListView; + import android.widget.TextView; + import android.widget.Toast; + +-import com.google.android.gms.ads.AdRequest; +-import com.google.android.gms.ads.AdView; +- + public class MainActivity extends FragmentActivity { + + // Params to get JSON Array +@@ -159,8 +156,6 @@ public class MainActivity extends FragmentActivity { + + private boolean okay = false; + +- private AdView adView; +- + @Override + protected void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); +@@ -318,18 +313,6 @@ public class MainActivity extends FragmentActivity { + + } + +- // Load Banner +- +- public void loadBanner() { +- +- // Look up the AdView as a resource and load a request. +- adView = (AdView) this.findViewById(R.id.adView); +- AdRequest adRequest = new AdRequest.Builder().build(); +- +- // Start loading the ad in the background. +- adView.loadAd(adRequest); +- } +- + // Drawer's method + + @Override +@@ -403,9 +386,6 @@ public class MainActivity extends FragmentActivity { + + qtt.execute(params); + +- // Load banner +- loadBanner(); +- + // Connecting message + Toast.makeText(getApplicationContext(), R.string.connecting, Toast.LENGTH_SHORT).show(); + +diff --git a/qBittorrentClient/src/com/lgallardo/qbittorrentclient/TorrentDetailsFragment.java b/qBittorrentClient/src/com/lgallardo/qbittorrentclient/TorrentDetailsFragment.java +index af9d1bd..656461d 100644 +--- a/qBittorrentClient/src/com/lgallardo/qbittorrentclient/TorrentDetailsFragment.java ++++ b/qBittorrentClient/src/com/lgallardo/qbittorrentclient/TorrentDetailsFragment.java +@@ -10,10 +10,6 @@ + ******************************************************************************/ + package com.lgallardo.qbittorrentclient; + +-import com.google.android.gms.ads.AdRequest; +-import com.google.android.gms.ads.AdSize; +-import com.google.android.gms.ads.AdView; +- + import android.app.Fragment; + import android.content.pm.ActivityInfo; + import android.os.Bundle; +@@ -45,7 +41,6 @@ public class TorrentDetailsFragment extends Fragment { + + int position; + +- private AdView adView; + private View rootView; + + public TorrentDetailsFragment() { +@@ -143,8 +138,6 @@ public class TorrentDetailsFragment extends Fragment { + Log.e("TorrentDetailsFragment - onCreateView", e.toString()); + } + +- // Load banner +- loadBanner(); + return rootView; + } + +@@ -177,31 +170,4 @@ public class TorrentDetailsFragment extends Fragment { + } + } + +- // Load Banner +- public void loadBanner() { +- +- // LinearLayout linearLayout = null; +- +- // linearLayout.removeView(adView); +- // +- // LinearLayout.LayoutParams adsParams = new +- // LinearLayout.LayoutParams(LinearLayout.LayoutParams.WRAP_CONTENT, +- // LinearLayout.LayoutParams.WRAP_CONTENT, +- // android.view.Gravity.BOTTOM | +- // android.view.Gravity.CENTER_HORIZONTAL); +- // +- // +- // linearLayout.addView(adView, adsParams); +- // +- +- // Get the adView. +- adView = (AdView) getActivity().findViewById(R.id.adView); +- +- AdRequest adRequest = new AdRequest.Builder().build(); +- +- // Start loading the ad in the background. +- adView.loadAd(adRequest); +- +- } +- + } +diff --git a/qBittorrentClient/project.properties b/qBittorrentClient/project.properties +index 745e472..7472fc8 100644 +--- a/qBittorrentClient/project.properties ++++ b/qBittorrentClient/project.properties +@@ -22,4 +22,3 @@ + + # Project target. + target=android-19 +-android.library.reference.1=../../../Projects/Android/extras/google/google_play_services/libproject/google-play-services_lib