Skip to content
This repository has been archived by the owner on Dec 28, 2022. It is now read-only.

Commit

Permalink
Remove 'upgrade to pro' (Shuttle is now free)
Browse files Browse the repository at this point in the history
  • Loading branch information
timusus committed Jul 12, 2020
1 parent b381433 commit 036dbba
Show file tree
Hide file tree
Showing 61 changed files with 42 additions and 865 deletions.
11 changes: 1 addition & 10 deletions .idea/compiler.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 10 additions & 12 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ android {
}

compileSdkVersion Dependencies.compileSdk
buildToolsVersion Dependencies.buildTools

defaultConfig {
minSdkVersion Dependencies.minSdk
Expand Down Expand Up @@ -270,7 +269,6 @@ dependencies {
implementation Dependencies.materialDialogs
implementation Dependencies.materialDialogCommons
implementation Dependencies.expandableRecyclerView
implementation Dependencies.billing

implementation Dependencies.butterknife
kapt Dependencies.butterknifeAnnotationProcessor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,16 +35,13 @@
import com.simplecity.amp_library.sql.databases.CustomArtworkTable;
import com.simplecity.amp_library.sql.providers.PlayCountTable;
import com.simplecity.amp_library.sql.sqlbrite.SqlBriteUtils;
import com.simplecity.amp_library.utils.AnalyticsManager;
import com.simplecity.amp_library.utils.DataManager;
import com.simplecity.amp_library.utils.InputMethodManagerLeaks;
import com.simplecity.amp_library.utils.LegacyUtils;
import com.simplecity.amp_library.utils.LogUtils;
import com.simplecity.amp_library.utils.SettingsManager;
import com.simplecity.amp_library.utils.StringUtils;
import com.squareup.leakcanary.LeakCanary;
import com.squareup.leakcanary.RefWatcher;
import hu.akarnokd.rxjava2.debug.RxJavaAssemblyTracking;
import io.fabric.sdk.android.Fabric;
import io.reactivex.Completable;
import io.reactivex.Observable;
Expand Down Expand Up @@ -78,8 +75,6 @@ public static synchronized ShuttleApplication getInstance() {
return instance;
}

private boolean isUpgraded;

public static final double VOLUME_INCREMENT = 0.05;

private RefWatcher refWatcher;
Expand Down Expand Up @@ -203,15 +198,6 @@ public static String getVersion() {
return "unknown";
}

public void setIsUpgraded(boolean isUpgraded) {
this.isUpgraded = isUpgraded;
AnalyticsManager.setIsUpgraded();
}

public boolean getIsUpgraded() {
return isUpgraded || BuildConfig.DEBUG;
}

public static File getDiskCacheDir(String uniqueName) {
try {
// Check if media is mounted or storage is built-in, if so, try and use external cache dir
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,4 @@ private Config() {
public static final String PACKAGE_NAME_PRO = "com.simplecity.amp_pro";

public static final String CHROMECAST_APP_ID = "73341C53";

// IAP
public static final String SKU_PREMIUM = "id_upgrade_to_pro";
}
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,9 @@ class ChromecastManager {
}

void init() {
if (ShuttleUtils.isUpgraded()) {
castManager = VideoCastManager.getInstance();
setupCastListener();
castManager.addVideoCastConsumer(castConsumer);
}
castManager = VideoCastManager.getInstance();
setupCastListener();
castManager.addVideoCastConsumer(castConsumer);

if (castManager != null && castManager.isConnected()) {
updatePlaybackLocation(PlaybackManager.PlaybackLocation.REMOTE);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -652,7 +652,7 @@ public void stop(boolean goToIdle) {
Log.e(TAG, e.toString());
}
if (goToIdle) {
if (ShuttleUtils.isUpgraded() && chromecastManager.castManager != null) {
if (chromecastManager.castManager != null) {
HttpServer.getInstance().stop();
}
setIsSupposedToBePlaying(false, false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
import com.simplecity.amp_library.ui.detail.album.AlbumDetailFragment;
import com.simplecity.amp_library.ui.detail.artist.ArtistDetailFragment;
import com.simplecity.amp_library.ui.dialog.DeleteDialog;
import com.simplecity.amp_library.ui.dialog.UpgradeDialog;
import com.simplecity.amp_library.ui.fragments.BaseFragment;
import com.simplecity.amp_library.ui.modelviews.AlbumArtistView;
import com.simplecity.amp_library.ui.modelviews.AlbumView;
Expand Down Expand Up @@ -350,11 +349,6 @@ public void goToAlbum(Album album, View transitionView) {
searchView.getHandler().postDelayed(() -> pushDetailFragment(AlbumDetailFragment.newInstance(album, transitionName), transitionView), 50);
}

@Override
public void showUpgradeDialog() {
UpgradeDialog.getUpgradeDialog(getActivity()).show();
}

void pushDetailFragment(Fragment fragment, @Nullable View transitionView) {

List<Pair<View, String>> transitions = new ArrayList<>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,4 @@ public interface SearchView {
void goToArtist(AlbumArtist albumArtist, View transitionView);

void goToAlbum(Album album, View transitionView);

void showUpgradeDialog();
}

0 comments on commit 036dbba

Please sign in to comment.