Kaydet (Commit) a990ccca authored tarafından Daniel Boelzle's avatar Daniel Boelzle

#91149# support events for titledbox, text

üst 342d1120
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Id: dialog.dtd,v 1.16 2001-08-07 10:55:46 dbo Exp $
$Id: dialog.dtd,v 1.17 2001-08-16 14:11:24 dbo Exp $
The Contents of this file are made available subject to the terms of
either of the following licenses
......@@ -218,14 +218,14 @@
dlg:tabstop %boolean; #IMPLIED
>
<!ELEMENT dlg:titledbox (dlg:title?, dlg:radio*, (%control;)*)>
<!ELEMENT dlg:titledbox (dlg:title?, dlg:radio*, (%control;)*, (%event;)*)>
<!ATTLIST dlg:titledbox %default-attributes;
>
<!ELEMENT dlg:title EMPTY>
<!ATTLIST dlg:title dlg:value CDATA #IMPLIED
>
<!ELEMENT dlg:text EMPTY>
<!ELEMENT dlg:text ((%event;)*)>
<!ATTLIST dlg:text %default-attributes;
dlg:align (left|center|right|none) #IMPLIED
dlg:multiline %boolean; #IMPLIED
......
......@@ -2,9 +2,9 @@
*
* $RCSfile: xmldlg_expmodels.cxx,v $
*
* $Revision: 1.12 $
* $Revision: 1.13 $
*
* last change: $Author: dbo $ $Date: 2001-08-07 10:55:46 $
* last change: $Author: dbo $ $Date: 2001-08-16 14:11:24 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
......@@ -345,6 +345,7 @@ void ElementDescriptor::readGroupBoxModel( StyleBag * all_styles )
aTitle );
addSubElement( title );
}
readEvents();
}
//__________________________________________________________________________________________________
void ElementDescriptor::readFixedTextModel( StyleBag * all_styles )
......@@ -374,6 +375,7 @@ void ElementDescriptor::readFixedTextModel( StyleBag * all_styles )
OUString( RTL_CONSTASCII_USTRINGPARAM(XMLNS_DIALOGS_PREFIX ":multiline") ) );
readAlignAttr( OUString( RTL_CONSTASCII_USTRINGPARAM("Align") ),
OUString( RTL_CONSTASCII_USTRINGPARAM(XMLNS_DIALOGS_PREFIX ":align") ) );
readEvents();
}
//__________________________________________________________________________________________________
void ElementDescriptor::readEditModel( StyleBag * all_styles )
......
......@@ -2,9 +2,9 @@
*
* $RCSfile: xmldlg_impmodels.cxx,v $
*
* $Revision: 1.18 $
* $Revision: 1.19 $
*
* last change: $Author: dbo $ $Date: 2001-08-07 10:55:46 $
* last change: $Author: dbo $ $Date: 2001-08-16 14:11:24 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
......@@ -852,6 +852,11 @@ Reference< xml::XImportContext > TitledBoxElement::createChildContext(
_radios.push_back( xRet );
return xRet;
}
// event
else if (isEventElement( nUid, rLocalName ))
{
return new EventElement( nUid, rLocalName, xAttributes, this, _pImport );
}
else
{
return BulletinBoardElement::createChildContext( nUid, rLocalName, xAttributes );
......@@ -882,6 +887,7 @@ void TitledBoxElement::endElement()
xControlModel->setPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Label") ),
makeAny( _label ) );
}
ctx.importEvents( _events );
}
// create radios AFTER group box!
......
......@@ -66,16 +66,21 @@
</radiogroup>
<titledbox id="groupbox1" left="250" top="250" width="120" height="100">
<script:listener-event script:macro-name="ExecutingMacro" script:location="application" script:language="StarBasic" script:listener-type="com.sun.star.awt.XMouseListener" script:listener-method="mouseEntered"/>
<title value="grouped"/>
<radio id="radio5" value="default radio" left="5" top="15" width="100" height="20"/>
<radio id="radio7" value="unchecked" left="5" top="35" width="100" height="20" checked="false"/>
<radio id="radio8" value="checked" left="5" top="55" width="100" height="20" checked="true"/>
</titledbox>
<text id="fixed1" left="50" top="520" width="180" height="20" value="fixed text is here..." multiline="true" align="center"/>
<text id="fixed1" left="50" top="520" width="180" height="20" value="fixed text is here..." multiline="true" align="center">
<script:listener-event script:macro-name="ExecutingMacro" script:location="application" script:language="StarBasic" script:listener-type="com.sun.star.awt.XMouseListener" script:listener-method="mouseEntered"/>
</text>
<textfield id="field1" left="250" top="520" width="50" height="40" value="edit no text here..." readonly="true" vscroll="true" multiline="true" align="right" style-id="no_border"/>
<textfield id="field2" left="320" top="520" width="50" height="40" value="hidden text" hscroll="true" echochar="*" align="left"/>
<img id="image1" left="50" top="585" width="80" height="20" src="../../test/w3c.jpg"/>
<img id="image1" left="50" top="585" width="80" height="20" src="../../test/w3c.jpg">
<script:listener-event script:macro-name="ExecutingMacro" script:location="application" script:language="StarBasic" script:listener-type="com.sun.star.awt.XMouseListener" script:listener-method="mouseEntered"/>
</img>
<filecontrol id="file1" left="150" top="585" width="100" height="20" value="../../test/w3c.jpg"/>
<datefield id="datefield1" left="20" top="610" width="100" height="20" date-format="short_DDMMYY" spin="true" value="20010301"/>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment