<html>
<head>
<link rel="stylesheet" type="text/css" href="../../resources/css/ext-all.css" />
<script type="text/javascript" src="../../adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="../../ext-all.js"></script>
<script language="javascript" type="text/javascript">
Ext.onReady(function(){
var action = new Ext.Action({
text: 'Click Me',
handler: function(){
Ext.Msg.alert('ClickTitle', 'You Clicked me.');
}
});
var btn = new Ext.CycleButton({
showText: true,
prependText: 'View as ',
items: [{
text:'text only',
checked:true
},{
text:'HTML'
}],
changeHandler:function(btn, item){
Ext.Msg.alert('Change View', item.text);
}
});
var panel = new Ext.Panel({
title: 'Actions',
width:500,
height:300,
tbar: [
action,
{
text: 'Action Menu',
menu: [action]
}
],
items : [btn],
renderTo : Ext.getBody()
});
})
</script>
</head>
<body>
</html>