Discussion:
reparent menu item
(too old to reply)
Leon Davis
2017-06-18 03:25:40 UTC
Permalink
Using Gambas v3.9.2 and GTK+3

Is there a safe way to reparent a menu item during runtime? Any help would
be greatly appreciated.

Leon
Charlie
2017-06-18 09:48:40 UTC
Permalink
Can you supply more detail and an example of what you are trying to do?



-----
Check out www.gambas.one
--
View this message in context: http://gambas.8142.n7.nabble.com/reparent-menu-item-tp59386p59397.html
Sent from the gambas-user mailing list archive at Nabble.com.
Leon Davis
2017-06-18 14:52:22 UTC
Permalink
I have created a form with containing a component I designed. When the
program is started the menu is created: MenuItem = new Menu(FormMain) as
"FileMenu" and is displayed as a text menu of the form. There is also a
context menu that is created for when the user right clicks on the control:
MenuItem = new Menu(Control) as "PopupMenu". One of the options I want to
present is to the user is to move the "FileMenu" to the "PopupMenu" so that
the "FileMenu" is no longer displayed on the form but on the "PopupMenu".
Post by Charlie
Can you supply more detail and an example of what you are trying to do?
-----
Check out www.gambas.one
--
View this message in context: http://gambas.8142.n7.nabble.
com/reparent-menu-item-tp59386p59397.html
Sent from the gambas-user mailing list archive at Nabble.com.
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
https://lists.sourceforge.net/lists/listinfo/gambas-user
Fabien Bodard
2017-07-11 07:08:57 UTC
Permalink
ok so just set the filemenu(parent item) invisible and then call the
same menu with filemenu.popup.

All menus are contained by the form parent... just they are visible or not.
Post by Leon Davis
I have created a form with containing a component I designed. When the
program is started the menu is created: MenuItem = new Menu(FormMain) as
"FileMenu" and is displayed as a text menu of the form. There is also a
MenuItem = new Menu(Control) as "PopupMenu". One of the options I want to
present is to the user is to move the "FileMenu" to the "PopupMenu" so that
the "FileMenu" is no longer displayed on the form but on the "PopupMenu".
Post by Charlie
Can you supply more detail and an example of what you are trying to do?
-----
Check out www.gambas.one
--
View this message in context: http://gambas.8142.n7.nabble.
com/reparent-menu-item-tp59386p59397.html
Sent from the gambas-user mailing list archive at Nabble.com.
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
https://lists.sourceforge.net/lists/listinfo/gambas-user
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
https://lists.sourceforge.net/lists/listinfo/gambas-user
--
Fabien Bodard
Continue reading on narkive:
Loading...