Donc voilà la base (un peu à l'arrache)
Code : Tout sélectionner
Global x = 10, y = 10
Declare Move()
OpenWindow(0, 0, 0, 500, 500, "ContainerGadget", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
ButtonGadget(1, 320, 15, 70, 25, "Add Gadgets")
ContainerGadget(0,x, y, 300, 130, #PB_Container_Raised)
CloseGadgetList()
Repeat
EventID = WaitWindowEvent()
If EventID = #PB_Event_Gadget And EventGadget() = 1
OpenGadgetList(0)
ButtonGadget(#PB_Any, 10, 15, 80, 24, "Button 1")
ButtonGadget(#PB_Any, 95, 15, 80, 24, "Button 2")
TextGadget(#PB_Any, 10, 70, 250, 20, "Nous sommes bien dans le Container !")
CloseGadgetList()
AddWindowTimer(0, 0, 200)
EndIf
If EventID = #PB_Event_Timer
Move()
EndIf
Until EventID = #PB_Event_CloseWindow
Procedure Move()
y + 5
ResizeGadget(0, x, y, #PB_Ignore, #PB_Ignore)
If y = 255
RemoveWindowTimer(0, 0)
EndIf
EndProcedure