Skip to content

Incorrect Action Executed In OMList.doAction() #55

@jose-m-torres

Description

@jose-m-torres

In the OMList.doAction() method the OMGraphicConstants.LOWER_TO_BOTTOM_GRAPHIC_MASK action calls the moveIndexedOneToBottom() method instead of moveIndexedToBottom().

Both OMGraphicConstants.LOWER_TO_BOTTOM_GRAPHIC_MASK and OMGraphicConstants.LOWER_GRAPHIC_MASK currently perform the same action to moveIndexedOneToBottom().

I verified that correctly calling moveIndexedToBottom() when the mask is set to OMGraphicConstants.LOWER_TO_BOTTOM_GRAPHIC_MASK works as expected.

The issue exists in the currently available download version, OpenMap 5.1.15.

The correction is the following inside the OMList.doAction() method:

if (action.isMask(LOWER_TO_BOTTOM_GRAPHIC_MASK)) {
    Debug.message("omgl", "OMGraphicList.doAction: lowering graphic to bottom");
    moveIndexedToBottom(i); // -> Corrected by Jose M. Torres
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions