Skip to content

Commit

Permalink
Merge pull request #1702 from axmhari/reclist-after-play
Browse files Browse the repository at this point in the history
Show PVR recordings view after replaying a PVR item.
  • Loading branch information
pieh committed Nov 21, 2012
2 parents 2ff8cca + 42ef712 commit 4bf192d
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 5 deletions.
2 changes: 1 addition & 1 deletion xbmc/pvr/windows/GUIWindowPVRChannels.cpp
Expand Up @@ -207,7 +207,7 @@ void CGUIWindowPVRChannels::UpdateData(bool bUpdateSelectedFile /* = true */)
CPVRChannelGroupPtr selectedGroup = SelectedGroup(); CPVRChannelGroupPtr selectedGroup = SelectedGroup();


m_iSelected = m_parent->m_viewControl.GetSelectedItem(); m_iSelected = m_parent->m_viewControl.GetSelectedItem();
m_parent->m_viewControl.Clear(); ShowBusyItem();
m_parent->m_vecItems->Clear(); m_parent->m_vecItems->Clear();
m_parent->m_viewControl.SetCurrentView(m_iControlList); m_parent->m_viewControl.SetCurrentView(m_iControlList);


Expand Down
14 changes: 14 additions & 0 deletions xbmc/pvr/windows/GUIWindowPVRCommon.cpp
Expand Up @@ -190,6 +190,7 @@ bool CGUIWindowPVRCommon::OnMessageFocus(CGUIMessage &message)
void CGUIWindowPVRCommon::OnWindowUnload(void) void CGUIWindowPVRCommon::OnWindowUnload(void)
{ {
m_iSelected = m_parent->m_viewControl.GetSelectedItem(); m_iSelected = m_parent->m_viewControl.GetSelectedItem();
m_history = m_parent->m_history;
} }


bool CGUIWindowPVRCommon::OnAction(const CAction &action) bool CGUIWindowPVRCommon::OnAction(const CAction &action)
Expand Down Expand Up @@ -869,3 +870,16 @@ bool CGUIWindowPVRCommon::OnContextButtonFind(CFileItem *item, CONTEXT_BUTTON bu


return bReturn; return bReturn;
} }

void CGUIWindowPVRCommon::ShowBusyItem(void)
{
// FIXME: display a temporary entry so that the list can keep its focus
// busy_items has to be static, because m_viewControl holds the pointer to it
static CFileItemList busy_items;
if (busy_items.IsEmpty())
{
CFileItemPtr pItem(new CFileItem(g_localizeStrings.Get(1040)));
busy_items.AddFront(pItem, 0);
}
m_parent->m_viewControl.SetItems(busy_items);
}
1 change: 1 addition & 0 deletions xbmc/pvr/windows/GUIWindowPVRCommon.h
Expand Up @@ -119,6 +119,7 @@ namespace PVR
virtual bool UpdateEpgForChannel(CFileItem *item); virtual bool UpdateEpgForChannel(CFileItem *item);
virtual bool ShowTimerSettings(CFileItem *item); virtual bool ShowTimerSettings(CFileItem *item);
virtual bool ShowNewTimerDialog(void); virtual bool ShowNewTimerDialog(void);
virtual void ShowBusyItem(void);


virtual bool OnContextButtonMenuHooks(CFileItem *item, CONTEXT_BUTTON button); virtual bool OnContextButtonMenuHooks(CFileItem *item, CONTEXT_BUTTON button);
virtual bool OnContextButtonSortAsc(CFileItem *item, CONTEXT_BUTTON button); virtual bool OnContextButtonSortAsc(CFileItem *item, CONTEXT_BUTTON button);
Expand Down
2 changes: 1 addition & 1 deletion xbmc/pvr/windows/GUIWindowPVRGuide.cpp
Expand Up @@ -270,7 +270,7 @@ void CGUIWindowPVRGuide::UpdateData(bool bUpdateSelectedFile /* = true */)


/* lock the graphics context while updating */ /* lock the graphics context while updating */
CSingleLock graphicsLock(g_graphicsContext); CSingleLock graphicsLock(g_graphicsContext);
m_parent->m_viewControl.Clear(); ShowBusyItem();
m_parent->m_vecItems->Clear(); m_parent->m_vecItems->Clear();


if (m_iGuideView == GUIDE_VIEW_CHANNEL) if (m_iGuideView == GUIDE_VIEW_CHANNEL)
Expand Down
2 changes: 1 addition & 1 deletion xbmc/pvr/windows/GUIWindowPVRRecordings.cpp
Expand Up @@ -208,7 +208,7 @@ void CGUIWindowPVRRecordings::UpdateData(bool bUpdateSelectedFile /* = true */)
else else
m_strSelectedPath = m_parent->m_vecItems->GetPath(); m_strSelectedPath = m_parent->m_vecItems->GetPath();


m_parent->m_viewControl.Clear(); ShowBusyItem();
m_parent->m_vecItems->Clear(); m_parent->m_vecItems->Clear();
m_parent->m_viewControl.SetCurrentView(m_iControlList); m_parent->m_viewControl.SetCurrentView(m_iControlList);
m_parent->m_vecItems->SetPath(m_strSelectedPath); m_parent->m_vecItems->SetPath(m_strSelectedPath);
Expand Down
2 changes: 1 addition & 1 deletion xbmc/pvr/windows/GUIWindowPVRSearch.cpp
Expand Up @@ -101,7 +101,7 @@ void CGUIWindowPVRSearch::UpdateData(bool bUpdateSelectedFile /* = true */)
CSingleLock graphicsLock(g_graphicsContext); CSingleLock graphicsLock(g_graphicsContext);


m_iSelected = m_parent->m_viewControl.GetSelectedItem(); m_iSelected = m_parent->m_viewControl.GetSelectedItem();
m_parent->m_viewControl.Clear(); ShowBusyItem();
m_parent->m_vecItems->Clear(); m_parent->m_vecItems->Clear();
m_parent->m_viewControl.SetCurrentView(m_iControlList); m_parent->m_viewControl.SetCurrentView(m_iControlList);


Expand Down
2 changes: 1 addition & 1 deletion xbmc/pvr/windows/GUIWindowPVRTimers.cpp
Expand Up @@ -105,7 +105,7 @@ void CGUIWindowPVRTimers::UpdateData(bool bUpdateSelectedFile /* = true */)
CSingleLock graphicsLock(g_graphicsContext); CSingleLock graphicsLock(g_graphicsContext);


m_iSelected = m_parent->m_viewControl.GetSelectedItem(); m_iSelected = m_parent->m_viewControl.GetSelectedItem();
m_parent->m_viewControl.Clear(); ShowBusyItem();
m_parent->m_vecItems->Clear(); m_parent->m_vecItems->Clear();
m_parent->m_viewControl.SetCurrentView(m_iControlList); m_parent->m_viewControl.SetCurrentView(m_iControlList);
m_parent->m_vecItems->SetPath("pvr://timers/"); m_parent->m_vecItems->SetPath("pvr://timers/");
Expand Down

1 comment on commit 4bf192d

@avdleeuw
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This commit seems to break the EPG timeline for me... Haven't been able to figure out why, yet.

Please sign in to comment.