@Override
        public boolean handleMessage(Message msg) {
            try {
                if(mReleasing) {
                    // When the releasing flag is set, just release without processing any more messages
                    releaseInternal();
                    return true;
                }

                switch (msg.what) {
                    case PLAYBACK_PREPARE:
                        prepareInternal();
                        return true;
                    case PLAYBACK_PLAY:
                        playInternal();
                        return true;
                    case PLAYBACK_PAUSE:
                        pauseInternal();
                        return true;
                    case PLAYBACK_PAUSE_AUDIO:
                        pauseInternalAudio();
                        return true;
                    case PLAYBACK_LOOP:
                        loopInternal();
                        return true;
                    case PLAYBACK_SEEK:
                        seekInternal((Long) msg.obj);
                        return true;
                    case PLAYBACK_RELEASE:
                        releaseInternal();
                        return true;
                    case DECODER_SET_SURFACE:
                        setVideoSurface((Surface) msg.obj);
                        return true;
                    default:
                        Log.d(TAG, "unknown/invalid message");
                        return false;
                }
            } catch (InterruptedException e) {
                Log.d(TAG, "decoder interrupted", e);
                mEventHandler.sendMessage(mEventHandler.obtainMessage(MEDIA_ERROR,
                        MEDIA_ERROR_UNKNOWN, 0));
            } catch (IllegalStateException e) {
                Log.e(TAG, "decoder error, too many instances?", e);
                mEventHandler.sendMessage(mEventHandler.obtainMessage(MEDIA_ERROR,
                        MEDIA_ERROR_UNKNOWN, 0));
            } catch (IOException e) {
                Log.e(TAG, "decoder error, codec can not be created", e);
                mEventHandler.sendMessage(mEventHandler.obtainMessage(MEDIA_ERROR,
                        MEDIA_ERROR_UNKNOWN, MEDIA_ERROR_IO));
            }

            // Release after an exception
            releaseInternal();
            return true;
        }
Removes a cue added by {@link #addCue(int, Object)} from the playback timeline.

@param cue the cue to remove
@return true if removal was successful, false if the cue wasn't cued on the timeline,
i.e. it has already been removed before
MediaPlayer/src/main/java/net/protyposis/android/mediaplayer/MediaPlayer.java