本文整理汇总了Java中net.sourceforge.servestream.utils.MusicUtils.unbindFromService方法的典型用法代码示例。如果您正苦于以下问题:Java MusicUtils.unbindFromService方法的具体用法?Java MusicUtils.unbindFromService怎么用?Java MusicUtils.unbindFromService使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类net.sourceforge.servestream.utils.MusicUtils
的用法示例。
在下文中一共展示了MusicUtils.unbindFromService方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onDestroy
import net.sourceforge.servestream.utils.MusicUtils; //导入方法依赖的package包/类
@Override
public void onDestroy() {
MusicUtils.unbindFromService(mToken);
mService = null;
super.onDestroy();
mImageFetcher.closeCache();
}
示例2: onStop
import net.sourceforge.servestream.utils.MusicUtils; //导入方法依赖的package包/类
@Override
public void onStop() {
getActivity().unregisterReceiver(mStatusListener);
MusicUtils.unbindFromService(mToken);
mService = null;
super.onStop();
}
示例3: onDestroy
import net.sourceforge.servestream.utils.MusicUtils; //导入方法依赖的package包/类
@Override
public void onDestroy() {
stop();
// Stop listening for incoming calls.
mTelephonyManager.listen(mPhoneStateListener, 0);
AlarmAlertWakeLock.releaseCpuLock();
MusicUtils.unbindFromService(mToken);
}
示例4: onStop
import net.sourceforge.servestream.utils.MusicUtils; //导入方法依赖的package包/类
@Override
public void onStop() {
paused = true;
mHandler.removeMessages(REFRESH);
getApplicationContext().getContentResolver().unregisterContentObserver(mVolumeObserver);
unregisterReceiver(mStatusListener);
MusicUtils.unbindFromService(mToken);
mService = null;
super.onStop();
}
示例5: onDestroy
import net.sourceforge.servestream.utils.MusicUtils; //导入方法依赖的package包/类
@Override
public void onDestroy() {
ListView lv = mList;
if (lv != null) {
// clear the listeners so we won't get any more callbacks
((DragSortListView) lv).setDropListener(null);
((DragSortListView) lv).setRemoveListener(null);
}
MusicUtils.unbindFromService(mToken);
try {
unregisterReceiver(mNowPlayingListener);
} catch (IllegalArgumentException ex) {
// we end up here in case we never registered the listeners
}
// If we have an adapter and didn't send it off to another activity yet, we should
// close its cursor, which we do by assigning a null cursor to it. Doing this
// instead of closing the cursor directly keeps the framework from accessing
// the closed cursor later.
if (!mAdapterSent && mAdapter != null) {
mAdapter.changeCursor(null);
}
// Because we pass the adapter to the next activity, we need to make
// sure it doesn't keep a reference to this activity. We can do this
// by clearing its DatasetObservers, which setListAdapter(null) does.
mList.setAdapter(null);
mAdapter = null;
mImageFetcher.closeCache();
super.onDestroy();
}
示例6: onDestroy
import net.sourceforge.servestream.utils.MusicUtils; //导入方法依赖的package包/类
@Override
public void onDestroy() {
ListView lv = getListView();
if (lv != null) {
// clear the listeners so we won't get any more callbacks
((DragSortListView) lv).setDropListener(null);
((DragSortListView) lv).setRemoveListener(null);
}
MusicUtils.unbindFromService(mToken);
try {
unregisterReceiver(mNowPlayingListener);
} catch (IllegalArgumentException ex) {
// we end up here in case we never registered the listeners
}
// If we have an adapter and didn't send it off to another activity yet, we should
// close its cursor, which we do by assigning a null cursor to it. Doing this
// instead of closing the cursor directly keeps the framework from accessing
// the closed cursor later.
if (!mAdapterSent && mAdapter != null) {
mAdapter.changeCursor(null);
}
// Because we pass the adapter to the next activity, we need to make
// sure it doesn't keep a reference to this activity. We can do this
// by clearing its DatasetObservers, which setListAdapter(null) does.
getListView().setAdapter(null);
mAdapter = null;
super.onDestroy();
}
示例7: onDestroy
import net.sourceforge.servestream.utils.MusicUtils; //导入方法依赖的package包/类
@Override
public void onDestroy() {
super.onDestroy();
MusicUtils.unbindFromService(mToken);
}
示例8: onDestroy
import net.sourceforge.servestream.utils.MusicUtils; //导入方法依赖的package包/类
@Override
protected void onDestroy() {
MusicUtils.unbindFromService(mToken);
super.onDestroy();
}