Skip to content
Browse files

autoplay next item didn't apply to some music addons

  • Loading branch information...
1 parent 873c854 commit 0f9b3ed6a33ebaa2ec9dca24654a6ece5252c801 Jonathan Marshall committed Jan 27, 2012
Showing with 6 additions and 4 deletions.
  1. +6 −4 xbmc/windows/GUIMediaWindow.cpp
View
10 xbmc/windows/GUIMediaWindow.cpp
@@ -967,16 +967,18 @@ bool CGUIMediaWindow::OnClick(int iItem)
g_guiSettings.GetBool("karaoke.autopopupselector") && pItem->IsKaraoke();
bool autoplay = m_guiState.get() && m_guiState->AutoPlayNextItem();
- if (pItem->IsPlugin())
+ if (m_vecItems->IsPlugin())
{
- CURL url(pItem->GetPath());
+ CURL url(m_vecItems->GetPath());
AddonPtr addon;
if (CAddonMgr::Get().GetAddon(url.GetHostName(),addon))
{
PluginPtr plugin = boost::dynamic_pointer_cast<CPluginSource>(addon);
- if (plugin && plugin->Provides(CPluginSource::AUDIO) && pItem->IsAudio())
+ if (plugin && plugin->Provides(CPluginSource::AUDIO))
{
- autoplay = g_guiSettings.GetBool("musicplayer.autoplaynextitem");
+ CFileItemList items;
+ auto_ptr<CGUIViewState> state(CGUIViewState::GetViewState(GetID(), items));
+ autoplay = state.get() && state->AutoPlayNextItem();
}
}
}

0 comments on commit 0f9b3ed

Please sign in to comment.
Something went wrong with that request. Please try again.