Browse files

changed: No need for CGUIWindowAddonBrowser to have OnJobComplete - u…

…se CAddonInstaller's instead.
  • Loading branch information...
1 parent b5c934d commit 01fa5fef56ba9b37e4371eff88d9f6590ae982f7 Jonathan Marshall committed Jan 30, 2011
Showing with 2 additions and 14 deletions.
  1. +1 −10 xbmc/addons/GUIWindowAddonBrowser.cpp
  2. +1 −4 xbmc/addons/GUIWindowAddonBrowser.h
View
11 xbmc/addons/GUIWindowAddonBrowser.cpp
@@ -191,7 +191,7 @@ bool CGUIWindowAddonBrowser::OnContextButton(int itemNumber,
if (button == CONTEXT_BUTTON_SCAN)
{
RepositoryPtr repo = boost::dynamic_pointer_cast<CRepository>(addon);
- CJobManager::GetInstance().AddJob(new CRepositoryUpdateJob(repo,false),this);
+ CJobManager::GetInstance().AddJob(new CRepositoryUpdateJob(repo,false),&CAddonInstaller::Get());
return true;
}
@@ -378,12 +378,3 @@ CStdString CGUIWindowAddonBrowser::GetStartFolder(const CStdString &dir)
return dir;
return CGUIMediaWindow::GetStartFolder(dir);
}
-
-void CGUIWindowAddonBrowser::OnJobComplete(unsigned int jobID, bool success, CJob* job)
-{
- if (success)
- { // repository update is finished - refresh listing
- CGUIMessage msg(GUI_MSG_NOTIFY_ALL, 0, 0, GUI_MSG_UPDATE);
- g_windowManager.SendThreadMessage(msg);
- }
-}
View
5 xbmc/addons/GUIWindowAddonBrowser.h
@@ -23,20 +23,17 @@
#include "addons/Addon.h"
#include "windows/GUIMediaWindow.h"
-#include "utils/Job.h"
#include "pictures/PictureThumbLoader.h"
class CFileItem;
class CFileItemList;
-class CGUIWindowAddonBrowser : public CGUIMediaWindow, IJobCallback
+class CGUIWindowAddonBrowser : public CGUIMediaWindow
{
public:
CGUIWindowAddonBrowser(void);
virtual ~CGUIWindowAddonBrowser(void);
virtual bool OnMessage(CGUIMessage& message);
-
- void OnJobComplete(unsigned int jobID, bool success, CJob* job);
/*! \brief Popup a selection dialog with a list of addons of the given type
\param type the type of addon wanted

0 comments on commit 01fa5fe

Please sign in to comment.