]> git.sesse.net Git - vlc/blobdiff - modules/gui/skins2/src/popup.cpp
skins2: implement relative positioning
[vlc] / modules / gui / skins2 / src / popup.cpp
index 8da08bd77e2c7d7c6a297ae6f46fd55086cb5118..073b97352941bb50615e9bf39ab29a22fea3add4 100644 (file)
@@ -4,7 +4,7 @@
  * Copyright (C) 2003 the VideoLAN team
  * $Id$
  *
- * Authors: Olivier Teulière <ipkiss@via.ecp.fr>
+ * Authors: Olivier Teulière <ipkiss@via.ecp.fr>
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -73,14 +73,14 @@ void Popup::addSeparator( int pos )
 void Popup::handleEvent( const EvtMenu &rEvent )
 {
     unsigned int n = m_pOsPopup->getPosFromId( rEvent.getItemId() );
-    if( n >= 0 && n < m_actions.size() && m_actions[n] )
+    if( (n < m_actions.size()) && m_actions[n] )
     {
         m_actions[n]->execute();
     }
     else
     {
         // Should never happen
-        msg_Warn( getIntf(), "Problem in the popup implementation" );
+        msg_Warn( getIntf(), "problem in the popup implementation" );
     }
 }