Giter Club home page Giter Club logo

Comments (6)

4oo4 avatar 4oo4 commented on June 8, 2024 1

I think I managed to capture this happening in a logcat, will post that in gitter. This also happens to me on occasion, also using LOS 15.1 on OnePlus 5T. From experience, it seems to happen when getting towards the end of a longer (10+ minute) song.

from ultrasonic.

evan-goode avatar evan-goode commented on June 8, 2024

I've been having this issue since I started using Ultrasonic. I have to "force stop" it to get the second track to stop.

I'm running LineageOS 15.1 on a Oneplus 5T. I can dig a little deeper, perhaps post a logcat if it would be helpful.

from ultrasonic.

mgoldeyy avatar mgoldeyy commented on June 8, 2024

This happened to me again a week ago while driving. Also a long song. Freeze, then both instances started playing at the same time.

Samsung S6 (same phone as before), Android 7.0, Ultrasonic 2.5

from ultrasonic.

4oo4 avatar 4oo4 commented on June 8, 2024

Any update on this? This is a super annoying bug. I'm taking a stab in the dark as to what could be causing this, could it be related to MenuDrawer? I see a default duration of 600 for a menu animation, could it be when that duration is reached during playback, that's what triggers the behavior?

/**
* The maximum animation duration.
*/
private static final int DEFAULT_ANIMATION_DURATION = 600;

/**
* Moves the drawer to the position passed.
*
* @param position The position the content is moved to.
* @param velocity Optional velocity if called by releasing a drag event.
* @param animate Whether the move is animated.
*/
protected void animateOffsetTo(int position, int velocity, boolean animate) {
endDrag();
endPeek();
final int startX = (int) mOffsetPixels;
final int dx = position - startX;
if (dx == 0 || !animate) {
setOffsetPixels(position);
setDrawerState(position == 0 ? STATE_CLOSED : STATE_OPEN);
stopLayerTranslation();
return;
}
int duration;
velocity = Math.abs(velocity);
if (velocity > 0) {
duration = 4 * Math.round(1000.f * Math.abs((float) dx / velocity));
} else {
duration = (int) (600.f * Math.abs((float) dx / mMenuSize));
}
duration = Math.min(duration, mMaxAnimationDuration);
animateOffsetTo(position, duration);
}

from ultrasonic.

4oo4 avatar 4oo4 commented on June 8, 2024

That doesn't seem to be it, but whatever is causing it, it's calling writeObject.

10-07 20:09:14.823 I/FileUtil( 8008): Serialized object to /data/user/0/org.moire.ultrasonic/cache/downloadstate.ser

public static <T extends Serializable> boolean serialize(Context context, T obj, String fileName)
{
File file = new File(context.getCacheDir(), fileName);
ObjectOutputStream out = null;
try
{
out = new ObjectOutputStream(new FileOutputStream(file));
out.writeObject(obj);
Log.i(TAG, String.format("Serialized object to %s", file));
return true;
}
catch (Throwable x)
{
Log.w(TAG, String.format("Failed to serialize object to %s", file));
return false;
}
finally
{
Util.close(out);
}
}

from ultrasonic.

4oo4 avatar 4oo4 commented on June 8, 2024

Any updates on this? I just noticed that with Android Q (stock Pixel 3 ROM) that it now will stop the first song and the second "headless" one takes over, whereas with Android O and P it would play them both simultaneously (that was OnePlus 5T on LineageOS though).

EDIT: I wonder if 2.6.2 may have fixed this? Since updating I haven't been able to reproduce this. I'll do some more testing.

from ultrasonic.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.