All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.github.humbleui.jwm.MouseButton Maven / Gradle / Ivy

There is a newer version: 0.2.6
Show newest version
package io.github.humbleui.jwm;

import org.jetbrains.annotations.*;

public enum MouseButton {
    PRIMARY   (1 << 0),
    SECONDARY (1 << 1),
    MIDDLE    (1 << 2),
    BACK      (1 << 3),
    FORWARD   (1 << 4);

    @ApiStatus.Internal public final int _mask;

    private MouseButton(int mask) {
        _mask = mask;
    }

    @ApiStatus.Internal public static final MouseButton[] _values = values();

    public static MouseButton makeFromInt(int v) {
        return _values[Integer.numberOfTrailingZeros(v)];
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy