Treeview active is one place off

Discuss GUI programming with the RapaGUI plugin here
SamuraiCrow
Posts: 475
Joined: Fri May 15, 2015 5:15 pm
Location: Waterville, Minnesota USA

Re: Treeview active is one place off

Post by SamuraiCrow »

@emeck

The test_mui.hws listing in your previous post is not what it should be. ;)
I'm on registered MorphOS using FlowStudio.
User avatar
emeck
Posts: 169
Joined: Fri Apr 03, 2015 3:17 pm

Re: Treeview active is one place off

Post by emeck »

@SamuraiCrow

:oops: Right, thank you

test.xml:

Code: Select all

<?xml version="1.0" encoding="iso-8859-1"?>
<application id="app_test" base="APPTEST">
    <window id="win_test" title="Listtree" muiid="MAIN" notify="closerequest">
        <hgroup>
            <listtree id="lt_test" notify="active">
                <node id="nd1" name="node1"></node>
                <node id="nd2" name="node2"></node>
                <node id="nd3" name="node3"></node>
            </listtree>
        </hgroup>
    </window>
</application>
test.hws:

Code: Select all

@DISPLAY {Hidden = True}

Function p_EventHandler(msg)
    Switch msg.Class
    Case "Window":
        Switch msg.Attribute
        Case "CloseRequest":
            End()
        EndSwitch
    Case "Listtree":
        Switch msg.Attribute
        Case "Active":
            DebugPrint(mui.Get("lt_test", "active"))
        EndSwitch
    EndSwitch
EndFunction

InstallEventHandler({MUIRoyale = p_EventHandler})
mui.CreateGUI(FileToString("test.xml"))

Repeat
    WaitEvent
Forever
PowerBook 5.2 MorphOS 3.15
PowerBook 5.8 MorphOS 3.15
Amiga 1200 BPPC/BVision AOS4.1 FE
User avatar
airsoftsoftwair
Posts: 5433
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Treeview active is one place off

Post by airsoftsoftwair »

Ok, looks like a bug. Will be fixed.
Post Reply