Skip to content

In Button.cpp, the doubleclickFound flag is not cleared #5

@mrtktabornsr

Description

@mrtktabornsr

In Button.cpp, the doubleclickFound flag is not cleared until the next time the button is pressed. The Button::isDoubleClicked() member will return true every time it is called until the button is pressed again. The Button::isDoubleClicked() member could be used to clear the flag once it is read.

bool Button::isDoubleClicked(bool proc)
{
bool currentFlagState ;
if(proc) process();
currentFlagState = doubleclickFound; //-------- remember the current flag state
doubleclickFound = false; //-------- clear the doubleclickFound flag
return currentFlagState; //------------ return the actual dooubleclick state
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions