Skip to content
This repository
Browse code

make sure we setup the visualisation preset list prior to init'ing th…

…e window. part of #13556
  • Loading branch information...
commit c0e9cc0b31dbe12b2275c045a25c88cd52046e25 1 parent 18e10be
authored November 16, 2012
18  xbmc/music/dialogs/GUIDialogVisualisationPresetList.cpp
@@ -67,16 +67,6 @@ bool CGUIDialogVisualisationPresetList::OnMessage(CGUIMessage &message)
67 67
       }
68 68
     }
69 69
     break;
70  
-  case GUI_MSG_WINDOW_INIT:
71  
-    {
72  
-      CGUIDialog::OnMessage(message);
73  
-
74  
-      CGUIMessage msg(GUI_MSG_GET_VISUALISATION, 0, 0);
75  
-      g_windowManager.SendMessage(msg);
76  
-      SetVisualisation((CVisualisation*)msg.GetPointer());
77  
-      return true;
78  
-    }
79  
-    break;
80 70
   case GUI_MSG_WINDOW_DEINIT:
81 71
   case GUI_MSG_VISUALISATION_UNLOADING:
82 72
     {
@@ -122,6 +112,14 @@ void CGUIDialogVisualisationPresetList::FrameMove()
122 112
   CGUIDialog::FrameMove();
123 113
 }
124 114
 
  115
+void CGUIDialogVisualisationPresetList::OnInitWindow()
  116
+{
  117
+  CGUIMessage msg(GUI_MSG_GET_VISUALISATION, 0, 0);
  118
+  g_windowManager.SendMessage(msg);
  119
+  SetVisualisation((CVisualisation*)msg.GetPointer());
  120
+  CGUIDialog::OnInitWindow();
  121
+}
  122
+
125 123
 void CGUIDialogVisualisationPresetList::Update()
126 124
 {
127 125
   m_vecPresets->Clear();
1  xbmc/music/dialogs/GUIDialogVisualisationPresetList.h
@@ -38,6 +38,7 @@ class CGUIDialogVisualisationPresetList :
38 38
   virtual void FrameMove();
39 39
 
40 40
 protected:
  41
+  virtual void OnInitWindow();
41 42
   void SetVisualisation(ADDON::CVisualisation *addon);
42 43
   void Update();
43 44
   ADDON::CVisualisation* m_viz; //TODO get rid

0 notes on commit c0e9cc0

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