vernid
11-01-2007, 01:45 AM
Hi,
I have a view which contains subviews. I have defined a contextmenu on the main view and I would like that all subviews have it too.
So, I would like in fact that all subviews inherite the contextmenu from its parent.
Code example:
<canvas>
<view name="v" width="50%" height="50%" bgcolor="blue">
<handler name="oninit">
var cm1 = new LzContextMenu(); cm1.hideBuiltInItems();
this.setContextMenu(cm1);
</handler>
<view width="50%" height="50%" bgcolor="red">
</view>
</view>
</canvas>
I would like that the red view got my context menu.
Is there a way to say that a view must inherite from the parent menu without creating it from the view (oninit)?
Thanks
Dominique
I have a view which contains subviews. I have defined a contextmenu on the main view and I would like that all subviews have it too.
So, I would like in fact that all subviews inherite the contextmenu from its parent.
Code example:
<canvas>
<view name="v" width="50%" height="50%" bgcolor="blue">
<handler name="oninit">
var cm1 = new LzContextMenu(); cm1.hideBuiltInItems();
this.setContextMenu(cm1);
</handler>
<view width="50%" height="50%" bgcolor="red">
</view>
</view>
</canvas>
I would like that the red view got my context menu.
Is there a way to say that a view must inherite from the parent menu without creating it from the view (oninit)?
Thanks
Dominique