Los errores en VR-VIEW provocan en la mayoría de los casos un bloqueo del sistema y un reinicio de la Raspberry PI. En algunos casos, incluso la destrucción de la imagen SD.
Aquí obtendrá un bloqueo y reinicio de la Raspberry PI.
Errors on VR-VIEW gives on the majority of cases a crash of the system and reset of the Raspberry PI. On some cases even destruction of SD image.
Here you will obtain a crash ans reset of the Raspberry PI.
test.pi
Code: Select all
class Test implements GL_Program
{
properties:
vista = null;
function Start()
{
AddScriptPackage("scripts/");
console = GetEngine().GetDOS(true).GetConsole();
vista = new Vista(this);
console.PrintLn("Ok test.pi");
::Start();
End(0);
}
}vista.pi
Code: Select all
class Vista implements Task
{
function Init()
{
_wnd = app.GetEngine().GetDesktop().GetActiveWindow();
_mdi = _wnd.CreateMDI(0, 0, 100, 100);
_mdi.CenterToDesktop();
_button = _mdi.CreateButton(0, 0, 100, -1);
_button.SetText("Play");
_button.SetOnClick(this, "OnPlay");
_button.AlignToParent(UI_BOTTOM | UI_RIGHT, 5);
}
function OnPlay(_sender, _event, _params)
{
console = app.GetEngine().GetDOS(true).GetConsole();
//Esto borraría nuestro MDI
//delete _sender.GetWindow();
_sender.hola();
console.PrintLn("Ok vista.pi");
//app.End(0);
}
}