* builder.cpp
*****************************************************************************
* Copyright (C) 2003 VideoLAN
- * $Id: builder.cpp,v 1.9 2004/03/02 21:45:15 ipkiss Exp $
+ * $Id$
*
* Authors: Cyril Deguet <asmax@via.ecp.fr>
* Olivier Teulière <ipkiss@via.ecp.fr>
pBmp->getHeight(), *pLayout );
// XXX: test to be changed! XXX
- if( rData.m_onclickId == "move" )
+ if( rData.m_actionId == "move" )
{
CtrlMove *pMove = new CtrlMove( getIntf(), m_pTheme->getWindowManager(),
*pImage, *pWindow, UString( getIntf(), rData.m_help.c_str() ),
NULL);
pLayout->addControl( pMove, pos, rData.m_layer );
}
- else if( rData.m_onclickId == "resize" )
+ else if( rData.m_actionId == "resize" )
{
CtrlResize *pResize = new CtrlResize( getIntf(), *pImage, *pLayout,
UString( getIntf(), rData.m_help.c_str() ), NULL );
Anchor xPos:int yPos:int range:int priority:int points:string windowId:string
Button id:string xPos:int yPos:int leftTop:string rightBottom:string upId:string downId:string overId:string actionId:string tooltip:string help:string layer:int windowId:string layoutId:string
Checkbox id:string xPos:int yPos:int leftTop:string rightBottom:string up1Id:string down1Id:string over1Id:string up2Id:string down2Id:string over2Id:string state:string action1:string action2:string tooltip1:string tooltip2:string help:string layer:int windowId:string layoutId:string
-Image id:string xPos:int yPos:int leftTop:string rightBottom:string visible:bool bmpId:string onclickId:string help:string layer:int windowId:string layoutId:string
+Image id:string xPos:int yPos:int leftTop:string rightBottom:string visible:bool bmpId:string actionId:string help:string layer:int windowId:string layoutId:string
Text id:string xPos:int yPos:int fontId:string text:string width:int color:uint32_t help:string layer:int windowId:string layoutId:string
RadialSlider id:string visible:string xPos:int yPos:int leftTop:string rightBottom:string sequence:string nbImages:int minAngle:float maxAngle:float value:string tooltip:string help:string layer:int windowId:string layoutId:string
Slider id:string visible:string xPos:int yPos:int leftTop:string rightBottom:string upId:string downId:string overId:string points:string thickness:int value:string tooltip:string help:string layer:int windowId:string layoutId:string
* builder_data.hpp
*****************************************************************************
* Copyright (C) 2003 VideoLAN
- * $Id: builder_data.hpp,v 1.6 2004/03/02 21:45:15 ipkiss Exp $
+ * $Id$
*
* Authors: Cyril Deguet <asmax@via.ecp.fr>
* Olivier Teulière <ipkiss@via.ecp.fr>
#ifndef BUILDER_DATA_HPP
#define BUILDER_DATA_HPP
-using namespace std;
-
#include <vlc/vlc.h>
#include <list>
#include <map>
#include <string>
+using namespace std;
+
/// Structure for mapping data from XML file
struct BuilderData
{
/// Type definition
struct Image
{
- Image( const string & id, int xPos, int yPos, const string & leftTop, const string & rightBottom, bool visible, const string & bmpId, const string & onclickId, const string & help, int layer, const string & windowId, const string & layoutId ):
-m_id( id ), m_xPos( xPos ), m_yPos( yPos ), m_leftTop( leftTop ), m_rightBottom( rightBottom ), m_visible( visible ), m_bmpId( bmpId ), m_onclickId( onclickId ), m_help( help ), m_layer( layer ), m_windowId( windowId ), m_layoutId( layoutId ) {}
+ Image( const string & id, int xPos, int yPos, const string & leftTop, const string & rightBottom, bool visible, const string & bmpId, const string & actionId, const string & help, int layer, const string & windowId, const string & layoutId ):
+m_id( id ), m_xPos( xPos ), m_yPos( yPos ), m_leftTop( leftTop ), m_rightBottom( rightBottom ), m_visible( visible ), m_bmpId( bmpId ), m_actionId( actionId ), m_help( help ), m_layer( layer ), m_windowId( windowId ), m_layoutId( layoutId ) {}
const string m_id;
int m_xPos;
const string m_rightBottom;
bool m_visible;
const string m_bmpId;
- const string m_onclickId;
+ const string m_actionId;
const string m_help;
int m_layer;
const string m_windowId;
* skin_parser.cpp
*****************************************************************************
* Copyright (C) 2004 VideoLAN
- * $Id: skin_parser.cpp,v 1.5 2004/03/02 21:45:15 ipkiss Exp $
+ * $Id$
*
* Authors: Cyril Deguet <asmax@via.ecp.fr>
*
const BuilderData::Image imageData( uniqueId( attr["id"] ), atoi( attr["x"] ) +
m_xOffset, atoi( attr["y"] ) + m_yOffset, attr["lefttop"],
attr["rightbottom"], ConvertBoolean( attr["visible"] ),
- attr["image"], attr["onclick"], attr["help"], m_curLayer,
+ attr["image"], attr["action"], attr["help"], m_curLayer,
m_curWindowId, m_curLayoutId );
m_curLayer++;
m_data.m_listImage.push_back( imageData );
* generic_window.cpp
*****************************************************************************
* Copyright (C) 2003 VideoLAN
- * $Id: generic_window.cpp,v 1.3 2004/02/29 16:49:55 asmax Exp $
+ * $Id$
*
* Authors: Cyril Deguet <asmax@via.ecp.fr>
* Olivier Teulière <ipkiss@via.ecp.fr>
if( (rEvtKey.getMod() & EvtInput::kModCtrl) &&
rEvtKey.getKey() == 's' )
{
- Dialogs::instance( getIntf() )->showChangeSkin();
+ Dialogs *pDialogs = Dialogs::instance( getIntf() );
+ if( pDialogs != NULL )
+ {
+ pDialogs->showChangeSkin();
+ }
return;
}
lefttop CDATA "lefttop"
rightbottom CDATA "lefttop"
image CDATA #REQUIRED
- onclick CDATA "none"
+ action CDATA "none"
help CDATA ""
>
<!ELEMENT Button EMPTY>
<Layout id="testlayout" width="424" height="152">
<Group x="0" y="0">
- <Image x="0" y="0" image="mainbody" onclick="move"/>
+ <Image x="0" y="0" image="mainbody" action="move"/>
<Button x="8" y="5" up="close" down="close_onclick" over="close_mouseover" action="vlc.quit()" tooltiptext="Quit VLC"/>
</Group>
</Layout>
<Layout id="mainlayout" width="424" height="152">
<Group x="0" y="0">
<Anchor x="7" y="151" points="(0,0)" priority="100"/>
- <Image x="0" y="0" image="mainbody" onclick="move"/>
+ <Image x="0" y="0" image="mainbody" action="move"/>
<Text font="default_font" width="70" x="287" y="79" text="$T" color="#000000"/>
<Button x="42" y="42" up="preferences" down="preferences_onclick" over="preferences" action="dialogs.prefs()" tooltiptext="Preferences"/>
<Button x="17" y="64" up="stop" down="stop_onclick" over="stop" action="vlc.stop()" tooltiptext="Stop"/>
<Layout id="playlistLayout" width="410" height="250" minwidth="200" minheight="150" maxwidth="1000" maxheight="800">
<Group x="0" y="0">
<Anchor x="0" y="0" points="(0,0)" priority="50"/>
- <Image image="playlist1" x="0" y="0" lefttop="lefttop" rightbottom="lefttop" onclick="move"/>
- <Image image="playlist2" x="17" y="0" lefttop="lefttop" rightbottom="righttop" onclick="move"/>
- <Image image="playlist3" x="350" y="0" lefttop="righttop" rightbottom="righttop" onclick="move"/>
- <Image image="playlist4" x="0" y="70" lefttop="lefttop" rightbottom="leftbottom" onclick="move"/>
- <Image image="playlist6" x="350" y="70" lefttop="righttop" rightbottom="rightbottom" onclick="move"/>
- <Image image="playlist7" x="0" y="200" lefttop="leftbottom" rightbottom="leftbottom" onclick="move"/>
- <Image image="playlist8" x="17" y="200" lefttop="leftbottom" rightbottom="rightbottom" onclick="move"/>
- <Image image="playlist9" x="350" y="200" lefttop="rightbottom" rightbottom="rightbottom" onclick="move"/>
- <Image image="resize" x="392" y="232" lefttop="rightbottom" rightbottom="rightbottom" onclick="resize"/>
+ <Image image="playlist1" x="0" y="0" lefttop="lefttop" rightbottom="lefttop" action="move"/>
+ <Image image="playlist2" x="17" y="0" lefttop="lefttop" rightbottom="righttop" action="move"/>
+ <Image image="playlist3" x="350" y="0" lefttop="righttop" rightbottom="righttop" action="move"/>
+ <Image image="playlist4" x="0" y="70" lefttop="lefttop" rightbottom="leftbottom" action="move"/>
+ <Image image="playlist6" x="350" y="70" lefttop="righttop" rightbottom="rightbottom" action="move"/>
+ <Image image="playlist7" x="0" y="200" lefttop="leftbottom" rightbottom="leftbottom" action="move"/>
+ <Image image="playlist8" x="17" y="200" lefttop="leftbottom" rightbottom="rightbottom" action="move"/>
+ <Image image="playlist9" x="350" y="200" lefttop="rightbottom" rightbottom="rightbottom" action="move"/>
+ <Image image="resize" x="392" y="232" lefttop="rightbottom" rightbottom="rightbottom" action="resize"/>
<Button x="374" y="12" lefttop="righttop" rightbottom="righttop" up="add_item" down="add_item_onclick" over="add_item" action="playlist.add()" tooltiptext="Add item"/>
<Button x="374" y="40" up="delete_item" lefttop="righttop" rightbottom="righttop" down="delete_item_onclick" over="delete_item" action="playlist.del()" tooltiptext="Del item"/>