Skip to content

Commit

Permalink
[cleanup] convert a few g_windowManager.SendMessage()'s to OnMessage()
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Marshall committed Jul 4, 2014
1 parent 7c52d33 commit 5bf55b2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
4 changes: 2 additions & 2 deletions xbmc/settings/dialogs/GUIDialogContentSettings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ bool CGUIDialogContentSettings::OnMessage(CGUIMessage &message)
if (iControl == CONTROL_CONTENT_TYPE)
{
CGUIMessage msg(GUI_MSG_ITEM_SELECTED, GetID(), CONTROL_CONTENT_TYPE);
g_windowManager.SendMessage(msg);
OnMessage(msg);
m_content = static_cast<CONTENT_TYPE>(msg.GetParam1());
SetupView();
}
Expand All @@ -100,7 +100,7 @@ bool CGUIDialogContentSettings::OnMessage(CGUIMessage &message)
break;

CGUIMessage msg(GUI_MSG_ITEM_SELECTED, GetID(), CONTROL_SCRAPER_LIST);
g_windowManager.SendMessage(msg);
OnMessage(msg);
int iSelected = msg.GetParam1();
if (iSelected == m_vecItems->Size() - 1)
{ // Get More... item, path 'addons://more/<content>'
Expand Down
3 changes: 1 addition & 2 deletions xbmc/windows/GUIWindowWeather.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
#include "dialogs/GUIDialogOK.h"
#include "GUIWindowWeather.h"
#include "utils/Weather.h"
#include "guilib/GUIWindowManager.h"
#include "utils/URIUtils.h"
#ifdef HAS_PYTHON
#include "interfaces/python/XBPython.h"
Expand Down Expand Up @@ -85,7 +84,7 @@ bool CGUIWindowWeather::OnMessage(CGUIMessage& message)
else if (iControl == CONTROL_SELECTLOCATION)
{
CGUIMessage msg(GUI_MSG_ITEM_SELECTED,GetID(),CONTROL_SELECTLOCATION);
g_windowManager.SendMessage(msg);
OnMessage(msg);

SetLocation(msg.GetParam1());
}
Expand Down

0 comments on commit 5bf55b2

Please sign in to comment.