https://bugs.kde.org/show_bug.cgi?id=368089

            Bug ID: 368089
           Summary: Ringing Phone stops
           Product: kdeconnect
           Version: unspecified
          Platform: Android
                OS: Android 5.x
            Status: UNCONFIRMED
          Severity: normal
          Priority: NOR
         Component: android-application
          Assignee: [email protected]
          Reporter: [email protected]

Ok, there are a few prerequisites.
- The user must have a custom ringtone.
- There are possibly more that I don't know about.

When the ringtone is a user defined ringtone, after one iteration, KDE Connect
stops playing the ringtone.

I tested with a custom ringtone, and it didn't loop. When I reverted back to
the default 'Over the Horizon' (which sounds pretty good!) the sound looped.

I had this problem when I was coding this thing called theLink for Android, I
fixed this issue by creating an object of type MediaPlayer, setting the Data
Source to the URI of the default ringtone, setting the Looping property to true
and starting it. When the activity was destroyed, I would stop the media
player.

           MediaPlayer mp = new MediaPlayer();
            mp.setAudioStreamType(AudioManager.STREAM_MUSIC);
            mp.setDataSource(getApplicationContext(),
RingtoneManager.getDefaultUri(RingtoneManager.TYPE_RINGTONE));
            mp.setLooping(true);
            mp.prepare();
            mp.start();

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to